Compare commits
3 Commits
2b7ae75cc3
...
73cfbd5bbd
Author | SHA1 | Date | |
---|---|---|---|
73cfbd5bbd | |||
c53a9654b5 | |||
ec841b9591 |
@ -97,14 +97,19 @@
|
|||||||
methods: {
|
methods: {
|
||||||
strHashHSL,
|
strHashHSL,
|
||||||
gettags(row) {
|
gettags(row) {
|
||||||
var res = {}, matches;
|
var res = {}, re, matches;
|
||||||
if((row.RESOURCENAME) && (matches = row.RESOURCENAME.replace(/\W+/g, '-').replace(/^-+|-+$/g, ''))) res[matches.toLowerCase()] = matches;
|
if((row.RESOURCENAME) && (matches = row.RESOURCENAME.replace(/\W+/g, '-').replace(/^-+|-+$/g, ''))) res[matches.toLowerCase()] = matches;
|
||||||
if(row.WALKIN != '0') res['walkin'] = 'WALKIN';
|
if(row.WALKIN != '0') res['walkin'] = 'WALKIN';
|
||||||
if(row.CANCELLED != '0') res['cancelled'] = 'CANCELLED';
|
if(row.CANCELLED != '0') res['cancelled'] = 'CANCELLED';
|
||||||
else if(row.NOSHOW != '0') res['noshow'] = 'NOSHOW';
|
else if(row.NOSHOW != '0') res['noshow'] = 'NOSHOW';
|
||||||
else if(row.CHECKOUT) res['checkedout'] = 'CHECKEDOUT';
|
else if(row.CHECKOUT) res['checkedout'] = 'CHECKEDOUT';
|
||||||
else if(row.CHECKIN) res['checkedin'] = 'CHECKEDIN';
|
else if(row.CHECKIN) res['checkedin'] = 'CHECKEDIN';
|
||||||
if((row.NOTE) && (matches = row.NOTE.match(/#[0-9a-z][\w-]*/gi))) matches.reduce((acc, val) => (acc[val.substring(1).toLowerCase()] = val.substring(1), acc), res);
|
if(row.NOTE) {
|
||||||
|
re = /#([0-9a-z][\w-]*)/gi;
|
||||||
|
while(matches = re.exec(row.NOTE)) res[matches[1].toLowerCase()] = matches[1];
|
||||||
|
re = /Dr[\.\s]*\b([a-z][\w-]*)/gi;
|
||||||
|
while(matches = re.exec(row.NOTE)) res[matches[1].toLowerCase()] = matches[1];
|
||||||
|
}
|
||||||
return res;
|
return res;
|
||||||
},
|
},
|
||||||
filter_conj(tags) {
|
filter_conj(tags) {
|
||||||
@ -130,6 +135,7 @@
|
|||||||
this.$watch(
|
this.$watch(
|
||||||
() => (this.client, this.selection, this.date_begin, this.date_end, {}),
|
() => (this.client, this.selection, this.date_begin, this.date_end, {}),
|
||||||
debounce(async () => {
|
debounce(async () => {
|
||||||
|
this.filter = {};
|
||||||
window.clearTimeout(this.timer);
|
window.clearTimeout(this.timer);
|
||||||
this.update();
|
this.update();
|
||||||
}, 500)
|
}, 500)
|
||||||
|
@ -339,7 +339,7 @@ export function Client(cid, secret) {
|
|||||||
if(localstate.practitioner) delete localstate.practitioner;
|
if(localstate.practitioner) delete localstate.practitioner;
|
||||||
};
|
};
|
||||||
|
|
||||||
this.XWB_IM_HERE = unwrapped(logged(() => this.call({ method: 'XWB_IM_HERE', ttl: 30 }), 'XWB_IM_HERE'));
|
this.XWB_IM_HERE = unwrapped(logged(() => this.call({ method: 'XWB_IM_HERE', ttl: 30, stale: false }), 'XWB_IM_HERE'));
|
||||||
|
|
||||||
this.XUS_INTRO_MSG = memoized(unwrapped(logged(() => this.callctx(['XUCOMMAND'], 'XUS_INTRO_MSG'), 'XUS_INTRO_MSG')));
|
this.XUS_INTRO_MSG = memoized(unwrapped(logged(() => this.callctx(['XUCOMMAND'], 'XUS_INTRO_MSG'), 'XUS_INTRO_MSG')));
|
||||||
this.XWB_GET_BROKER_INFO = memoized(unwrapped(logged(() => this.callctx(['XUCOMMAND'], 'XWB_GET_BROKER_INFO'), 'XWB_GET_BROKER_INFO')));
|
this.XWB_GET_BROKER_INFO = memoized(unwrapped(logged(() => this.callctx(['XUCOMMAND'], 'XWB_GET_BROKER_INFO'), 'XWB_GET_BROKER_INFO')));
|
||||||
@ -463,7 +463,7 @@ Client.fromCookie = async function(secret, defaulthost='vista.northport.med.va.g
|
|||||||
console.log('Using saved secret and connection', secret);
|
console.log('Using saved secret and connection', secret);
|
||||||
var cid = localstate.cid;
|
var cid = localstate.cid;
|
||||||
var client = Client.fromID(cid, secret);
|
var client = Client.fromID(cid, secret);
|
||||||
if((await vista.call(cid, { method: 'XWB_IM_HERE', ttl: 30, id: Date.now() })).result == '1') {
|
if((await vista.call(cid, { method: 'XWB_IM_HERE', ttl: 0, stale: false, id: Date.now() })).result == '1') {
|
||||||
var server = await client.serverinfo();
|
var server = await client.serverinfo();
|
||||||
if((host[0] == server.result.host) && (host[1] == server.result.port)) {
|
if((host[0] == server.result.host) && (host[1] == server.result.port)) {
|
||||||
localstate.host = host.join(':');
|
localstate.host = host.join(':');
|
||||||
|
Loading…
Reference in New Issue
Block a user