<div class="flex flex-col gap-6">
  <app-card-data cardTitle="اطلاعات مشتری" [(editMode)]="editMode">
    <ng-template #moreActions> </ng-template>
    <div class="flex flex-col gap-4">
      <div class="listKeyValue">
        <app-key-value label="نام مشتری" [value]="consumer()?.name" />
        <app-key-value label="وضعیت" [value]="consumer()?.status?.translate" />
        <app-key-value label="نوع مشتری" [value]="consumer()?.type?.translate" />

        @if (consumer()?.type?.value === "LEGAL") {
          <app-key-value label="شناسه ملی" [value]="consumer()?.legal?.registration_code" />
        } @else {
          <app-key-value label="شماره موبایل" [value]="consumer()?.individual?.mobile_number" />
          <app-key-value label="کد ملی" [value]="consumer()?.individual?.national_code" />
        }
      </div>
    </div>
  </app-card-data>

  <superAdmin-consumer-account-list [consumerId]="consumerId()" />
  <superAdmin-consumer-businessActivities-list [consumerId]="consumerId()" />

  <superAdmin-consumer-form
    [(visible)]="editMode"
    [editMode]="true"
    [consumerId]="consumerId()"
    [initialValues]="consumer() || undefined"
    (onSubmit)="getData()"
  />
</div>
