updated to new model format
This commit is contained in:
@ -238,7 +238,7 @@
|
||||
[(ngModel)]="measurement.measurement_template"
|
||||
(ngModelChange)="clearMeasurement(gIndex, mIndex)">
|
||||
<option [value]="sample.condition.condition_template">
|
||||
{{d.id.measurementTemplates[measurement.measurement_template].name}} - current
|
||||
{{d.id.measurementTemplates[measurement.measurement_template].name}} - old
|
||||
</option>
|
||||
<option *ngFor="let m of d.latest.measurementTemplates" [value]="m._id">{{m.name}}</option>
|
||||
</rb-form-select>
|
||||
@ -330,7 +330,7 @@
|
||||
<ng-template #modalDeleteConfirm>
|
||||
<rb-alert alertTitle="Are you sure?" type="danger" [okBtnLabel]="'Delete sample' + (samples.length > 1 ? 's' : '')"
|
||||
cancelBtnLabel="Cancel">
|
||||
Do you really want to delete {{samples.length > 1 ? 'these samples' : 'this sample'}}?
|
||||
Do you really want to delete {{(samples.length > 1 ? 'samples ' : 'sample ') + sampleNames()}}?
|
||||
</rb-alert>
|
||||
</ng-template>
|
||||
|
||||
|
@ -613,6 +613,10 @@ export class SampleComponent implements OnInit, AfterContentChecked {
|
||||
return this.sampleReferenceList.bind(this);
|
||||
}
|
||||
|
||||
sampleNames() {
|
||||
return this.samples.map(e => e.number).join(', ');
|
||||
}
|
||||
|
||||
uniqueCfValues(index) { // returns all names until index for unique check
|
||||
return this.customFields ? this.customFields.slice(0, index).map(e => e[0]) : [];
|
||||
}
|
||||
|
Reference in New Issue
Block a user