| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one or more |
| contributor license agreements. See the NOTICE file distributed with |
| this work for additional information regarding copyright ownership. |
| The ASF licenses this file to You under the Apache License, Version 2.0 |
| (the "License"); you may not use this file except in compliance with |
| the License. You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
| --> |
| |
| <td-steps mode="'vertical'"> |
| <td-step #detailsStep label="{{'Member details' | translate}}" [state]="detailForm.valid ? 'complete' : detailForm.pristine ? 'none' : 'required'"> |
| |
| <fims-customer-detail-form #detailForm [formData]="detailFormData" [editMode]="editMode"></fims-customer-detail-form> |
| |
| <ng-template td-step-actions> |
| <fims-form-continue-action (onContinue)="addressStep.open()"></fims-form-continue-action> |
| </ng-template> |
| </td-step> |
| |
| <td-step #addressStep label="{{'Member Address' | translate}}" [state]="addressForm.valid ? 'complete' : addressForm.pristine ? 'none' : 'required'"> |
| |
| <fims-address-form #addressForm [formData]="addressFormData"></fims-address-form> |
| |
| <ng-template td-step-actions> |
| <fims-form-continue-action (onContinue)="contactStep.open()"></fims-form-continue-action> |
| </ng-template> |
| </td-step> |
| |
| <td-step #contactStep label="{{'Member contact(optional)' | translate}}" [state]="contactForm.pristine ? 'none' : contactForm.valid ? 'completed' : 'required'"> |
| |
| <fims-customer-contact-form #contactForm [formData]="contactFormData"></fims-customer-contact-form> |
| |
| <ng-template td-step-actions> |
| <fims-form-continue-action (onContinue)="officeStep.open()"></fims-form-continue-action> |
| </ng-template> |
| </td-step> |
| |
| <td-step #officeStep label="{{'Assign member to office(optional)' | translate}}" |
| [state]="selectedOffices.length ? 'complete' : 'none'"> |
| |
| <fims-customer-offices-form [preSelection]="selectedOffices" (onSelectionChange)="selectOffice($event)"></fims-customer-offices-form> |
| |
| <ng-template td-step-actions> |
| <fims-form-continue-action (onContinue)="employeeStep.open()"></fims-form-continue-action> |
| </ng-template> |
| <ng-template td-step-summary *ngIf="selectedOffices && selectedOffices.length > 0" [translate]="'Member is assigned to office:'" [translateParams]="{value: selectedOffices[0]}"> |
| </ng-template> |
| </td-step> |
| |
| <td-step #employeeStep label="{{'Assign member to employee(optional)' | translate}}" |
| [state]="selectedEmployees.length ? 'complete' : 'none'"> |
| |
| <fims-customer-employees-form [preSelection]="selectedEmployees" (onSelectionChange)="selectEmployee($event)"></fims-customer-employees-form> |
| |
| <ng-template td-step-actions> |
| <fims-form-continue-action (onContinue)="customFieldsStep.open()"></fims-form-continue-action> |
| </ng-template> |
| </td-step> |
| |
| <td-step #customFieldsStep label="{{'Custom fields' | translate}}" [state]="customFieldsForm.pristine ? 'none' : customFieldsForm.valid ? 'completed' : 'required'"> |
| <fims-custom-fields-component |
| #customFieldsForm |
| [catalog]="catalog" |
| [formData]="customFieldsFormData"> |
| </fims-custom-fields-component> |
| </td-step> |
| |
| <td-step label="{{'Final step' | translate}}" [state]="'complete'"> |
| <ng-template td-step-summary> |
| <fims-form-final-action |
| [resourceName]="'MEMBER'" |
| [editMode]="editMode" |
| [disabled]="!isValid" |
| (onCancel)="cancel()" |
| (onSave)="save()"> |
| </fims-form-final-action> |
| </ng-template> |
| </td-step> |
| </td-steps> |