Fix handling of null ORWORB FASTUSER meta field
This commit is contained in:
parent
d7d716cc27
commit
83c9f11c73
@ -157,18 +157,20 @@ export const d_parse_orderoptions_meddose = data => {
|
||||
};
|
||||
|
||||
export const d_parse_notifications_fastuser = data => d_split(data, '^', 'info', 'patient', 'location', 'urgency', 'time', 'message', 'unk_6', 'meta', 'unk_7', 'unk_8').map(row => {
|
||||
var meta = row.meta.split(';');
|
||||
var xqaid = row.meta_xqaid = meta[0];
|
||||
row.meta_duz = meta[1];
|
||||
row.meta_time = +meta[2];
|
||||
if(xqaid.startsWith('OR,')) {
|
||||
xqaid = xqaid.split(',');
|
||||
row.meta_source = xqaid[0];
|
||||
row.meta_dfn = xqaid[1];
|
||||
row.meta_ien = xqaid[2]; // file 100.9 IEN
|
||||
} else if(xqaid.startsWith('TIU')) {
|
||||
row.meta_source = 'TIU';
|
||||
row.meta_ien = xqaid.substring(3); // document IEN (DA)
|
||||
if(row.meta) {
|
||||
var meta = row.meta.split(';');
|
||||
var xqaid = row.meta_xqaid = meta[0];
|
||||
row.meta_duz = meta[1];
|
||||
row.meta_time = +meta[2];
|
||||
if(xqaid.startsWith('OR,')) {
|
||||
xqaid = xqaid.split(',');
|
||||
row.meta_source = xqaid[0];
|
||||
row.meta_dfn = xqaid[1];
|
||||
row.meta_ien = xqaid[2]; // file 100.9 IEN
|
||||
} else if(xqaid.startsWith('TIU')) {
|
||||
row.meta_source = 'TIU';
|
||||
row.meta_ien = xqaid.substring(3); // document IEN (DA)
|
||||
}
|
||||
}
|
||||
return row;
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user