Update custom1 report: modify test-info layout and add department-based instrument mapping
This commit is contained in:
parent
7dbc288553
commit
2392b4ba25
@ -81,22 +81,22 @@
|
|||||||
<div class="info-section">
|
<div class="info-section">
|
||||||
<table class="info-table">
|
<table class="info-table">
|
||||||
<tr>
|
<tr>
|
||||||
<td class="info-label">TEST NAME</td>
|
<td class="info-label">Institution</td>
|
||||||
|
<td class="value">Laboratorium Trisensa</td>
|
||||||
|
<td class="info-label">Instrument</td>
|
||||||
|
<td class="value" x-text="instrumentName"></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="info-label">Test</td>
|
||||||
<td class="value" x-text="testName"></td>
|
<td class="value" x-text="testName"></td>
|
||||||
<td class="info-label">NO. LOT</td>
|
<td class="info-label">Control</td>
|
||||||
<td class="value" x-text="controlLotNumber"></td>
|
<td class="value" x-text="controlNames"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="info-label">METHOD</td>
|
<td class="info-label">Method</td>
|
||||||
<td class="value" x-text="testMethod"></td>
|
<td class="value" x-text="testMethod"></td>
|
||||||
<td class="info-label">EXP</td>
|
<td class="info-label">Lot-No</td>
|
||||||
<td class="value" x-text="expiryDate"></td>
|
<td class="value" x-text="controlLotNumber"></td>
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td class="info-label">PERIOD</td>
|
|
||||||
<td class="value" x-text="periodDisplay"></td>
|
|
||||||
<td class="info-label">Unit</td>
|
|
||||||
<td class="value" x-text="testUnit"></td>
|
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
@ -934,6 +934,26 @@
|
|||||||
return this.testData ? this.testData.testName : '';
|
return this.testData ? this.testData.testName : '';
|
||||||
},
|
},
|
||||||
|
|
||||||
|
get institutionName() {
|
||||||
|
return this.testData ? (this.testData.institutionName || 'Trisensa Diagnostic Centre') : 'Trisensa Diagnostic Centre';
|
||||||
|
},
|
||||||
|
|
||||||
|
get instrumentName() {
|
||||||
|
if (!this.testData) return '-';
|
||||||
|
if (this.testData.instrumentName) return this.testData.instrumentName;
|
||||||
|
const dept = this.testData.deptName;
|
||||||
|
const mapping = {
|
||||||
|
'Kimia': 'TMS 50i',
|
||||||
|
'Imun': 'Mindray CL900i'
|
||||||
|
};
|
||||||
|
return mapping[dept] || '-';
|
||||||
|
},
|
||||||
|
|
||||||
|
get controlNames() {
|
||||||
|
if (this.controls.length === 0) return '-';
|
||||||
|
return this.controls.map(c => c.controlName).join(', ');
|
||||||
|
},
|
||||||
|
|
||||||
get testCode() {
|
get testCode() {
|
||||||
return this.testData ? (this.testData.testCode || this.testData.testName) : '';
|
return this.testData ? (this.testData.testCode || this.testData.testName) : '';
|
||||||
},
|
},
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user