ecinc-cloud-moadesktop 9.6.252 → 9.6.254
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/ecmoadesktop.common.js +186 -209
- package/lib/ecmoadesktop.umd.js +189 -212
- package/lib/ecmoadesktop.umd.min.js +5 -5
- package/package.json +1 -1
package/lib/ecmoadesktop.umd.js
CHANGED
|
@@ -251,13 +251,8 @@ module.exports = {
|
|
|
251
251
|
__webpack_require__.r(__webpack_exports__);
|
|
252
252
|
/* harmony import */ var js_cookie__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2215);
|
|
253
253
|
/* harmony import */ var js_cookie__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(js_cookie__WEBPACK_IMPORTED_MODULE_0__);
|
|
254
|
-
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
255
|
-
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
256
|
-
function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
|
|
257
|
-
function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
|
|
258
254
|
|
|
259
255
|
var $parent = '';
|
|
260
|
-
var curInterval = null; // 定时任务
|
|
261
256
|
var timeSpanData = null; // 考勤时段
|
|
262
257
|
var p1 = null; // 打卡位置经纬度
|
|
263
258
|
var gpsScope = null;
|
|
@@ -325,72 +320,54 @@ function getCurAddress(lng, lat) {
|
|
|
325
320
|
});
|
|
326
321
|
}
|
|
327
322
|
|
|
328
|
-
/**
|
|
329
|
-
*地图定位 获取当前位置
|
|
330
|
-
*/
|
|
331
|
-
function getCurLocation() {
|
|
332
|
-
function h5Position(e) {
|
|
333
|
-
if (this.getStatus() == 0) {
|
|
334
|
-
getDis(e.lnglat.lng, e.lnglat.lat);
|
|
335
|
-
getCurAddress(e.lnglat.lng, e.lnglat.lat);
|
|
336
|
-
} else {
|
|
337
|
-
console.log('Geolocation getCurrentPosition status', lo.getStatus());
|
|
338
|
-
$parent.dakaType = dakaType[0];
|
|
339
|
-
}
|
|
340
|
-
}
|
|
341
|
-
var lo = new T.Geolocation();
|
|
342
|
-
lo.getCurrentPosition(h5Position);
|
|
343
|
-
}
|
|
344
323
|
// 定位
|
|
345
324
|
function curLocationAndDis() {
|
|
346
325
|
var device = js_cookie__WEBPACK_IMPORTED_MODULE_0___default().get('device');
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
if (window.mappType === 'ecinc') {
|
|
351
|
-
//APP定位
|
|
352
|
-
$parent.$wv.getLocationInformation(function (res) {
|
|
353
|
-
if (typeof res === 'string') res = JSON.parse(res);
|
|
354
|
-
if (res && res.data) {
|
|
355
|
-
getDis(Number(res.data.longitude), Number(res.data.latitude));
|
|
356
|
-
getCurAddress(Number(res.data.longitude), Number(res.data.latitude));
|
|
357
|
-
} else {
|
|
358
|
-
console.log('$wv getCurrentPosition res =', res);
|
|
359
|
-
$parent.dakaType = dakaType[0];
|
|
360
|
-
}
|
|
361
|
-
});
|
|
362
|
-
curInterval = setInterval(function () {
|
|
326
|
+
return new Promise(function (resolve) {
|
|
327
|
+
if (window.mappType === 'ecinc') {
|
|
328
|
+
//APP定位
|
|
363
329
|
$parent.$wv.getLocationInformation(function (res) {
|
|
364
330
|
if (typeof res === 'string') res = JSON.parse(res);
|
|
365
331
|
if (res && res.data) {
|
|
366
332
|
getDis(Number(res.data.longitude), Number(res.data.latitude));
|
|
367
333
|
getCurAddress(Number(res.data.longitude), Number(res.data.latitude));
|
|
334
|
+
resolve(true);
|
|
368
335
|
} else {
|
|
369
336
|
console.log('$wv getCurrentPosition res =', res);
|
|
370
|
-
|
|
337
|
+
resolve(false);
|
|
371
338
|
}
|
|
372
339
|
});
|
|
373
|
-
}
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
340
|
+
} else if (window.isOpenMapLocation === 1) {
|
|
341
|
+
//H5地图定位
|
|
342
|
+
var h5Position = function h5Position(e) {
|
|
343
|
+
if (this.getStatus() == 0) {
|
|
344
|
+
getDis(e.lnglat.lng, e.lnglat.lat);
|
|
345
|
+
getCurAddress(e.lnglat.lng, e.lnglat.lat);
|
|
346
|
+
resolve(true);
|
|
347
|
+
} else {
|
|
348
|
+
console.log('Geolocation getCurrentPosition status', lo.getStatus());
|
|
349
|
+
resolve(false);
|
|
350
|
+
}
|
|
351
|
+
};
|
|
352
|
+
var lo = new T.Geolocation();
|
|
353
|
+
lo.getCurrentPosition(h5Position);
|
|
354
|
+
} else if (device === 'qywx') {
|
|
355
|
+
// 企业微信定位
|
|
356
|
+
window.wx.getLocation({
|
|
357
|
+
type: 'gcj02',
|
|
358
|
+
// 默认为wgs84的gps坐标,如果要返回直接给openLocation用的火星坐标,可传入'gcj02'
|
|
359
|
+
success: function success(resp) {
|
|
360
|
+
getDis(resp.longitude, resp.latitude);
|
|
361
|
+
getCurAddress(resp.longitude, resp.latitude);
|
|
362
|
+
resolve(true);
|
|
363
|
+
},
|
|
364
|
+
fail: function fail(error) {
|
|
365
|
+
resolve(false);
|
|
366
|
+
consloe.log('用户拒绝获取位置信息');
|
|
367
|
+
}
|
|
368
|
+
});
|
|
369
|
+
}
|
|
370
|
+
});
|
|
394
371
|
}
|
|
395
372
|
var defaultMethods = {
|
|
396
373
|
/**
|
|
@@ -401,145 +378,132 @@ var defaultMethods = {
|
|
|
401
378
|
$parent = $scope;
|
|
402
379
|
loginUser = $scope.loginUser;
|
|
403
380
|
}
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
timeSpanData.timeInterval.
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
timeSpanData.timeInterval.
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
381
|
+
return new Promise(function (resolve) {
|
|
382
|
+
var today = new Date();
|
|
383
|
+
var y = today.getFullYear();
|
|
384
|
+
var m = today.getMonth();
|
|
385
|
+
var d = today.getDate();
|
|
386
|
+
var h = today.getHours();
|
|
387
|
+
var mins = today.getMinutes();
|
|
388
|
+
// const sec = today.getSeconds()
|
|
389
|
+
occureDate = y + '-' + (m >= 9 ? m + 1 : '0' + (m + 1)) + '-' + (d > 9 ? d : '0' + d) + ' ' + (h > 9 ? h : '0' + h) + ':' + (mins > 9 ? mins : '0' + mins);
|
|
390
|
+
tDate = y + '-' + (m >= 9 ? m + 1 : '0' + (m + 1)) + '-' + (d > 9 ? d : '0' + d);
|
|
391
|
+
// 获取打卡时段
|
|
392
|
+
$parent.$http({
|
|
393
|
+
method: 'POST',
|
|
394
|
+
url: 'ecykq/timeInterval/getDakaTime',
|
|
395
|
+
headers: {
|
|
396
|
+
'Content-Type': 'application/x-www-form-urlencoded'
|
|
397
|
+
},
|
|
398
|
+
params: {
|
|
399
|
+
account: loginUser.personAccount,
|
|
400
|
+
occurredDate: tDate,
|
|
401
|
+
orgCode: loginUser.orgCode
|
|
402
|
+
}
|
|
403
|
+
}).then(function (response) {
|
|
404
|
+
if (response.code === 'success') {
|
|
405
|
+
timeSpanData = JSON.parse(response.body.json);
|
|
406
|
+
timeSpanData.dakaType = Number(timeSpanData.dakaType);
|
|
407
|
+
// if (!this.isLoad) {
|
|
408
|
+
// this.isLoad = true
|
|
409
|
+
if (!timeSpanData.mobileSign || !timeSpanData.addressList || timeSpanData.addressList.length === 0) {
|
|
410
|
+
$parent.dakaType = dakaType[0];
|
|
411
|
+
return $parent.$toast.fail('移动打卡功能异常,请联系管理员开启或设置考勤位置信息!');
|
|
412
|
+
}
|
|
413
|
+
var nowtime = moment(new Date()).format('HH:mm');
|
|
414
|
+
if (timeSpanData.timeInterval && (nowtime > timeSpanData.timeInterval.logonStart && nowtime < timeSpanData.timeInterval.logonEnd || nowtime === timeSpanData.timeInterval.logonStart || nowtime === timeSpanData.timeInterval.logonEnd)) {
|
|
415
|
+
timeSpanData.timeInterval.showTime = timeSpanData.timeInterval.logonRecordTime ? timeSpanData.timeInterval.logonRecordTime : '未打卡';
|
|
416
|
+
timeSpanData.timeInterval.showStatus = timeSpanData.timeInterval.logonRecordTime ? 1 : 3;
|
|
417
|
+
} else if (timeSpanData.timeInterval && (nowtime > timeSpanData.timeInterval.logoffStart && nowtime < timeSpanData.timeInterval.logoffEnd || nowtime === timeSpanData.timeInterval.logoffStart || nowtime === timeSpanData.timeInterval.logoffEnd)) {
|
|
418
|
+
timeSpanData.timeInterval.showTime = timeSpanData.timeInterval.logoffRecordTime ? timeSpanData.timeInterval.logoffRecordTime : '未打卡';
|
|
419
|
+
timeSpanData.timeInterval.showStatus = timeSpanData.timeInterval.logoffRecordTime ? 1 : 3;
|
|
420
|
+
} else if (timeSpanData.timeInterval && (nowtime > timeSpanData.timeInterval.logoffStart && nowtime > timeSpanData.timeInterval.logoffEnd || nowtime === timeSpanData.timeInterval.logoffStart || nowtime === timeSpanData.timeInterval.logoffEnd)) {
|
|
421
|
+
timeSpanData.timeInterval.showTime = timeSpanData.timeInterval.logoffRecordTime ? timeSpanData.timeInterval.logoffRecordTime : '未打卡';
|
|
422
|
+
timeSpanData.timeInterval.showStatus = timeSpanData.timeInterval.logoffRecordTime ? 1 : 3;
|
|
423
|
+
} else {
|
|
424
|
+
timeSpanData.timeInterval = timeSpanData.timeInterval || {};
|
|
425
|
+
timeSpanData.timeInterval.showTime = nowtime;
|
|
426
|
+
timeSpanData.timeInterval.showStatus = 0;
|
|
427
|
+
}
|
|
428
|
+
$parent.timeInterval = timeSpanData.timeInterval;
|
|
429
|
+
$parent.$forceUpdate();
|
|
430
|
+
|
|
431
|
+
// 获取位置信息
|
|
432
|
+
curLocationAndDis().then(function (res) {
|
|
433
|
+
if (!res) {
|
|
434
|
+
$parent.dakaType = dakaType[0];
|
|
435
|
+
}
|
|
436
|
+
if ($parent.dakaType !== dakaType[0]) {
|
|
437
|
+
$parent.dakaType = dakaType[timeSpanData.dakaType];
|
|
438
|
+
}
|
|
439
|
+
resolve(res);
|
|
440
|
+
});
|
|
448
441
|
} else {
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
timeSpanData.timeInterval.showStatus = 0;
|
|
442
|
+
$parent.dakaType = dakaType[0];
|
|
443
|
+
$parent.$toast.fail(response.message);
|
|
452
444
|
}
|
|
453
|
-
|
|
454
|
-
$parent.$forceUpdate();
|
|
455
|
-
// }
|
|
456
|
-
} else {
|
|
457
|
-
$parent.$toast.fail(response.message);
|
|
458
|
-
}
|
|
445
|
+
});
|
|
459
446
|
});
|
|
460
447
|
},
|
|
461
448
|
// 打卡
|
|
462
449
|
dkEvent: function dkEvent($scope) {
|
|
463
450
|
var _this = this;
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
name: loginUser.personName,
|
|
516
|
-
occureDate: occureDate,
|
|
517
|
-
orgCode: loginUser.orgCode,
|
|
518
|
-
orgName: loginUser.orgName,
|
|
519
|
-
personSchId: timeSpanData.personSchId,
|
|
520
|
-
timeId: timeSpanData.timeInterval.id,
|
|
521
|
-
unitAddress: curAddress
|
|
522
|
-
}
|
|
523
|
-
}).then(function (response) {
|
|
524
|
-
if (response.code === 'success') {
|
|
525
|
-
_this.freshData();
|
|
526
|
-
if (parseInt(timeSpanData.dakaType) === 1 || parseInt(timeSpanData.dakaType) === 2) {
|
|
527
|
-
$parent.$toast('打卡成功!');
|
|
528
|
-
} else if (parseInt(timeSpanData.dakaType) === 3) {
|
|
529
|
-
$parent.$toast('更新打卡成功!');
|
|
530
|
-
}
|
|
531
|
-
} else {
|
|
532
|
-
$parent.$toast.fail(response.message);
|
|
533
|
-
}
|
|
534
|
-
}, function (err) {
|
|
535
|
-
$parent.$toast.fail(err);
|
|
536
|
-
});
|
|
537
|
-
case 20:
|
|
538
|
-
case "end":
|
|
539
|
-
return _context.stop();
|
|
451
|
+
$parent = $scope;
|
|
452
|
+
|
|
453
|
+
// 刷新一次数据
|
|
454
|
+
this.freshData($scope).then(function (res) {
|
|
455
|
+
if (timeSpanData && timeSpanData.mobileSign !== 1) {
|
|
456
|
+
return;
|
|
457
|
+
}
|
|
458
|
+
if (!dis || dis === 'undefined' || dis === null) {
|
|
459
|
+
return;
|
|
460
|
+
}
|
|
461
|
+
if (dis && dis > gpsScope) {
|
|
462
|
+
$parent.dakaType = dakaType[0];
|
|
463
|
+
return $parent.$toast.fail('当前地点不在考勤打卡范围内');
|
|
464
|
+
}
|
|
465
|
+
var departmentId = loginUser.staffList[0].orgFullId.split('-');
|
|
466
|
+
var departmentName = loginUser.staffList[0].orgFullName.split('-');
|
|
467
|
+
departmentId = departmentId[departmentId.length - 1];
|
|
468
|
+
departmentName = departmentName[departmentName.length - 1];
|
|
469
|
+
if (canDk) {
|
|
470
|
+
canDk = false;
|
|
471
|
+
} else {
|
|
472
|
+
return;
|
|
473
|
+
}
|
|
474
|
+
setTimeout(function () {
|
|
475
|
+
canDk = true;
|
|
476
|
+
}, 800);
|
|
477
|
+
$parent.$http({
|
|
478
|
+
url: 'ecykq/recordDetail/saveMobileDakaDetail',
|
|
479
|
+
method: 'POST',
|
|
480
|
+
data: {
|
|
481
|
+
account: loginUser.personAccount,
|
|
482
|
+
departmentId: departmentId,
|
|
483
|
+
departmentName: departmentName,
|
|
484
|
+
name: loginUser.personName,
|
|
485
|
+
occureDate: occureDate,
|
|
486
|
+
orgCode: loginUser.orgCode,
|
|
487
|
+
orgName: loginUser.orgName,
|
|
488
|
+
personSchId: timeSpanData.personSchId,
|
|
489
|
+
timeId: timeSpanData.timeInterval.id,
|
|
490
|
+
unitAddress: curAddress
|
|
491
|
+
}
|
|
492
|
+
}).then(function (response) {
|
|
493
|
+
if (response.code === 'success') {
|
|
494
|
+
_this.freshData();
|
|
495
|
+
if (parseInt(timeSpanData.dakaType) === 1 || parseInt(timeSpanData.dakaType) === 2) {
|
|
496
|
+
$parent.$toast('打卡成功!');
|
|
497
|
+
} else if (parseInt(timeSpanData.dakaType) === 3) {
|
|
498
|
+
$parent.$toast('更新打卡成功!');
|
|
499
|
+
}
|
|
500
|
+
} else {
|
|
501
|
+
$parent.$toast.fail(response.message);
|
|
540
502
|
}
|
|
541
|
-
},
|
|
542
|
-
|
|
503
|
+
}, function (err) {
|
|
504
|
+
$parent.$toast.fail(err);
|
|
505
|
+
});
|
|
506
|
+
});
|
|
543
507
|
}
|
|
544
508
|
};
|
|
545
509
|
/* harmony default export */ __webpack_exports__["default"] = (defaultMethods);
|
|
@@ -630,7 +594,7 @@ ___CSS_LOADER_EXPORT___.push([module.id, ".no-data[data-v-ef203e2e]{display:-web
|
|
|
630
594
|
|
|
631
595
|
/***/ }),
|
|
632
596
|
|
|
633
|
-
/***/
|
|
597
|
+
/***/ 6867:
|
|
634
598
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
635
599
|
|
|
636
600
|
"use strict";
|
|
@@ -649,7 +613,7 @@ var ___CSS_LOADER_URL_IMPORT_0___ = new URL(/* asset import */ __webpack_require
|
|
|
649
613
|
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
650
614
|
var ___CSS_LOADER_URL_REPLACEMENT_0___ = _node_modules_css_loader_dist_runtime_getUrl_js__WEBPACK_IMPORTED_MODULE_2___default()(___CSS_LOADER_URL_IMPORT_0___);
|
|
651
615
|
// Module
|
|
652
|
-
___CSS_LOADER_EXPORT___.push([module.id, "[data-v-
|
|
616
|
+
___CSS_LOADER_EXPORT___.push([module.id, "[data-v-5bb0f910] .van-ellipsis{font-size:18px;color:#fff}[data-v-5bb0f910] .van-dropdown-menu__title{color:#fff!important;padding:0 8px 0 0!important}[data-v-5bb0f910] .van-dropdown-menu .van-dropdown-menu__bar .van-dropdown-menu__title--active{color:#fff!important}[data-v-5bb0f910] .van-dropdown-menu__title:after{border-color:transparent transparent #fff #fff!important;right:0}[data-v-5bb0f910] .van-dropdown-menu__bar{background-color:unset!important;-webkit-box-shadow:unset!important;box-shadow:unset!important}[data-v-5bb0f910] .van-dropdown-menu__item{-webkit-box-pack:left;-ms-flex-pack:left;justify-content:left}[data-v-5bb0f910] .chat_icon .van-info{top:5px!important;right:-4px!important}.work_pageHeader[data-v-5bb0f910]{background:url(" + ___CSS_LOADER_URL_REPLACEMENT_0___ + ");padding:0 16px;height:123px;font-size:16px;color:#fff;background-repeat:no-repeat;background-size:cover;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;overflow:hidden;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-transition:height .3s;transition:height .3s}.work_pageHeader[data-v-5bb0f910],.work_pageHeader .flex-horizon-bw[data-v-5bb0f910]{display:-webkit-box;display:-ms-flexbox;display:flex;width:100%}.work_pageHeader .flex-horizon-bw[data-v-5bb0f910]{-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.work_pageHeader .pageHeader_compony[data-v-5bb0f910]{font-size:18px;font-weight:500;color:#fff;-webkit-box-flex:1;-ms-flex:1;flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-right:10px;height:48px;line-height:48px}.work_pageHeader .pageHeader_name[data-v-5bb0f910]{font-size:14px;margin-left:8px}.work_pageHeader .pageHeader_check_work[data-v-5bb0f910]{width:122px;border-radius:15px;background:hsla(0,0%,100%,.8);padding:7px 10px;display:-webkit-box;display:-ms-flexbox;display:flex;color:#333;font-size:12px}.work_pageHeader .pageHeader_timer[data-v-5bb0f910]{-webkit-box-flex:1;-ms-flex:1;flex:1;text-align:right;color:#fff;font-size:14px;line-height:30px;margin-right:16px}.work_pageHeader .more_compony[data-v-5bb0f910]{position:relative;-webkit-transform:rotate(90deg);transform:rotate(90deg);font-size:10px;margin-left:6px}.check_time[data-v-5bb0f910]{-webkit-box-flex:1;-ms-flex:1;flex:1;border-right:1px solid #999;text-align:left;font-size:13px;color:#333;position:relative;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.check_time img[data-v-5bb0f910]{width:14px;height:14px}.check_time span[data-v-5bb0f910]{margin-left:5px}.check_button[data-v-5bb0f910]{-webkit-box-flex:1;-ms-flex:1;flex:1;text-align:right;line-height:18px}", ""]);
|
|
653
617
|
// Exports
|
|
654
618
|
/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
|
|
655
619
|
|
|
@@ -6599,7 +6563,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
|
|
|
6599
6563
|
|
|
6600
6564
|
/***/ }),
|
|
6601
6565
|
|
|
6602
|
-
/***/
|
|
6566
|
+
/***/ 3117:
|
|
6603
6567
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
6604
6568
|
|
|
6605
6569
|
//! moment.js locale configuration
|
|
@@ -16714,12 +16678,12 @@ var map = {
|
|
|
16714
16678
|
"./fil.js": 5995,
|
|
16715
16679
|
"./fo": 2477,
|
|
16716
16680
|
"./fo.js": 2477,
|
|
16717
|
-
"./fr":
|
|
16681
|
+
"./fr": 3117,
|
|
16718
16682
|
"./fr-ca": 6435,
|
|
16719
16683
|
"./fr-ca.js": 6435,
|
|
16720
16684
|
"./fr-ch": 7892,
|
|
16721
16685
|
"./fr-ch.js": 7892,
|
|
16722
|
-
"./fr.js":
|
|
16686
|
+
"./fr.js": 3117,
|
|
16723
16687
|
"./fy": 7071,
|
|
16724
16688
|
"./fy.js": 7071,
|
|
16725
16689
|
"./ga": 1734,
|
|
@@ -22677,19 +22641,19 @@ var update = add("300ba1e0", content, true, {"sourceMap":false,"shadowMode":fals
|
|
|
22677
22641
|
|
|
22678
22642
|
/***/ }),
|
|
22679
22643
|
|
|
22680
|
-
/***/
|
|
22644
|
+
/***/ 3031:
|
|
22681
22645
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
22682
22646
|
|
|
22683
22647
|
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
22684
22648
|
|
|
22685
22649
|
// load the styles
|
|
22686
|
-
var content = __webpack_require__(
|
|
22650
|
+
var content = __webpack_require__(6867);
|
|
22687
22651
|
if(content.__esModule) content = content.default;
|
|
22688
22652
|
if(typeof content === 'string') content = [[module.id, content, '']];
|
|
22689
22653
|
if(content.locals) module.exports = content.locals;
|
|
22690
22654
|
// add the styles to the DOM
|
|
22691
22655
|
var add = (__webpack_require__(9548)/* ["default"] */ .A)
|
|
22692
|
-
var update = add("
|
|
22656
|
+
var update = add("02aba879", content, true, {"sourceMap":false,"shadowMode":false});
|
|
22693
22657
|
|
|
22694
22658
|
/***/ }),
|
|
22695
22659
|
|
|
@@ -27708,8 +27672,8 @@ var commonApps_component = normalizeComponent(
|
|
|
27708
27672
|
)
|
|
27709
27673
|
|
|
27710
27674
|
/* harmony default export */ var commonApps = (commonApps_component.exports);
|
|
27711
|
-
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=template&id=
|
|
27712
|
-
var
|
|
27675
|
+
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=template&id=5bb0f910&scoped=true
|
|
27676
|
+
var workHeadvue_type_template_id_5bb0f910_scoped_true_render = function render() {
|
|
27713
27677
|
var _vm = this,
|
|
27714
27678
|
_c = _vm._self._c;
|
|
27715
27679
|
return _c('div', {
|
|
@@ -27833,7 +27797,7 @@ var workHeadvue_type_template_id_6c6c5bb3_scoped_true_render = function render()
|
|
|
27833
27797
|
staticClass: "pageHeader_timer"
|
|
27834
27798
|
}, [_c('span', [_vm._v(_vm._s(_vm.nowDay))])])])]);
|
|
27835
27799
|
};
|
|
27836
|
-
var
|
|
27800
|
+
var workHeadvue_type_template_id_5bb0f910_scoped_true_staticRenderFns = [];
|
|
27837
27801
|
|
|
27838
27802
|
;// CONCATENATED MODULE: ./node_modules/vuex/dist/vuex.esm.js
|
|
27839
27803
|
/*!
|
|
@@ -29024,11 +28988,15 @@ var workClock = __webpack_require__(2554);
|
|
|
29024
28988
|
organName: '',
|
|
29025
28989
|
nowDay: '',
|
|
29026
28990
|
orgCode: '',
|
|
29027
|
-
dakaType: '',
|
|
28991
|
+
dakaType: '正在定位',
|
|
29028
28992
|
ecykqPath: '',
|
|
29029
28993
|
canClockIn: false,
|
|
29030
28994
|
boxHeight: 123,
|
|
29031
|
-
timeInterval: {}
|
|
28995
|
+
timeInterval: {},
|
|
28996
|
+
// 签到校验信息
|
|
28997
|
+
timer: '',
|
|
28998
|
+
//时钟定时器
|
|
28999
|
+
curInterval: '' // 勤数据更新定时器
|
|
29032
29000
|
};
|
|
29033
29001
|
},
|
|
29034
29002
|
computed: _objectSpread({}, mapGetters({
|
|
@@ -29054,6 +29022,8 @@ var workClock = __webpack_require__(2554);
|
|
|
29054
29022
|
this.getBgImg();
|
|
29055
29023
|
},
|
|
29056
29024
|
beforeDestroy: function beforeDestroy() {
|
|
29025
|
+
if (this.timer) clearInterval(this.timer);
|
|
29026
|
+
if (this.curInterval) clearInterval(this.curInterval);
|
|
29057
29027
|
this.$bus.off('reduceHeadHeight', this.reduceHeadHeight);
|
|
29058
29028
|
},
|
|
29059
29029
|
mounted: function mounted() {
|
|
@@ -29061,9 +29031,9 @@ var workClock = __webpack_require__(2554);
|
|
|
29061
29031
|
this.loadH5apps();
|
|
29062
29032
|
this.formatNowDay();
|
|
29063
29033
|
this.getTime();
|
|
29064
|
-
setInterval(function () {
|
|
29034
|
+
this.timer = setInterval(function () {
|
|
29065
29035
|
_this2.getTime();
|
|
29066
|
-
}, 1000 *
|
|
29036
|
+
}, 1000 * 2);
|
|
29067
29037
|
},
|
|
29068
29038
|
methods: {
|
|
29069
29039
|
scan: function scan() {
|
|
@@ -29130,7 +29100,7 @@ var workClock = __webpack_require__(2554);
|
|
|
29130
29100
|
productCode = window.productCode;
|
|
29131
29101
|
}
|
|
29132
29102
|
url = "/apigw" + '/mpp/image/download?nameField=fileName&dataField=image&id=' + res.body.listdata[0].id + '&httpPort=' + location.port + '&productCode=' + productCode;
|
|
29133
|
-
document.querySelector('.work_pageHeader').style.background =
|
|
29103
|
+
document.querySelector('.work_pageHeader').style.background = 'url(' + url + ')';
|
|
29134
29104
|
document.querySelector('.work_pageHeader').style.backgroundSize = 'cover';
|
|
29135
29105
|
document.querySelector('.work_pageHeader').style.backgroundRepeat = 'no-repeat';
|
|
29136
29106
|
}
|
|
@@ -29213,6 +29183,13 @@ var workClock = __webpack_require__(2554);
|
|
|
29213
29183
|
} else if (workClock.default) {
|
|
29214
29184
|
workClock.default.freshData(_this5);
|
|
29215
29185
|
}
|
|
29186
|
+
_this5.curInterval = setInterval(function () {
|
|
29187
|
+
if (workClock.freshData) {
|
|
29188
|
+
workClock.freshData(_this5);
|
|
29189
|
+
} else if (workClock.default) {
|
|
29190
|
+
workClock.default.freshData(_this5);
|
|
29191
|
+
}
|
|
29192
|
+
}, 1000 * 60);
|
|
29216
29193
|
});
|
|
29217
29194
|
}
|
|
29218
29195
|
}
|
|
@@ -29304,9 +29281,9 @@ var workClock = __webpack_require__(2554);
|
|
|
29304
29281
|
});
|
|
29305
29282
|
;// CONCATENATED MODULE: ./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=script&lang=js
|
|
29306
29283
|
/* harmony default export */ var components_workHeadvue_type_script_lang_js = (workHeadvue_type_script_lang_js);
|
|
29307
|
-
// EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-64.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-64.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-64.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=style&index=0&id=
|
|
29308
|
-
var
|
|
29309
|
-
;// CONCATENATED MODULE: ./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=style&index=0&id=
|
|
29284
|
+
// EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-64.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-64.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-64.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=style&index=0&id=5bb0f910&prod&scoped=true&lang=scss
|
|
29285
|
+
var workHeadvue_type_style_index_0_id_5bb0f910_prod_scoped_true_lang_scss = __webpack_require__(3031);
|
|
29286
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/desktop/src/components/workHead.vue?vue&type=style&index=0&id=5bb0f910&prod&scoped=true&lang=scss
|
|
29310
29287
|
|
|
29311
29288
|
;// CONCATENATED MODULE: ./packages/ecmoa/desktop/src/components/workHead.vue
|
|
29312
29289
|
|
|
@@ -29319,11 +29296,11 @@ var workHeadvue_type_style_index_0_id_6c6c5bb3_prod_scoped_true_lang_scss = __we
|
|
|
29319
29296
|
|
|
29320
29297
|
var workHead_component = normalizeComponent(
|
|
29321
29298
|
components_workHeadvue_type_script_lang_js,
|
|
29322
|
-
|
|
29323
|
-
|
|
29299
|
+
workHeadvue_type_template_id_5bb0f910_scoped_true_render,
|
|
29300
|
+
workHeadvue_type_template_id_5bb0f910_scoped_true_staticRenderFns,
|
|
29324
29301
|
false,
|
|
29325
29302
|
null,
|
|
29326
|
-
"
|
|
29303
|
+
"5bb0f910",
|
|
29327
29304
|
null
|
|
29328
29305
|
|
|
29329
29306
|
)
|