zignal-stencil-library 1.1.192 → 1.1.194
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/dist/cjs/{autocomplete-address_45.cjs.entry.js → autocomplete-address_46.cjs.entry.js} +669 -439
- package/dist/cjs/create-master-data-dialog.master-data-item.entry.cjs.js.map +1 -1
- package/dist/cjs/create-master-data-dialog_2.cjs.entry.js +9 -10
- package/dist/cjs/{icon-svg-BOZqsGgm.js → icon-svg-CgXY0S7L.js} +3 -3
- package/dist/cjs/{icon-svg-BOZqsGgm.js.map → icon-svg-CgXY0S7L.js.map} +1 -1
- package/dist/cjs/{index-1blDTX13.js → index-GjHureph.js} +228 -81
- package/dist/cjs/index-GjHureph.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/master-status-app.cjs.entry.js +17 -19
- package/dist/cjs/master-status-app.entry.cjs.js.map +1 -1
- package/dist/cjs/master-tag-app.cjs.entry.js +17 -19
- package/dist/cjs/master-tag-app.entry.cjs.js.map +1 -1
- package/dist/cjs/{z-input-BgYi1fKB.js → z-input-BDN69u5m.js} +365 -13
- package/dist/cjs/z-input-BDN69u5m.js.map +1 -0
- package/dist/cjs/zignal-stencil-library.cjs.js +1 -1
- package/dist/collection/components/autocomplete-address/autocomplete-address.css +1 -1
- package/dist/collection/components/autocomplete-multiple-select/autocomplete-multiple-select.css +1 -1
- package/dist/collection/components/autocomplete-select/autocomplete-select.css +1 -1
- package/dist/collection/components/channel-box/channel-box.css +1 -1
- package/dist/collection/components/chat-app/chat-app.css +1 -1
- package/dist/collection/components/chat-app/chat-app.js +37 -1
- package/dist/collection/components/chat-app/chat-app.js.map +1 -1
- package/dist/collection/components/chat-header/chat-header.css +1 -1
- package/dist/collection/components/chat-input/chat-input.css +1 -1
- package/dist/collection/components/checkbox-list/checkbox-list.css +1 -1
- package/dist/collection/components/create-master-data-dialog/create-master-data-dialog.css +1 -1
- package/dist/collection/components/dialog-bill-editor/dialog-bill-editor.css +1 -1
- package/dist/collection/components/dialog-custom-filter/dialog-custom-filter.css +1 -1
- package/dist/collection/components/dialog-editor/dialog-editor.css +1 -1
- package/dist/collection/components/dialog-preview-media/dialog-preview-media.css +1 -1
- package/dist/collection/components/dialog-search/dialog-search.css +1 -1
- package/dist/collection/components/master-data-item/master-data-item.css +1 -1
- package/dist/collection/components/master-status-app/master-status-app.css +1 -1
- package/dist/collection/components/master-tag-app/master-tag-app.css +1 -1
- package/dist/collection/components/menu-chat-channel/menu-chat-channel.css +1 -1
- package/dist/collection/components/menu-chat-type/menu-chat-type.css +1 -1
- package/dist/collection/components/menu-list/menu-list.css +1 -1
- package/dist/collection/components/message-box/message-box.css +1 -1
- package/dist/collection/components/message-box/message-box.js +2 -1
- package/dist/collection/components/message-box/message-box.js.map +1 -1
- package/dist/collection/components/message-content/message-content.css +1 -1
- package/dist/collection/components/message-item/message-item.css +1 -1
- package/dist/collection/components/message-media/message-media.css +1 -1
- package/dist/collection/components/profile-history/profile-history.css +1 -1
- package/dist/collection/components/profile-info/profile-info.css +1 -1
- package/dist/collection/components/profile-media/profile-media.css +1 -1
- package/dist/collection/components/profile-tabs/profile-tabs.css +1 -1
- package/dist/collection/components/profile-tabs/profile-tabs.js +4 -3
- package/dist/collection/components/profile-tabs/profile-tabs.js.map +1 -1
- package/dist/collection/components/quick-message-add-template/quick-message-add-template.css +1 -1
- package/dist/collection/components/quick-message-app/quick-message-app.css +1 -1
- package/dist/collection/components/quick-message-file/quick-message-file.css +1 -1
- package/dist/collection/components/quick-message-image/quick-message-image.css +1 -1
- package/dist/collection/components/quick-message-modal/quick-message-modal.css +1 -1
- package/dist/collection/components/quick-message-template/quick-message-template.css +1 -1
- package/dist/collection/components/quick-message-template/quick-message-template.js +4 -4
- package/dist/collection/components/quick-message-template/quick-message-template.js.map +1 -1
- package/dist/collection/components/search-box/search-box.css +1 -1
- package/dist/collection/components/status-badge/status-badge.css +1 -1
- package/dist/collection/components/tag-list/tag-list.css +1 -1
- package/dist/collection/components/tag-or-status-item/tag-or-status-item.css +1 -1
- package/dist/collection/components/tag-popper/tag-popper.css +1 -1
- package/dist/collection/components/typography-clamp/typography-clamp.css +1 -1
- package/dist/collection/components/z-avatar/z-avatar.css +1 -1
- package/dist/collection/components/z-dialog/z-dialog.css +1 -1
- package/dist/collection/components/z-tooltip/z-tooltip.css +1 -1
- package/dist/collection/store/store.js +1 -0
- package/dist/collection/store/store.js.map +1 -1
- package/dist/collection/store/type.js.map +1 -1
- package/dist/components/autocomplete-address2.js +1 -1
- package/dist/components/autocomplete-address2.js.map +1 -1
- package/dist/components/autocomplete-multiple-select2.js +1 -1
- package/dist/components/autocomplete-multiple-select2.js.map +1 -1
- package/dist/components/autocomplete-select2.js +1 -1
- package/dist/components/autocomplete-select2.js.map +1 -1
- package/dist/components/channel-box2.js +1 -1
- package/dist/components/channel-box2.js.map +1 -1
- package/dist/components/chat-app.js +19 -2
- package/dist/components/chat-app.js.map +1 -1
- package/dist/components/chat-header2.js +1 -1
- package/dist/components/chat-header2.js.map +1 -1
- package/dist/components/chat-input2.js +1 -1
- package/dist/components/chat-input2.js.map +1 -1
- package/dist/components/checkbox-list2.js +1 -1
- package/dist/components/checkbox-list2.js.map +1 -1
- package/dist/components/create-master-data-dialog2.js +1 -1
- package/dist/components/create-master-data-dialog2.js.map +1 -1
- package/dist/components/dialog-bill-editor2.js +1 -1
- package/dist/components/dialog-bill-editor2.js.map +1 -1
- package/dist/components/dialog-custom-filter2.js +1 -1
- package/dist/components/dialog-custom-filter2.js.map +1 -1
- package/dist/components/dialog-editor2.js +1 -1
- package/dist/components/dialog-editor2.js.map +1 -1
- package/dist/components/dialog-preview-media2.js +1 -1
- package/dist/components/dialog-preview-media2.js.map +1 -1
- package/dist/components/dialog-search2.js +1 -1
- package/dist/components/dialog-search2.js.map +1 -1
- package/dist/components/master-data-item2.js +1 -1
- package/dist/components/master-data-item2.js.map +1 -1
- package/dist/components/master-status-app.js +1 -1
- package/dist/components/master-status-app.js.map +1 -1
- package/dist/components/master-tag-app.js +1 -1
- package/dist/components/master-tag-app.js.map +1 -1
- package/dist/components/menu-chat-channel2.js +1 -1
- package/dist/components/menu-chat-channel2.js.map +1 -1
- package/dist/components/menu-chat-type2.js +1 -1
- package/dist/components/menu-chat-type2.js.map +1 -1
- package/dist/components/menu-list2.js +1 -1
- package/dist/components/menu-list2.js.map +1 -1
- package/dist/components/message-box2.js +3 -2
- package/dist/components/message-box2.js.map +1 -1
- package/dist/components/message-content2.js +1 -1
- package/dist/components/message-content2.js.map +1 -1
- package/dist/components/message-item2.js +1 -1
- package/dist/components/message-item2.js.map +1 -1
- package/dist/components/message-media2.js +1 -1
- package/dist/components/message-media2.js.map +1 -1
- package/dist/components/profile-history2.js +1 -1
- package/dist/components/profile-history2.js.map +1 -1
- package/dist/components/profile-info2.js +1 -1
- package/dist/components/profile-info2.js.map +1 -1
- package/dist/components/profile-media2.js +1 -1
- package/dist/components/profile-media2.js.map +1 -1
- package/dist/components/profile-tabs2.js +5 -4
- package/dist/components/profile-tabs2.js.map +1 -1
- package/dist/components/quick-message-add-template2.js +1 -1
- package/dist/components/quick-message-add-template2.js.map +1 -1
- package/dist/components/quick-message-app.js +1 -1
- package/dist/components/quick-message-app.js.map +1 -1
- package/dist/components/quick-message-file2.js +1 -1
- package/dist/components/quick-message-file2.js.map +1 -1
- package/dist/components/quick-message-image2.js +1 -1
- package/dist/components/quick-message-image2.js.map +1 -1
- package/dist/components/quick-message-modal2.js +1 -1
- package/dist/components/quick-message-modal2.js.map +1 -1
- package/dist/components/quick-message-template2.js +5 -5
- package/dist/components/quick-message-template2.js.map +1 -1
- package/dist/components/search-box2.js +1 -1
- package/dist/components/search-box2.js.map +1 -1
- package/dist/components/status-badge2.js +1 -1
- package/dist/components/status-badge2.js.map +1 -1
- package/dist/components/store.js +1 -0
- package/dist/components/store.js.map +1 -1
- package/dist/components/summarize-message-section2.js +1 -1
- package/dist/components/summarize-message-section2.js.map +1 -1
- package/dist/components/tag-list2.js +1 -1
- package/dist/components/tag-list2.js.map +1 -1
- package/dist/components/tag-or-status-item2.js +1 -1
- package/dist/components/tag-or-status-item2.js.map +1 -1
- package/dist/components/tag-popper2.js +1 -1
- package/dist/components/tag-popper2.js.map +1 -1
- package/dist/components/typography-clamp2.js +1 -1
- package/dist/components/typography-clamp2.js.map +1 -1
- package/dist/components/user-info-section2.js +1 -1
- package/dist/components/user-info-section2.js.map +1 -1
- package/dist/components/z-avatar2.js +1 -1
- package/dist/components/z-avatar2.js.map +1 -1
- package/dist/components/z-dialog2.js +1 -1
- package/dist/components/z-dialog2.js.map +1 -1
- package/dist/components/z-tooltip2.js +1 -1
- package/dist/components/z-tooltip2.js.map +1 -1
- package/dist/esm/{autocomplete-address_45.entry.js → autocomplete-address_46.entry.js} +284 -55
- package/dist/esm/create-master-data-dialog.master-data-item.entry.js.map +1 -1
- package/dist/esm/create-master-data-dialog_2.entry.js +4 -5
- package/dist/{zignal-stencil-library/icon-svg-DrE2FRgl.js → esm/icon-svg-t8bE_WeG.js} +3 -3
- package/dist/{zignal-stencil-library/icon-svg-DrE2FRgl.js.map → esm/icon-svg-t8bE_WeG.js.map} +1 -1
- package/dist/{zignal-stencil-library/index-ncO14pdv.js → esm/index-CtvW4AWU.js} +144 -5
- package/dist/esm/index-CtvW4AWU.js.map +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/master-status-app.entry.js +3 -5
- package/dist/esm/master-status-app.entry.js.map +1 -1
- package/dist/esm/master-tag-app.entry.js +3 -5
- package/dist/esm/master-tag-app.entry.js.map +1 -1
- package/dist/{zignal-stencil-library/z-input-D-b72atY.js → esm/z-input-D9WwC2eR.js} +338 -7
- package/dist/esm/z-input-D9WwC2eR.js.map +1 -0
- package/dist/esm/zignal-stencil-library.js +1 -1
- package/dist/types/components/chat-app/chat-app.d.ts +3 -0
- package/dist/types/components.d.ts +2 -0
- package/dist/types/store/type.d.ts +1 -0
- package/dist/zignal-stencil-library/{autocomplete-address_45.entry.js → autocomplete-address_46.entry.js} +284 -55
- package/dist/zignal-stencil-library/create-master-data-dialog.master-data-item.entry.esm.js.map +1 -1
- package/dist/zignal-stencil-library/create-master-data-dialog_2.entry.js +4 -5
- package/dist/{esm/icon-svg-DrE2FRgl.js → zignal-stencil-library/icon-svg-t8bE_WeG.js} +3 -3
- package/dist/{esm/icon-svg-DrE2FRgl.js.map → zignal-stencil-library/icon-svg-t8bE_WeG.js.map} +1 -1
- package/dist/{esm/index-ncO14pdv.js → zignal-stencil-library/index-CtvW4AWU.js} +144 -5
- package/dist/zignal-stencil-library/index-CtvW4AWU.js.map +1 -0
- package/dist/zignal-stencil-library/master-status-app.entry.esm.js.map +1 -1
- package/dist/zignal-stencil-library/master-status-app.entry.js +3 -5
- package/dist/zignal-stencil-library/master-tag-app.entry.esm.js.map +1 -1
- package/dist/zignal-stencil-library/master-tag-app.entry.js +3 -5
- package/dist/{esm/z-input-D-b72atY.js → zignal-stencil-library/z-input-D9WwC2eR.js} +338 -7
- package/dist/zignal-stencil-library/z-input-D9WwC2eR.js.map +1 -0
- package/dist/zignal-stencil-library/zignal-stencil-library.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/dayjs-DJhkF-a1.js +0 -155
- package/dist/cjs/dayjs-DJhkF-a1.js.map +0 -1
- package/dist/cjs/index-1blDTX13.js.map +0 -1
- package/dist/cjs/quick-message-app.cjs.entry.js +0 -223
- package/dist/cjs/quick-message-app.entry.cjs.js.map +0 -1
- package/dist/cjs/store-BZKByNB8.js +0 -359
- package/dist/cjs/store-BZKByNB8.js.map +0 -1
- package/dist/cjs/z-input-BgYi1fKB.js.map +0 -1
- package/dist/esm/dayjs-BAV7Kp5H.js +0 -144
- package/dist/esm/dayjs-BAV7Kp5H.js.map +0 -1
- package/dist/esm/index-ncO14pdv.js.map +0 -1
- package/dist/esm/quick-message-app.entry.js +0 -221
- package/dist/esm/quick-message-app.entry.js.map +0 -1
- package/dist/esm/store-CZ0k2e68.js +0 -337
- package/dist/esm/store-CZ0k2e68.js.map +0 -1
- package/dist/esm/z-input-D-b72atY.js.map +0 -1
- package/dist/zignal-stencil-library/dayjs-BAV7Kp5H.js +0 -144
- package/dist/zignal-stencil-library/dayjs-BAV7Kp5H.js.map +0 -1
- package/dist/zignal-stencil-library/index-ncO14pdv.js.map +0 -1
- package/dist/zignal-stencil-library/quick-message-app.entry.esm.js.map +0 -1
- package/dist/zignal-stencil-library/quick-message-app.entry.js +0 -221
- package/dist/zignal-stencil-library/store-CZ0k2e68.js +0 -337
- package/dist/zignal-stencil-library/store-CZ0k2e68.js.map +0 -1
- package/dist/zignal-stencil-library/z-input-D-b72atY.js.map +0 -1
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var store = require('./store-BZKByNB8.js');
|
|
3
|
+
var zInput = require('./z-input-BDN69u5m.js');
|
|
5
4
|
var index = require('./index-DPhBM48K.js');
|
|
6
5
|
|
|
7
|
-
|
|
6
|
+
zInput.configStore.get('isProduction') ? 'https://api.zwiz.app' : 'https://develop.api.zwiz.app';
|
|
8
7
|
// : 'http://localhost:5555';
|
|
9
|
-
const BASE_URL =
|
|
8
|
+
const BASE_URL = zInput.configStore.get('isProduction') ? 'https://d1cl6ecu5d3v2r.cloudfront.net' : 'https://dp46r1vjkg63g.cloudfront.net';
|
|
10
9
|
// : 'http://localhost:5556';
|
|
11
10
|
const DEFAULT_TIMEOUT = 30000;
|
|
12
11
|
const CHAT_PAGE_LIMIT = 14;
|
|
@@ -72,6 +71,146 @@ const TRANSLATE_LANGUAGES = {
|
|
|
72
71
|
'zh-tw': 'Chinese - Traditional',
|
|
73
72
|
};
|
|
74
73
|
|
|
74
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
75
|
+
|
|
76
|
+
function getDefaultExportFromCjs (x) {
|
|
77
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
var dayjs_min$1 = {exports: {}};
|
|
81
|
+
|
|
82
|
+
var dayjs_min = dayjs_min$1.exports;
|
|
83
|
+
|
|
84
|
+
var hasRequiredDayjs_min;
|
|
85
|
+
|
|
86
|
+
function requireDayjs_min () {
|
|
87
|
+
if (hasRequiredDayjs_min) return dayjs_min$1.exports;
|
|
88
|
+
hasRequiredDayjs_min = 1;
|
|
89
|
+
(function (module, exports) {
|
|
90
|
+
!function(t,e){module.exports=e();}(dayjs_min,(function(){var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",s="minute",u="hour",a="day",o="week",c="month",f="quarter",h="year",d="date",l="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|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,M={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(t){var e=["th","st","nd","rd"],n=t%100;return "["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return !r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return (e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return -t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),s=n-i<0,u=e.clone().add(r+(s?-1:1),c);return +(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return {M:c,y:h,w:o,d:a,D:d,h:u,m:s,s:i,ms:r,Q:f}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},g="en",D={};D[g]=M;var p="$isDayjsObject",S=function(t){return t instanceof _||!(!t||!t[p])},w=function t(e,n,r){var i;if(!e)return g;if("string"==typeof e){var s=e.toLowerCase();D[s]&&(i=s),n&&(D[s]=n,i=s);var u=e.split("-");if(!i&&u.length>1)return t(u[0])}else {var a=e.name;D[a]=e,i=a;}return !r&&i&&(g=i),i||!r&&g},O=function(t,e){if(S(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},b=v;b.l=w,b.i=S,b.w=function(t,e){return O(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=w(t.locale,null,true),this.parse(t),this.$x=this.$x||t.x||{},this[p]=true;}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(b.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.init();},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds();},m.$utils=function(){return b},m.isValid=function(){return !(this.$d.toString()===l)},m.isSame=function(t,e){var n=O(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return O(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<O(t)},m.$g=function(t,e,n){return b.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!b.u(e)||e,f=b.p(t),l=function(t,e){var i=b.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(a)},$=function(t,e){return b.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,M=this.$M,m=this.$D,v="set"+(this.$u?"UTC":"");switch(f){case h:return r?l(1,0):l(31,11);case c:return r?l(1,M):l(0,M+1);case o:var g=this.$locale().weekStart||0,D=(y<g?y+7:y)-g;return l(r?m-D:m+(6-D),M);case a:case d:return $(v+"Hours",0);case u:return $(v+"Minutes",1);case s:return $(v+"Seconds",2);case i:return $(v+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,false)},m.$set=function(t,e){var n,o=b.p(t),f="set"+(this.$u?"UTC":""),l=(n={},n[a]=f+"Date",n[d]=f+"Date",n[c]=f+"Month",n[h]=f+"FullYear",n[u]=f+"Hours",n[s]=f+"Minutes",n[i]=f+"Seconds",n[r]=f+"Milliseconds",n)[o],$=o===a?this.$D+(e-this.$W):e;if(o===c||o===h){var y=this.clone().set(d,1);y.$d[l]($),y.init(),this.$d=y.set(d,Math.min(this.$D,y.daysInMonth())).$d;}else l&&this.$d[l]($);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[b.p(t)]()},m.add=function(r,f){var d,l=this;r=Number(r);var $=b.p(f),y=function(t){var e=O(l);return b.w(e.date(e.date()+Math.round(t*r)),l)};if($===c)return this.set(c,this.$M+r);if($===h)return this.set(h,this.$y+r);if($===a)return y(1);if($===o)return y(7);var M=(d={},d[s]=e,d[u]=n,d[i]=t,d)[$]||1,m=this.$d.getTime()+r*M;return b.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||l;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=b.z(this),s=this.$H,u=this.$m,a=this.$M,o=n.weekdays,c=n.months,f=n.meridiem,h=function(t,n,i,s){return t&&(t[n]||t(e,r))||i[n].slice(0,s)},d=function(t){return b.s(s%12||12,t,"0")},$=f||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case "YY":return String(e.$y).slice(-2);case "YYYY":return b.s(e.$y,4,"0");case "M":return a+1;case "MM":return b.s(a+1,2,"0");case "MMM":return h(n.monthsShort,a,c,3);case "MMMM":return h(c,a);case "D":return e.$D;case "DD":return b.s(e.$D,2,"0");case "d":return String(e.$W);case "dd":return h(n.weekdaysMin,e.$W,o,2);case "ddd":return h(n.weekdaysShort,e.$W,o,3);case "dddd":return o[e.$W];case "H":return String(s);case "HH":return b.s(s,2,"0");case "h":return d(1);case "hh":return d(2);case "a":return $(s,u,true);case "A":return $(s,u,false);case "m":return String(u);case "mm":return b.s(u,2,"0");case "s":return String(e.$s);case "ss":return b.s(e.$s,2,"0");case "SSS":return b.s(e.$ms,3,"0");case "Z":return i}return null}(t)||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,l){var $,y=this,M=b.p(d),m=O(r),v=(m.utcOffset()-this.utcOffset())*e,g=this-m,D=function(){return b.m(y,m)};switch(M){case h:$=D()/12;break;case c:$=D();break;case f:$=D()/3;break;case o:$=(g-v)/6048e5;break;case a:$=(g-v)/864e5;break;case u:$=g/n;break;case s:$=g/e;break;case i:$=g/t;break;default:$=g;}return l?$:b.a($)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return D[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=w(t,e,true);return r&&(n.$L=r),n},m.clone=function(){return b.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},M}(),k=_.prototype;return O.prototype=k,[["$ms",r],["$s",i],["$m",s],["$H",u],["$W",a],["$M",c],["$y",h],["$D",d]].forEach((function(t){k[t[1]]=function(e){return this.$g(e,t[0],t[1])};})),O.extend=function(t,e){return t.$i||(t(e,_,O),t.$i=true),O},O.locale=w,O.isDayjs=S,O.unix=function(t){return O(1e3*t)},O.en=D[g],O.Ls=D,O.p={},O}));
|
|
91
|
+
} (dayjs_min$1));
|
|
92
|
+
return dayjs_min$1.exports;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
var dayjs_minExports = requireDayjs_min();
|
|
96
|
+
var dayjs = /*@__PURE__*/getDefaultExportFromCjs(dayjs_minExports);
|
|
97
|
+
|
|
98
|
+
var utc$2 = {exports: {}};
|
|
99
|
+
|
|
100
|
+
var utc$1 = utc$2.exports;
|
|
101
|
+
|
|
102
|
+
var hasRequiredUtc;
|
|
103
|
+
|
|
104
|
+
function requireUtc () {
|
|
105
|
+
if (hasRequiredUtc) return utc$2.exports;
|
|
106
|
+
hasRequiredUtc = 1;
|
|
107
|
+
(function (module, exports) {
|
|
108
|
+
!function(t,i){module.exports=i();}(utc$1,(function(){var t="minute",i=/[+-]\d\d(?::?\d\d)?/g,e=/([+-]|\d\d)/g;return function(s,f,n){var u=f.prototype;n.utc=function(t){var i={date:t,utc:true,args:arguments};return new f(i)},u.utc=function(i){var e=n(this.toDate(),{locale:this.$L,utc:true});return i?e.add(this.utcOffset(),t):e},u.local=function(){return n(this.toDate(),{locale:this.$L,utc:false})};var r=u.parse;u.parse=function(t){t.utc&&(this.$u=true),this.$utils().u(t.$offset)||(this.$offset=t.$offset),r.call(this,t);};var o=u.init;u.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds();}else o.call(this);};var a=u.utcOffset;u.utcOffset=function(s,f){var n=this.$utils().u;if(n(s))return this.$u?0:n(this.$offset)?a.call(this):this.$offset;if("string"==typeof s&&(s=function(t){ void 0===t&&(t="");var s=t.match(i);if(!s)return null;var f=(""+s[0]).match(e)||["-",0,0],n=f[0],u=60*+f[1]+ +f[2];return 0===u?0:"+"===n?u:-u}(s),null===s))return this;var u=Math.abs(s)<=16?60*s:s;if(0===u)return this.utc(f);var r=this.clone();if(f)return r.$offset=u,r.$u=false,r;var o=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return (r=this.local().add(u+o,t)).$offset=u,r.$x.$localOffset=o,r};var h=u.format;u.format=function(t){var i=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return h.call(this,i)},u.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},u.isUTC=function(){return !!this.$u},u.toISOString=function(){return this.toDate().toISOString()},u.toString=function(){return this.toDate().toUTCString()};var l=u.toDate;u.toDate=function(t){return "s"===t&&this.$offset?n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():l.call(this)};var c=u.diff;u.diff=function(t,i,e){if(t&&this.$u===t.$u)return c.call(this,t,i,e);var s=this.local(),f=n(t).local();return c.call(s,f,i,e)};}}));
|
|
109
|
+
} (utc$2));
|
|
110
|
+
return utc$2.exports;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
var utcExports = requireUtc();
|
|
114
|
+
var utc = /*@__PURE__*/getDefaultExportFromCjs(utcExports);
|
|
115
|
+
|
|
116
|
+
var timezone$2 = {exports: {}};
|
|
117
|
+
|
|
118
|
+
var timezone$1 = timezone$2.exports;
|
|
119
|
+
|
|
120
|
+
var hasRequiredTimezone;
|
|
121
|
+
|
|
122
|
+
function requireTimezone () {
|
|
123
|
+
if (hasRequiredTimezone) return timezone$2.exports;
|
|
124
|
+
hasRequiredTimezone = 1;
|
|
125
|
+
(function (module, exports) {
|
|
126
|
+
!function(t,e){module.exports=e();}(timezone$1,(function(){var t={year:0,month:1,day:2,hour:3,minute:4,second:5},e={};return function(n,i,o){var r,a=function(t,n,i){ void 0===i&&(i={});var o=new Date(t),r=function(t,n){ void 0===n&&(n={});var i=n.timeZoneName||"short",o=t+"|"+i,r=e[o];return r||(r=new Intl.DateTimeFormat("en-US",{hour12:false,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:i}),e[o]=r),r}(n,i);return r.formatToParts(o)},u=function(e,n){for(var i=a(e,n),r=[],u=0;u<i.length;u+=1){var f=i[u],s=f.type,m=f.value,c=t[s];c>=0&&(r[c]=parseInt(m,10));}var d=r[3],l=24===d?0:d,h=r[0]+"-"+r[1]+"-"+r[2]+" "+l+":"+r[4]+":"+r[5]+":000",v=+e;return (o.utc(h).valueOf()-(v-=v%1e3))/6e4},f=i.prototype;f.tz=function(t,e){ void 0===t&&(t=r);var n,i=this.utcOffset(),a=this.toDate(),u=a.toLocaleString("en-US",{timeZone:t}),f=Math.round((a-new Date(u))/1e3/60),s=15*-Math.round(a.getTimezoneOffset()/15)-f;if(!Number(s))n=this.utcOffset(0,e);else if(n=o(u,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(s,true),e){var m=n.utcOffset();n=n.add(i-m,"minute");}return n.$x.$timezone=t,n},f.offsetName=function(t){var e=this.$x.$timezone||o.tz.guess(),n=a(this.valueOf(),e,{timeZoneName:t}).find((function(t){return "timezonename"===t.type.toLowerCase()}));return n&&n.value};var s=f.startOf;f.startOf=function(t,e){if(!this.$x||!this.$x.$timezone)return s.call(this,t,e);var n=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return s.call(n,t,e).tz(this.$x.$timezone,true)},o.tz=function(t,e,n){var i=n&&e,a=n||e||r,f=u(+o(),a);if("string"!=typeof t)return o(t).tz(a);var s=function(t,e,n){var i=t-60*e*1e3,o=u(i,n);if(e===o)return [i,e];var r=u(i-=60*(o-e)*1e3,n);return o===r?[i,o]:[t-60*Math.min(o,r)*1e3,Math.max(o,r)]}(o.utc(t,i).valueOf(),f,a),m=s[0],c=s[1],d=o(m).utcOffset(c);return d.$x.$timezone=a,d},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(t){r=t;};}}));
|
|
127
|
+
} (timezone$2));
|
|
128
|
+
return timezone$2.exports;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
var timezoneExports = requireTimezone();
|
|
132
|
+
var timezone = /*@__PURE__*/getDefaultExportFromCjs(timezoneExports);
|
|
133
|
+
|
|
134
|
+
var duration$2 = {exports: {}};
|
|
135
|
+
|
|
136
|
+
var duration$1 = duration$2.exports;
|
|
137
|
+
|
|
138
|
+
var hasRequiredDuration;
|
|
139
|
+
|
|
140
|
+
function requireDuration () {
|
|
141
|
+
if (hasRequiredDuration) return duration$2.exports;
|
|
142
|
+
hasRequiredDuration = 1;
|
|
143
|
+
(function (module, exports) {
|
|
144
|
+
!function(t,s){module.exports=s();}(duration$1,(function(){var t,s,n=1e3,i=6e4,e=36e5,r=864e5,o=/\[([^\]]+)]|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,u=31536e6,d=2628e6,a=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,h={years:u,months:d,days:r,hours:e,minutes:i,seconds:n,milliseconds:1,weeks:6048e5},c=function(t){return t instanceof g},f=function(t,s,n){return new g(t,n,s.$l)},m=function(t){return s.p(t)+"s"},l=function(t){return t<0},$=function(t){return l(t)?Math.ceil(t):Math.floor(t)},y=function(t){return Math.abs(t)},v=function(t,s){return t?l(t)?{negative:true,format:""+y(t)+s}:{negative:false,format:""+t+s}:{negative:false,format:""}},g=function(){function l(t,s,n){var i=this;if(this.$d={},this.$l=n,void 0===t&&(this.$ms=0,this.parseFromMilliseconds()),s)return f(t*h[m(s)],this);if("number"==typeof t)return this.$ms=t,this.parseFromMilliseconds(),this;if("object"==typeof t)return Object.keys(t).forEach((function(s){i.$d[m(s)]=t[s];})),this.calMilliseconds(),this;if("string"==typeof t){var e=t.match(a);if(e){var r=e.slice(2).map((function(t){return null!=t?Number(t):0}));return this.$d.years=r[0],this.$d.months=r[1],this.$d.weeks=r[2],this.$d.days=r[3],this.$d.hours=r[4],this.$d.minutes=r[5],this.$d.seconds=r[6],this.calMilliseconds(),this}}return this}var y=l.prototype;return y.calMilliseconds=function(){var t=this;this.$ms=Object.keys(this.$d).reduce((function(s,n){return s+(t.$d[n]||0)*h[n]}),0);},y.parseFromMilliseconds=function(){var t=this.$ms;this.$d.years=$(t/u),t%=u,this.$d.months=$(t/d),t%=d,this.$d.days=$(t/r),t%=r,this.$d.hours=$(t/e),t%=e,this.$d.minutes=$(t/i),t%=i,this.$d.seconds=$(t/n),t%=n,this.$d.milliseconds=t;},y.toISOString=function(){var t=v(this.$d.years,"Y"),s=v(this.$d.months,"M"),n=+this.$d.days||0;this.$d.weeks&&(n+=7*this.$d.weeks);var i=v(n,"D"),e=v(this.$d.hours,"H"),r=v(this.$d.minutes,"M"),o=this.$d.seconds||0;this.$d.milliseconds&&(o+=this.$d.milliseconds/1e3,o=Math.round(1e3*o)/1e3);var u=v(o,"S"),d=t.negative||s.negative||i.negative||e.negative||r.negative||u.negative,a=e.format||r.format||u.format?"T":"",h=(d?"-":"")+"P"+t.format+s.format+i.format+a+e.format+r.format+u.format;return "P"===h||"-P"===h?"P0D":h},y.toJSON=function(){return this.toISOString()},y.format=function(t){var n=t||"YYYY-MM-DDTHH:mm:ss",i={Y:this.$d.years,YY:s.s(this.$d.years,2,"0"),YYYY:s.s(this.$d.years,4,"0"),M:this.$d.months,MM:s.s(this.$d.months,2,"0"),D:this.$d.days,DD:s.s(this.$d.days,2,"0"),H:this.$d.hours,HH:s.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:s.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:s.s(this.$d.seconds,2,"0"),SSS:s.s(this.$d.milliseconds,3,"0")};return n.replace(o,(function(t,s){return s||String(i[t])}))},y.as=function(t){return this.$ms/h[m(t)]},y.get=function(t){var s=this.$ms,n=m(t);return "milliseconds"===n?s%=1e3:s="weeks"===n?$(s/h[n]):this.$d[n],s||0},y.add=function(t,s,n){var i;return i=s?t*h[m(s)]:c(t)?t.$ms:f(t,this).$ms,f(this.$ms+i*(n?-1:1),this)},y.subtract=function(t,s){return this.add(t,s,true)},y.locale=function(t){var s=this.clone();return s.$l=t,s},y.clone=function(){return f(this.$ms,this)},y.humanize=function(s){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!s)},y.valueOf=function(){return this.asMilliseconds()},y.milliseconds=function(){return this.get("milliseconds")},y.asMilliseconds=function(){return this.as("milliseconds")},y.seconds=function(){return this.get("seconds")},y.asSeconds=function(){return this.as("seconds")},y.minutes=function(){return this.get("minutes")},y.asMinutes=function(){return this.as("minutes")},y.hours=function(){return this.get("hours")},y.asHours=function(){return this.as("hours")},y.days=function(){return this.get("days")},y.asDays=function(){return this.as("days")},y.weeks=function(){return this.get("weeks")},y.asWeeks=function(){return this.as("weeks")},y.months=function(){return this.get("months")},y.asMonths=function(){return this.as("months")},y.years=function(){return this.get("years")},y.asYears=function(){return this.as("years")},l}(),p=function(t,s,n){return t.add(s.years()*n,"y").add(s.months()*n,"M").add(s.days()*n,"d").add(s.hours()*n,"h").add(s.minutes()*n,"m").add(s.seconds()*n,"s").add(s.milliseconds()*n,"ms")};return function(n,i,e){t=e,s=e().$utils(),e.duration=function(t,s){var n=e.locale();return f(t,{$l:n},s)},e.isDuration=c;var r=i.prototype.add,o=i.prototype.subtract;i.prototype.add=function(t,s){return c(t)?p(this,t,1):r.bind(this)(t,s)},i.prototype.subtract=function(t,s){return c(t)?p(this,t,-1):o.bind(this)(t,s)};}}));
|
|
145
|
+
} (duration$2));
|
|
146
|
+
return duration$2.exports;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
var durationExports = requireDuration();
|
|
150
|
+
var duration = /*@__PURE__*/getDefaultExportFromCjs(durationExports);
|
|
151
|
+
|
|
152
|
+
var isBetween$2 = {exports: {}};
|
|
153
|
+
|
|
154
|
+
var isBetween$1 = isBetween$2.exports;
|
|
155
|
+
|
|
156
|
+
var hasRequiredIsBetween;
|
|
157
|
+
|
|
158
|
+
function requireIsBetween () {
|
|
159
|
+
if (hasRequiredIsBetween) return isBetween$2.exports;
|
|
160
|
+
hasRequiredIsBetween = 1;
|
|
161
|
+
(function (module, exports) {
|
|
162
|
+
!function(e,i){module.exports=i();}(isBetween$1,(function(){return function(e,i,t){i.prototype.isBetween=function(e,i,s,f){var n=t(e),o=t(i),r="("===(f=f||"()")[0],u=")"===f[1];return (r?this.isAfter(n,s):!this.isBefore(n,s))&&(u?this.isBefore(o,s):!this.isAfter(o,s))||(r?this.isBefore(n,s):!this.isAfter(n,s))&&(u?this.isAfter(o,s):!this.isBefore(o,s))};}}));
|
|
163
|
+
} (isBetween$2));
|
|
164
|
+
return isBetween$2.exports;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
var isBetweenExports = requireIsBetween();
|
|
168
|
+
var isBetween = /*@__PURE__*/getDefaultExportFromCjs(isBetweenExports);
|
|
169
|
+
|
|
170
|
+
var th$1 = {exports: {}};
|
|
171
|
+
|
|
172
|
+
var th = th$1.exports;
|
|
173
|
+
|
|
174
|
+
var hasRequiredTh;
|
|
175
|
+
|
|
176
|
+
function requireTh () {
|
|
177
|
+
if (hasRequiredTh) return th$1.exports;
|
|
178
|
+
hasRequiredTh = 1;
|
|
179
|
+
(function (module, exports) {
|
|
180
|
+
!function(_,e){module.exports=e(requireDayjs_min());}(th,(function(_){function e(_){return _&&"object"==typeof _&&"default"in _?_:{default:_}}var t=e(_),d={name:"th",weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"ม.ค._ก.พ._มี.ค._เม.ย._พ.ค._มิ.ย._ก.ค._ส.ค._ก.ย._ต.ค._พ.ย._ธ.ค.".split("_"),formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H:mm",LLLL:"วันddddที่ D MMMM YYYY เวลา H:mm"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"},ordinal:function(_){return _+"."}};return t.default.locale(d,null,true),d}));
|
|
181
|
+
} (th$1));
|
|
182
|
+
return th$1.exports;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
requireTh();
|
|
186
|
+
|
|
187
|
+
// Extend dayjs with required plugins only
|
|
188
|
+
dayjs.extend(utc);
|
|
189
|
+
dayjs.extend(timezone);
|
|
190
|
+
dayjs.extend(duration);
|
|
191
|
+
dayjs.extend(isBetween);
|
|
192
|
+
const displayTime = (date) => {
|
|
193
|
+
return dayjs(date).isValid() ? dayjs(date).tz().format('HH:mm') : '';
|
|
194
|
+
};
|
|
195
|
+
const displayDate = (date) => {
|
|
196
|
+
return dayjs(date).isValid() ? dayjs(date).tz().format('DD/MM/YYYY') : '';
|
|
197
|
+
};
|
|
198
|
+
const isToday = (date) => {
|
|
199
|
+
return dayjs().tz().format('DD MMM YYYY') === dayjs(date).tz().format('DD MMM YYYY');
|
|
200
|
+
};
|
|
201
|
+
const displayLongDate = (date) => {
|
|
202
|
+
return dayjs(date).isValid() ? dayjs(date).tz().format('DD MMM YYYY') : '';
|
|
203
|
+
};
|
|
204
|
+
const displayDateTime = (date) => {
|
|
205
|
+
return dayjs(date).isValid() ? dayjs(date).tz().format('DD MMM YYYY HH:mm') : '';
|
|
206
|
+
};
|
|
207
|
+
const setDayjsLocale = (locale) => {
|
|
208
|
+
dayjs.locale(locale);
|
|
209
|
+
};
|
|
210
|
+
const setDayjsTimeZone = (timezone) => {
|
|
211
|
+
dayjs.tz.setDefault(timezone);
|
|
212
|
+
};
|
|
213
|
+
|
|
75
214
|
/*! Axios v1.13.2 Copyright (c) 2025 Matt Zabriskie and contributors */
|
|
76
215
|
|
|
77
216
|
var axios_1;
|
|
@@ -409,7 +548,7 @@ function requireAxios () {
|
|
|
409
548
|
const _global = (() => {
|
|
410
549
|
/*eslint no-undef:0*/
|
|
411
550
|
if (typeof globalThis !== "undefined") return globalThis;
|
|
412
|
-
return typeof self !== "undefined" ? self : (typeof window !== 'undefined' ? window :
|
|
551
|
+
return typeof self !== "undefined" ? self : (typeof window !== 'undefined' ? window : commonjsGlobal)
|
|
413
552
|
})();
|
|
414
553
|
|
|
415
554
|
const isContextDefined = (context) => !isUndefined(context) && context !== _global;
|
|
@@ -3991,11 +4130,11 @@ function requireAxios () {
|
|
|
3991
4130
|
}
|
|
3992
4131
|
|
|
3993
4132
|
var axiosExports = /*@__PURE__*/ requireAxios();
|
|
3994
|
-
var axios = /*@__PURE__*/
|
|
4133
|
+
var axios = /*@__PURE__*/getDefaultExportFromCjs(axiosExports);
|
|
3995
4134
|
|
|
3996
4135
|
const apiService = () => axios.create({
|
|
3997
4136
|
headers: {
|
|
3998
|
-
Authorization:
|
|
4137
|
+
Authorization: zInput.configStore.get('accessToken'),
|
|
3999
4138
|
},
|
|
4000
4139
|
baseURL: BASE_URL,
|
|
4001
4140
|
timeout: DEFAULT_TIMEOUT,
|
|
@@ -4212,7 +4351,7 @@ class BlobCache {
|
|
|
4212
4351
|
// Export a singleton instance
|
|
4213
4352
|
const blobCache = new BlobCache();
|
|
4214
4353
|
|
|
4215
|
-
const { state } =
|
|
4354
|
+
const { state } = zInput.createStore({
|
|
4216
4355
|
dialog: { open: false, type: "DEFAULT" /* DIALOG_TYPE.DEFAULT */ },
|
|
4217
4356
|
});
|
|
4218
4357
|
const dialogStore = state;
|
|
@@ -4225,7 +4364,7 @@ const closeDialog = (callback) => {
|
|
|
4225
4364
|
callback();
|
|
4226
4365
|
};
|
|
4227
4366
|
const handleError = (error, defaultMessage = 'error') => {
|
|
4228
|
-
const t =
|
|
4367
|
+
const t = zInput.useTranslation();
|
|
4229
4368
|
let title = defaultMessage;
|
|
4230
4369
|
let contentCustom = null;
|
|
4231
4370
|
if (error instanceof axiosExports.AxiosError) {
|
|
@@ -4266,13 +4405,13 @@ const handleError = (error, defaultMessage = 'error') => {
|
|
|
4266
4405
|
|
|
4267
4406
|
const getChats = async (params) => {
|
|
4268
4407
|
const { connectionIds, lastAnswerByIds, statusIds, tagIds, ...rest } = params;
|
|
4269
|
-
const businessId =
|
|
4270
|
-
const shopId =
|
|
4408
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4409
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4271
4410
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat`, {
|
|
4272
4411
|
params: {
|
|
4273
4412
|
...rest,
|
|
4274
|
-
connection_id: connectionIds && connectionIds.length ===
|
|
4275
|
-
last_answer_by_id: lastAnswerByIds && lastAnswerByIds.length ===
|
|
4413
|
+
connection_id: connectionIds && connectionIds.length === zInput.configStore.get('connectionList').length ? undefined : connectionIds,
|
|
4414
|
+
last_answer_by_id: lastAnswerByIds && lastAnswerByIds.length === zInput.configStore.get('memberList').length ? undefined : lastAnswerByIds,
|
|
4276
4415
|
status_id: statusIds,
|
|
4277
4416
|
tag_id: tagIds,
|
|
4278
4417
|
},
|
|
@@ -4284,8 +4423,8 @@ const getChats = async (params) => {
|
|
|
4284
4423
|
};
|
|
4285
4424
|
const getChat = async (params) => {
|
|
4286
4425
|
const { sessionId } = params;
|
|
4287
|
-
const businessId =
|
|
4288
|
-
const shopId =
|
|
4426
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4427
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4289
4428
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat/${sessionId}`);
|
|
4290
4429
|
if (status === 200) {
|
|
4291
4430
|
return data;
|
|
@@ -4293,8 +4432,8 @@ const getChat = async (params) => {
|
|
|
4293
4432
|
throw new Error('Failed to getChat');
|
|
4294
4433
|
};
|
|
4295
4434
|
const updateChat = async (params) => {
|
|
4296
|
-
const businessId =
|
|
4297
|
-
const shopId =
|
|
4435
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4436
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4298
4437
|
const { sessionId, ...rest } = params;
|
|
4299
4438
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/chat/${sessionId}`, rest);
|
|
4300
4439
|
if (status === 200) {
|
|
@@ -4303,8 +4442,8 @@ const updateChat = async (params) => {
|
|
|
4303
4442
|
throw new Error('Failed to updateUser');
|
|
4304
4443
|
};
|
|
4305
4444
|
const translateChatMessage = async (params) => {
|
|
4306
|
-
const businessId =
|
|
4307
|
-
const shopId =
|
|
4445
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4446
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4308
4447
|
const { sessionId, text, messageIds } = params;
|
|
4309
4448
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/translate`, {
|
|
4310
4449
|
text,
|
|
@@ -4316,8 +4455,8 @@ const translateChatMessage = async (params) => {
|
|
|
4316
4455
|
throw new Error('Failed to updateUser');
|
|
4317
4456
|
};
|
|
4318
4457
|
const getChatMessages = async (params) => {
|
|
4319
|
-
const businessId =
|
|
4320
|
-
const shopId =
|
|
4458
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4459
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4321
4460
|
const { sessionId, startMessageId, ...rest } = params;
|
|
4322
4461
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat/${sessionId}/message`, {
|
|
4323
4462
|
params: {
|
|
@@ -4331,8 +4470,8 @@ const getChatMessages = async (params) => {
|
|
|
4331
4470
|
throw new Error('Failed to getChatMessages');
|
|
4332
4471
|
};
|
|
4333
4472
|
const sendMessage = async (params) => {
|
|
4334
|
-
const businessId =
|
|
4335
|
-
const shopId =
|
|
4473
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4474
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4336
4475
|
const { sessionId, messages } = params;
|
|
4337
4476
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/send-message`, {
|
|
4338
4477
|
messages: (messages || []).map(({ mimeType, replyMessageId, buttons, menu_list, ...rest }) => ({
|
|
@@ -4349,8 +4488,8 @@ const sendMessage = async (params) => {
|
|
|
4349
4488
|
throw new Error('Failed to sendMessage');
|
|
4350
4489
|
};
|
|
4351
4490
|
const readMessage = async (params) => {
|
|
4352
|
-
const businessId =
|
|
4353
|
-
const shopId =
|
|
4491
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4492
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4354
4493
|
const { sessionId } = params;
|
|
4355
4494
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/read`);
|
|
4356
4495
|
if (status === 200) {
|
|
@@ -4359,8 +4498,8 @@ const readMessage = async (params) => {
|
|
|
4359
4498
|
throw new Error('Failed to readMessage');
|
|
4360
4499
|
};
|
|
4361
4500
|
const unReadMessage = async (params) => {
|
|
4362
|
-
const businessId =
|
|
4363
|
-
const shopId =
|
|
4501
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4502
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4364
4503
|
const { sessionId } = params;
|
|
4365
4504
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/mark-as-unread`);
|
|
4366
4505
|
if (status === 200) {
|
|
@@ -4369,8 +4508,8 @@ const unReadMessage = async (params) => {
|
|
|
4369
4508
|
throw new Error('Failed to unReadMessage');
|
|
4370
4509
|
};
|
|
4371
4510
|
const getMessageMedia = async (params) => {
|
|
4372
|
-
const businessId =
|
|
4373
|
-
const shopId =
|
|
4511
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4512
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4374
4513
|
const { channel, sessionId, messageId } = params;
|
|
4375
4514
|
const cached = blobCache.get(channel, sessionId, messageId);
|
|
4376
4515
|
if (cached) {
|
|
@@ -4409,8 +4548,8 @@ const getMessageMedia = async (params) => {
|
|
|
4409
4548
|
};
|
|
4410
4549
|
const getUser = async (params) => {
|
|
4411
4550
|
const { type = 'user', channel, id, sessionId } = params;
|
|
4412
|
-
const businessId =
|
|
4413
|
-
const shopId =
|
|
4551
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4552
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4414
4553
|
let route = `user/${channel}/${id}`;
|
|
4415
4554
|
if (type === 'group') {
|
|
4416
4555
|
route = `${channel}/group/${id}`;
|
|
@@ -4434,8 +4573,8 @@ const getUser = async (params) => {
|
|
|
4434
4573
|
throw new Error('Failed to getUser');
|
|
4435
4574
|
};
|
|
4436
4575
|
const getActivityLogs = async (params) => {
|
|
4437
|
-
const businessId =
|
|
4438
|
-
const shopId =
|
|
4576
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4577
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4439
4578
|
const { type = 'user', channel, id } = params;
|
|
4440
4579
|
let route = `user/${channel}/${id}/activity-log`;
|
|
4441
4580
|
if (type === 'group') {
|
|
@@ -4448,8 +4587,8 @@ const getActivityLogs = async (params) => {
|
|
|
4448
4587
|
throw new Error('Failed to getActivityLogs');
|
|
4449
4588
|
};
|
|
4450
4589
|
const updateUser = async (params) => {
|
|
4451
|
-
const businessId =
|
|
4452
|
-
const shopId =
|
|
4590
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4591
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4453
4592
|
const { type = 'user', channel, id } = params;
|
|
4454
4593
|
let _channel = channel;
|
|
4455
4594
|
if (type === 'group') {
|
|
@@ -4478,8 +4617,8 @@ const updateUser = async (params) => {
|
|
|
4478
4617
|
throw new Error('Failed to updateUser');
|
|
4479
4618
|
};
|
|
4480
4619
|
const mergeUser = async (params) => {
|
|
4481
|
-
const businessId =
|
|
4482
|
-
const shopId =
|
|
4620
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4621
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4483
4622
|
const { matchUserId, matchDecision } = params;
|
|
4484
4623
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/user/merge`, {
|
|
4485
4624
|
match_user_id: matchUserId,
|
|
@@ -4491,8 +4630,8 @@ const mergeUser = async (params) => {
|
|
|
4491
4630
|
throw new Error('Failed to mergeUser');
|
|
4492
4631
|
};
|
|
4493
4632
|
const unlinkUser = async (params) => {
|
|
4494
|
-
const businessId =
|
|
4495
|
-
const shopId =
|
|
4633
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4634
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4496
4635
|
const { zignalUserId, channel, userId } = params;
|
|
4497
4636
|
const { data, status } = await apiService().request({
|
|
4498
4637
|
method: 'DELETE',
|
|
@@ -4509,8 +4648,8 @@ const unlinkUser = async (params) => {
|
|
|
4509
4648
|
throw new Error('Failed to unlinkUser');
|
|
4510
4649
|
};
|
|
4511
4650
|
const getUserStatuses = async () => {
|
|
4512
|
-
const businessId =
|
|
4513
|
-
const shopId =
|
|
4651
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4652
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4514
4653
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/user/status`);
|
|
4515
4654
|
if (status === 200) {
|
|
4516
4655
|
return data;
|
|
@@ -4518,8 +4657,8 @@ const getUserStatuses = async () => {
|
|
|
4518
4657
|
throw new Error('Failed to getUserStatuses');
|
|
4519
4658
|
};
|
|
4520
4659
|
const createUserStatus = async (params) => {
|
|
4521
|
-
const businessId =
|
|
4522
|
-
const shopId =
|
|
4660
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4661
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4523
4662
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/user/status`, params);
|
|
4524
4663
|
if (status === 200) {
|
|
4525
4664
|
return data;
|
|
@@ -4527,8 +4666,8 @@ const createUserStatus = async (params) => {
|
|
|
4527
4666
|
throw new Error('Failed to createUserStatus');
|
|
4528
4667
|
};
|
|
4529
4668
|
const getUserTags = async () => {
|
|
4530
|
-
const businessId =
|
|
4531
|
-
const shopId =
|
|
4669
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4670
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4532
4671
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/user/tag`);
|
|
4533
4672
|
if (status === 200) {
|
|
4534
4673
|
return data;
|
|
@@ -4536,8 +4675,8 @@ const getUserTags = async () => {
|
|
|
4536
4675
|
throw new Error('Failed to getUserTags');
|
|
4537
4676
|
};
|
|
4538
4677
|
const createUserTag = async (params) => {
|
|
4539
|
-
const businessId =
|
|
4540
|
-
const shopId =
|
|
4678
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4679
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4541
4680
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/user/tag`, params);
|
|
4542
4681
|
if (status === 200) {
|
|
4543
4682
|
return data;
|
|
@@ -4545,8 +4684,8 @@ const createUserTag = async (params) => {
|
|
|
4545
4684
|
throw new Error('Failed to createUserTag');
|
|
4546
4685
|
};
|
|
4547
4686
|
const updateUserStatus = async (params) => {
|
|
4548
|
-
const businessId =
|
|
4549
|
-
const shopId =
|
|
4687
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4688
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4550
4689
|
const { id, ...rest } = params;
|
|
4551
4690
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/user/status/${id}`, rest);
|
|
4552
4691
|
if (status === 200) {
|
|
@@ -4555,8 +4694,8 @@ const updateUserStatus = async (params) => {
|
|
|
4555
4694
|
throw new Error('Failed to updateUserStatus');
|
|
4556
4695
|
};
|
|
4557
4696
|
const deleteUserStatus = async (params) => {
|
|
4558
|
-
const businessId =
|
|
4559
|
-
const shopId =
|
|
4697
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4698
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4560
4699
|
const { id, force, checkOnly } = params;
|
|
4561
4700
|
const { data, status } = await apiService().delete(`api/${businessId}/${shopId}/user/status/${id}`, {
|
|
4562
4701
|
data: { force, check_only: checkOnly }
|
|
@@ -4567,8 +4706,8 @@ const deleteUserStatus = async (params) => {
|
|
|
4567
4706
|
throw new Error('Failed to deleteUserStatus');
|
|
4568
4707
|
};
|
|
4569
4708
|
const reorderUserStatus = async (params) => {
|
|
4570
|
-
const businessId =
|
|
4571
|
-
const shopId =
|
|
4709
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4710
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4572
4711
|
const { id, sequence } = params;
|
|
4573
4712
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/user/status/${id}`, {
|
|
4574
4713
|
sequence
|
|
@@ -4579,8 +4718,8 @@ const reorderUserStatus = async (params) => {
|
|
|
4579
4718
|
throw new Error('Failed to reorderUserStatus');
|
|
4580
4719
|
};
|
|
4581
4720
|
const updateUserTag = async (params) => {
|
|
4582
|
-
const businessId =
|
|
4583
|
-
const shopId =
|
|
4721
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4722
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4584
4723
|
const { id, ...rest } = params;
|
|
4585
4724
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/user/tag/${id}`, rest);
|
|
4586
4725
|
if (status === 200) {
|
|
@@ -4589,8 +4728,8 @@ const updateUserTag = async (params) => {
|
|
|
4589
4728
|
throw new Error('Failed to updateUserTag');
|
|
4590
4729
|
};
|
|
4591
4730
|
const deleteUserTag = async (params) => {
|
|
4592
|
-
const businessId =
|
|
4593
|
-
const shopId =
|
|
4731
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4732
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4594
4733
|
const { id, force, checkOnly } = params;
|
|
4595
4734
|
const { data, status } = await apiService().delete(`api/${businessId}/${shopId}/user/tag/${id}`, {
|
|
4596
4735
|
data: { force, check_only: checkOnly }
|
|
@@ -4601,8 +4740,8 @@ const deleteUserTag = async (params) => {
|
|
|
4601
4740
|
throw new Error('Failed to deleteUserTag');
|
|
4602
4741
|
};
|
|
4603
4742
|
const reorderUserTag = async (params) => {
|
|
4604
|
-
const businessId =
|
|
4605
|
-
const shopId =
|
|
4743
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4744
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4606
4745
|
const { id, sequence } = params;
|
|
4607
4746
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/user/tag/${id}`, {
|
|
4608
4747
|
sequence
|
|
@@ -4613,8 +4752,8 @@ const reorderUserTag = async (params) => {
|
|
|
4613
4752
|
throw new Error('Failed to reorderUserTag');
|
|
4614
4753
|
};
|
|
4615
4754
|
const saveUserEvent = async (params) => {
|
|
4616
|
-
const businessId =
|
|
4617
|
-
const shopId =
|
|
4755
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4756
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4618
4757
|
const { sessionId } = params;
|
|
4619
4758
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/zwiz/save-user-event`, params);
|
|
4620
4759
|
if (status === 200) {
|
|
@@ -4623,8 +4762,8 @@ const saveUserEvent = async (params) => {
|
|
|
4623
4762
|
throw new Error('Failed to saveUserEvent');
|
|
4624
4763
|
};
|
|
4625
4764
|
const getReplyTokenInfo = async (params) => {
|
|
4626
|
-
const businessId =
|
|
4627
|
-
const shopId =
|
|
4765
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4766
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4628
4767
|
const { sessionId } = params;
|
|
4629
4768
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat/${sessionId}/reply-token-info`);
|
|
4630
4769
|
if (status === 200) {
|
|
@@ -4633,8 +4772,8 @@ const getReplyTokenInfo = async (params) => {
|
|
|
4633
4772
|
throw new Error('Failed to getReplyTokenInfo');
|
|
4634
4773
|
};
|
|
4635
4774
|
const syncMessage = async (params) => {
|
|
4636
|
-
const businessId =
|
|
4637
|
-
const shopId =
|
|
4775
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4776
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4638
4777
|
const { sessionId } = params;
|
|
4639
4778
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/sync-message`);
|
|
4640
4779
|
if (status === 200) {
|
|
@@ -4643,8 +4782,8 @@ const syncMessage = async (params) => {
|
|
|
4643
4782
|
throw new Error('Failed to syncMessage');
|
|
4644
4783
|
};
|
|
4645
4784
|
const syncTags = async (params) => {
|
|
4646
|
-
const businessId =
|
|
4647
|
-
const shopId =
|
|
4785
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4786
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4648
4787
|
const { sessionId } = params;
|
|
4649
4788
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/${sessionId}/sync-tag`);
|
|
4650
4789
|
if (status === 200) {
|
|
@@ -4653,8 +4792,8 @@ const syncTags = async (params) => {
|
|
|
4653
4792
|
throw new Error('Failed to syncTags');
|
|
4654
4793
|
};
|
|
4655
4794
|
const syncUser = async (params) => {
|
|
4656
|
-
const businessId =
|
|
4657
|
-
const shopId =
|
|
4795
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4796
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4658
4797
|
const { channel, id } = params;
|
|
4659
4798
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/user/${channel}/${id}/sync`);
|
|
4660
4799
|
if (status === 200) {
|
|
@@ -4664,8 +4803,8 @@ const syncUser = async (params) => {
|
|
|
4664
4803
|
};
|
|
4665
4804
|
// Custom Filter API Functions
|
|
4666
4805
|
const getChatFilters = async () => {
|
|
4667
|
-
const businessId =
|
|
4668
|
-
const shopId =
|
|
4806
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4807
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4669
4808
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat/filters`);
|
|
4670
4809
|
if (status === 200) {
|
|
4671
4810
|
return data;
|
|
@@ -4673,8 +4812,8 @@ const getChatFilters = async () => {
|
|
|
4673
4812
|
throw new Error('Failed to getChatFilters');
|
|
4674
4813
|
};
|
|
4675
4814
|
const createChatFilter = async (params) => {
|
|
4676
|
-
const businessId =
|
|
4677
|
-
const shopId =
|
|
4815
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4816
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4678
4817
|
const { connection_ids, last_answer_by_ids, status_ids, tag_ids, ...rest } = params;
|
|
4679
4818
|
const { data, status } = await apiService().post(`api/${businessId}/${shopId}/chat/filters`, {
|
|
4680
4819
|
...rest,
|
|
@@ -4689,8 +4828,8 @@ const createChatFilter = async (params) => {
|
|
|
4689
4828
|
throw new Error('Failed to createChatFilter');
|
|
4690
4829
|
};
|
|
4691
4830
|
const updateChatFilter = async (params) => {
|
|
4692
|
-
const businessId =
|
|
4693
|
-
const shopId =
|
|
4831
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4832
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4694
4833
|
const { id, connection_ids, last_answer_by_ids, status_ids, tag_ids, ...rest } = params;
|
|
4695
4834
|
const { data, status } = await apiService().patch(`api/${businessId}/${shopId}/chat/filters/${id}`, {
|
|
4696
4835
|
...rest,
|
|
@@ -4705,8 +4844,8 @@ const updateChatFilter = async (params) => {
|
|
|
4705
4844
|
throw new Error('Failed to updateChatFilter');
|
|
4706
4845
|
};
|
|
4707
4846
|
const deleteChatFilter = async (params) => {
|
|
4708
|
-
const businessId =
|
|
4709
|
-
const shopId =
|
|
4847
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4848
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4710
4849
|
const { data, status } = await apiService().delete(`api/${businessId}/${shopId}/chat/filters/${params.id}`);
|
|
4711
4850
|
if (status === 200) {
|
|
4712
4851
|
return data;
|
|
@@ -4714,8 +4853,8 @@ const deleteChatFilter = async (params) => {
|
|
|
4714
4853
|
throw new Error('Failed to deleteChatFilter');
|
|
4715
4854
|
};
|
|
4716
4855
|
const getChatFilterConfig = async () => {
|
|
4717
|
-
const businessId =
|
|
4718
|
-
const shopId =
|
|
4856
|
+
const businessId = zInput.configStore.get('businessId');
|
|
4857
|
+
const shopId = zInput.configStore.get('shopId');
|
|
4719
4858
|
const { data, status } = await apiService().get(`api/${businessId}/${shopId}/chat/filter-config`);
|
|
4720
4859
|
if (status === 200) {
|
|
4721
4860
|
return data;
|
|
@@ -4734,10 +4873,15 @@ exports.closeDialog = closeDialog;
|
|
|
4734
4873
|
exports.createChatFilter = createChatFilter;
|
|
4735
4874
|
exports.createUserStatus = createUserStatus;
|
|
4736
4875
|
exports.createUserTag = createUserTag;
|
|
4876
|
+
exports.dayjs = dayjs;
|
|
4737
4877
|
exports.deleteChatFilter = deleteChatFilter;
|
|
4738
4878
|
exports.deleteUserStatus = deleteUserStatus;
|
|
4739
4879
|
exports.deleteUserTag = deleteUserTag;
|
|
4740
4880
|
exports.dialogStore = dialogStore;
|
|
4881
|
+
exports.displayDate = displayDate;
|
|
4882
|
+
exports.displayDateTime = displayDateTime;
|
|
4883
|
+
exports.displayLongDate = displayLongDate;
|
|
4884
|
+
exports.displayTime = displayTime;
|
|
4741
4885
|
exports.getActivityLogs = getActivityLogs;
|
|
4742
4886
|
exports.getAddressAsText = getAddressAsText;
|
|
4743
4887
|
exports.getChat = getChat;
|
|
@@ -4754,6 +4898,7 @@ exports.getUser = getUser;
|
|
|
4754
4898
|
exports.getUserStatuses = getUserStatuses;
|
|
4755
4899
|
exports.getUserTags = getUserTags;
|
|
4756
4900
|
exports.handleError = handleError;
|
|
4901
|
+
exports.isToday = isToday;
|
|
4757
4902
|
exports.isValidTelNumber = isValidTelNumber;
|
|
4758
4903
|
exports.mergeUser = mergeUser;
|
|
4759
4904
|
exports.openDialog = openDialog;
|
|
@@ -4762,6 +4907,8 @@ exports.reorderUserStatus = reorderUserStatus;
|
|
|
4762
4907
|
exports.reorderUserTag = reorderUserTag;
|
|
4763
4908
|
exports.saveUserEvent = saveUserEvent;
|
|
4764
4909
|
exports.sendMessage = sendMessage;
|
|
4910
|
+
exports.setDayjsLocale = setDayjsLocale;
|
|
4911
|
+
exports.setDayjsTimeZone = setDayjsTimeZone;
|
|
4765
4912
|
exports.syncMessage = syncMessage;
|
|
4766
4913
|
exports.syncTags = syncTags;
|
|
4767
4914
|
exports.syncUser = syncUser;
|
|
@@ -4773,6 +4920,6 @@ exports.updateChatFilter = updateChatFilter;
|
|
|
4773
4920
|
exports.updateUser = updateUser;
|
|
4774
4921
|
exports.updateUserStatus = updateUserStatus;
|
|
4775
4922
|
exports.updateUserTag = updateUserTag;
|
|
4776
|
-
//# sourceMappingURL=index-
|
|
4923
|
+
//# sourceMappingURL=index-GjHureph.js.map
|
|
4777
4924
|
|
|
4778
|
-
//# sourceMappingURL=index-
|
|
4925
|
+
//# sourceMappingURL=index-GjHureph.js.map
|