This commit is contained in:
@@ -233,6 +233,21 @@ export default {
|
||||
return ret;
|
||||
},
|
||||
///////////////////////////////////////////////
|
||||
// UTC ISO 8601 string add minutes
|
||||
// and return as UTC ISO 8601 string
|
||||
// (used to set automatic / default adjusted times)
|
||||
//
|
||||
addMinutesToUTC8601String(val, minutes) {
|
||||
if (!val || val == "" || minutes == null || minutes == 0) {
|
||||
return val;
|
||||
}
|
||||
//instantiate a luxon date object from val which is assumed to be an iso string
|
||||
let dt = window.$gz.DateTime.fromISO(val);
|
||||
//add minutes
|
||||
dt = dt.plus({ minutes: minutes });
|
||||
return dt.toUTC().toString();
|
||||
},
|
||||
///////////////////////////////////////////////
|
||||
// Local now timestamp converted to timeZoneName
|
||||
// and output as ISO 8601
|
||||
// (used to inform server of local client time)
|
||||
|
||||
Reference in New Issue
Block a user