giime 0.6.7 → 0.6.8
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/index.css +7 -7
- package/es/giime/version.d.ts +1 -1
- package/es/giime/version.mjs +1 -1
- package/es/giime/version.mjs.map +1 -1
- package/es/hooks/base/usePageHtmlClass/index.d.ts +1 -1
- package/es/hooks/base/usePageHtmlClass/index.mjs +1 -1
- package/es/hooks/base/usePageHtmlClass/index.mjs.map +1 -1
- package/es/hooks/store/common/useCountryList/index.mjs +2 -3
- package/es/hooks/store/common/useCountryList/index.mjs.map +1 -1
- package/es/hooks/store/common/useCurrencyList/index.mjs +2 -3
- package/es/hooks/store/common/useCurrencyList/index.mjs.map +1 -1
- package/es/hooks/store/common/useSystemList/index.mjs +3 -2
- package/es/hooks/store/common/useSystemList/index.mjs.map +1 -1
- package/es/hooks/store/useAliCategoryList/index.mjs +3 -2
- package/es/hooks/store/useAliCategoryList/index.mjs.map +1 -1
- package/es/hooks/store/useAliOssConfigs/index.mjs +3 -2
- package/es/hooks/store/useAliOssConfigs/index.mjs.map +1 -1
- package/es/hooks/store/useCompanyCategoryList/index.mjs +3 -2
- package/es/hooks/store/useCompanyCategoryList/index.mjs.map +1 -1
- package/es/hooks/store/useLangList/index.mjs +3 -3
- package/es/hooks/store/useLangList/index.mjs.map +1 -1
- package/es/hooks/store/useLineList/index.mjs +3 -3
- package/es/hooks/store/useLineList/index.mjs.map +1 -1
- package/es/hooks/store/useOrgUserList/index.mjs +3 -2
- package/es/hooks/store/useOrgUserList/index.mjs.map +1 -1
- package/es/hooks/store/usePlatformLineList/index.mjs +3 -2
- package/es/hooks/store/usePlatformLineList/index.mjs.map +1 -1
- package/es/hooks/store/usePlatformList/index.mjs +3 -3
- package/es/hooks/store/usePlatformList/index.mjs.map +1 -1
- package/es/hooks/store/useRepiteFilter/index.mjs +3 -2
- package/es/hooks/store/useRepiteFilter/index.mjs.map +1 -1
- package/es/hooks/store/userCenter/useAreaList/index.mjs +3 -2
- package/es/hooks/store/userCenter/useAreaList/index.mjs.map +1 -1
- package/es/hooks/store/userCenter/useOrgList/index.mjs +2 -3
- package/es/hooks/store/userCenter/useOrgList/index.mjs.map +1 -1
- package/es/hooks/store/userCenter/useOrgTreeList/index.mjs +3 -2
- package/es/hooks/store/userCenter/useOrgTreeList/index.mjs.map +1 -1
- package/es/hooks/store/userCenter/useRoleList/index.mjs +2 -3
- package/es/hooks/store/userCenter/useRoleList/index.mjs.map +1 -1
- package/es/index.css +7 -7
- package/lib/giime/version.d.ts +1 -1
- package/lib/giime/version.js +1 -1
- package/lib/giime/version.js.map +1 -1
- package/lib/hooks/base/usePageHtmlClass/index.d.ts +1 -1
- package/lib/hooks/base/usePageHtmlClass/index.js +3 -3
- package/lib/hooks/base/usePageHtmlClass/index.js.map +1 -1
- package/lib/hooks/store/common/useCountryList/index.js +1 -2
- package/lib/hooks/store/common/useCountryList/index.js.map +1 -1
- package/lib/hooks/store/common/useCurrencyList/index.js +1 -2
- package/lib/hooks/store/common/useCurrencyList/index.js.map +1 -1
- package/lib/hooks/store/common/useSystemList/index.js +2 -1
- package/lib/hooks/store/common/useSystemList/index.js.map +1 -1
- package/lib/hooks/store/useAliCategoryList/index.js +2 -1
- package/lib/hooks/store/useAliCategoryList/index.js.map +1 -1
- package/lib/hooks/store/useAliOssConfigs/index.js +2 -1
- package/lib/hooks/store/useAliOssConfigs/index.js.map +1 -1
- package/lib/hooks/store/useCompanyCategoryList/index.js +2 -1
- package/lib/hooks/store/useCompanyCategoryList/index.js.map +1 -1
- package/lib/hooks/store/useLangList/index.js +1 -1
- package/lib/hooks/store/useLangList/index.js.map +1 -1
- package/lib/hooks/store/useLineList/index.js +1 -1
- package/lib/hooks/store/useLineList/index.js.map +1 -1
- package/lib/hooks/store/useOrgUserList/index.js +2 -1
- package/lib/hooks/store/useOrgUserList/index.js.map +1 -1
- package/lib/hooks/store/usePlatformLineList/index.js +2 -1
- package/lib/hooks/store/usePlatformLineList/index.js.map +1 -1
- package/lib/hooks/store/usePlatformList/index.js +1 -1
- package/lib/hooks/store/usePlatformList/index.js.map +1 -1
- package/lib/hooks/store/useRepiteFilter/index.js +2 -1
- package/lib/hooks/store/useRepiteFilter/index.js.map +1 -1
- package/lib/hooks/store/userCenter/useAreaList/index.js +2 -1
- package/lib/hooks/store/userCenter/useAreaList/index.js.map +1 -1
- package/lib/hooks/store/userCenter/useOrgList/index.js +1 -2
- package/lib/hooks/store/userCenter/useOrgList/index.js.map +1 -1
- package/lib/hooks/store/userCenter/useOrgTreeList/index.js +2 -1
- package/lib/hooks/store/userCenter/useOrgTreeList/index.js.map +1 -1
- package/lib/hooks/store/userCenter/useRoleList/index.js +1 -2
- package/lib/hooks/store/userCenter/useRoleList/index.js.map +1 -1
- package/lib/index.css +7 -7
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -806,6 +806,13 @@ video {
|
|
|
806
806
|
margin: 0;
|
|
807
807
|
}
|
|
808
808
|
|
|
809
|
+
.gm-flex-center[data-v-2a79bac9] {
|
|
810
|
+
align-items: center;
|
|
811
|
+
}
|
|
812
|
+
|
|
813
|
+
.gm-flex-justify-between[data-v-2a79bac9] {
|
|
814
|
+
justify-content: space-between;
|
|
815
|
+
}
|
|
809
816
|
.gm-number-interval-single[data-v-47a13fd0] {
|
|
810
817
|
border-radius: var(--el-input-border-radius, var(--el-border-radius-base));
|
|
811
818
|
box-shadow: 0 0 0 1px var(--el-input-border-color, var(--el-border-color)) inset;
|
|
@@ -824,13 +831,6 @@ video {
|
|
|
824
831
|
.gm-number-interval-single[data-v-47a13fd0]:hover .gm-number-interval-close[data-v-47a13fd0] {
|
|
825
832
|
display: flex;
|
|
826
833
|
}
|
|
827
|
-
.gm-flex-center[data-v-2a79bac9] {
|
|
828
|
-
align-items: center;
|
|
829
|
-
}
|
|
830
|
-
|
|
831
|
-
.gm-flex-justify-between[data-v-2a79bac9] {
|
|
832
|
-
justify-content: space-between;
|
|
833
|
-
}
|
|
834
834
|
.circular[data-v-b391445c] {
|
|
835
835
|
animation: loading-rotate-b391445c 2s linear infinite;
|
|
836
836
|
}
|
package/es/giime/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.6.
|
|
1
|
+
export declare const version = "0.6.8";
|
package/es/giime/version.mjs
CHANGED
package/es/giime/version.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.mjs","sources":["../../../../packages/giime/version.ts"],"sourcesContent":["export const version = '0.6.
|
|
1
|
+
{"version":3,"file":"version.mjs","sources":["../../../../packages/giime/version.ts"],"sourcesContent":["export const version = '0.6.8';\n"],"names":[],"mappings":"AAAO,MAAM,OAAU,GAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/base/usePageHtmlClass/index.ts"],"sourcesContent":["import { isRef } from 'vue';\nimport { tryOnMounted, tryOnUnmounted } from '@vueuse/
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/base/usePageHtmlClass/index.ts"],"sourcesContent":["import { isRef } from 'vue';\nimport { tryOnMounted, tryOnUnmounted } from '@vueuse/core';\nimport type { MaybeRef } from 'vue';\n\n/**\n * 在页面级别设置 <html> 的类,并在页面离开时恢复\n */\nexport function usePageHtmlClass(classNames: MaybeRef<string[]>) {\n // 定义一个名为 addHtmlClasses 的内部函数,用于向 <html> 元素添加类名\n const addHtmlClasses = () => {\n const names = isRef(classNames) ? classNames.value : classNames;\n if (names.length > 0) {\n document?.documentElement?.classList.add(...names);\n }\n };\n\n // 定义一个名为 removeHtmlClasses 的内部函数,用于从 <html> 元素移除类名\n const removeHtmlClasses = () => {\n const names = isRef(classNames) ? classNames.value : classNames;\n if (names.length > 0) {\n document?.documentElement?.classList.remove(...names);\n }\n };\n\n // 使用 onMounted 钩子在组件挂载时调用 addHtmlClasses 函数\n tryOnMounted(() => {\n addHtmlClasses();\n });\n\n // 使用 onUnmounted 钩子在组件卸载时调用 removeHtmlClasses 函数\n tryOnUnmounted(() => {\n removeHtmlClasses();\n });\n}\n"],"names":[],"mappings":";;;AAOO,SAAS,iBAAiB,UAAgC,EAAA;AAE/D,EAAA,MAAM,iBAAiB,MAAM;AAC3B,IAAA,MAAM,KAAQ,GAAA,KAAA,CAAM,UAAU,CAAA,GAAI,WAAW,KAAQ,GAAA,UAAA,CAAA;AACrD,IAAI,IAAA,KAAA,CAAM,SAAS,CAAG,EAAA;AACpB,MAAA,QAAA,EAAU,eAAiB,EAAA,SAAA,CAAU,GAAI,CAAA,GAAG,KAAK,CAAA,CAAA;AAAA,KACnD;AAAA,GACF,CAAA;AAGA,EAAA,MAAM,oBAAoB,MAAM;AAC9B,IAAA,MAAM,KAAQ,GAAA,KAAA,CAAM,UAAU,CAAA,GAAI,WAAW,KAAQ,GAAA,UAAA,CAAA;AACrD,IAAI,IAAA,KAAA,CAAM,SAAS,CAAG,EAAA;AACpB,MAAA,QAAA,EAAU,eAAiB,EAAA,SAAA,CAAU,MAAO,CAAA,GAAG,KAAK,CAAA,CAAA;AAAA,KACtD;AAAA,GACF,CAAA;AAGA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAe,cAAA,EAAA,CAAA;AAAA,GAChB,CAAA,CAAA;AAGD,EAAA,cAAA,CAAe,MAAM;AACnB,IAAkB,iBAAA,EAAA,CAAA;AAAA,GACnB,CAAA,CAAA;AACH;;;;"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { onMounted } from 'vue';
|
|
2
1
|
import { defineStore } from 'pinia';
|
|
3
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
2
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
4
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
5
4
|
import { usePostCommonV1CountryList } from '../../../../api/basic/controller/Common/usePostCommonV1CountryList.mjs';
|
|
6
5
|
|
|
@@ -17,7 +16,7 @@ const useCountryListStore = defineStore("gmCountryList", () => {
|
|
|
17
16
|
}
|
|
18
17
|
});
|
|
19
18
|
};
|
|
20
|
-
|
|
19
|
+
tryOnMounted(() => {
|
|
21
20
|
getCountryList();
|
|
22
21
|
});
|
|
23
22
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useCountryList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useCountryList/index.ts"],"sourcesContent":["import { defineStore } from 'pinia';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport { usePostCommonV1CountryList } from '@giime/api/basic/controller';\nimport type { PostCommonV1CountryListResultData } from '@giime/api/basic/controller';\n\n/** 国家 */\nexport const useCountryListStore = defineStore('gmCountryList', () => {\n const { isLoading, exec } = usePostCommonV1CountryList();\n const countryList = useSessionStorage<PostCommonV1CountryListResultData[]>('gmCountryList', [], { listenToStorageChanges: false });\n\n const getCountryList = async () => {\n if (countryList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec().then(response => {\n if (response.data.value?.code == 200) {\n countryList.value = response.data.value?.data || [];\n }\n });\n };\n tryOnMounted(() => {\n getCountryList();\n });\n return {\n countryList,\n isLoading,\n getCountryList,\n };\n});\n"],"names":[],"mappings":";;;;;AAMa,MAAA,mBAAA,GAAsB,WAAY,CAAA,eAAA,EAAiB,MAAM;AACpE,EAAA,MAAM,EAAE,SAAA,EAAW,IAAK,EAAA,GAAI,0BAA2B,EAAA,CAAA;AACvD,EAAM,MAAA,WAAA,GAAc,kBAAuD,eAAiB,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAEjI,EAAA,MAAM,iBAAiB,YAAY;AACjC,IAAA,IAAI,WAAY,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACrD,MAAA,OAAA;AAAA,KACF;AACA,IAAO,OAAA,IAAA,EAAO,CAAA,IAAA,CAAK,CAAY,QAAA,KAAA;AAC7B,MAAA,IAAI,QAAS,CAAA,IAAA,CAAK,KAAO,EAAA,IAAA,IAAQ,GAAK,EAAA;AACpC,QAAA,WAAA,CAAY,KAAQ,GAAA,QAAA,CAAS,IAAK,CAAA,KAAA,EAAO,QAAQ,EAAC,CAAA;AAAA,OACpD;AAAA,KACD,CAAA,CAAA;AAAA,GACH,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAe,cAAA,EAAA,CAAA;AAAA,GAChB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,WAAA;AAAA,IACA,SAAA;AAAA,IACA,cAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { onMounted } from 'vue';
|
|
2
1
|
import { defineStore } from 'pinia';
|
|
3
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
2
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
4
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
5
4
|
import { usePostCommonV1CurrencyList } from '../../../../api/basic/controller/Common/usePostCommonV1CurrencyList.mjs';
|
|
6
5
|
|
|
@@ -17,7 +16,7 @@ const useCurrencyListStore = defineStore("gmCurrencyList", () => {
|
|
|
17
16
|
}
|
|
18
17
|
});
|
|
19
18
|
};
|
|
20
|
-
|
|
19
|
+
tryOnMounted(() => {
|
|
21
20
|
getCurrencyList();
|
|
22
21
|
});
|
|
23
22
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useCurrencyList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useCurrencyList/index.ts"],"sourcesContent":["import { defineStore } from 'pinia';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport { usePostCommonV1CurrencyList } from '@giime/api/basic/controller';\nimport type { PostCommonV1CurrencyListResultData } from '@giime/api/basic/controller';\n\n/** 币种 */\nexport const useCurrencyListStore = defineStore('gmCurrencyList', () => {\n const { isLoading, exec } = usePostCommonV1CurrencyList();\n const currencyList = useSessionStorage<PostCommonV1CurrencyListResultData[]>('gmCurrencyList', [], { listenToStorageChanges: false });\n\n const getCurrencyList = async () => {\n if (currencyList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec().then(res => {\n if (res.data.value?.code == 200) {\n currencyList.value = res.data.value?.data || [];\n }\n });\n };\n tryOnMounted(() => {\n getCurrencyList();\n });\n return {\n currencyList,\n isLoading,\n getCurrencyList,\n };\n});\n"],"names":[],"mappings":";;;;;AAMa,MAAA,oBAAA,GAAuB,WAAY,CAAA,gBAAA,EAAkB,MAAM;AACtE,EAAA,MAAM,EAAE,SAAA,EAAW,IAAK,EAAA,GAAI,2BAA4B,EAAA,CAAA;AACxD,EAAM,MAAA,YAAA,GAAe,kBAAwD,gBAAkB,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAEpI,EAAA,MAAM,kBAAkB,YAAY;AAClC,IAAA,IAAI,YAAa,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACtD,MAAA,OAAA;AAAA,KACF;AACA,IAAO,OAAA,IAAA,EAAO,CAAA,IAAA,CAAK,CAAO,GAAA,KAAA;AACxB,MAAA,IAAI,GAAI,CAAA,IAAA,CAAK,KAAO,EAAA,IAAA,IAAQ,GAAK,EAAA;AAC/B,QAAA,YAAA,CAAa,KAAQ,GAAA,GAAA,CAAI,IAAK,CAAA,KAAA,EAAO,QAAQ,EAAC,CAAA;AAAA,OAChD;AAAA,KACD,CAAA,CAAA;AAAA,GACH,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAgB,eAAA,EAAA,CAAA;AAAA,GACjB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,YAAA;AAAA,IACA,SAAA;AAAA,IACA,eAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { usePostCommonV1SystemList } from '../../../../api/basic/controller/Common/usePostCommonV1SystemList.mjs';
|
|
5
6
|
|
|
6
7
|
const useSystemListStore = defineStore("gmSystemList", () => {
|
|
@@ -12,7 +13,7 @@ const useSystemListStore = defineStore("gmSystemList", () => {
|
|
|
12
13
|
}
|
|
13
14
|
return exec();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
+
tryOnMounted(() => {
|
|
16
17
|
getSystemList();
|
|
17
18
|
});
|
|
18
19
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useSystemList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/common/useSystemList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { usePostCommonV1SystemList } from '@giime/api/basic/controller';\nimport { tryOnMounted } from '@vueuse/core';\n\n/** 系统 */\nexport const useSystemListStore = defineStore('gmSystemList', () => {\n const { isLoading, exec, data } = usePostCommonV1SystemList();\n const systemList = computed(() => data.value?.data || []);\n const getSystemList = async () => {\n if (systemList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec();\n };\n tryOnMounted(() => {\n getSystemList();\n });\n return {\n systemList,\n isLoading,\n getSystemList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,kBAAA,GAAqB,WAAY,CAAA,cAAA,EAAgB,MAAM;AAClE,EAAA,MAAM,EAAE,SAAA,EAAW,IAAM,EAAA,IAAA,KAAS,yBAA0B,EAAA,CAAA;AAC5D,EAAA,MAAM,aAAa,QAAS,CAAA,MAAM,KAAK,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AACxD,EAAA,MAAM,gBAAgB,YAAY;AAChC,IAAA,IAAI,UAAW,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACpD,MAAA,OAAA;AAAA,KACF;AACA,IAAA,OAAO,IAAK,EAAA,CAAA;AAAA,GACd,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAc,aAAA,EAAA,CAAA;AAAA,GACf,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,UAAA;AAAA,IACA,SAAA;AAAA,IACA,aAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/gstore/controller/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { useGetV1BasicGetAliCategoryList } from '../../../api/gstore/controller/JiChuXinXi/useGetV1BasicGetAliCategoryList.mjs';
|
|
5
6
|
|
|
6
7
|
const useAliCategoryListStore = defineStore("gmAliCategoryList", () => {
|
|
@@ -12,7 +13,7 @@ const useAliCategoryListStore = defineStore("gmAliCategoryList", () => {
|
|
|
12
13
|
}
|
|
13
14
|
return exec();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
+
tryOnMounted(() => {
|
|
16
17
|
getAliCategoryList();
|
|
17
18
|
});
|
|
18
19
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useAliCategoryList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useAliCategoryList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { useGetV1BasicGetAliCategoryList } from '@giime/api/gstore/controller';\nimport { tryOnMounted } from '@vueuse/core';\n\n/**1688分类列表 */\nexport const useAliCategoryListStore = defineStore('gmAliCategoryList', () => {\n const { isLoading, exec, data: aliCategoryListData } = useGetV1BasicGetAliCategoryList();\n const aliCategoryList = computed(() => aliCategoryListData.value?.data || []);\n\n const getAliCategoryList = async () => {\n if (aliCategoryList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec();\n };\n tryOnMounted(() => {\n getAliCategoryList();\n });\n return {\n aliCategoryList,\n isLoading,\n getAliCategoryList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,uBAAA,GAA0B,WAAY,CAAA,mBAAA,EAAqB,MAAM;AAC5E,EAAA,MAAM,EAAE,SAAW,EAAA,IAAA,EAAM,IAAM,EAAA,mBAAA,KAAwB,+BAAgC,EAAA,CAAA;AACvF,EAAA,MAAM,kBAAkB,QAAS,CAAA,MAAM,oBAAoB,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AAE5E,EAAA,MAAM,qBAAqB,YAAY;AACrC,IAAA,IAAI,eAAgB,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACzD,MAAA,OAAA;AAAA,KACF;AACA,IAAA,OAAO,IAAK,EAAA,CAAA;AAAA,GACd,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAmB,kBAAA,EAAA,CAAA;AAAA,GACpB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,eAAA;AAAA,IACA,SAAA;AAAA,IACA,kBAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ref
|
|
1
|
+
import { ref } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/materialApi/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { getAliOssConfigs } from '../../../api/materialApi/cross/getAliOssConfigs.mjs';
|
|
5
6
|
|
|
6
7
|
const useAliOssConfigsStore = defineStore("gmaliOssConfigs", () => {
|
|
@@ -17,7 +18,7 @@ const useAliOssConfigsStore = defineStore("gmaliOssConfigs", () => {
|
|
|
17
18
|
isLoading.value = false;
|
|
18
19
|
}
|
|
19
20
|
};
|
|
20
|
-
|
|
21
|
+
tryOnMounted(() => {
|
|
21
22
|
getaliOssConfigsAsync();
|
|
22
23
|
});
|
|
23
24
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useAliOssConfigs/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useAliOssConfigs/index.ts"],"sourcesContent":["import { ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { type GetAliOssConfigsResponseData, getAliOssConfigs } from '@giime/api/materialApi';\nimport { tryOnMounted } from '@vueuse/core';\n\n/** 阿里云oss配置id */\nexport const useAliOssConfigsStore = defineStore('gmaliOssConfigs', () => {\n const aliOssConfigs = ref<GetAliOssConfigsResponseData | null>(null);\n const isLoading = ref(false);\n\n const getaliOssConfigsAsync = async () => {\n if (aliOssConfigs.value) return;\n isLoading.value = true;\n try {\n const { data } = await getAliOssConfigs();\n aliOssConfigs.value = data.data;\n } finally {\n isLoading.value = false;\n }\n };\n\n tryOnMounted(() => {\n getaliOssConfigsAsync();\n });\n\n return {\n isLoading,\n aliOssConfigs,\n getaliOssConfigsAsync,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,qBAAA,GAAwB,WAAY,CAAA,iBAAA,EAAmB,MAAM;AACxE,EAAM,MAAA,aAAA,GAAgB,IAAyC,IAAI,CAAA,CAAA;AACnE,EAAM,MAAA,SAAA,GAAY,IAAI,KAAK,CAAA,CAAA;AAE3B,EAAA,MAAM,wBAAwB,YAAY;AACxC,IAAA,IAAI,aAAc,CAAA,KAAA;AAAO,MAAA,OAAA;AACzB,IAAA,SAAA,CAAU,KAAQ,GAAA,IAAA,CAAA;AAClB,IAAI,IAAA;AACF,MAAA,MAAM,EAAE,IAAA,EAAS,GAAA,MAAM,gBAAiB,EAAA,CAAA;AACxC,MAAA,aAAA,CAAc,QAAQ,IAAK,CAAA,IAAA,CAAA;AAAA,KAC3B,SAAA;AACA,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF,CAAA;AAEA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAsB,qBAAA,EAAA,CAAA;AAAA,GACvB,CAAA,CAAA;AAED,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,aAAA;AAAA,IACA,qBAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/productCenter/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { useGetCompanyCategoryTree } from '../../../api/productCenter/categoryManage/useGetCompanyCategoryTree.mjs';
|
|
5
6
|
|
|
6
7
|
const useCompanyCategoryListStore = defineStore("gmCompanyCategoryList", () => {
|
|
@@ -12,7 +13,7 @@ const useCompanyCategoryListStore = defineStore("gmCompanyCategoryList", () => {
|
|
|
12
13
|
}
|
|
13
14
|
return exec();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
+
tryOnMounted(() => {
|
|
16
17
|
getCompanyCategoryList();
|
|
17
18
|
});
|
|
18
19
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useCompanyCategoryList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useCompanyCategoryList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { useGetCompanyCategoryTree } from '@giime/api/productCenter';\nimport { tryOnMounted } from '@vueuse/core';\n\n/**公司分类列表 */\nexport const useCompanyCategoryListStore = defineStore('gmCompanyCategoryList', () => {\n const { isLoading, exec, data: companyCategoryListData } = useGetCompanyCategoryTree();\n const companyCategoryList = computed(() => companyCategoryListData.value?.data ?? []);\n\n const getCompanyCategoryList = async () => {\n if (companyCategoryList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec();\n };\n tryOnMounted(() => {\n getCompanyCategoryList();\n });\n return {\n companyCategoryList,\n isLoading,\n getCompanyCategoryList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,2BAAA,GAA8B,WAAY,CAAA,uBAAA,EAAyB,MAAM;AACpF,EAAA,MAAM,EAAE,SAAW,EAAA,IAAA,EAAM,IAAM,EAAA,uBAAA,KAA4B,yBAA0B,EAAA,CAAA;AACrF,EAAA,MAAM,sBAAsB,QAAS,CAAA,MAAM,wBAAwB,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AAEpF,EAAA,MAAM,yBAAyB,YAAY;AACzC,IAAA,IAAI,mBAAoB,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AAC7D,MAAA,OAAA;AAAA,KACF;AACA,IAAA,OAAO,IAAK,EAAA,CAAA;AAAA,GACd,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAuB,sBAAA,EAAA,CAAA;AAAA,GACxB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,mBAAA;AAAA,IACA,SAAA;AAAA,IACA,sBAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ref
|
|
1
|
+
import { ref } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/index.mjs';
|
|
4
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
4
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
5
5
|
import { useLoading } from '../../base/useLoading/index.mjs';
|
|
6
6
|
import { getV1BasicGetLangList } from '../../../api/gstore/controller/JiChuXinXi/getV1BasicGetLangList.mjs';
|
|
7
7
|
|
|
@@ -19,7 +19,7 @@ const useLangListStore = defineStore("gmLangList", () => {
|
|
|
19
19
|
}
|
|
20
20
|
langList.value = data.data;
|
|
21
21
|
};
|
|
22
|
-
|
|
22
|
+
tryOnMounted(() => {
|
|
23
23
|
getLangList();
|
|
24
24
|
});
|
|
25
25
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useLangList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useLangList/index.ts"],"sourcesContent":["import { ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { getV1BasicGetLangList } from '@giime/api';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport { useLoading } from '@giime/hooks/base/useLoading/index';\nimport type { GetV1BasicGetLangListResultData } from '@giime/api';\n\n/**语种列表 */\nexport const useLangListStore = defineStore('gmLangList', () => {\n // const langList = ref<GetV1BasicGetLangListResultData[]>([]);\n const langList = useSessionStorage<GetV1BasicGetLangListResultData[]>('gmLangList', [], { listenToStorageChanges: false });\n\n const { isLoading, exec: getLangListExec, getDataFinally } = useLoading(getV1BasicGetLangList);\n const isFinished = ref(false);\n\n const getLangList = async () => {\n if (langList.value.length !== 0 || isLoading.value) {\n return;\n }\n const { data } = await getLangListExec();\n if (data.code !== 200) {\n return;\n }\n langList.value = data.data;\n };\n tryOnMounted(() => {\n getLangList();\n });\n return {\n langList,\n isLoading,\n isFinished,\n getLangList,\n getDataFinally,\n };\n});\n"],"names":[],"mappings":";;;;;;;AAQa,MAAA,gBAAA,GAAmB,WAAY,CAAA,YAAA,EAAc,MAAM;AAE9D,EAAM,MAAA,QAAA,GAAW,kBAAqD,YAAc,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAEzH,EAAA,MAAM,EAAE,SAAW,EAAA,IAAA,EAAM,iBAAiB,cAAe,EAAA,GAAI,WAAW,qBAAqB,CAAA,CAAA;AAC7F,EAAM,MAAA,UAAA,GAAa,IAAI,KAAK,CAAA,CAAA;AAE5B,EAAA,MAAM,cAAc,YAAY;AAC9B,IAAA,IAAI,QAAS,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AAClD,MAAA,OAAA;AAAA,KACF;AACA,IAAA,MAAM,EAAE,IAAA,EAAS,GAAA,MAAM,eAAgB,EAAA,CAAA;AACvC,IAAI,IAAA,IAAA,CAAK,SAAS,GAAK,EAAA;AACrB,MAAA,OAAA;AAAA,KACF;AACA,IAAA,QAAA,CAAS,QAAQ,IAAK,CAAA,IAAA,CAAA;AAAA,GACxB,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAY,WAAA,EAAA,CAAA;AAAA,GACb,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,QAAA;AAAA,IACA,SAAA;AAAA,IACA,UAAA;AAAA,IACA,WAAA;AAAA,IACA,cAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ref
|
|
1
|
+
import { ref } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
3
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
4
4
|
import '../../../api/shopAdmin/index.mjs';
|
|
5
5
|
import { postShopAdminStoreFilter } from '../../../api/shopAdmin/store/postShopAdminStoreFilter.mjs';
|
|
6
6
|
|
|
@@ -28,7 +28,7 @@ const useLineListStore = defineStore("gmLineList", () => {
|
|
|
28
28
|
isLoading.value = false;
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
|
-
|
|
31
|
+
tryOnMounted(() => {
|
|
32
32
|
getLineList();
|
|
33
33
|
});
|
|
34
34
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useLineList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useLineList/index.ts"],"sourcesContent":["import { ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport { postShopAdminStoreFilter } from '@giime/api/shopAdmin';\nimport type { PostShopAdminStoreFilterResponseDataLine } from '@giime/api/shopAdmin';\n\n/**国家线路列表 */\nexport const useLineListStore = defineStore('gmLineList', () => {\n const lineList = useSessionStorage<PostShopAdminStoreFilterResponseDataLine[]>('gmLineList', [], { listenToStorageChanges: false });\n\n const isLoading = ref(false);\n const getLineList = async () => {\n if (lineList.value.length !== 0) {\n isLoading.value = false;\n return;\n }\n if (isLoading.value) {\n return;\n }\n try {\n isLoading.value = true;\n const { data } = await postShopAdminStoreFilter({ keys: 'line' });\n isLoading.value = false;\n if (data.code !== 0) {\n return;\n }\n lineList.value = data.data.line;\n } catch (e) {\n console.error(e);\n isLoading.value = false;\n }\n };\n tryOnMounted(() => {\n getLineList();\n });\n return {\n lineList,\n isLoading,\n getLineList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAOa,MAAA,gBAAA,GAAmB,WAAY,CAAA,YAAA,EAAc,MAAM;AAC9D,EAAM,MAAA,QAAA,GAAW,kBAA8D,YAAc,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAElI,EAAM,MAAA,SAAA,GAAY,IAAI,KAAK,CAAA,CAAA;AAC3B,EAAA,MAAM,cAAc,YAAY;AAC9B,IAAI,IAAA,QAAA,CAAS,KAAM,CAAA,MAAA,KAAW,CAAG,EAAA;AAC/B,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAA,OAAA;AAAA,KACF;AACA,IAAA,IAAI,UAAU,KAAO,EAAA;AACnB,MAAA,OAAA;AAAA,KACF;AACA,IAAI,IAAA;AACF,MAAA,SAAA,CAAU,KAAQ,GAAA,IAAA,CAAA;AAClB,MAAM,MAAA,EAAE,MAAS,GAAA,MAAM,yBAAyB,EAAE,IAAA,EAAM,QAAQ,CAAA,CAAA;AAChE,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAI,IAAA,IAAA,CAAK,SAAS,CAAG,EAAA;AACnB,QAAA,OAAA;AAAA,OACF;AACA,MAAS,QAAA,CAAA,KAAA,GAAQ,KAAK,IAAK,CAAA,IAAA,CAAA;AAAA,aACpB,CAAG,EAAA;AACV,MAAA,OAAA,CAAQ,MAAM,CAAC,CAAA,CAAA;AACf,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAY,WAAA,EAAA,CAAA;AAAA,GACb,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,QAAA;AAAA,IACA,SAAA;AAAA,IACA,WAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import { groupBy } from 'lodash-es';
|
|
4
4
|
import '../../../api/guardBasic/controller/index.mjs';
|
|
5
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
5
6
|
import { usePostBasicV1UserListUserOrg } from '../../../api/guardBasic/controller/JiChuFuWu/YongHuGuanLi/usePostBasicV1UserListUserOrg.mjs';
|
|
6
7
|
|
|
7
8
|
const useOrgUserListStore = defineStore("gmOrgUserList", (options = { disabledInitList: false }) => {
|
|
@@ -21,7 +22,7 @@ const useOrgUserListStore = defineStore("gmOrgUserList", (options = { disabledIn
|
|
|
21
22
|
return exec(input);
|
|
22
23
|
};
|
|
23
24
|
if (!options.disabledInitList) {
|
|
24
|
-
|
|
25
|
+
tryOnMounted(() => {
|
|
25
26
|
if (userList.value.length !== 0 || isLoading.value) {
|
|
26
27
|
return;
|
|
27
28
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useOrgUserList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useOrgUserList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { groupBy } from 'lodash-es';\nimport { usePostBasicV1UserListUserOrg } from '@giime/api/guardBasic/controller';\nimport { tryOnMounted } from '@vueuse/core';\nimport type { UserOrgReq } from '@giime/api/guardBasic/interface';\n\n/**用户-家族列表 */\nexport const useOrgUserListStore = defineStore('gmOrgUserList', (options = { disabledInitList: false }) => {\n const { isLoading, exec, data: userListData } = usePostBasicV1UserListUserOrg();\n const userList = computed(() => userListData.value?.data || []);\n const orgUserList = computed(() => {\n const familyGroup = groupBy(userList.value, 'family_code');\n return Object.keys(familyGroup).map(familyCode => {\n return {\n label: familyGroup[familyCode][0].family_name,\n value: familyCode,\n children: familyGroup[familyCode].map(it => ({ label: it.user_name, value: it.user_id })),\n };\n });\n });\n const getOrgUserList = async (input?: UserOrgReq) => {\n return exec(input);\n };\n if (!options.disabledInitList) {\n tryOnMounted(() => {\n if (userList.value.length !== 0 || isLoading.value) {\n return;\n }\n getOrgUserList({ user_status: 1 });\n });\n }\n\n return {\n userList,\n isLoading,\n orgUserList,\n getOrgUserList,\n };\n});\n"],"names":[],"mappings":";;;;;;;AAQa,MAAA,mBAAA,GAAsB,YAAY,eAAiB,EAAA,CAAC,UAAU,EAAE,gBAAA,EAAkB,OAAY,KAAA;AACzG,EAAA,MAAM,EAAE,SAAW,EAAA,IAAA,EAAM,IAAM,EAAA,YAAA,KAAiB,6BAA8B,EAAA,CAAA;AAC9E,EAAA,MAAM,WAAW,QAAS,CAAA,MAAM,aAAa,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AAC9D,EAAM,MAAA,WAAA,GAAc,SAAS,MAAM;AACjC,IAAA,MAAM,WAAc,GAAA,OAAA,CAAQ,QAAS,CAAA,KAAA,EAAO,aAAa,CAAA,CAAA;AACzD,IAAA,OAAO,MAAO,CAAA,IAAA,CAAK,WAAW,CAAA,CAAE,IAAI,CAAc,UAAA,KAAA;AAChD,MAAO,OAAA;AAAA,QACL,KAAO,EAAA,WAAA,CAAY,UAAU,CAAA,CAAE,CAAC,CAAE,CAAA,WAAA;AAAA,QAClC,KAAO,EAAA,UAAA;AAAA,QACP,QAAU,EAAA,WAAA,CAAY,UAAU,CAAA,CAAE,GAAI,CAAA,CAAA,EAAA,MAAO,EAAE,KAAA,EAAO,EAAG,CAAA,SAAA,EAAW,KAAO,EAAA,EAAA,CAAG,SAAU,CAAA,CAAA;AAAA,OAC1F,CAAA;AAAA,KACD,CAAA,CAAA;AAAA,GACF,CAAA,CAAA;AACD,EAAM,MAAA,cAAA,GAAiB,OAAO,KAAuB,KAAA;AACnD,IAAA,OAAO,KAAK,KAAK,CAAA,CAAA;AAAA,GACnB,CAAA;AACA,EAAI,IAAA,CAAC,QAAQ,gBAAkB,EAAA;AAC7B,IAAA,YAAA,CAAa,MAAM;AACjB,MAAA,IAAI,QAAS,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AAClD,QAAA,OAAA;AAAA,OACF;AACA,MAAe,cAAA,CAAA,EAAE,WAAa,EAAA,CAAA,EAAG,CAAA,CAAA;AAAA,KAClC,CAAA,CAAA;AAAA,GACH;AAEA,EAAO,OAAA;AAAA,IACL,QAAA;AAAA,IACA,SAAA;AAAA,IACA,WAAA;AAAA,IACA,cAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ref
|
|
1
|
+
import { ref } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/shopAdmin/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { getPlatformLineApi } from '../../../api/shopAdmin/store/getPlatformLine.mjs';
|
|
5
6
|
|
|
6
7
|
const usePlatformLineListStore = defineStore("gmPlatformLineList", () => {
|
|
@@ -40,7 +41,7 @@ const usePlatformLineListStore = defineStore("gmPlatformLineList", () => {
|
|
|
40
41
|
isLoading.value = false;
|
|
41
42
|
}
|
|
42
43
|
};
|
|
43
|
-
|
|
44
|
+
tryOnMounted(() => {
|
|
44
45
|
getPlatformLineList();
|
|
45
46
|
});
|
|
46
47
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/usePlatformLineList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/usePlatformLineList/index.ts"],"sourcesContent":["import { ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { getPlatformLineApi } from '@giime/api/shopAdmin';\nimport { tryOnMounted } from '@vueuse/core';\nimport type { GetPlatformLineResponseDatum } from '@giime/api/shopAdmin';\nexport interface UsePlatformLineListStoreCascaderListItem {\n id: number;\n name: string;\n lineList: {\n id: string;\n name: string;\n }[];\n}\n/**三方平台线路列表 */\nexport const usePlatformLineListStore = defineStore('gmPlatformLineList', () => {\n const platformLineList = ref<GetPlatformLineResponseDatum[]>([]);\n /**\n * 获取平台线路级联列表\n */\n const cascaderList = ref<UsePlatformLineListStoreCascaderListItem[]>([]);\n const isLoading = ref(false);\n const getPlatformLineList = async (options?: { isReload: boolean }) => {\n if (!options?.isReload && platformLineList.value.length !== 0) {\n isLoading.value = false;\n return;\n }\n if (isLoading.value) {\n return;\n }\n try {\n isLoading.value = true;\n const { data } = await getPlatformLineApi();\n isLoading.value = false;\n if (data.code !== 0) {\n return;\n }\n platformLineList.value = data.data;\n cascaderList.value = data.data.map(item => {\n return {\n id: item.plat_id,\n name: item.platform,\n lineList: item.line_list.map(it => {\n return {\n id: it.line_code,\n name: it.line_name,\n };\n }),\n };\n });\n } catch (e) {\n console.error(e);\n isLoading.value = false;\n }\n };\n tryOnMounted(() => {\n getPlatformLineList();\n });\n return {\n platformLineList,\n /**\n * 获取平台线路级联列表\n */\n cascaderList,\n isLoading,\n getPlatformLineList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAca,MAAA,wBAAA,GAA2B,WAAY,CAAA,oBAAA,EAAsB,MAAM;AAC9E,EAAM,MAAA,gBAAA,GAAmB,GAAoC,CAAA,EAAE,CAAA,CAAA;AAI/D,EAAM,MAAA,YAAA,GAAe,GAAgD,CAAA,EAAE,CAAA,CAAA;AACvE,EAAM,MAAA,SAAA,GAAY,IAAI,KAAK,CAAA,CAAA;AAC3B,EAAM,MAAA,mBAAA,GAAsB,OAAO,OAAoC,KAAA;AACrE,IAAA,IAAI,CAAC,OAAS,EAAA,QAAA,IAAY,gBAAiB,CAAA,KAAA,CAAM,WAAW,CAAG,EAAA;AAC7D,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAA,OAAA;AAAA,KACF;AACA,IAAA,IAAI,UAAU,KAAO,EAAA;AACnB,MAAA,OAAA;AAAA,KACF;AACA,IAAI,IAAA;AACF,MAAA,SAAA,CAAU,KAAQ,GAAA,IAAA,CAAA;AAClB,MAAA,MAAM,EAAE,IAAA,EAAS,GAAA,MAAM,kBAAmB,EAAA,CAAA;AAC1C,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAI,IAAA,IAAA,CAAK,SAAS,CAAG,EAAA;AACnB,QAAA,OAAA;AAAA,OACF;AACA,MAAA,gBAAA,CAAiB,QAAQ,IAAK,CAAA,IAAA,CAAA;AAC9B,MAAA,YAAA,CAAa,KAAQ,GAAA,IAAA,CAAK,IAAK,CAAA,GAAA,CAAI,CAAQ,IAAA,KAAA;AACzC,QAAO,OAAA;AAAA,UACL,IAAI,IAAK,CAAA,OAAA;AAAA,UACT,MAAM,IAAK,CAAA,QAAA;AAAA,UACX,QAAU,EAAA,IAAA,CAAK,SAAU,CAAA,GAAA,CAAI,CAAM,EAAA,KAAA;AACjC,YAAO,OAAA;AAAA,cACL,IAAI,EAAG,CAAA,SAAA;AAAA,cACP,MAAM,EAAG,CAAA,SAAA;AAAA,aACX,CAAA;AAAA,WACD,CAAA;AAAA,SACH,CAAA;AAAA,OACD,CAAA,CAAA;AAAA,aACM,CAAG,EAAA;AACV,MAAA,OAAA,CAAQ,MAAM,CAAC,CAAA,CAAA;AACf,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAoB,mBAAA,EAAA,CAAA;AAAA,GACrB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,gBAAA;AAAA;AAAA;AAAA;AAAA,IAIA,YAAA;AAAA,IACA,SAAA;AAAA,IACA,mBAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ref
|
|
1
|
+
import { ref } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/shopAdmin/index.mjs';
|
|
4
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
4
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
5
5
|
import { postPlatListApi } from '../../../api/shopAdmin/store/postPlatfirmList.mjs';
|
|
6
6
|
|
|
7
7
|
const usePlatformListStore = defineStore("gmPlatformList", () => {
|
|
@@ -28,7 +28,7 @@ const usePlatformListStore = defineStore("gmPlatformList", () => {
|
|
|
28
28
|
isLoading.value = false;
|
|
29
29
|
}
|
|
30
30
|
};
|
|
31
|
-
|
|
31
|
+
tryOnMounted(() => {
|
|
32
32
|
getPlatformList();
|
|
33
33
|
});
|
|
34
34
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/usePlatformList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/usePlatformList/index.ts"],"sourcesContent":["import { ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { postPlatListApi } from '@giime/api/shopAdmin';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport type { PostPlatformListResponseDatum } from '@giime/api/shopAdmin';\n\n/**三方平台列表 */\nexport const usePlatformListStore = defineStore('gmPlatformList', () => {\n const platformList = useSessionStorage<PostPlatformListResponseDatum[]>('gmPlatformList', [], { listenToStorageChanges: false });\n\n const isLoading = ref(false);\n const getPlatformList = async () => {\n if (platformList.value.length !== 0) {\n isLoading.value = false;\n return;\n }\n if (isLoading.value) {\n return;\n }\n try {\n isLoading.value = true;\n const { data } = await postPlatListApi();\n isLoading.value = false;\n if (data.code !== 0) {\n return;\n }\n platformList.value = data.data;\n } catch (e) {\n console.error(e);\n isLoading.value = false;\n }\n };\n tryOnMounted(() => {\n getPlatformList();\n });\n return {\n platformList,\n isLoading,\n getPlatformList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAOa,MAAA,oBAAA,GAAuB,WAAY,CAAA,gBAAA,EAAkB,MAAM;AACtE,EAAM,MAAA,YAAA,GAAe,kBAAmD,gBAAkB,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAE/H,EAAM,MAAA,SAAA,GAAY,IAAI,KAAK,CAAA,CAAA;AAC3B,EAAA,MAAM,kBAAkB,YAAY;AAClC,IAAI,IAAA,YAAA,CAAa,KAAM,CAAA,MAAA,KAAW,CAAG,EAAA;AACnC,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAA,OAAA;AAAA,KACF;AACA,IAAA,IAAI,UAAU,KAAO,EAAA;AACnB,MAAA,OAAA;AAAA,KACF;AACA,IAAI,IAAA;AACF,MAAA,SAAA,CAAU,KAAQ,GAAA,IAAA,CAAA;AAClB,MAAA,MAAM,EAAE,IAAA,EAAS,GAAA,MAAM,eAAgB,EAAA,CAAA;AACvC,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAI,IAAA,IAAA,CAAK,SAAS,CAAG,EAAA;AACnB,QAAA,OAAA;AAAA,OACF;AACA,MAAA,YAAA,CAAa,QAAQ,IAAK,CAAA,IAAA,CAAA;AAAA,aACnB,CAAG,EAAA;AACV,MAAA,OAAA,CAAQ,MAAM,CAAC,CAAA,CAAA;AACf,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAgB,eAAA,EAAA,CAAA;AAAA,GACjB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,YAAA;AAAA,IACA,SAAA;AAAA,IACA,eAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ref, computed
|
|
1
|
+
import { ref, computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../api/shopAdmin/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { getRepiteFillter } from '../../../api/shopAdmin/repite/getRepiteFillter.mjs';
|
|
5
6
|
|
|
6
7
|
const useRepiteFilterStore = defineStore("gmRepiteFilter", () => {
|
|
@@ -28,7 +29,7 @@ const useRepiteFilterStore = defineStore("gmRepiteFilter", () => {
|
|
|
28
29
|
isLoading.value = false;
|
|
29
30
|
}
|
|
30
31
|
};
|
|
31
|
-
|
|
32
|
+
tryOnMounted(() => {
|
|
32
33
|
getRepiteFilterData();
|
|
33
34
|
});
|
|
34
35
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useRepiteFilter/index.ts"],"sourcesContent":["import { computed,
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/hooks/store/useRepiteFilter/index.ts"],"sourcesContent":["import { computed, ref } from 'vue';\nimport { defineStore } from 'pinia';\nimport { getRepiteFillter } from '@giime/api/shopAdmin';\nimport { tryOnMounted } from '@vueuse/core';\nimport type { GetRepiteFillterResponseData } from '@giime/api/shopAdmin';\n\n/**选品筛选条件 */\nexport const useRepiteFilterStore = defineStore('gmRepiteFilter', () => {\n const filterData = ref<GetRepiteFillterResponseData>();\n const langList = computed(() => filterData.value?.language.data ?? []);\n const isLoading = ref(false);\n const getRepiteFilterData = async () => {\n if (filterData.value) {\n isLoading.value = false;\n return;\n }\n if (isLoading.value) {\n return;\n }\n try {\n isLoading.value = true;\n const { data } = await getRepiteFillter();\n isLoading.value = false;\n if (data.code !== 0) {\n return;\n }\n filterData.value = data.data;\n } catch (e) {\n console.error(e);\n isLoading.value = false;\n }\n };\n tryOnMounted(() => {\n getRepiteFilterData();\n });\n return {\n filterData,\n langList,\n isLoading,\n getRepiteFilterData,\n };\n});\n"],"names":[],"mappings":";;;;;;AAOa,MAAA,oBAAA,GAAuB,WAAY,CAAA,gBAAA,EAAkB,MAAM;AACtE,EAAA,MAAM,aAAa,GAAkC,EAAA,CAAA;AACrD,EAAM,MAAA,QAAA,GAAW,SAAS,MAAM,UAAA,CAAW,OAAO,QAAS,CAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AACrE,EAAM,MAAA,SAAA,GAAY,IAAI,KAAK,CAAA,CAAA;AAC3B,EAAA,MAAM,sBAAsB,YAAY;AACtC,IAAA,IAAI,WAAW,KAAO,EAAA;AACpB,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAA,OAAA;AAAA,KACF;AACA,IAAA,IAAI,UAAU,KAAO,EAAA;AACnB,MAAA,OAAA;AAAA,KACF;AACA,IAAI,IAAA;AACF,MAAA,SAAA,CAAU,KAAQ,GAAA,IAAA,CAAA;AAClB,MAAA,MAAM,EAAE,IAAA,EAAS,GAAA,MAAM,gBAAiB,EAAA,CAAA;AACxC,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAClB,MAAI,IAAA,IAAA,CAAK,SAAS,CAAG,EAAA;AACnB,QAAA,OAAA;AAAA,OACF;AACA,MAAA,UAAA,CAAW,QAAQ,IAAK,CAAA,IAAA,CAAA;AAAA,aACjB,CAAG,EAAA;AACV,MAAA,OAAA,CAAQ,MAAM,CAAC,CAAA,CAAA;AACf,MAAA,SAAA,CAAU,KAAQ,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAoB,mBAAA,EAAA,CAAA;AAAA,GACrB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,UAAA;AAAA,IACA,QAAA;AAAA,IACA,SAAA;AAAA,IACA,mBAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { usePostUserCenterV1AreaList } from '../../../../api/basic/controller/UserCenter/usePostUserCenterV1AreaList.mjs';
|
|
5
6
|
|
|
6
7
|
const useAreaListStore = defineStore("gmAreaList", () => {
|
|
@@ -12,7 +13,7 @@ const useAreaListStore = defineStore("gmAreaList", () => {
|
|
|
12
13
|
}
|
|
13
14
|
return exec();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
+
tryOnMounted(() => {
|
|
16
17
|
getAreaList();
|
|
17
18
|
});
|
|
18
19
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useAreaList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useAreaList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { usePostUserCenterV1AreaList } from '@giime/api/basic/controller';\nimport { tryOnMounted } from '@vueuse/core';\n\n/** 团队 */\nexport const useAreaListStore = defineStore('gmAreaList', () => {\n const { isLoading, exec, data } = usePostUserCenterV1AreaList();\n const areaList = computed(() => data.value?.data || []);\n const getAreaList = async () => {\n if (areaList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec();\n };\n tryOnMounted(() => {\n getAreaList();\n });\n return {\n areaList,\n isLoading,\n getAreaList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,gBAAA,GAAmB,WAAY,CAAA,YAAA,EAAc,MAAM;AAC9D,EAAA,MAAM,EAAE,SAAA,EAAW,IAAM,EAAA,IAAA,KAAS,2BAA4B,EAAA,CAAA;AAC9D,EAAA,MAAM,WAAW,QAAS,CAAA,MAAM,KAAK,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AACtD,EAAA,MAAM,cAAc,YAAY;AAC9B,IAAA,IAAI,QAAS,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AAClD,MAAA,OAAA;AAAA,KACF;AACA,IAAA,OAAO,IAAK,EAAA,CAAA;AAAA,GACd,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAY,WAAA,EAAA,CAAA;AAAA,GACb,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,QAAA;AAAA,IACA,SAAA;AAAA,IACA,WAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { onMounted } from 'vue';
|
|
2
1
|
import { defineStore } from 'pinia';
|
|
3
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
2
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
4
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
5
4
|
import { usePostUserCenterV1OrgList } from '../../../../api/basic/controller/UserCenter/usePostUserCenterV1OrgList.mjs';
|
|
6
5
|
|
|
@@ -17,7 +16,7 @@ const useOrgListStore = defineStore("gmOrgList", () => {
|
|
|
17
16
|
}
|
|
18
17
|
});
|
|
19
18
|
};
|
|
20
|
-
|
|
19
|
+
tryOnMounted(() => {
|
|
21
20
|
getOrgList();
|
|
22
21
|
});
|
|
23
22
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useOrgList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useOrgList/index.ts"],"sourcesContent":["import { defineStore } from 'pinia';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\nimport { usePostUserCenterV1OrgList } from '@giime/api/basic/controller';\nimport type { PostUserCenterV1OrgListResultData } from '@giime/api/basic/controller';\n/** 家族 */\nexport const useOrgListStore = defineStore('gmOrgList', () => {\n const { isLoading, exec } = usePostUserCenterV1OrgList();\n const orgList = useSessionStorage<PostUserCenterV1OrgListResultData[]>('gmOrgList', [], { listenToStorageChanges: false });\n\n const getOrgList = async () => {\n if (orgList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec().then(res => {\n if (res.data.value?.code == 200) {\n orgList.value = res.data.value?.data || [];\n }\n });\n };\n tryOnMounted(() => {\n getOrgList();\n });\n return {\n orgList,\n isLoading,\n getOrgList,\n };\n});\n"],"names":[],"mappings":";;;;;AAKa,MAAA,eAAA,GAAkB,WAAY,CAAA,WAAA,EAAa,MAAM;AAC5D,EAAA,MAAM,EAAE,SAAA,EAAW,IAAK,EAAA,GAAI,0BAA2B,EAAA,CAAA;AACvD,EAAM,MAAA,OAAA,GAAU,kBAAuD,WAAa,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAEzH,EAAA,MAAM,aAAa,YAAY;AAC7B,IAAA,IAAI,OAAQ,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACjD,MAAA,OAAA;AAAA,KACF;AACA,IAAO,OAAA,IAAA,EAAO,CAAA,IAAA,CAAK,CAAO,GAAA,KAAA;AACxB,MAAA,IAAI,GAAI,CAAA,IAAA,CAAK,KAAO,EAAA,IAAA,IAAQ,GAAK,EAAA;AAC/B,QAAA,OAAA,CAAQ,KAAQ,GAAA,GAAA,CAAI,IAAK,CAAA,KAAA,EAAO,QAAQ,EAAC,CAAA;AAAA,OAC3C;AAAA,KACD,CAAA,CAAA;AAAA,GACH,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAW,UAAA,EAAA,CAAA;AAAA,GACZ,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,OAAA;AAAA,IACA,SAAA;AAAA,IACA,UAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { computed
|
|
1
|
+
import { computed } from 'vue';
|
|
2
2
|
import { defineStore } from 'pinia';
|
|
3
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
4
|
+
import { tryOnMounted } from '@vueuse/core';
|
|
4
5
|
import { usePostUserCenterV1OrgTreeList } from '../../../../api/basic/controller/UserCenter/usePostUserCenterV1OrgTreeList.mjs';
|
|
5
6
|
|
|
6
7
|
const useOrgTreeListStore = defineStore("gmOrgTreeList", () => {
|
|
@@ -12,7 +13,7 @@ const useOrgTreeListStore = defineStore("gmOrgTreeList", () => {
|
|
|
12
13
|
}
|
|
13
14
|
return exec();
|
|
14
15
|
};
|
|
15
|
-
|
|
16
|
+
tryOnMounted(() => {
|
|
16
17
|
getOrgTreeList();
|
|
17
18
|
});
|
|
18
19
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useOrgTreeList/index.ts"],"sourcesContent":["import { computed
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useOrgTreeList/index.ts"],"sourcesContent":["import { computed } from 'vue';\nimport { defineStore } from 'pinia';\nimport { usePostUserCenterV1OrgTreeList } from '@giime/api/basic/controller';\nimport { tryOnMounted } from '@vueuse/core';\n\n/** 部门 */\nexport const useOrgTreeListStore = defineStore('gmOrgTreeList', () => {\n const { isLoading, exec, data } = usePostUserCenterV1OrgTreeList();\n const orgTreeList = computed(() => data.value?.data || []);\n const getOrgTreeList = async () => {\n if (orgTreeList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec();\n };\n tryOnMounted(() => {\n getOrgTreeList();\n });\n return {\n orgTreeList,\n isLoading,\n getOrgTreeList,\n };\n});\n"],"names":[],"mappings":";;;;;;AAMa,MAAA,mBAAA,GAAsB,WAAY,CAAA,eAAA,EAAiB,MAAM;AACpE,EAAA,MAAM,EAAE,SAAA,EAAW,IAAM,EAAA,IAAA,KAAS,8BAA+B,EAAA,CAAA;AACjE,EAAA,MAAM,cAAc,QAAS,CAAA,MAAM,KAAK,KAAO,EAAA,IAAA,IAAQ,EAAE,CAAA,CAAA;AACzD,EAAA,MAAM,iBAAiB,YAAY;AACjC,IAAA,IAAI,WAAY,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AACrD,MAAA,OAAA;AAAA,KACF;AACA,IAAA,OAAO,IAAK,EAAA,CAAA;AAAA,GACd,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAe,cAAA,EAAA,CAAA;AAAA,GAChB,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,WAAA;AAAA,IACA,SAAA;AAAA,IACA,cAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { onMounted } from 'vue';
|
|
2
1
|
import { defineStore } from 'pinia';
|
|
3
|
-
import { useSessionStorage } from '@vueuse/core';
|
|
2
|
+
import { useSessionStorage, tryOnMounted } from '@vueuse/core';
|
|
4
3
|
import '../../../../api/basic/controller/index.mjs';
|
|
5
4
|
import { usePostUserCenterV1RoleList } from '../../../../api/basic/controller/UserCenter/usePostUserCenterV1RoleList.mjs';
|
|
6
5
|
|
|
@@ -17,7 +16,7 @@ const useRoleListStore = defineStore("gmRoleList", () => {
|
|
|
17
16
|
}
|
|
18
17
|
});
|
|
19
18
|
};
|
|
20
|
-
|
|
19
|
+
tryOnMounted(() => {
|
|
21
20
|
getRoleList();
|
|
22
21
|
});
|
|
23
22
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useRoleList/index.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../../packages/hooks/store/userCenter/useRoleList/index.ts"],"sourcesContent":["import { defineStore } from 'pinia';\nimport { tryOnMounted, useSessionStorage } from '@vueuse/core';\n\nimport { usePostUserCenterV1RoleList } from '@giime/api/basic/controller';\nimport type { PostUserCenterV1RoleListResultData } from '@giime/api/basic/controller';\n\n/** 角色 */\nexport const useRoleListStore = defineStore('gmRoleList', () => {\n const { isLoading, exec } = usePostUserCenterV1RoleList();\n const roleList = useSessionStorage<PostUserCenterV1RoleListResultData[]>('gmRoleList', [], { listenToStorageChanges: false });\n\n const getRoleList = async () => {\n if (roleList.value.length !== 0 || isLoading.value) {\n return;\n }\n return exec().then(res => {\n if (res.data.value?.code == 200) {\n roleList.value = res.data.value?.data || [];\n }\n });\n };\n tryOnMounted(() => {\n getRoleList();\n });\n return {\n roleList,\n isLoading,\n getRoleList,\n };\n});\n"],"names":[],"mappings":";;;;;AAOa,MAAA,gBAAA,GAAmB,WAAY,CAAA,YAAA,EAAc,MAAM;AAC9D,EAAA,MAAM,EAAE,SAAA,EAAW,IAAK,EAAA,GAAI,2BAA4B,EAAA,CAAA;AACxD,EAAM,MAAA,QAAA,GAAW,kBAAwD,YAAc,EAAA,IAAI,EAAE,sBAAA,EAAwB,OAAO,CAAA,CAAA;AAE5H,EAAA,MAAM,cAAc,YAAY;AAC9B,IAAA,IAAI,QAAS,CAAA,KAAA,CAAM,MAAW,KAAA,CAAA,IAAK,UAAU,KAAO,EAAA;AAClD,MAAA,OAAA;AAAA,KACF;AACA,IAAO,OAAA,IAAA,EAAO,CAAA,IAAA,CAAK,CAAO,GAAA,KAAA;AACxB,MAAA,IAAI,GAAI,CAAA,IAAA,CAAK,KAAO,EAAA,IAAA,IAAQ,GAAK,EAAA;AAC/B,QAAA,QAAA,CAAS,KAAQ,GAAA,GAAA,CAAI,IAAK,CAAA,KAAA,EAAO,QAAQ,EAAC,CAAA;AAAA,OAC5C;AAAA,KACD,CAAA,CAAA;AAAA,GACH,CAAA;AACA,EAAA,YAAA,CAAa,MAAM;AACjB,IAAY,WAAA,EAAA,CAAA;AAAA,GACb,CAAA,CAAA;AACD,EAAO,OAAA;AAAA,IACL,QAAA;AAAA,IACA,SAAA;AAAA,IACA,WAAA;AAAA,GACF,CAAA;AACF,CAAC;;;;"}
|