@neutron.co.id/operasional-interfaces 1.12.6 → 1.12.7

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.
@@ -3448,8 +3448,8 @@ function addYears(dirtyDate, dirtyAmount) {
3448
3448
  var amount = toInteger(dirtyAmount);
3449
3449
  return addMonths(dirtyDate, amount * 12);
3450
3450
  }
3451
- var commonjsGlobal$1 = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
3452
- var freeGlobal$1$1 = typeof commonjsGlobal$1 == "object" && commonjsGlobal$1 && commonjsGlobal$1.Object === Object && commonjsGlobal$1;
3451
+ var commonjsGlobal$3 = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
3452
+ var freeGlobal$1$1 = typeof commonjsGlobal$3 == "object" && commonjsGlobal$3 && commonjsGlobal$3.Object === Object && commonjsGlobal$3;
3453
3453
  var _freeGlobal$1 = freeGlobal$1$1;
3454
3454
  var freeGlobal$2 = _freeGlobal$1;
3455
3455
  var freeSelf$1 = typeof self == "object" && self && self.Object === Object && self;
@@ -11010,7 +11010,7 @@ var parseLocale$1 = function parseLocale(preset, object, isLocal) {
11010
11010
  L2 = l;
11011
11011
  return l || !isLocal && L2;
11012
11012
  };
11013
- var dayjs$2 = function dayjs(date2, c2) {
11013
+ var dayjs$3 = function dayjs(date2, c2) {
11014
11014
  if (isDayjs$1(date2)) {
11015
11015
  return date2.clone();
11016
11016
  }
@@ -11020,7 +11020,7 @@ var dayjs$2 = function dayjs(date2, c2) {
11020
11020
  return new Dayjs$1(cfg);
11021
11021
  };
11022
11022
  var wrapper$2 = function wrapper(date2, instance) {
11023
- return dayjs$2(date2, {
11023
+ return dayjs$3(date2, {
11024
11024
  locale: instance.$L,
11025
11025
  utc: instance.$u,
11026
11026
  x: instance.$x,
@@ -11083,14 +11083,14 @@ var Dayjs$1 = /* @__PURE__ */ function() {
11083
11083
  return !(this.$d.toString() === INVALID_DATE_STRING$1);
11084
11084
  };
11085
11085
  _proto.isSame = function isSame(that, units) {
11086
- var other = dayjs$2(that);
11086
+ var other = dayjs$3(that);
11087
11087
  return this.startOf(units) <= other && other <= this.endOf(units);
11088
11088
  };
11089
11089
  _proto.isAfter = function isAfter(that, units) {
11090
- return dayjs$2(that) < this.startOf(units);
11090
+ return dayjs$3(that) < this.startOf(units);
11091
11091
  };
11092
11092
  _proto.isBefore = function isBefore(that, units) {
11093
- return this.endOf(units) < dayjs$2(that);
11093
+ return this.endOf(units) < dayjs$3(that);
11094
11094
  };
11095
11095
  _proto.$g = function $g(input2, get2, set2) {
11096
11096
  if (Utils$1.u(input2))
@@ -11175,7 +11175,7 @@ var Dayjs$1 = /* @__PURE__ */ function() {
11175
11175
  number = Number(number);
11176
11176
  var unit = Utils$1.p(units);
11177
11177
  var instanceFactorySet = function instanceFactorySet2(n) {
11178
- var d3 = dayjs$2(_this2);
11178
+ var d3 = dayjs$3(_this2);
11179
11179
  return Utils$1.w(d3.date(d3.date() + Math.round(n * number)), _this2);
11180
11180
  };
11181
11181
  if (unit === M3) {
@@ -11279,7 +11279,7 @@ var Dayjs$1 = /* @__PURE__ */ function() {
11279
11279
  _proto.diff = function diff(input2, units, _float) {
11280
11280
  var _this4 = this;
11281
11281
  var unit = Utils$1.p(units);
11282
- var that = dayjs$2(input2);
11282
+ var that = dayjs$3(input2);
11283
11283
  var zoneDelta = (that.utcOffset() - this.utcOffset()) * MILLISECONDS_A_MINUTE$1;
11284
11284
  var diff2 = this - that;
11285
11285
  var getMonth = function getMonth2() {
@@ -11350,28 +11350,28 @@ var Dayjs$1 = /* @__PURE__ */ function() {
11350
11350
  return Dayjs2;
11351
11351
  }();
11352
11352
  var proto$1 = Dayjs$1.prototype;
11353
- dayjs$2.prototype = proto$1;
11353
+ dayjs$3.prototype = proto$1;
11354
11354
  [["$ms", MS$1], ["$s", S3], ["$m", MIN$1], ["$H", H3], ["$W", D2], ["$M", M3], ["$y", Y2], ["$D", DATE$1]].forEach(function(g) {
11355
11355
  proto$1[g[1]] = function(input2) {
11356
11356
  return this.$g(input2, g[0], g[1]);
11357
11357
  };
11358
11358
  });
11359
- dayjs$2.extend = function(plugin, option) {
11359
+ dayjs$3.extend = function(plugin, option) {
11360
11360
  if (!plugin.$i) {
11361
- plugin(option, Dayjs$1, dayjs$2);
11361
+ plugin(option, Dayjs$1, dayjs$3);
11362
11362
  plugin.$i = true;
11363
11363
  }
11364
- return dayjs$2;
11364
+ return dayjs$3;
11365
11365
  };
11366
- dayjs$2.locale = parseLocale$1;
11367
- dayjs$2.isDayjs = isDayjs$1;
11368
- dayjs$2.unix = function(timestamp) {
11369
- return dayjs$2(timestamp * 1e3);
11366
+ dayjs$3.locale = parseLocale$1;
11367
+ dayjs$3.isDayjs = isDayjs$1;
11368
+ dayjs$3.unix = function(timestamp) {
11369
+ return dayjs$3(timestamp * 1e3);
11370
11370
  };
11371
- dayjs$2.en = Ls$1[L2];
11372
- dayjs$2.Ls = Ls$1;
11373
- dayjs$2.p = {};
11374
- const dayjs$3 = dayjs$2;
11371
+ dayjs$3.en = Ls$1[L2];
11372
+ dayjs$3.Ls = Ls$1;
11373
+ dayjs$3.p = {};
11374
+ const dayjs$4 = dayjs$3;
11375
11375
  var locale$1 = {
11376
11376
  name: "id",
11377
11377
  weekdays: "Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),
@@ -11407,7 +11407,7 @@ var locale$1 = {
11407
11407
  return n + ".";
11408
11408
  }
11409
11409
  };
11410
- dayjs$3.locale(locale$1, null, true);
11410
+ dayjs$4.locale(locale$1, null, true);
11411
11411
  const advancedFormat$1 = function(o, c2) {
11412
11412
  var proto2 = c2.prototype;
11413
11413
  var oldFormat = proto2.format;
@@ -11716,16 +11716,16 @@ var Duration$1 = /* @__PURE__ */ function() {
11716
11716
  var manipulateDuration$1 = function manipulateDuration(date2, duration, k2) {
11717
11717
  return date2.add(duration.years() * k2, "y").add(duration.months() * k2, "M").add(duration.days() * k2, "d").add(duration.hours() * k2, "h").add(duration.minutes() * k2, "m").add(duration.seconds() * k2, "s").add(duration.milliseconds() * k2, "ms");
11718
11718
  };
11719
- const durationPlugin$1 = function(option, Dayjs2, dayjs3) {
11720
- $d$1 = dayjs3;
11721
- $u$1 = dayjs3().$utils();
11722
- dayjs3.duration = function(input2, unit) {
11723
- var $l = dayjs3.locale();
11719
+ const durationPlugin$1 = function(option, Dayjs2, dayjs4) {
11720
+ $d$1 = dayjs4;
11721
+ $u$1 = dayjs4().$utils();
11722
+ dayjs4.duration = function(input2, unit) {
11723
+ var $l = dayjs4.locale();
11724
11724
  return wrapper2(input2, {
11725
11725
  $l
11726
11726
  }, unit);
11727
11727
  };
11728
- dayjs3.isDuration = isDuration$1;
11728
+ dayjs4.isDuration = isDuration$1;
11729
11729
  var oldAdd = Dayjs2.prototype.add;
11730
11730
  var oldSubtract = Dayjs2.prototype.subtract;
11731
11731
  Dayjs2.prototype.add = function(value, unit) {
@@ -11897,14 +11897,14 @@ const relativeTimePlugin$1 = function(o, c2, d3) {
11897
11897
  return this.from(makeNow(this), withoutSuffix);
11898
11898
  };
11899
11899
  };
11900
- dayjs$3.extend(durationPlugin$1);
11901
- dayjs$3.extend(relativeTimePlugin$1);
11902
- dayjs$3.extend(advancedFormat$1);
11903
- dayjs$3.extend(isoWeek$1);
11904
- dayjs$3.locale("id");
11900
+ dayjs$4.extend(durationPlugin$1);
11901
+ dayjs$4.extend(relativeTimePlugin$1);
11902
+ dayjs$4.extend(advancedFormat$1);
11903
+ dayjs$4.extend(isoWeek$1);
11904
+ dayjs$4.locale("id");
11905
11905
  class DateUtil {
11906
11906
  static get day() {
11907
- return dayjs$3;
11907
+ return dayjs$4;
11908
11908
  }
11909
11909
  }
11910
11910
  const _withScopeId$3 = (n) => (vue$1.pushScopeId("data-v-805321b9"), n = n(), vue$1.popScopeId(), n);
@@ -14169,6 +14169,37 @@ const StatusStaff$1 = model$2.Choice.define({
14169
14169
  }
14170
14170
  ]
14171
14171
  });
14172
+ const StatusWork$1 = model$2.Choice.define({
14173
+ handle: "statusWork",
14174
+ name: "Work Status",
14175
+ items: [
14176
+ {
14177
+ label: "Off",
14178
+ value: "off",
14179
+ color: "danger"
14180
+ },
14181
+ {
14182
+ label: "Kerja",
14183
+ value: "work",
14184
+ color: "success"
14185
+ },
14186
+ {
14187
+ label: "Cuti",
14188
+ value: "leave",
14189
+ color: "warning"
14190
+ },
14191
+ {
14192
+ label: "Libur",
14193
+ value: "holiday",
14194
+ color: "info"
14195
+ },
14196
+ {
14197
+ label: "Pulang",
14198
+ value: "home",
14199
+ color: "info"
14200
+ }
14201
+ ]
14202
+ });
14172
14203
  const PriorityStatus$1 = model$2.Choice.define({
14173
14204
  handle: "priorityStatus",
14174
14205
  name: "Priority Status",
@@ -18052,6 +18083,302 @@ const SituationTypeModel$1 = model$2.Model.define({
18052
18083
  fluffy: {}
18053
18084
  }
18054
18085
  });
18086
+ var commonjsGlobal$2 = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
18087
+ function getDefaultExportFromCjs$1(x2) {
18088
+ return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
18089
+ }
18090
+ var dayjs_min$1 = { exports: {} };
18091
+ (function(module2, exports2) {
18092
+ !function(t2, e3) {
18093
+ module2.exports = e3();
18094
+ }(commonjsGlobal$2, function() {
18095
+ var t2 = 1e3, e3 = 6e4, n = 36e5, r = "millisecond", i2 = "second", s3 = "minute", u2 = "hour", a3 = "day", o = "week", c2 = "month", f = "quarter", h3 = "year", d3 = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y3 = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M4 = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t3) {
18096
+ var e4 = ["th", "st", "nd", "rd"], n2 = t3 % 100;
18097
+ return "[" + t3 + (e4[(n2 - 20) % 10] || e4[n2] || e4[0]) + "]";
18098
+ } }, m3 = function(t3, e4, n2) {
18099
+ var r2 = String(t3);
18100
+ return !r2 || r2.length >= e4 ? t3 : "" + Array(e4 + 1 - r2.length).join(n2) + t3;
18101
+ }, v = { s: m3, z: function(t3) {
18102
+ var e4 = -t3.utcOffset(), n2 = Math.abs(e4), r2 = Math.floor(n2 / 60), i3 = n2 % 60;
18103
+ return (e4 <= 0 ? "+" : "-") + m3(r2, 2, "0") + ":" + m3(i3, 2, "0");
18104
+ }, m: function t3(e4, n2) {
18105
+ if (e4.date() < n2.date())
18106
+ return -t3(n2, e4);
18107
+ var r2 = 12 * (n2.year() - e4.year()) + (n2.month() - e4.month()), i3 = e4.clone().add(r2, c2), s4 = n2 - i3 < 0, u3 = e4.clone().add(r2 + (s4 ? -1 : 1), c2);
18108
+ return +(-(r2 + (n2 - i3) / (s4 ? i3 - u3 : u3 - i3)) || 0);
18109
+ }, a: function(t3) {
18110
+ return t3 < 0 ? Math.ceil(t3) || 0 : Math.floor(t3);
18111
+ }, p: function(t3) {
18112
+ return { M: c2, y: h3, w: o, d: a3, D: d3, h: u2, m: s3, s: i2, ms: r, Q: f }[t3] || String(t3 || "").toLowerCase().replace(/s$/, "");
18113
+ }, u: function(t3) {
18114
+ return void 0 === t3;
18115
+ } }, g = "en", D3 = {};
18116
+ D3[g] = M4;
18117
+ var p = "$isDayjsObject", S4 = function(t3) {
18118
+ return t3 instanceof _ || !(!t3 || !t3[p]);
18119
+ }, w2 = function t3(e4, n2, r2) {
18120
+ var i3;
18121
+ if (!e4)
18122
+ return g;
18123
+ if ("string" == typeof e4) {
18124
+ var s4 = e4.toLowerCase();
18125
+ D3[s4] && (i3 = s4), n2 && (D3[s4] = n2, i3 = s4);
18126
+ var u3 = e4.split("-");
18127
+ if (!i3 && u3.length > 1)
18128
+ return t3(u3[0]);
18129
+ } else {
18130
+ var a4 = e4.name;
18131
+ D3[a4] = e4, i3 = a4;
18132
+ }
18133
+ return !r2 && i3 && (g = i3), i3 || !r2 && g;
18134
+ }, O2 = function(t3, e4) {
18135
+ if (S4(t3))
18136
+ return t3.clone();
18137
+ var n2 = "object" == typeof e4 ? e4 : {};
18138
+ return n2.date = t3, n2.args = arguments, new _(n2);
18139
+ }, b2 = v;
18140
+ b2.l = w2, b2.i = S4, b2.w = function(t3, e4) {
18141
+ return O2(t3, { locale: e4.$L, utc: e4.$u, x: e4.$x, $offset: e4.$offset });
18142
+ };
18143
+ var _ = function() {
18144
+ function M5(t3) {
18145
+ this.$L = w2(t3.locale, null, true), this.parse(t3), this.$x = this.$x || t3.x || {}, this[p] = true;
18146
+ }
18147
+ var m4 = M5.prototype;
18148
+ return m4.parse = function(t3) {
18149
+ this.$d = function(t4) {
18150
+ var e4 = t4.date, n2 = t4.utc;
18151
+ if (null === e4)
18152
+ return /* @__PURE__ */ new Date(NaN);
18153
+ if (b2.u(e4))
18154
+ return /* @__PURE__ */ new Date();
18155
+ if (e4 instanceof Date)
18156
+ return new Date(e4);
18157
+ if ("string" == typeof e4 && !/Z$/i.test(e4)) {
18158
+ var r2 = e4.match($);
18159
+ if (r2) {
18160
+ var i3 = r2[2] - 1 || 0, s4 = (r2[7] || "0").substring(0, 3);
18161
+ return n2 ? new Date(Date.UTC(r2[1], i3, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s4)) : new Date(r2[1], i3, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s4);
18162
+ }
18163
+ }
18164
+ return new Date(e4);
18165
+ }(t3), this.init();
18166
+ }, m4.init = function() {
18167
+ var t3 = this.$d;
18168
+ this.$y = t3.getFullYear(), this.$M = t3.getMonth(), this.$D = t3.getDate(), this.$W = t3.getDay(), this.$H = t3.getHours(), this.$m = t3.getMinutes(), this.$s = t3.getSeconds(), this.$ms = t3.getMilliseconds();
18169
+ }, m4.$utils = function() {
18170
+ return b2;
18171
+ }, m4.isValid = function() {
18172
+ return !(this.$d.toString() === l);
18173
+ }, m4.isSame = function(t3, e4) {
18174
+ var n2 = O2(t3);
18175
+ return this.startOf(e4) <= n2 && n2 <= this.endOf(e4);
18176
+ }, m4.isAfter = function(t3, e4) {
18177
+ return O2(t3) < this.startOf(e4);
18178
+ }, m4.isBefore = function(t3, e4) {
18179
+ return this.endOf(e4) < O2(t3);
18180
+ }, m4.$g = function(t3, e4, n2) {
18181
+ return b2.u(t3) ? this[e4] : this.set(n2, t3);
18182
+ }, m4.unix = function() {
18183
+ return Math.floor(this.valueOf() / 1e3);
18184
+ }, m4.valueOf = function() {
18185
+ return this.$d.getTime();
18186
+ }, m4.startOf = function(t3, e4) {
18187
+ var n2 = this, r2 = !!b2.u(e4) || e4, f2 = b2.p(t3), l2 = function(t4, e5) {
18188
+ var i3 = b2.w(n2.$u ? Date.UTC(n2.$y, e5, t4) : new Date(n2.$y, e5, t4), n2);
18189
+ return r2 ? i3 : i3.endOf(a3);
18190
+ }, $2 = function(t4, e5) {
18191
+ return b2.w(n2.toDate()[t4].apply(n2.toDate("s"), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e5)), n2);
18192
+ }, y4 = this.$W, M6 = this.$M, m5 = this.$D, v2 = "set" + (this.$u ? "UTC" : "");
18193
+ switch (f2) {
18194
+ case h3:
18195
+ return r2 ? l2(1, 0) : l2(31, 11);
18196
+ case c2:
18197
+ return r2 ? l2(1, M6) : l2(0, M6 + 1);
18198
+ case o:
18199
+ var g2 = this.$locale().weekStart || 0, D4 = (y4 < g2 ? y4 + 7 : y4) - g2;
18200
+ return l2(r2 ? m5 - D4 : m5 + (6 - D4), M6);
18201
+ case a3:
18202
+ case d3:
18203
+ return $2(v2 + "Hours", 0);
18204
+ case u2:
18205
+ return $2(v2 + "Minutes", 1);
18206
+ case s3:
18207
+ return $2(v2 + "Seconds", 2);
18208
+ case i2:
18209
+ return $2(v2 + "Milliseconds", 3);
18210
+ default:
18211
+ return this.clone();
18212
+ }
18213
+ }, m4.endOf = function(t3) {
18214
+ return this.startOf(t3, false);
18215
+ }, m4.$set = function(t3, e4) {
18216
+ var n2, o2 = b2.p(t3), f2 = "set" + (this.$u ? "UTC" : ""), l2 = (n2 = {}, n2[a3] = f2 + "Date", n2[d3] = f2 + "Date", n2[c2] = f2 + "Month", n2[h3] = f2 + "FullYear", n2[u2] = f2 + "Hours", n2[s3] = f2 + "Minutes", n2[i2] = f2 + "Seconds", n2[r] = f2 + "Milliseconds", n2)[o2], $2 = o2 === a3 ? this.$D + (e4 - this.$W) : e4;
18217
+ if (o2 === c2 || o2 === h3) {
18218
+ var y4 = this.clone().set(d3, 1);
18219
+ y4.$d[l2]($2), y4.init(), this.$d = y4.set(d3, Math.min(this.$D, y4.daysInMonth())).$d;
18220
+ } else
18221
+ l2 && this.$d[l2]($2);
18222
+ return this.init(), this;
18223
+ }, m4.set = function(t3, e4) {
18224
+ return this.clone().$set(t3, e4);
18225
+ }, m4.get = function(t3) {
18226
+ return this[b2.p(t3)]();
18227
+ }, m4.add = function(r2, f2) {
18228
+ var d4, l2 = this;
18229
+ r2 = Number(r2);
18230
+ var $2 = b2.p(f2), y4 = function(t3) {
18231
+ var e4 = O2(l2);
18232
+ return b2.w(e4.date(e4.date() + Math.round(t3 * r2)), l2);
18233
+ };
18234
+ if ($2 === c2)
18235
+ return this.set(c2, this.$M + r2);
18236
+ if ($2 === h3)
18237
+ return this.set(h3, this.$y + r2);
18238
+ if ($2 === a3)
18239
+ return y4(1);
18240
+ if ($2 === o)
18241
+ return y4(7);
18242
+ var M6 = (d4 = {}, d4[s3] = e3, d4[u2] = n, d4[i2] = t2, d4)[$2] || 1, m5 = this.$d.getTime() + r2 * M6;
18243
+ return b2.w(m5, this);
18244
+ }, m4.subtract = function(t3, e4) {
18245
+ return this.add(-1 * t3, e4);
18246
+ }, m4.format = function(t3) {
18247
+ var e4 = this, n2 = this.$locale();
18248
+ if (!this.isValid())
18249
+ return n2.invalidDate || l;
18250
+ var r2 = t3 || "YYYY-MM-DDTHH:mm:ssZ", i3 = b2.z(this), s4 = this.$H, u3 = this.$m, a4 = this.$M, o2 = n2.weekdays, c3 = n2.months, f2 = n2.meridiem, h4 = function(t4, n3, i4, s5) {
18251
+ return t4 && (t4[n3] || t4(e4, r2)) || i4[n3].slice(0, s5);
18252
+ }, d4 = function(t4) {
18253
+ return b2.s(s4 % 12 || 12, t4, "0");
18254
+ }, $2 = f2 || function(t4, e5, n3) {
18255
+ var r3 = t4 < 12 ? "AM" : "PM";
18256
+ return n3 ? r3.toLowerCase() : r3;
18257
+ };
18258
+ return r2.replace(y3, function(t4, r3) {
18259
+ return r3 || function(t5) {
18260
+ switch (t5) {
18261
+ case "YY":
18262
+ return String(e4.$y).slice(-2);
18263
+ case "YYYY":
18264
+ return b2.s(e4.$y, 4, "0");
18265
+ case "M":
18266
+ return a4 + 1;
18267
+ case "MM":
18268
+ return b2.s(a4 + 1, 2, "0");
18269
+ case "MMM":
18270
+ return h4(n2.monthsShort, a4, c3, 3);
18271
+ case "MMMM":
18272
+ return h4(c3, a4);
18273
+ case "D":
18274
+ return e4.$D;
18275
+ case "DD":
18276
+ return b2.s(e4.$D, 2, "0");
18277
+ case "d":
18278
+ return String(e4.$W);
18279
+ case "dd":
18280
+ return h4(n2.weekdaysMin, e4.$W, o2, 2);
18281
+ case "ddd":
18282
+ return h4(n2.weekdaysShort, e4.$W, o2, 3);
18283
+ case "dddd":
18284
+ return o2[e4.$W];
18285
+ case "H":
18286
+ return String(s4);
18287
+ case "HH":
18288
+ return b2.s(s4, 2, "0");
18289
+ case "h":
18290
+ return d4(1);
18291
+ case "hh":
18292
+ return d4(2);
18293
+ case "a":
18294
+ return $2(s4, u3, true);
18295
+ case "A":
18296
+ return $2(s4, u3, false);
18297
+ case "m":
18298
+ return String(u3);
18299
+ case "mm":
18300
+ return b2.s(u3, 2, "0");
18301
+ case "s":
18302
+ return String(e4.$s);
18303
+ case "ss":
18304
+ return b2.s(e4.$s, 2, "0");
18305
+ case "SSS":
18306
+ return b2.s(e4.$ms, 3, "0");
18307
+ case "Z":
18308
+ return i3;
18309
+ }
18310
+ return null;
18311
+ }(t4) || i3.replace(":", "");
18312
+ });
18313
+ }, m4.utcOffset = function() {
18314
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
18315
+ }, m4.diff = function(r2, d4, l2) {
18316
+ var $2, y4 = this, M6 = b2.p(d4), m5 = O2(r2), v2 = (m5.utcOffset() - this.utcOffset()) * e3, g2 = this - m5, D4 = function() {
18317
+ return b2.m(y4, m5);
18318
+ };
18319
+ switch (M6) {
18320
+ case h3:
18321
+ $2 = D4() / 12;
18322
+ break;
18323
+ case c2:
18324
+ $2 = D4();
18325
+ break;
18326
+ case f:
18327
+ $2 = D4() / 3;
18328
+ break;
18329
+ case o:
18330
+ $2 = (g2 - v2) / 6048e5;
18331
+ break;
18332
+ case a3:
18333
+ $2 = (g2 - v2) / 864e5;
18334
+ break;
18335
+ case u2:
18336
+ $2 = g2 / n;
18337
+ break;
18338
+ case s3:
18339
+ $2 = g2 / e3;
18340
+ break;
18341
+ case i2:
18342
+ $2 = g2 / t2;
18343
+ break;
18344
+ default:
18345
+ $2 = g2;
18346
+ }
18347
+ return l2 ? $2 : b2.a($2);
18348
+ }, m4.daysInMonth = function() {
18349
+ return this.endOf(c2).$D;
18350
+ }, m4.$locale = function() {
18351
+ return D3[this.$L];
18352
+ }, m4.locale = function(t3, e4) {
18353
+ if (!t3)
18354
+ return this.$L;
18355
+ var n2 = this.clone(), r2 = w2(t3, e4, true);
18356
+ return r2 && (n2.$L = r2), n2;
18357
+ }, m4.clone = function() {
18358
+ return b2.w(this.$d, this);
18359
+ }, m4.toDate = function() {
18360
+ return new Date(this.valueOf());
18361
+ }, m4.toJSON = function() {
18362
+ return this.isValid() ? this.toISOString() : null;
18363
+ }, m4.toISOString = function() {
18364
+ return this.$d.toISOString();
18365
+ }, m4.toString = function() {
18366
+ return this.$d.toUTCString();
18367
+ }, M5;
18368
+ }(), k2 = _.prototype;
18369
+ return O2.prototype = k2, [["$ms", r], ["$s", i2], ["$m", s3], ["$H", u2], ["$W", a3], ["$M", c2], ["$y", h3], ["$D", d3]].forEach(function(t3) {
18370
+ k2[t3[1]] = function(e4) {
18371
+ return this.$g(e4, t3[0], t3[1]);
18372
+ };
18373
+ }), O2.extend = function(t3, e4) {
18374
+ return t3.$i || (t3(e4, _, O2), t3.$i = true), O2;
18375
+ }, O2.locale = w2, O2.isDayjs = S4, O2.unix = function(t3) {
18376
+ return O2(1e3 * t3);
18377
+ }, O2.en = D3[g], O2.Ls = D3, O2.p = {}, O2;
18378
+ });
18379
+ })(dayjs_min$1);
18380
+ var dayjs_minExports$1 = dayjs_min$1.exports;
18381
+ const dayjs2 = /* @__PURE__ */ getDefaultExportFromCjs$1(dayjs_minExports$1);
18055
18382
  const StaffModel$2 = model$2.Model.define({
18056
18383
  name: "Staff",
18057
18384
  definition: "neu:personalia:staff",
@@ -18258,6 +18585,249 @@ const StaffModel$2 = model$2.Model.define({
18258
18585
  return roleIds;
18259
18586
  }
18260
18587
  }
18588
+ }),
18589
+ workStatus: model$2.Field.define({
18590
+ handle: "workStatus",
18591
+ name: "Status",
18592
+ type: "string",
18593
+ input: "select",
18594
+ options: {
18595
+ note: "Status dari karyawan.",
18596
+ default: "notActive",
18597
+ enums: StatusWork$1.values,
18598
+ choices: StatusWork$1.items,
18599
+ isVirtual: true,
18600
+ isPersisted: true
18601
+ },
18602
+ virtual: {
18603
+ dependency: {
18604
+ checkIns: {
18605
+ _id: 1,
18606
+ type: 1,
18607
+ checkInAt: 1
18608
+ },
18609
+ submitStaffAttendances: {
18610
+ _id: 1,
18611
+ type: 1,
18612
+ startedAt: 1,
18613
+ status: 1
18614
+ }
18615
+ },
18616
+ reduce(o) {
18617
+ var _a;
18618
+ if (!o.checkIns.length)
18619
+ return "off";
18620
+ const opts = { pattern: "yyyy-MM-dd" };
18621
+ const todayDate = date.DateUtil.formatTz((/* @__PURE__ */ new Date()).toISOString(), opts);
18622
+ const arrCheckIn = o.checkIns.filter(
18623
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
18624
+ );
18625
+ const arrCheckInReverse = arrCheckIn.reverse();
18626
+ const checkInAtReverse = arrCheckInReverse[0];
18627
+ const lastPresence = date.DateUtil.formatTz(
18628
+ checkInAtReverse == null ? void 0 : checkInAtReverse.checkInAt,
18629
+ opts
18630
+ );
18631
+ const arrCheckInHome = o.checkIns.filter(
18632
+ (field2) => field2.type == "home"
18633
+ );
18634
+ const arrCheckInHomeReverse = (_a = arrCheckInHome.reverse()[0]) == null ? void 0 : _a.checkInAt;
18635
+ const lastPresenceHome = date.DateUtil.formatTz(
18636
+ arrCheckInHomeReverse,
18637
+ opts
18638
+ );
18639
+ const arrAttendance = o.submitStaffAttendances.filter(
18640
+ (field2) => field2.type == "leave" && field2.status == "approved"
18641
+ ).map((field2) => date.DateUtil.formatTz(field2.startedAt, opts));
18642
+ if (arrAttendance.includes(todayDate)) {
18643
+ return "leave";
18644
+ } else {
18645
+ if (todayDate == lastPresence) {
18646
+ if (todayDate == lastPresenceHome) {
18647
+ return "home";
18648
+ } else {
18649
+ return "work";
18650
+ }
18651
+ } else {
18652
+ return "off";
18653
+ }
18654
+ }
18655
+ }
18656
+ }
18657
+ }),
18658
+ workCome: model$2.Field.define({
18659
+ handle: "workCome",
18660
+ name: "Masuk",
18661
+ type: "date",
18662
+ input: "date2",
18663
+ display: "date",
18664
+ options: {
18665
+ note: "Presensi masuk hari ini.",
18666
+ isVirtual: true,
18667
+ isPersisted: true
18668
+ },
18669
+ virtual: {
18670
+ dependency: {
18671
+ checkIns: {
18672
+ _id: 1,
18673
+ type: 1,
18674
+ checkInAt: 1
18675
+ }
18676
+ },
18677
+ reduce(o) {
18678
+ var _a, _b;
18679
+ if (!o.checkIns.length)
18680
+ return null;
18681
+ const todayDate = dayjs2((/* @__PURE__ */ new Date()).toISOString()).hour(0).minute(0).second(0).millisecond(0).toISOString();
18682
+ const checkInsCome = (_a = o.checkIns) == null ? void 0 : _a.filter(
18683
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
18684
+ );
18685
+ const checkInsNotNull = checkInsCome == null ? void 0 : checkInsCome.filter(
18686
+ (field2) => field2.checkInAt != null
18687
+ );
18688
+ const checkInAtCome = checkInsNotNull == null ? void 0 : checkInsNotNull.filter(
18689
+ (field2) => dayjs2(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() > todayDate
18690
+ );
18691
+ console.log({ checkInAtCome });
18692
+ if (!checkInAtCome.length) {
18693
+ return null;
18694
+ } else {
18695
+ const resultCheckInCome = (_b = checkInAtCome[0]) == null ? void 0 : _b.checkInAt;
18696
+ return resultCheckInCome;
18697
+ }
18698
+ }
18699
+ }
18700
+ }),
18701
+ workHome: model$2.Field.define({
18702
+ handle: "workHome",
18703
+ name: "Pulang",
18704
+ type: "date",
18705
+ input: "date2",
18706
+ display: "date",
18707
+ options: {
18708
+ note: "Presensi pulang hari ini.",
18709
+ isVirtual: true,
18710
+ isPersisted: true
18711
+ },
18712
+ virtual: {
18713
+ dependency: {
18714
+ checkIns: {
18715
+ _id: 1,
18716
+ type: 1,
18717
+ checkInAt: 1
18718
+ }
18719
+ },
18720
+ reduce(o) {
18721
+ var _a;
18722
+ if (!o.checkIns.length)
18723
+ return null;
18724
+ const lateTodayDate = dayjs2((/* @__PURE__ */ new Date()).toISOString()).hour(23).minute(0).second(0).millisecond(0).toISOString();
18725
+ const checkInsHome = o.checkIns.filter(
18726
+ (field2) => field2.type == "home"
18727
+ );
18728
+ const checkInsHomeNotNull = checkInsHome == null ? void 0 : checkInsHome.filter(
18729
+ (field2) => field2.checkInAt != null
18730
+ );
18731
+ const checkInAtHome = checkInsHomeNotNull.filter(
18732
+ (field2) => dayjs2(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() < lateTodayDate
18733
+ ).reverse();
18734
+ if (!checkInAtHome.length) {
18735
+ return null;
18736
+ } else {
18737
+ const resultCheckInHome = (_a = checkInAtHome[0]) == null ? void 0 : _a.checkInAt;
18738
+ const todayDateOnly = dayjs2(lateTodayDate).format("YYYY-MM-DD");
18739
+ const homeDateOnly = dayjs2(resultCheckInHome).format("YYYY-MM-DD");
18740
+ if (todayDateOnly == homeDateOnly) {
18741
+ return resultCheckInHome;
18742
+ } else {
18743
+ return null;
18744
+ }
18745
+ }
18746
+ }
18747
+ }
18748
+ }),
18749
+ workNote: model$2.Field.define({
18750
+ handle: "workNote",
18751
+ name: "Keterangan",
18752
+ type: "string",
18753
+ input: "short-text",
18754
+ options: {
18755
+ note: "Keterangan presensi hari ini.",
18756
+ isVirtual: true,
18757
+ isPersisted: true
18758
+ },
18759
+ virtual: {
18760
+ dependency: {
18761
+ workStatus: 1,
18762
+ checkIns: {
18763
+ _id: 1,
18764
+ type: 1,
18765
+ checkInAt: 1
18766
+ }
18767
+ },
18768
+ reduce(o) {
18769
+ var _a, _b, _c, _d, _e, _f;
18770
+ if (!o.checkIns.length)
18771
+ return null;
18772
+ const todayDate = dayjs2((/* @__PURE__ */ new Date()).toISOString()).hour(0).minute(0).second(0).millisecond(0).toISOString();
18773
+ const checkInsCome = (_a = o.checkIns) == null ? void 0 : _a.filter(
18774
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
18775
+ );
18776
+ const checkInsComeNotNull = checkInsCome == null ? void 0 : checkInsCome.filter(
18777
+ (field2) => field2.checkInAt != null
18778
+ );
18779
+ const checkInAtCome = checkInsComeNotNull == null ? void 0 : checkInsComeNotNull.filter(
18780
+ (field2) => dayjs2(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() > todayDate
18781
+ );
18782
+ const resultCheckInCome = checkInAtCome[0];
18783
+ const lateTodayDate = dayjs2((/* @__PURE__ */ new Date()).toISOString()).hour(23).minute(0).second(0).millisecond(0).toISOString();
18784
+ const checkInsHome = (_b = o.checkIns) == null ? void 0 : _b.filter(
18785
+ (field2) => field2.type == "home"
18786
+ );
18787
+ const checkInsHomeNotNull = checkInsHome == null ? void 0 : checkInsHome.filter(
18788
+ (field2) => field2.checkInAt != null
18789
+ );
18790
+ const checkInAtHome = (_c = checkInsHomeNotNull == null ? void 0 : checkInsHomeNotNull.filter(
18791
+ (field2) => dayjs2(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() < lateTodayDate
18792
+ )) == null ? void 0 : _c.reverse();
18793
+ const resultCheckInHome = checkInAtHome[0];
18794
+ const opts = { pattern: "yyyy-MM-dd" };
18795
+ const todayDateOnly = date.DateUtil.formatTz(
18796
+ (/* @__PURE__ */ new Date()).toISOString(),
18797
+ opts
18798
+ );
18799
+ const arrCheckInHome = (_d = o.checkIns) == null ? void 0 : _d.filter(
18800
+ (field2) => field2.type == "home"
18801
+ );
18802
+ const arrCheckInHomeReverse = (_e = arrCheckInHome == null ? void 0 : arrCheckInHome.reverse()[0]) == null ? void 0 : _e.checkInAt;
18803
+ const lastPresenceHome = date.DateUtil.formatTz(
18804
+ arrCheckInHomeReverse,
18805
+ opts
18806
+ );
18807
+ if (o.workStatus == "leave") {
18808
+ return "Cuti";
18809
+ } else if (o.workStatus == "off") {
18810
+ return "Belum Masuk";
18811
+ } else {
18812
+ if (todayDateOnly == lastPresenceHome) {
18813
+ const workMinutes = ((_f = date.DateUtil) == null ? void 0 : _f.diff(
18814
+ resultCheckInCome == null ? void 0 : resultCheckInCome.checkInAt,
18815
+ resultCheckInHome == null ? void 0 : resultCheckInHome.checkInAt,
18816
+ "minutes"
18817
+ )) || 0;
18818
+ const hours = Math.floor(workMinutes / 60);
18819
+ const minutes = workMinutes % 60;
18820
+ if (workMinutes < 540) {
18821
+ return `Jam kerja tidak memenuhi waktu minimal: ${hours} Jam ${minutes} minutes`;
18822
+ } else {
18823
+ return `Tepat Waktu: ${hours - 1} Jam ${minutes} minutes`;
18824
+ }
18825
+ } else {
18826
+ return "Sedang Bekerja";
18827
+ }
18828
+ }
18829
+ }
18830
+ }
18261
18831
  })
18262
18832
  },
18263
18833
  fragments: {
@@ -18296,7 +18866,11 @@ const StaffModel$2 = model$2.Model.define({
18296
18866
  display: 1,
18297
18867
  flag: 1,
18298
18868
  name: 1
18299
- }
18869
+ },
18870
+ workStatus: 1,
18871
+ workCome: 1,
18872
+ workHome: 1,
18873
+ workNote: 1
18300
18874
  },
18301
18875
  detail: {
18302
18876
  id: 1,
@@ -18337,7 +18911,11 @@ const StaffModel$2 = model$2.Model.define({
18337
18911
  branchId: 1,
18338
18912
  branchIds: 1,
18339
18913
  userId: 1,
18340
- virtualRoleIds: 1
18914
+ virtualRoleIds: 1,
18915
+ workStatus: 1,
18916
+ workCome: 1,
18917
+ workHome: 1,
18918
+ workNote: 1
18341
18919
  },
18342
18920
  fluffy: {}
18343
18921
  }
@@ -26066,6 +26644,7 @@ const _sfc_main$h = /* @__PURE__ */ vue$1.defineComponent({
26066
26644
  staffId: (_a2 = staff.value) == null ? void 0 : _a2.id
26067
26645
  });
26068
26646
  await syncOne();
26647
+ window.location.href = `/pengajuan/staff-submission?peek=neu:personalia:submission:${id.value}:single-staff-view:m`;
26069
26648
  };
26070
26649
  return (_ctx, _cache) => {
26071
26650
  return vue$1.openBlock(), vue$1.createBlock(vue$1.unref(context.NeonSingle), { class: "neu-submission-single" }, {
@@ -26309,7 +26888,7 @@ const _sfc_main$h = /* @__PURE__ */ vue$1.defineComponent({
26309
26888
  };
26310
26889
  }
26311
26890
  });
26312
- const SubmissionStaff = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["__scopeId", "data-v-e39fa184"]]);
26891
+ const SubmissionStaff = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["__scopeId", "data-v-d0c7c05c"]]);
26313
26892
  const _sfc_main$g = /* @__PURE__ */ vue$1.defineComponent({
26314
26893
  __name: "SubmissionFollowUp",
26315
26894
  setup(__props) {
@@ -26631,14 +27210,17 @@ const _sfc_main$f = /* @__PURE__ */ vue$1.defineComponent({
26631
27210
  const syncResolved = async () => {
26632
27211
  await executeOne("resolvedSubmission", { submissionId: id.value });
26633
27212
  await syncOne();
27213
+ window.location.href = `/pengajuan/audit-submission?peek=neu:personalia:submission:${id.value}:single-audit-view:m`;
26634
27214
  };
26635
27215
  const syncDiscontinued = async () => {
26636
27216
  await executeOne("discontinuedSubmission", { submissionId: id.value });
26637
27217
  await syncOne();
27218
+ window.location.href = `/pengajuan/audit-submission?peek=neu:personalia:submission:${id.value}:single-audit-view:m`;
26638
27219
  };
26639
27220
  const syncMonitored = async () => {
26640
27221
  await executeOne("monitoredSubmission", { submissionId: id.value });
26641
27222
  await syncOne();
27223
+ window.location.href = `/pengajuan/audit-submission?peek=neu:personalia:submission:${id.value}:single-audit-view:m`;
26642
27224
  };
26643
27225
  const syncProcessed = async () => {
26644
27226
  var _a2;
@@ -26647,6 +27229,7 @@ const _sfc_main$f = /* @__PURE__ */ vue$1.defineComponent({
26647
27229
  staffId: (_a2 = staff.value) == null ? void 0 : _a2.id
26648
27230
  });
26649
27231
  await syncOne();
27232
+ window.location.href = `/pengajuan/audit-submission?peek=neu:personalia:submission:${id.value}:single-audit-view:m`;
26650
27233
  };
26651
27234
  const syncLowered = async () => {
26652
27235
  var _a2;
@@ -26655,6 +27238,7 @@ const _sfc_main$f = /* @__PURE__ */ vue$1.defineComponent({
26655
27238
  staffId: (_a2 = staff.value) == null ? void 0 : _a2.id
26656
27239
  });
26657
27240
  await syncOne();
27241
+ window.location.href = `/pengajuan/audit-submission?peek=neu:personalia:submission:${id.value}:single-audit-view:m`;
26658
27242
  };
26659
27243
  return (_ctx, _cache) => {
26660
27244
  return vue$1.openBlock(), vue$1.createBlock(vue$1.unref(context.NeonSingle), { class: "neu-submission-single" }, {
@@ -27021,7 +27605,7 @@ const _sfc_main$f = /* @__PURE__ */ vue$1.defineComponent({
27021
27605
  };
27022
27606
  }
27023
27607
  });
27024
- const SubmissionAudit = /* @__PURE__ */ _export_sfc$1(_sfc_main$f, [["__scopeId", "data-v-3ef7852b"]]);
27608
+ const SubmissionAudit = /* @__PURE__ */ _export_sfc$1(_sfc_main$f, [["__scopeId", "data-v-d1ec1298"]]);
27025
27609
  const _hoisted_1$4 = { class: "flex flex-wrap" };
27026
27610
  const _hoisted_2$4 = { class: "mt-2" };
27027
27611
  const _hoisted_3$2 = { class: "mt-2" };
@@ -27134,6 +27718,7 @@ const _sfc_main$e = /* @__PURE__ */ vue$1.defineComponent({
27134
27718
  staffId: (_a2 = staff.value) == null ? void 0 : _a2.id
27135
27719
  });
27136
27720
  await syncOne();
27721
+ window.location.href = `/pengajuan/decision-submission?peek=neu:personalia:submission:${id.value}:single-decision-view:m`;
27137
27722
  };
27138
27723
  const syncApproved = async () => {
27139
27724
  var _a2;
@@ -27142,6 +27727,7 @@ const _sfc_main$e = /* @__PURE__ */ vue$1.defineComponent({
27142
27727
  staffId: (_a2 = staff.value) == null ? void 0 : _a2.id
27143
27728
  });
27144
27729
  await syncOne();
27730
+ window.location.href = `/pengajuan/decision-submission?peek=neu:personalia:submission:${id.value}:single-decision-view:m`;
27145
27731
  };
27146
27732
  return (_ctx, _cache) => {
27147
27733
  return vue$1.openBlock(), vue$1.createBlock(vue$1.unref(context.NeonSingle), { class: "neu-submission-single" }, {
@@ -27456,7 +28042,7 @@ const _sfc_main$e = /* @__PURE__ */ vue$1.defineComponent({
27456
28042
  };
27457
28043
  }
27458
28044
  });
27459
- const SubmissionDecision = /* @__PURE__ */ _export_sfc$1(_sfc_main$e, [["__scopeId", "data-v-b87a8600"]]);
28045
+ const SubmissionDecision = /* @__PURE__ */ _export_sfc$1(_sfc_main$e, [["__scopeId", "data-v-6f8e3ae5"]]);
27460
28046
  const _hoisted_1$3 = { class: "flex flex-wrap" };
27461
28047
  const _hoisted_2$3 = { class: "mt-2" };
27462
28048
  const _hoisted_3$1 = { class: "mt-2" };
@@ -29530,8 +30116,8 @@ function setDefaultFragments(model2) {
29530
30116
  model2.fragments.item = { id: 1, display: 1 };
29531
30117
  }
29532
30118
  }
29533
- var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
29534
- var freeGlobal$1 = typeof commonjsGlobal == "object" && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
30119
+ var commonjsGlobal$1 = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
30120
+ var freeGlobal$1 = typeof commonjsGlobal$1 == "object" && commonjsGlobal$1 && commonjsGlobal$1.Object === Object && commonjsGlobal$1;
29535
30121
  var _freeGlobal = freeGlobal$1;
29536
30122
  var freeGlobal = _freeGlobal;
29537
30123
  var freeSelf = typeof self == "object" && self && self.Object === Object && self;
@@ -31751,7 +32337,7 @@ var parseLocale2 = function parseLocale22(preset, object, isLocal) {
31751
32337
  L22 = l;
31752
32338
  return l || !isLocal && L22;
31753
32339
  };
31754
- var dayjs2 = function dayjs22(date2, c2) {
32340
+ var dayjs$1 = function dayjs3(date2, c2) {
31755
32341
  if (isDayjs2(date2)) {
31756
32342
  return date2.clone();
31757
32343
  }
@@ -31761,7 +32347,7 @@ var dayjs2 = function dayjs22(date2, c2) {
31761
32347
  return new Dayjs(cfg);
31762
32348
  };
31763
32349
  var wrapper$1 = function wrapper4(date2, instance) {
31764
- return dayjs2(date2, {
32350
+ return dayjs$1(date2, {
31765
32351
  locale: instance.$L,
31766
32352
  utc: instance.$u,
31767
32353
  x: instance.$x,
@@ -31824,14 +32410,14 @@ var Dayjs = /* @__PURE__ */ function() {
31824
32410
  return !(this.$d.toString() === INVALID_DATE_STRING);
31825
32411
  };
31826
32412
  _proto.isSame = function isSame(that, units) {
31827
- var other = dayjs2(that);
32413
+ var other = dayjs$1(that);
31828
32414
  return this.startOf(units) <= other && other <= this.endOf(units);
31829
32415
  };
31830
32416
  _proto.isAfter = function isAfter(that, units) {
31831
- return dayjs2(that) < this.startOf(units);
32417
+ return dayjs$1(that) < this.startOf(units);
31832
32418
  };
31833
32419
  _proto.isBefore = function isBefore(that, units) {
31834
- return this.endOf(units) < dayjs2(that);
32420
+ return this.endOf(units) < dayjs$1(that);
31835
32421
  };
31836
32422
  _proto.$g = function $g(input2, get2, set2) {
31837
32423
  if (Utils.u(input2))
@@ -31916,7 +32502,7 @@ var Dayjs = /* @__PURE__ */ function() {
31916
32502
  number = Number(number);
31917
32503
  var unit = Utils.p(units);
31918
32504
  var instanceFactorySet = function instanceFactorySet2(n) {
31919
- var d3 = dayjs2(_this2);
32505
+ var d3 = dayjs$1(_this2);
31920
32506
  return Utils.w(d3.date(d3.date() + Math.round(n * number)), _this2);
31921
32507
  };
31922
32508
  if (unit === M32) {
@@ -32020,7 +32606,7 @@ var Dayjs = /* @__PURE__ */ function() {
32020
32606
  _proto.diff = function diff(input2, units, _float) {
32021
32607
  var _this4 = this;
32022
32608
  var unit = Utils.p(units);
32023
- var that = dayjs2(input2);
32609
+ var that = dayjs$1(input2);
32024
32610
  var zoneDelta = (that.utcOffset() - this.utcOffset()) * MILLISECONDS_A_MINUTE;
32025
32611
  var diff2 = this - that;
32026
32612
  var getMonth = function getMonth2() {
@@ -32091,28 +32677,28 @@ var Dayjs = /* @__PURE__ */ function() {
32091
32677
  return Dayjs2;
32092
32678
  }();
32093
32679
  var proto = Dayjs.prototype;
32094
- dayjs2.prototype = proto;
32680
+ dayjs$1.prototype = proto;
32095
32681
  [["$ms", MS], ["$s", S32], ["$m", MIN], ["$H", H32], ["$W", D22], ["$M", M32], ["$y", Y22], ["$D", DATE]].forEach(function(g) {
32096
32682
  proto[g[1]] = function(input2) {
32097
32683
  return this.$g(input2, g[0], g[1]);
32098
32684
  };
32099
32685
  });
32100
- dayjs2.extend = function(plugin, option) {
32686
+ dayjs$1.extend = function(plugin, option) {
32101
32687
  if (!plugin.$i) {
32102
- plugin(option, Dayjs, dayjs2);
32688
+ plugin(option, Dayjs, dayjs$1);
32103
32689
  plugin.$i = true;
32104
32690
  }
32105
- return dayjs2;
32691
+ return dayjs$1;
32106
32692
  };
32107
- dayjs2.locale = parseLocale2;
32108
- dayjs2.isDayjs = isDayjs2;
32109
- dayjs2.unix = function(timestamp) {
32110
- return dayjs2(timestamp * 1e3);
32693
+ dayjs$1.locale = parseLocale2;
32694
+ dayjs$1.isDayjs = isDayjs2;
32695
+ dayjs$1.unix = function(timestamp) {
32696
+ return dayjs$1(timestamp * 1e3);
32111
32697
  };
32112
- dayjs2.en = Ls[L22];
32113
- dayjs2.Ls = Ls;
32114
- dayjs2.p = {};
32115
- const dayjs$1 = dayjs2;
32698
+ dayjs$1.en = Ls[L22];
32699
+ dayjs$1.Ls = Ls;
32700
+ dayjs$1.p = {};
32701
+ const dayjs$2 = dayjs$1;
32116
32702
  var locale = {
32117
32703
  name: "id",
32118
32704
  weekdays: "Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),
@@ -32148,7 +32734,7 @@ var locale = {
32148
32734
  return n + ".";
32149
32735
  }
32150
32736
  };
32151
- dayjs$1.locale(locale, null, true);
32737
+ dayjs$2.locale(locale, null, true);
32152
32738
  const advancedFormat = function(o, c2) {
32153
32739
  var proto2 = c2.prototype;
32154
32740
  var oldFormat = proto2.format;
@@ -32457,16 +33043,16 @@ var Duration = /* @__PURE__ */ function() {
32457
33043
  var manipulateDuration2 = function manipulateDuration22(date2, duration, k2) {
32458
33044
  return date2.add(duration.years() * k2, "y").add(duration.months() * k2, "M").add(duration.days() * k2, "d").add(duration.hours() * k2, "h").add(duration.minutes() * k2, "m").add(duration.seconds() * k2, "s").add(duration.milliseconds() * k2, "ms");
32459
33045
  };
32460
- const durationPlugin = function(option, Dayjs2, dayjs3) {
32461
- $d = dayjs3;
32462
- $u = dayjs3().$utils();
32463
- dayjs3.duration = function(input2, unit) {
32464
- var $l = dayjs3.locale();
33046
+ const durationPlugin = function(option, Dayjs2, dayjs32) {
33047
+ $d = dayjs32;
33048
+ $u = dayjs32().$utils();
33049
+ dayjs32.duration = function(input2, unit) {
33050
+ var $l = dayjs32.locale();
32465
33051
  return wrapper22(input2, {
32466
33052
  $l
32467
33053
  }, unit);
32468
33054
  };
32469
- dayjs3.isDuration = isDuration2;
33055
+ dayjs32.isDuration = isDuration2;
32470
33056
  var oldAdd = Dayjs2.prototype.add;
32471
33057
  var oldSubtract = Dayjs2.prototype.subtract;
32472
33058
  Dayjs2.prototype.add = function(value, unit) {
@@ -32638,11 +33224,11 @@ const relativeTimePlugin = function(o, c2, d3) {
32638
33224
  return this.from(makeNow(this), withoutSuffix);
32639
33225
  };
32640
33226
  };
32641
- dayjs$1.extend(durationPlugin);
32642
- dayjs$1.extend(relativeTimePlugin);
32643
- dayjs$1.extend(advancedFormat);
32644
- dayjs$1.extend(isoWeek);
32645
- dayjs$1.locale("id");
33227
+ dayjs$2.extend(durationPlugin);
33228
+ dayjs$2.extend(relativeTimePlugin);
33229
+ dayjs$2.extend(advancedFormat);
33230
+ dayjs$2.extend(isoWeek);
33231
+ dayjs$2.locale("id");
32646
33232
  const EntranceStatus = model$2.Choice.define({
32647
33233
  handle: "entranceStatus",
32648
33234
  name: "Entrance Status",
@@ -34612,6 +35198,37 @@ const StatusStaff = model$2.Choice.define({
34612
35198
  }
34613
35199
  ]
34614
35200
  });
35201
+ const StatusWork = model$2.Choice.define({
35202
+ handle: "statusWork",
35203
+ name: "Work Status",
35204
+ items: [
35205
+ {
35206
+ label: "Off",
35207
+ value: "off",
35208
+ color: "danger"
35209
+ },
35210
+ {
35211
+ label: "Kerja",
35212
+ value: "work",
35213
+ color: "success"
35214
+ },
35215
+ {
35216
+ label: "Cuti",
35217
+ value: "leave",
35218
+ color: "warning"
35219
+ },
35220
+ {
35221
+ label: "Libur",
35222
+ value: "holiday",
35223
+ color: "info"
35224
+ },
35225
+ {
35226
+ label: "Pulang",
35227
+ value: "home",
35228
+ color: "info"
35229
+ }
35230
+ ]
35231
+ });
34615
35232
  const PriorityStatus = model$2.Choice.define({
34616
35233
  handle: "priorityStatus",
34617
35234
  name: "Priority Status",
@@ -38495,6 +39112,302 @@ const SituationTypeModel = model$2.Model.define({
38495
39112
  fluffy: {}
38496
39113
  }
38497
39114
  });
39115
+ var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
39116
+ function getDefaultExportFromCjs(x2) {
39117
+ return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
39118
+ }
39119
+ var dayjs_min = { exports: {} };
39120
+ (function(module2, exports2) {
39121
+ !function(t2, e3) {
39122
+ module2.exports = e3();
39123
+ }(commonjsGlobal, function() {
39124
+ var t2 = 1e3, e3 = 6e4, n = 36e5, r = "millisecond", i2 = "second", s3 = "minute", u2 = "hour", a3 = "day", o = "week", c2 = "month", f = "quarter", h4 = "year", d3 = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y3 = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M4 = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t3) {
39125
+ var e4 = ["th", "st", "nd", "rd"], n2 = t3 % 100;
39126
+ return "[" + t3 + (e4[(n2 - 20) % 10] || e4[n2] || e4[0]) + "]";
39127
+ } }, m3 = function(t3, e4, n2) {
39128
+ var r2 = String(t3);
39129
+ return !r2 || r2.length >= e4 ? t3 : "" + Array(e4 + 1 - r2.length).join(n2) + t3;
39130
+ }, v = { s: m3, z: function(t3) {
39131
+ var e4 = -t3.utcOffset(), n2 = Math.abs(e4), r2 = Math.floor(n2 / 60), i3 = n2 % 60;
39132
+ return (e4 <= 0 ? "+" : "-") + m3(r2, 2, "0") + ":" + m3(i3, 2, "0");
39133
+ }, m: function t3(e4, n2) {
39134
+ if (e4.date() < n2.date())
39135
+ return -t3(n2, e4);
39136
+ var r2 = 12 * (n2.year() - e4.year()) + (n2.month() - e4.month()), i3 = e4.clone().add(r2, c2), s4 = n2 - i3 < 0, u3 = e4.clone().add(r2 + (s4 ? -1 : 1), c2);
39137
+ return +(-(r2 + (n2 - i3) / (s4 ? i3 - u3 : u3 - i3)) || 0);
39138
+ }, a: function(t3) {
39139
+ return t3 < 0 ? Math.ceil(t3) || 0 : Math.floor(t3);
39140
+ }, p: function(t3) {
39141
+ return { M: c2, y: h4, w: o, d: a3, D: d3, h: u2, m: s3, s: i2, ms: r, Q: f }[t3] || String(t3 || "").toLowerCase().replace(/s$/, "");
39142
+ }, u: function(t3) {
39143
+ return void 0 === t3;
39144
+ } }, g = "en", D3 = {};
39145
+ D3[g] = M4;
39146
+ var p = "$isDayjsObject", S4 = function(t3) {
39147
+ return t3 instanceof _ || !(!t3 || !t3[p]);
39148
+ }, w2 = function t3(e4, n2, r2) {
39149
+ var i3;
39150
+ if (!e4)
39151
+ return g;
39152
+ if ("string" == typeof e4) {
39153
+ var s4 = e4.toLowerCase();
39154
+ D3[s4] && (i3 = s4), n2 && (D3[s4] = n2, i3 = s4);
39155
+ var u3 = e4.split("-");
39156
+ if (!i3 && u3.length > 1)
39157
+ return t3(u3[0]);
39158
+ } else {
39159
+ var a4 = e4.name;
39160
+ D3[a4] = e4, i3 = a4;
39161
+ }
39162
+ return !r2 && i3 && (g = i3), i3 || !r2 && g;
39163
+ }, O2 = function(t3, e4) {
39164
+ if (S4(t3))
39165
+ return t3.clone();
39166
+ var n2 = "object" == typeof e4 ? e4 : {};
39167
+ return n2.date = t3, n2.args = arguments, new _(n2);
39168
+ }, b2 = v;
39169
+ b2.l = w2, b2.i = S4, b2.w = function(t3, e4) {
39170
+ return O2(t3, { locale: e4.$L, utc: e4.$u, x: e4.$x, $offset: e4.$offset });
39171
+ };
39172
+ var _ = function() {
39173
+ function M5(t3) {
39174
+ this.$L = w2(t3.locale, null, true), this.parse(t3), this.$x = this.$x || t3.x || {}, this[p] = true;
39175
+ }
39176
+ var m4 = M5.prototype;
39177
+ return m4.parse = function(t3) {
39178
+ this.$d = function(t4) {
39179
+ var e4 = t4.date, n2 = t4.utc;
39180
+ if (null === e4)
39181
+ return /* @__PURE__ */ new Date(NaN);
39182
+ if (b2.u(e4))
39183
+ return /* @__PURE__ */ new Date();
39184
+ if (e4 instanceof Date)
39185
+ return new Date(e4);
39186
+ if ("string" == typeof e4 && !/Z$/i.test(e4)) {
39187
+ var r2 = e4.match($);
39188
+ if (r2) {
39189
+ var i3 = r2[2] - 1 || 0, s4 = (r2[7] || "0").substring(0, 3);
39190
+ return n2 ? new Date(Date.UTC(r2[1], i3, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s4)) : new Date(r2[1], i3, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s4);
39191
+ }
39192
+ }
39193
+ return new Date(e4);
39194
+ }(t3), this.init();
39195
+ }, m4.init = function() {
39196
+ var t3 = this.$d;
39197
+ this.$y = t3.getFullYear(), this.$M = t3.getMonth(), this.$D = t3.getDate(), this.$W = t3.getDay(), this.$H = t3.getHours(), this.$m = t3.getMinutes(), this.$s = t3.getSeconds(), this.$ms = t3.getMilliseconds();
39198
+ }, m4.$utils = function() {
39199
+ return b2;
39200
+ }, m4.isValid = function() {
39201
+ return !(this.$d.toString() === l);
39202
+ }, m4.isSame = function(t3, e4) {
39203
+ var n2 = O2(t3);
39204
+ return this.startOf(e4) <= n2 && n2 <= this.endOf(e4);
39205
+ }, m4.isAfter = function(t3, e4) {
39206
+ return O2(t3) < this.startOf(e4);
39207
+ }, m4.isBefore = function(t3, e4) {
39208
+ return this.endOf(e4) < O2(t3);
39209
+ }, m4.$g = function(t3, e4, n2) {
39210
+ return b2.u(t3) ? this[e4] : this.set(n2, t3);
39211
+ }, m4.unix = function() {
39212
+ return Math.floor(this.valueOf() / 1e3);
39213
+ }, m4.valueOf = function() {
39214
+ return this.$d.getTime();
39215
+ }, m4.startOf = function(t3, e4) {
39216
+ var n2 = this, r2 = !!b2.u(e4) || e4, f2 = b2.p(t3), l2 = function(t4, e5) {
39217
+ var i3 = b2.w(n2.$u ? Date.UTC(n2.$y, e5, t4) : new Date(n2.$y, e5, t4), n2);
39218
+ return r2 ? i3 : i3.endOf(a3);
39219
+ }, $2 = function(t4, e5) {
39220
+ return b2.w(n2.toDate()[t4].apply(n2.toDate("s"), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e5)), n2);
39221
+ }, y4 = this.$W, M6 = this.$M, m5 = this.$D, v2 = "set" + (this.$u ? "UTC" : "");
39222
+ switch (f2) {
39223
+ case h4:
39224
+ return r2 ? l2(1, 0) : l2(31, 11);
39225
+ case c2:
39226
+ return r2 ? l2(1, M6) : l2(0, M6 + 1);
39227
+ case o:
39228
+ var g2 = this.$locale().weekStart || 0, D4 = (y4 < g2 ? y4 + 7 : y4) - g2;
39229
+ return l2(r2 ? m5 - D4 : m5 + (6 - D4), M6);
39230
+ case a3:
39231
+ case d3:
39232
+ return $2(v2 + "Hours", 0);
39233
+ case u2:
39234
+ return $2(v2 + "Minutes", 1);
39235
+ case s3:
39236
+ return $2(v2 + "Seconds", 2);
39237
+ case i2:
39238
+ return $2(v2 + "Milliseconds", 3);
39239
+ default:
39240
+ return this.clone();
39241
+ }
39242
+ }, m4.endOf = function(t3) {
39243
+ return this.startOf(t3, false);
39244
+ }, m4.$set = function(t3, e4) {
39245
+ var n2, o2 = b2.p(t3), f2 = "set" + (this.$u ? "UTC" : ""), l2 = (n2 = {}, n2[a3] = f2 + "Date", n2[d3] = f2 + "Date", n2[c2] = f2 + "Month", n2[h4] = f2 + "FullYear", n2[u2] = f2 + "Hours", n2[s3] = f2 + "Minutes", n2[i2] = f2 + "Seconds", n2[r] = f2 + "Milliseconds", n2)[o2], $2 = o2 === a3 ? this.$D + (e4 - this.$W) : e4;
39246
+ if (o2 === c2 || o2 === h4) {
39247
+ var y4 = this.clone().set(d3, 1);
39248
+ y4.$d[l2]($2), y4.init(), this.$d = y4.set(d3, Math.min(this.$D, y4.daysInMonth())).$d;
39249
+ } else
39250
+ l2 && this.$d[l2]($2);
39251
+ return this.init(), this;
39252
+ }, m4.set = function(t3, e4) {
39253
+ return this.clone().$set(t3, e4);
39254
+ }, m4.get = function(t3) {
39255
+ return this[b2.p(t3)]();
39256
+ }, m4.add = function(r2, f2) {
39257
+ var d4, l2 = this;
39258
+ r2 = Number(r2);
39259
+ var $2 = b2.p(f2), y4 = function(t3) {
39260
+ var e4 = O2(l2);
39261
+ return b2.w(e4.date(e4.date() + Math.round(t3 * r2)), l2);
39262
+ };
39263
+ if ($2 === c2)
39264
+ return this.set(c2, this.$M + r2);
39265
+ if ($2 === h4)
39266
+ return this.set(h4, this.$y + r2);
39267
+ if ($2 === a3)
39268
+ return y4(1);
39269
+ if ($2 === o)
39270
+ return y4(7);
39271
+ var M6 = (d4 = {}, d4[s3] = e3, d4[u2] = n, d4[i2] = t2, d4)[$2] || 1, m5 = this.$d.getTime() + r2 * M6;
39272
+ return b2.w(m5, this);
39273
+ }, m4.subtract = function(t3, e4) {
39274
+ return this.add(-1 * t3, e4);
39275
+ }, m4.format = function(t3) {
39276
+ var e4 = this, n2 = this.$locale();
39277
+ if (!this.isValid())
39278
+ return n2.invalidDate || l;
39279
+ var r2 = t3 || "YYYY-MM-DDTHH:mm:ssZ", i3 = b2.z(this), s4 = this.$H, u3 = this.$m, a4 = this.$M, o2 = n2.weekdays, c3 = n2.months, f2 = n2.meridiem, h5 = function(t4, n3, i4, s5) {
39280
+ return t4 && (t4[n3] || t4(e4, r2)) || i4[n3].slice(0, s5);
39281
+ }, d4 = function(t4) {
39282
+ return b2.s(s4 % 12 || 12, t4, "0");
39283
+ }, $2 = f2 || function(t4, e5, n3) {
39284
+ var r3 = t4 < 12 ? "AM" : "PM";
39285
+ return n3 ? r3.toLowerCase() : r3;
39286
+ };
39287
+ return r2.replace(y3, function(t4, r3) {
39288
+ return r3 || function(t5) {
39289
+ switch (t5) {
39290
+ case "YY":
39291
+ return String(e4.$y).slice(-2);
39292
+ case "YYYY":
39293
+ return b2.s(e4.$y, 4, "0");
39294
+ case "M":
39295
+ return a4 + 1;
39296
+ case "MM":
39297
+ return b2.s(a4 + 1, 2, "0");
39298
+ case "MMM":
39299
+ return h5(n2.monthsShort, a4, c3, 3);
39300
+ case "MMMM":
39301
+ return h5(c3, a4);
39302
+ case "D":
39303
+ return e4.$D;
39304
+ case "DD":
39305
+ return b2.s(e4.$D, 2, "0");
39306
+ case "d":
39307
+ return String(e4.$W);
39308
+ case "dd":
39309
+ return h5(n2.weekdaysMin, e4.$W, o2, 2);
39310
+ case "ddd":
39311
+ return h5(n2.weekdaysShort, e4.$W, o2, 3);
39312
+ case "dddd":
39313
+ return o2[e4.$W];
39314
+ case "H":
39315
+ return String(s4);
39316
+ case "HH":
39317
+ return b2.s(s4, 2, "0");
39318
+ case "h":
39319
+ return d4(1);
39320
+ case "hh":
39321
+ return d4(2);
39322
+ case "a":
39323
+ return $2(s4, u3, true);
39324
+ case "A":
39325
+ return $2(s4, u3, false);
39326
+ case "m":
39327
+ return String(u3);
39328
+ case "mm":
39329
+ return b2.s(u3, 2, "0");
39330
+ case "s":
39331
+ return String(e4.$s);
39332
+ case "ss":
39333
+ return b2.s(e4.$s, 2, "0");
39334
+ case "SSS":
39335
+ return b2.s(e4.$ms, 3, "0");
39336
+ case "Z":
39337
+ return i3;
39338
+ }
39339
+ return null;
39340
+ }(t4) || i3.replace(":", "");
39341
+ });
39342
+ }, m4.utcOffset = function() {
39343
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
39344
+ }, m4.diff = function(r2, d4, l2) {
39345
+ var $2, y4 = this, M6 = b2.p(d4), m5 = O2(r2), v2 = (m5.utcOffset() - this.utcOffset()) * e3, g2 = this - m5, D4 = function() {
39346
+ return b2.m(y4, m5);
39347
+ };
39348
+ switch (M6) {
39349
+ case h4:
39350
+ $2 = D4() / 12;
39351
+ break;
39352
+ case c2:
39353
+ $2 = D4();
39354
+ break;
39355
+ case f:
39356
+ $2 = D4() / 3;
39357
+ break;
39358
+ case o:
39359
+ $2 = (g2 - v2) / 6048e5;
39360
+ break;
39361
+ case a3:
39362
+ $2 = (g2 - v2) / 864e5;
39363
+ break;
39364
+ case u2:
39365
+ $2 = g2 / n;
39366
+ break;
39367
+ case s3:
39368
+ $2 = g2 / e3;
39369
+ break;
39370
+ case i2:
39371
+ $2 = g2 / t2;
39372
+ break;
39373
+ default:
39374
+ $2 = g2;
39375
+ }
39376
+ return l2 ? $2 : b2.a($2);
39377
+ }, m4.daysInMonth = function() {
39378
+ return this.endOf(c2).$D;
39379
+ }, m4.$locale = function() {
39380
+ return D3[this.$L];
39381
+ }, m4.locale = function(t3, e4) {
39382
+ if (!t3)
39383
+ return this.$L;
39384
+ var n2 = this.clone(), r2 = w2(t3, e4, true);
39385
+ return r2 && (n2.$L = r2), n2;
39386
+ }, m4.clone = function() {
39387
+ return b2.w(this.$d, this);
39388
+ }, m4.toDate = function() {
39389
+ return new Date(this.valueOf());
39390
+ }, m4.toJSON = function() {
39391
+ return this.isValid() ? this.toISOString() : null;
39392
+ }, m4.toISOString = function() {
39393
+ return this.$d.toISOString();
39394
+ }, m4.toString = function() {
39395
+ return this.$d.toUTCString();
39396
+ }, M5;
39397
+ }(), k2 = _.prototype;
39398
+ return O2.prototype = k2, [["$ms", r], ["$s", i2], ["$m", s3], ["$H", u2], ["$W", a3], ["$M", c2], ["$y", h4], ["$D", d3]].forEach(function(t3) {
39399
+ k2[t3[1]] = function(e4) {
39400
+ return this.$g(e4, t3[0], t3[1]);
39401
+ };
39402
+ }), O2.extend = function(t3, e4) {
39403
+ return t3.$i || (t3(e4, _, O2), t3.$i = true), O2;
39404
+ }, O2.locale = w2, O2.isDayjs = S4, O2.unix = function(t3) {
39405
+ return O2(1e3 * t3);
39406
+ }, O2.en = D3[g], O2.Ls = D3, O2.p = {}, O2;
39407
+ });
39408
+ })(dayjs_min);
39409
+ var dayjs_minExports = dayjs_min.exports;
39410
+ const dayjs22 = /* @__PURE__ */ getDefaultExportFromCjs(dayjs_minExports);
38498
39411
  const StaffModel$1 = model$2.Model.define({
38499
39412
  name: "Staff",
38500
39413
  definition: "neu:personalia:staff",
@@ -38701,6 +39614,249 @@ const StaffModel$1 = model$2.Model.define({
38701
39614
  return roleIds;
38702
39615
  }
38703
39616
  }
39617
+ }),
39618
+ workStatus: model$2.Field.define({
39619
+ handle: "workStatus",
39620
+ name: "Status",
39621
+ type: "string",
39622
+ input: "select",
39623
+ options: {
39624
+ note: "Status dari karyawan.",
39625
+ default: "notActive",
39626
+ enums: StatusWork.values,
39627
+ choices: StatusWork.items,
39628
+ isVirtual: true,
39629
+ isPersisted: true
39630
+ },
39631
+ virtual: {
39632
+ dependency: {
39633
+ checkIns: {
39634
+ _id: 1,
39635
+ type: 1,
39636
+ checkInAt: 1
39637
+ },
39638
+ submitStaffAttendances: {
39639
+ _id: 1,
39640
+ type: 1,
39641
+ startedAt: 1,
39642
+ status: 1
39643
+ }
39644
+ },
39645
+ reduce(o) {
39646
+ var _a;
39647
+ if (!o.checkIns.length)
39648
+ return "off";
39649
+ const opts = { pattern: "yyyy-MM-dd" };
39650
+ const todayDate = date.DateUtil.formatTz((/* @__PURE__ */ new Date()).toISOString(), opts);
39651
+ const arrCheckIn = o.checkIns.filter(
39652
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
39653
+ );
39654
+ const arrCheckInReverse = arrCheckIn.reverse();
39655
+ const checkInAtReverse = arrCheckInReverse[0];
39656
+ const lastPresence = date.DateUtil.formatTz(
39657
+ checkInAtReverse == null ? void 0 : checkInAtReverse.checkInAt,
39658
+ opts
39659
+ );
39660
+ const arrCheckInHome = o.checkIns.filter(
39661
+ (field2) => field2.type == "home"
39662
+ );
39663
+ const arrCheckInHomeReverse = (_a = arrCheckInHome.reverse()[0]) == null ? void 0 : _a.checkInAt;
39664
+ const lastPresenceHome = date.DateUtil.formatTz(
39665
+ arrCheckInHomeReverse,
39666
+ opts
39667
+ );
39668
+ const arrAttendance = o.submitStaffAttendances.filter(
39669
+ (field2) => field2.type == "leave" && field2.status == "approved"
39670
+ ).map((field2) => date.DateUtil.formatTz(field2.startedAt, opts));
39671
+ if (arrAttendance.includes(todayDate)) {
39672
+ return "leave";
39673
+ } else {
39674
+ if (todayDate == lastPresence) {
39675
+ if (todayDate == lastPresenceHome) {
39676
+ return "home";
39677
+ } else {
39678
+ return "work";
39679
+ }
39680
+ } else {
39681
+ return "off";
39682
+ }
39683
+ }
39684
+ }
39685
+ }
39686
+ }),
39687
+ workCome: model$2.Field.define({
39688
+ handle: "workCome",
39689
+ name: "Masuk",
39690
+ type: "date",
39691
+ input: "date2",
39692
+ display: "date",
39693
+ options: {
39694
+ note: "Presensi masuk hari ini.",
39695
+ isVirtual: true,
39696
+ isPersisted: true
39697
+ },
39698
+ virtual: {
39699
+ dependency: {
39700
+ checkIns: {
39701
+ _id: 1,
39702
+ type: 1,
39703
+ checkInAt: 1
39704
+ }
39705
+ },
39706
+ reduce(o) {
39707
+ var _a, _b;
39708
+ if (!o.checkIns.length)
39709
+ return null;
39710
+ const todayDate = dayjs22((/* @__PURE__ */ new Date()).toISOString()).hour(0).minute(0).second(0).millisecond(0).toISOString();
39711
+ const checkInsCome = (_a = o.checkIns) == null ? void 0 : _a.filter(
39712
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
39713
+ );
39714
+ const checkInsNotNull = checkInsCome == null ? void 0 : checkInsCome.filter(
39715
+ (field2) => field2.checkInAt != null
39716
+ );
39717
+ const checkInAtCome = checkInsNotNull == null ? void 0 : checkInsNotNull.filter(
39718
+ (field2) => dayjs22(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() > todayDate
39719
+ );
39720
+ console.log({ checkInAtCome });
39721
+ if (!checkInAtCome.length) {
39722
+ return null;
39723
+ } else {
39724
+ const resultCheckInCome = (_b = checkInAtCome[0]) == null ? void 0 : _b.checkInAt;
39725
+ return resultCheckInCome;
39726
+ }
39727
+ }
39728
+ }
39729
+ }),
39730
+ workHome: model$2.Field.define({
39731
+ handle: "workHome",
39732
+ name: "Pulang",
39733
+ type: "date",
39734
+ input: "date2",
39735
+ display: "date",
39736
+ options: {
39737
+ note: "Presensi pulang hari ini.",
39738
+ isVirtual: true,
39739
+ isPersisted: true
39740
+ },
39741
+ virtual: {
39742
+ dependency: {
39743
+ checkIns: {
39744
+ _id: 1,
39745
+ type: 1,
39746
+ checkInAt: 1
39747
+ }
39748
+ },
39749
+ reduce(o) {
39750
+ var _a;
39751
+ if (!o.checkIns.length)
39752
+ return null;
39753
+ const lateTodayDate = dayjs22((/* @__PURE__ */ new Date()).toISOString()).hour(23).minute(0).second(0).millisecond(0).toISOString();
39754
+ const checkInsHome = o.checkIns.filter(
39755
+ (field2) => field2.type == "home"
39756
+ );
39757
+ const checkInsHomeNotNull = checkInsHome == null ? void 0 : checkInsHome.filter(
39758
+ (field2) => field2.checkInAt != null
39759
+ );
39760
+ const checkInAtHome = checkInsHomeNotNull.filter(
39761
+ (field2) => dayjs22(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() < lateTodayDate
39762
+ ).reverse();
39763
+ if (!checkInAtHome.length) {
39764
+ return null;
39765
+ } else {
39766
+ const resultCheckInHome = (_a = checkInAtHome[0]) == null ? void 0 : _a.checkInAt;
39767
+ const todayDateOnly = dayjs22(lateTodayDate).format("YYYY-MM-DD");
39768
+ const homeDateOnly = dayjs22(resultCheckInHome).format("YYYY-MM-DD");
39769
+ if (todayDateOnly == homeDateOnly) {
39770
+ return resultCheckInHome;
39771
+ } else {
39772
+ return null;
39773
+ }
39774
+ }
39775
+ }
39776
+ }
39777
+ }),
39778
+ workNote: model$2.Field.define({
39779
+ handle: "workNote",
39780
+ name: "Keterangan",
39781
+ type: "string",
39782
+ input: "short-text",
39783
+ options: {
39784
+ note: "Keterangan presensi hari ini.",
39785
+ isVirtual: true,
39786
+ isPersisted: true
39787
+ },
39788
+ virtual: {
39789
+ dependency: {
39790
+ workStatus: 1,
39791
+ checkIns: {
39792
+ _id: 1,
39793
+ type: 1,
39794
+ checkInAt: 1
39795
+ }
39796
+ },
39797
+ reduce(o) {
39798
+ var _a, _b, _c, _d, _e, _f;
39799
+ if (!o.checkIns.length)
39800
+ return null;
39801
+ const todayDate = dayjs22((/* @__PURE__ */ new Date()).toISOString()).hour(0).minute(0).second(0).millisecond(0).toISOString();
39802
+ const checkInsCome = (_a = o.checkIns) == null ? void 0 : _a.filter(
39803
+ (field2) => field2.type == "in" || field2.type == "checkpoint" || field2.type == "checkin"
39804
+ );
39805
+ const checkInsComeNotNull = checkInsCome == null ? void 0 : checkInsCome.filter(
39806
+ (field2) => field2.checkInAt != null
39807
+ );
39808
+ const checkInAtCome = checkInsComeNotNull == null ? void 0 : checkInsComeNotNull.filter(
39809
+ (field2) => dayjs22(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() > todayDate
39810
+ );
39811
+ const resultCheckInCome = checkInAtCome[0];
39812
+ const lateTodayDate = dayjs22((/* @__PURE__ */ new Date()).toISOString()).hour(23).minute(0).second(0).millisecond(0).toISOString();
39813
+ const checkInsHome = (_b = o.checkIns) == null ? void 0 : _b.filter(
39814
+ (field2) => field2.type == "home"
39815
+ );
39816
+ const checkInsHomeNotNull = checkInsHome == null ? void 0 : checkInsHome.filter(
39817
+ (field2) => field2.checkInAt != null
39818
+ );
39819
+ const checkInAtHome = (_c = checkInsHomeNotNull == null ? void 0 : checkInsHomeNotNull.filter(
39820
+ (field2) => dayjs22(field2 == null ? void 0 : field2.checkInAt).add(7, "hour").toISOString() < lateTodayDate
39821
+ )) == null ? void 0 : _c.reverse();
39822
+ const resultCheckInHome = checkInAtHome[0];
39823
+ const opts = { pattern: "yyyy-MM-dd" };
39824
+ const todayDateOnly = date.DateUtil.formatTz(
39825
+ (/* @__PURE__ */ new Date()).toISOString(),
39826
+ opts
39827
+ );
39828
+ const arrCheckInHome = (_d = o.checkIns) == null ? void 0 : _d.filter(
39829
+ (field2) => field2.type == "home"
39830
+ );
39831
+ const arrCheckInHomeReverse = (_e = arrCheckInHome == null ? void 0 : arrCheckInHome.reverse()[0]) == null ? void 0 : _e.checkInAt;
39832
+ const lastPresenceHome = date.DateUtil.formatTz(
39833
+ arrCheckInHomeReverse,
39834
+ opts
39835
+ );
39836
+ if (o.workStatus == "leave") {
39837
+ return "Cuti";
39838
+ } else if (o.workStatus == "off") {
39839
+ return "Belum Masuk";
39840
+ } else {
39841
+ if (todayDateOnly == lastPresenceHome) {
39842
+ const workMinutes = ((_f = date.DateUtil) == null ? void 0 : _f.diff(
39843
+ resultCheckInCome == null ? void 0 : resultCheckInCome.checkInAt,
39844
+ resultCheckInHome == null ? void 0 : resultCheckInHome.checkInAt,
39845
+ "minutes"
39846
+ )) || 0;
39847
+ const hours = Math.floor(workMinutes / 60);
39848
+ const minutes = workMinutes % 60;
39849
+ if (workMinutes < 540) {
39850
+ return `Jam kerja tidak memenuhi waktu minimal: ${hours} Jam ${minutes} minutes`;
39851
+ } else {
39852
+ return `Tepat Waktu: ${hours - 1} Jam ${minutes} minutes`;
39853
+ }
39854
+ } else {
39855
+ return "Sedang Bekerja";
39856
+ }
39857
+ }
39858
+ }
39859
+ }
38704
39860
  })
38705
39861
  },
38706
39862
  fragments: {
@@ -38739,7 +39895,11 @@ const StaffModel$1 = model$2.Model.define({
38739
39895
  display: 1,
38740
39896
  flag: 1,
38741
39897
  name: 1
38742
- }
39898
+ },
39899
+ workStatus: 1,
39900
+ workCome: 1,
39901
+ workHome: 1,
39902
+ workNote: 1
38743
39903
  },
38744
39904
  detail: {
38745
39905
  id: 1,
@@ -38780,7 +39940,11 @@ const StaffModel$1 = model$2.Model.define({
38780
39940
  branchId: 1,
38781
39941
  branchIds: 1,
38782
39942
  userId: 1,
38783
- virtualRoleIds: 1
39943
+ virtualRoleIds: 1,
39944
+ workStatus: 1,
39945
+ workCome: 1,
39946
+ workHome: 1,
39947
+ workNote: 1
38784
39948
  },
38785
39949
  fluffy: {}
38786
39950
  }
@@ -39842,6 +41006,45 @@ const CheckInSingleSupervisorView = office$1.ResourceUtil.createSingle({
39842
41006
  },
39843
41007
  path: "/pengawas/checkIns"
39844
41008
  });
41009
+ const CheckInCollectionStaffView = office$1.ResourceUtil.createCollection({
41010
+ name: "staff",
41011
+ definition: "neu:tempat:checkIn",
41012
+ title: "Riwayat Presensi",
41013
+ icon: "clock-rotate-left",
41014
+ scope: "staff",
41015
+ path: "/staff/checkIns",
41016
+ single: {
41017
+ view: "external",
41018
+ peeks: ["modal"]
41019
+ },
41020
+ columns: [
41021
+ "statusGPS",
41022
+ "display",
41023
+ "type",
41024
+ "checkInAt",
41025
+ "staff",
41026
+ "building",
41027
+ "note"
41028
+ ],
41029
+ filters: ["type", "building", "checkInAt"],
41030
+ sorts: ["checkInAt"],
41031
+ excludes: ["create", "delete", "duplicate", "click", "destroy"],
41032
+ query: () => {
41033
+ var _a;
41034
+ const { staff } = useOperasional();
41035
+ return query.Query.define({
41036
+ filter: {
41037
+ staffId: {
41038
+ $eq: (_a = staff.value) == null ? void 0 : _a.id
41039
+ }
41040
+ },
41041
+ sort: {
41042
+ handle: "checkInAt",
41043
+ direction: "descending"
41044
+ }
41045
+ });
41046
+ }
41047
+ });
39845
41048
  const CheckInResource = context.Resource.define({
39846
41049
  model: CheckInModel$1,
39847
41050
  collection: {
@@ -39882,6 +41085,10 @@ const CheckInResource = context.Resource.define({
39882
41085
  checkInSupervisorSingle: {
39883
41086
  path: "/pengawas/checkIns/:slug",
39884
41087
  component: CheckInSingleSupervisorView
41088
+ },
41089
+ checkInStaff: {
41090
+ path: "/staff/checkIns",
41091
+ component: CheckInCollectionStaffView
39885
41092
  }
39886
41093
  },
39887
41094
  fragments: CheckInModel$1.fragments,
@@ -40759,7 +41966,17 @@ const StaffCollectionAccessView = office$1.ResourceUtil.createCollection({
40759
41966
  view: "access",
40760
41967
  peeks: ["modal"]
40761
41968
  },
40762
- excludes: ["create", "delete", "duplicate", "destroy"]
41969
+ excludes: ["create", "delete", "duplicate", "destroy"],
41970
+ columns: [
41971
+ "workStatus",
41972
+ "name",
41973
+ "nik",
41974
+ "branch",
41975
+ "branches",
41976
+ "workCome",
41977
+ "workHome",
41978
+ "workNote"
41979
+ ]
40763
41980
  });
40764
41981
  const StaffSingleAccessView = office$1.ResourceUtil.createSingle({
40765
41982
  name: "access",
@@ -41823,6 +43040,7 @@ const mod = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty(
41823
43040
  AttendanceSingleSupervisorView,
41824
43041
  AttendanceSingleView,
41825
43042
  CheckInCollectionExternalView,
43043
+ CheckInCollectionStaffView,
41826
43044
  CheckInCollectionSupervisorView,
41827
43045
  CheckInCollectionView,
41828
43046
  CheckInResource,