| .. | .. |
|---|
| 3 | 3 | <button md-icon-button (click)="goBack()" color="accent"> |
|---|
| 4 | 4 | <md-icon>arrow_back</md-icon> |
|---|
| 5 | 5 | </button> |
|---|
| 6 | | - <span class="md-title" [innerText]="form_title"></span> |
|---|
| 6 | + <span [innerText]="form_title"></span> |
|---|
| 7 | 7 | <span flex></span> |
|---|
| 8 | 8 | <button md-icon-button (click)="save()"><md-icon>save</md-icon></button> |
|---|
| 9 | 9 | </md-toolbar> |
|---|
| 10 | | - <!-- |
|---|
| 11 | | - code: 'CICS', |
|---|
| 12 | | - creation_timestamp: 1418384439000, |
|---|
| 13 | | - description: 'Wellbore integrity analysis software', |
|---|
| 14 | | - id: 1, |
|---|
| 15 | | - license_filename: 'config_server.lic', |
|---|
| 16 | | - name: 'CurisIntegrity', |
|---|
| 17 | | - metadata: |
|---|
| 18 | | - [ { key: 'max_docs', |
|---|
| 19 | | - value: '250000', |
|---|
| 20 | | - readonly: true, |
|---|
| 21 | | - mandatory: true } ] |
|---|
| 22 | | -} |
|---|
| 23 | | - --> |
|---|
| 10 | + |
|---|
| 24 | 11 | <div class="margin" layout-align-gt-xs="center start" layout-fill="" layout-gt-xs="row"> |
|---|
| 25 | 12 | <md-card flex="70"> |
|---|
| 26 | 13 | <md-card-title> |
|---|
| .. | .. |
|---|
| 31 | 18 | <form #form="ngForm" class="inset"> |
|---|
| 32 | 19 | <div layout="column" layout-align="start center"> |
|---|
| 33 | 20 | <div layout="row" layout-fill layout-padding> |
|---|
| 34 | | - <field-readonly [value]="data.id" label="field.id" flex="15" *ngIf="!isNew"></field-readonly> |
|---|
| 35 | | - <div layout="column" layout-fill flex> |
|---|
| 21 | + <field-readonly [value]="data.id" label="field.id" flex="10" *ngIf="!isNew"></field-readonly> |
|---|
| 22 | + <div layout="column" layout-fill flex="30"> |
|---|
| 36 | 23 | <md-input-container> |
|---|
| 37 | 24 | <input #firstField mdInput maxLength="50" type="text" [(ngModel)]="data.code" name="code" required [readonly]="!isNew" /> |
|---|
| 38 | 25 | <md-placeholder> |
|---|
| .. | .. |
|---|
| 41 | 28 | </md-input-container> |
|---|
| 42 | 29 | <error-checker [fieldName]="getFieldName('code')" [formField]="form.controls.code"></error-checker> |
|---|
| 43 | 30 | </div> |
|---|
| 44 | | - </div> |
|---|
| 45 | | - <div layout="row" layout-fill layout-padding> |
|---|
| 46 | 31 | <div layout="column" layout-fill flex> |
|---|
| 47 | 32 | <md-input-container flex> |
|---|
| 48 | 33 | <input mdInput type="text" [(ngModel)]="data.name" name="name" required /> |
|---|
| .. | .. |
|---|
| 51 | 36 | </md-placeholder> |
|---|
| 52 | 37 | </md-input-container> |
|---|
| 53 | 38 | <error-checker [fieldName]="getFieldName('name')" [formField]="form.controls.name"></error-checker> |
|---|
| 54 | | - </div> |
|---|
| 55 | | - <div layout="column" layout-fill flex> |
|---|
| 56 | | - <md-input-container flex> |
|---|
| 57 | | - <input mdInput type="text" [(ngModel)]="data.license_filename" name="license_filename" required /> |
|---|
| 58 | | - <md-placeholder> |
|---|
| 59 | | - <span i18n="field.license_filename"></span> |
|---|
| 60 | | - </md-placeholder> |
|---|
| 61 | | - </md-input-container> |
|---|
| 62 | | - <error-checker [fieldName]="getFieldName('license_filename')" [formField]="form.controls.license_filename"></error-checker> |
|---|
| 63 | 39 | </div> |
|---|
| 64 | 40 | </div> |
|---|
| 65 | 41 | <div layout="row" layout-fill layout-padding> |
|---|
| .. | .. |
|---|
| 73 | 49 | </md-input-container> |
|---|
| 74 | 50 | </div> |
|---|
| 75 | 51 | </div> |
|---|
| 76 | | - <div layout="row" layout-fill layout-padding *ngIf="!isNew"> |
|---|
| 77 | | - <field-readonly [value]="data.creation_timestamp | date: 'medium'" label="field.creation_timestamp" flex></field-readonly> |
|---|
| 52 | + <div layout="row" layout-fill layout-padding > |
|---|
| 53 | + <div layout="column" layout-fill flex> |
|---|
| 54 | + <md-select [placeholder]="getFieldName('org_parent_id')" flex [(ngModel)]="data.org_parent_id" name="org_parent_id"> |
|---|
| 55 | + <md-option *ngFor="let org of parentOrganizations" [value]="org.id"> |
|---|
| 56 | + {{org.label}} |
|---|
| 57 | + </md-option> |
|---|
| 58 | + </md-select> |
|---|
| 59 | + <error-checker [fieldName]="getFieldName('org_parent_id')" [formField]="form.controls.org_parent_id"></error-checker> |
|---|
| 60 | + </div> |
|---|
| 78 | 61 | </div> |
|---|
| 79 | | - <metadata-manager addOrDelete="true" editKeys="true" [metadata]="data.metadata" ></metadata-manager> |
|---|
| 62 | + <div layout="row" layout-fill layout-padding > |
|---|
| 63 | + <td-chips flex [mdTooltip]="$L.get('Users with access to this organization')" [placeholder]="$L.get('Select users')" |
|---|
| 64 | + [items]="usernames" [(ngModel)]="data.users_ids" name="users_ids" requireMatch> |
|---|
| 65 | + </td-chips> |
|---|
| 66 | + </div> |
|---|
| 80 | 67 | </div> |
|---|
| 81 | 68 | </form> |
|---|
| 82 | 69 | </md-card-content> |
|---|