@indfnd/utils 0.1.36 → 0.1.38

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.
Files changed (65) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/dist/ind-utils.es.js +865 -607
  3. package/dist/ind-utils.umd.cjs +21 -21
  4. package/global.d.ts +2 -0
  5. package/package.json +1 -1
  6. package/src/api/com.ts +4 -2
  7. package/src/api/item.ts +4 -2
  8. package/src/api/platform/oss.ts +6 -3
  9. package/src/utils/excel.js +157 -0
  10. package/types/api/com.d.ts +2 -4
  11. package/types/api/com.d.ts.map +1 -1
  12. package/types/api/index-desc.d.ts +2 -4
  13. package/types/api/index-desc.d.ts.map +1 -1
  14. package/types/api/index.d.ts +7 -7
  15. package/types/api/item.d.ts +4 -6
  16. package/types/api/item.d.ts.map +1 -1
  17. package/types/api/permission.d.ts +2 -2
  18. package/types/api/platform/base64.d.ts +5 -5
  19. package/types/api/platform/config.d.ts +2 -2
  20. package/types/api/platform/dict.d.ts +4 -6
  21. package/types/api/platform/dict.d.ts.map +1 -1
  22. package/types/api/platform/index.d.ts +6 -6
  23. package/types/api/platform/menu.d.ts +11 -21
  24. package/types/api/platform/menu.d.ts.map +1 -1
  25. package/types/api/platform/oss.d.ts +8 -16
  26. package/types/api/platform/oss.d.ts.map +1 -1
  27. package/types/api/platform/user.d.ts +12 -19
  28. package/types/api/platform/user.d.ts.map +1 -1
  29. package/types/api/user.d.ts +2 -2
  30. package/types/config/base.config.d.ts +33 -33
  31. package/types/config/dev.config.d.ts +3 -3
  32. package/types/config/index.d.ts +6 -6
  33. package/types/config/prod.config.d.ts +3 -3
  34. package/types/index.d.ts +4 -4
  35. package/types/utils/base64.d.ts +22 -22
  36. package/types/utils/blob.d.ts +3 -3
  37. package/types/utils/cache/dict-cache.d.ts +3 -3
  38. package/types/utils/cache/index-desc.d.ts +4 -4
  39. package/types/utils/cache/index.d.ts +4 -4
  40. package/types/utils/cache/permission-cache.d.ts +4 -4
  41. package/types/utils/cache/user-cache.d.ts +4 -4
  42. package/types/utils/date.d.ts +4 -4
  43. package/types/utils/enum.d.ts +39 -43
  44. package/types/utils/event.d.ts +5 -13
  45. package/types/utils/excel.d.ts +5 -4
  46. package/types/utils/excel.d.ts.map +1 -1
  47. package/types/utils/half-year.d.ts +6 -6
  48. package/types/utils/index.d.ts +20 -20
  49. package/types/utils/is-type.d.ts +33 -33
  50. package/types/utils/mime-type.d.ts +67 -67
  51. package/types/utils/number.d.ts +8 -8
  52. package/types/utils/quarter.d.ts +7 -7
  53. package/types/utils/request/axios.extends.d.ts +6 -18
  54. package/types/utils/request/cache-rules.d.ts +3 -3
  55. package/types/utils/request/content-type.d.ts +9 -9
  56. package/types/utils/request/index.d.ts +13 -16
  57. package/types/utils/request/interceptors.d.ts +4 -4
  58. package/types/utils/request/url-params.d.ts +6 -6
  59. package/types/utils/sm3/index.d.ts +6 -6
  60. package/types/utils/sm3/sm3.d.ts +3 -3
  61. package/types/utils/storage.d.ts +8 -8
  62. package/types/utils/table.d.ts +31 -40
  63. package/types/utils/token.d.ts +3 -3
  64. package/types/utils/uuid.d.ts +4 -4
  65. package/types/utils/validate.d.ts +5 -5
package/global.d.ts CHANGED
@@ -7,6 +7,8 @@ interface Window {
7
7
  wx: any
8
8
  }
9
9
 
10
+ declare const __IS_HB__: string
11
+
10
12
  interface Date {
11
13
  toGMTString: () => string
12
14
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@indfnd/utils",
3
- "version": "0.1.36",
3
+ "version": "0.1.38",
4
4
  "author": "huxuetong",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
package/src/api/com.ts CHANGED
@@ -1,12 +1,14 @@
1
1
  import { axios } from '@/utils'
2
2
  import { config } from '@/config'
3
- const isHb = location.pathname.includes('scyxweb')
3
+ function isHb() {
4
+ return __IS_HB__
5
+ }
4
6
  const CONTEXT = config.ismAmServerContext
5
7
 
6
8
  export function listComTreeApi(params) {
7
9
  if (config.useDddComItemTree) {
8
10
  return axios.get(
9
- `${isHb ? '/scyxgateway' : ''}${config.ucExtServerContext}/manage/tree/getBusiComTree`,
11
+ `${isHb() ? '/scyxgateway' : ''}${config.ucExtServerContext}/manage/tree/getBusiComTree`,
10
12
  { params },
11
13
  )
12
14
  }
package/src/api/item.ts CHANGED
@@ -1,12 +1,14 @@
1
1
  import { axios } from '@/utils'
2
2
  import { config } from '@/config'
3
- const isHb = location.pathname.includes('scyxweb')
3
+ function isHb() {
4
+ return __IS_HB__
5
+ }
4
6
  const CONTEXT = config.ismAmServerContext
5
7
 
6
8
  export function listItemTreeApi(params) {
7
9
  if (config.useDddComItemTree) {
8
10
  return axios.get(
9
- `${isHb ? '/scyxgateway' : ''}${
11
+ `${isHb() ? '/scyxgateway' : ''}${
10
12
  config.ucExtServerContext
11
13
  }/manage/tree/getProductInfoAsTreeData`,
12
14
  {
@@ -2,6 +2,9 @@ import { CONTENT_TYPE, axios, getToken, MIME_TYPE } from '@/utils'
2
2
  import { config } from '@/config'
3
3
  import { AxiosRequestConfig, ResponseType } from 'axios'
4
4
 
5
+ function isHb() {
6
+ return __IS_HB__
7
+ }
5
8
  const CONTEXT = config.ossServerContext
6
9
 
7
10
  /**
@@ -11,7 +14,7 @@ const CONTEXT = config.ossServerContext
11
14
  * @returns url
12
15
  */
13
16
  export function getOssFileUrl(fileId = '') {
14
- return `${CONTEXT}/oss/file/get/${fileId}`
17
+ return `${isHb() ? '/scyxgateway/ind-uc-ext-server' : CONTEXT}/oss/file/get/${fileId}`
15
18
  }
16
19
 
17
20
  /**
@@ -20,7 +23,7 @@ export function getOssFileUrl(fileId = '') {
20
23
  * @returns url
21
24
  */
22
25
  export function putOssFileUrl() {
23
- return `${CONTEXT}/oss/file/put`
26
+ return `${isHb() ? '/scyxgateway/ind-uc-ext-server' : CONTEXT}/oss/file/put`
24
27
  }
25
28
 
26
29
  /**
@@ -88,7 +91,7 @@ export async function downLoadScDcApi(fileId: string, fileName: string) {
88
91
  })
89
92
  } else {
90
93
  const downloadUrl = `${
91
- (location.pathname.includes('scyxweb') ? '/scyxgateway' : '') + '/ind-uc-ext-server'
94
+ (isHb() ? '/scyxgateway' : '') + '/ind-uc-ext-server'
92
95
  }/oss/file/get/${fileId}`
93
96
  const token = getToken() // 获取当前 Token
94
97
 
@@ -2,6 +2,7 @@
2
2
 
3
3
  // const XlsxPopulate = require('xlsx-populate/browser/xlsx-populate')
4
4
  import _ from 'lodash'
5
+ import { putOssFileApi } from '@/api/platform/oss'
5
6
 
6
7
  const titleStyle = {
7
8
  // title style
@@ -645,3 +646,159 @@ export function getExcelColumnIdx(number) {
645
646
  }
646
647
  return rlt
647
648
  }
649
+
650
+ export function previewJsonToExcel(excelData) {
651
+ return new Promise((resolve, reject) => {
652
+ var calcExportDatas = getAgColumnTitleAndData(excelData)
653
+ var fileId = ''
654
+
655
+ console.log('calcExportDatas', calcExportDatas)
656
+
657
+ var title = excelData.title
658
+
659
+ var titleDeepth = calcExportDatas.deepth
660
+ var columnAlign = excelData.columnAlign || calcExportDatas.columnAlign
661
+ var columnType = excelData.columnType || calcExportDatas.columnType
662
+
663
+ var columnTitle = calcExportDatas.columnTitle
664
+
665
+ var columnWidth = excelData.columnWidth || calcExportDatas.columnWidth
666
+
667
+ var columnCount = columnAlign.length
668
+
669
+ var paramLeft = excelData.paramLeft
670
+
671
+ var paramRight = excelData.paramRight
672
+
673
+ var jsonData = calcExportDatas.exportData
674
+
675
+ var numberFormat = excelData.numberFormat || calcExportDatas.numberFormat
676
+
677
+ XlsxPopulate.fromBlankAsync()
678
+ .then((workbook) => {
679
+ // Modify the workbook.
680
+ var sheet = workbook.sheet('Sheet1') // 初始化的时候不能传中文进去
681
+ // sheet.name(title)
682
+ // 设置列宽
683
+ for (var i = 0; i < columnCount; i++) {
684
+ sheet.column(i + 1).width(columnWidth[i] == 0 ? 10 : columnWidth[i])
685
+ }
686
+
687
+ var titleRange = sheet.range(1, 1, 1, columnCount)
688
+ titleRange.merged(true)
689
+ titleRange.style(titleStyle)
690
+ titleRange.cell(0, 0).value(title)
691
+ sheet.row(1).height(titleHeight)
692
+
693
+ var rowsNow = 2
694
+
695
+ if (!!excelData.paramLeft || !!excelData.paramRight) {
696
+ var paramLeftRange = sheet.range(2, 1, 2, Math.round(columnCount / 2))
697
+ paramLeftRange.cell(0, 0).value(paramLeft || '')
698
+ paramLeftRange.merged(true)
699
+ paramLeftRange.style(paramLeftStyle)
700
+ var paramRightRange = sheet.range(2, Math.round(columnCount / 2) + 1, 2, columnCount)
701
+ paramRightRange.cell(0, 0).value(paramRight || '')
702
+ paramRightRange.merged(true)
703
+ paramRightRange.style(paramRightStyle)
704
+ sheet.row(2).height(paramHeight)
705
+ rowsNow += 1
706
+ }
707
+
708
+ columnTitle.forEach((d) => {
709
+ var columnTitleRange = sheet.range(
710
+ d.srow + rowsNow - 1,
711
+ d.scol,
712
+ d.erow + rowsNow - 1,
713
+ d.ecol,
714
+ )
715
+ columnTitleRange.merged(true)
716
+ columnTitleRange.style(columnTitleStyle)
717
+ columnTitleRange.cell(0, 0).value(d.text?.replace(/<br\/>/g, ''))
718
+ })
719
+ for (let i = 0; i < titleDeepth; i++) {
720
+ sheet.row(rowsNow + i).height(columnTitleHeight)
721
+ }
722
+
723
+ // 处理表格里的数据,挨家挨户搜一下
724
+ rowsNow += titleDeepth
725
+
726
+ for (var i = 0; i < jsonData.length; i++) {
727
+ var lineData = jsonData[i]
728
+ for (var j = 0; j < lineData.length; j++) {
729
+ if (columnType[j] === 'p' && lineData[j]) {
730
+ // 百分比,当前数值除以100来转换成百分比
731
+ sheet.cell(rowsNow + i, j + 1).value(parseFloat(lineData[j].value / 100))
732
+ dataCellStyle.numberFormat = numberFormat[j]
733
+ } else if (columnType[j] === 'n' && lineData[j]) {
734
+ // 数字保留精度
735
+ sheet.cell(rowsNow + i, j + 1).value(parseFloat(lineData[j].value))
736
+ dataCellStyle.numberFormat = numberFormat[j]
737
+ } else if (columnType[j] === 's' && lineData[j]) {
738
+ // 字符串
739
+ sheet.cell(rowsNow + i, j + 1).value(lineData[j].value)
740
+ dataCellStyle.numberFormat = ''
741
+ } else {
742
+ if (columnType[j] === 'p' || columnType[j] === 'n') {
743
+ // 解决导出excel空串无法计算
744
+ dataCellStyle.numberFormat = numberFormat[j]
745
+ } else {
746
+ // 预留一下,将来可能加别的样式
747
+ sheet.cell(rowsNow + i, j + 1).value('')
748
+ }
749
+ }
750
+ dataCellStyle.horizontalAlignment = columnAlign[j]
751
+ sheet.cell(rowsNow + i, j + 1).style(dataCellStyle)
752
+ }
753
+ if (excelData.rowColor && i % 2 != 0) {
754
+ var row = sheet.range(rowsNow + i, 1, rowsNow + i, columnCount)
755
+ row.style({ fill: 'f8f8f9' })
756
+ }
757
+ sheet.row(rowsNow + i).height(dataRowHeight)
758
+ }
759
+
760
+ if (!!excelData.rowSpanDefs) {
761
+ initRowSpanInfosNew({ ...excelData, columns: calcExportDatas.columnsCalc })
762
+ _.forEach(rowSpanExcelInfos, function (rowSpanInfo) {
763
+ var columnTitleRange = sheet.range(
764
+ rowSpanInfo.mergeRowS + rowsNow,
765
+ rowSpanInfo.megerColS + 1,
766
+ rowSpanInfo.mergeRowE + rowsNow,
767
+ rowSpanInfo.megerColE + 1,
768
+ )
769
+ columnTitleRange.merged(true)
770
+ })
771
+ } else if (!!excelData.rowSpanColumns) {
772
+ initRowSpanInfos({ ...excelData, columns: calcExportDatas.columnsCalc })
773
+ _.forEach(rowSpanExcelInfos, function (rowSpanInfo) {
774
+ var columnTitleRange = sheet.range(
775
+ rowSpanInfo.mergeRowS + rowsNow,
776
+ rowSpanInfo.megerColS + 1,
777
+ rowSpanInfo.mergeRowE + rowsNow,
778
+ rowSpanInfo.megerColE + 1,
779
+ )
780
+ columnTitleRange.merged(true)
781
+ })
782
+ }
783
+
784
+ if (excelData.leftColumns || excelData.topRows) {
785
+ sheet.freezePanes(excelData.leftColumns || 0, (excelData.topRows || 0) + rowsNow - 1)
786
+ }
787
+
788
+ // Write to file.
789
+ workbook.outputAsync().then(async function (blob) {
790
+ const timestamp = new Date().getTime()
791
+ const filename = `${timestamp}.xlsx`
792
+ let { data } = await putOssFileApi(filename, blob)
793
+ // data = data.data // lambo-design多了一层,由于axios拦截器的原因
794
+ console.log('data is --111111', data)
795
+ fileId = data?.[0].fileId || ''
796
+ resolve(fileId)
797
+ })
798
+ })
799
+ .catch((err) => {
800
+ console.log(err)
801
+ reject(err)
802
+ })
803
+ })
804
+ }
@@ -1,4 +1,2 @@
1
- export declare function listComTreeApi(
2
- params: any,
3
- ): Promise<import('axios').AxiosResponse<any, any>>
4
- //# sourceMappingURL=com.d.ts.map
1
+ export declare function listComTreeApi(params: any): Promise<import("axios").AxiosResponse<any>>;
2
+ //# sourceMappingURL=com.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"com.d.ts","sourceRoot":"","sources":["../../src/api/com.ts"],"names":[],"mappings":"AAKA,wBAAgB,cAAc,CAAC,MAAM,KAAA,oDAQpC"}
1
+ {"version":3,"file":"com.d.ts","sourceRoot":"","sources":["../../src/api/com.ts"],"names":[],"mappings":"AAOA,wBAAgB,cAAc,CAAC,MAAM,KAAA,+CAQpC"}
@@ -1,4 +1,2 @@
1
- export declare function listIndexDescApi(
2
- params: any,
3
- ): Promise<import('axios').AxiosResponse<any, any>>
4
- //# sourceMappingURL=index-desc.d.ts.map
1
+ export declare function listIndexDescApi(params: any): Promise<import("axios").AxiosResponse<any>>;
2
+ //# sourceMappingURL=index-desc.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-desc.d.ts","sourceRoot":"","sources":["../../src/api/index-desc.ts"],"names":[],"mappings":"AAKA,wBAAgB,gBAAgB,CAAC,MAAM,KAAA,oDAEtC"}
1
+ {"version":3,"file":"index-desc.d.ts","sourceRoot":"","sources":["../../src/api/index-desc.ts"],"names":[],"mappings":"AAKA,wBAAgB,gBAAgB,CAAC,MAAM,KAAA,+CAEtC"}
@@ -1,7 +1,7 @@
1
- export * from './platform'
2
- export * from './com'
3
- export * from './index-desc'
4
- export * from './item'
5
- export * from './permission'
6
- export * from './user'
7
- //# sourceMappingURL=index.d.ts.map
1
+ export * from './platform';
2
+ export * from './com';
3
+ export * from './index-desc';
4
+ export * from './item';
5
+ export * from './permission';
6
+ export * from './user';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -1,6 +1,4 @@
1
- export declare function listItemTreeApi(
2
- params: any,
3
- ): Promise<import('axios').AxiosResponse<any, any>>
4
- export declare function getPriceInfo(): Promise<import('axios').AxiosResponse<any, any>>
5
- export declare function getItem(params: any): Promise<import('axios').AxiosResponse<any, any>>
6
- //# sourceMappingURL=item.d.ts.map
1
+ export declare function listItemTreeApi(params: any): Promise<import("axios").AxiosResponse<any>>;
2
+ export declare function getPriceInfo(): Promise<import("axios").AxiosResponse<any>>;
3
+ export declare function getItem(params: any): Promise<import("axios").AxiosResponse<any>>;
4
+ //# sourceMappingURL=item.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"item.d.ts","sourceRoot":"","sources":["../../src/api/item.ts"],"names":[],"mappings":"AAKA,wBAAgB,eAAe,CAAC,MAAM,KAAA,oDAYrC;AACD,wBAAgB,YAAY,qDAE3B;AACD,wBAAgB,OAAO,CAAC,MAAM,KAAA,oDAE7B"}
1
+ {"version":3,"file":"item.d.ts","sourceRoot":"","sources":["../../src/api/item.ts"],"names":[],"mappings":"AAOA,wBAAgB,eAAe,CAAC,MAAM,KAAA,+CAYrC;AACD,wBAAgB,YAAY,gDAE3B;AACD,wBAAgB,OAAO,CAAC,MAAM,KAAA,+CAE7B"}
@@ -1,2 +1,2 @@
1
- export declare function getApplicationTreeApi(params: any): Promise<any>
2
- //# sourceMappingURL=permission.d.ts.map
1
+ export declare function getApplicationTreeApi(params: any): Promise<any>;
2
+ //# sourceMappingURL=permission.d.ts.map
@@ -1,7 +1,7 @@
1
1
  export namespace Base64 {
2
- let Base64Chars: string
3
- function encode(s: any): any
4
- function ucs2_utf8(s: any): any[]
5
- function utf8_ucs2(s: any): string
2
+ let Base64Chars: string;
3
+ function encode(s: any): any;
4
+ function ucs2_utf8(s: any): any[];
5
+ function utf8_ucs2(s: any): string;
6
6
  }
7
- //# sourceMappingURL=base64.d.ts.map
7
+ //# sourceMappingURL=base64.d.ts.map
@@ -1,2 +1,2 @@
1
- export function getGlobalConfig(): Promise<any>
2
- //# sourceMappingURL=config.d.ts.map
1
+ export function getGlobalConfig(): Promise<any>;
2
+ //# sourceMappingURL=config.d.ts.map
@@ -1,6 +1,4 @@
1
- export declare function getDictsMapApi(
2
- dictId: string,
3
- ): Promise<import('axios').AxiosResponse<any, any>>
4
- export declare function getDictApi(dictId: string): Promise<any>
5
- export declare function getDictMapApi(dictIdArr: string[]): Promise<{}>
6
- //# sourceMappingURL=dict.d.ts.map
1
+ export declare function getDictsMapApi(dictId: string): Promise<import("axios").AxiosResponse<any>>;
2
+ export declare function getDictApi(dictId: string): Promise<any>;
3
+ export declare function getDictMapApi(dictIdArr: string[]): Promise<{}>;
4
+ //# sourceMappingURL=dict.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dict.d.ts","sourceRoot":"","sources":["../../../src/api/platform/dict.ts"],"names":[],"mappings":"AAMA,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,oDAE5C;AAED,wBAAsB,UAAU,CAAC,MAAM,EAAE,MAAM,gBAgB9C;AAkBD,wBAAsB,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,eActD"}
1
+ {"version":3,"file":"dict.d.ts","sourceRoot":"","sources":["../../../src/api/platform/dict.ts"],"names":[],"mappings":"AAMA,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,+CAE5C;AAED,wBAAsB,UAAU,CAAC,MAAM,EAAE,MAAM,gBAgB9C;AAkBD,wBAAsB,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,eActD"}
@@ -1,6 +1,6 @@
1
- export * from './dict'
2
- export * from './menu'
3
- export * from './oss'
4
- export * from './user'
5
- export * from './config.js'
6
- //# sourceMappingURL=index.d.ts.map
1
+ export * from './dict';
2
+ export * from './menu';
3
+ export * from './oss';
4
+ export * from './user';
5
+ export * from './config.js';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -1,21 +1,11 @@
1
- export declare function getPermissionApi(): Promise<import('axios').AxiosResponse<any, any>>
2
- export declare function getMenuHistoryApi(): Promise<import('axios').AxiosResponse<any, any>>
3
- export declare function menuHistoryApi(
4
- params: any,
5
- ): Promise<import('axios').AxiosResponse<any, any>>
6
- export declare function deleteMenuHistoryApi(
7
- historyId: any,
8
- ): Promise<import('axios').AxiosResponse<any, any>>
9
- export declare function getMenuCollectApi(): Promise<import('axios').AxiosResponse<any, any>>
10
- export declare function addMenuCollectApi(
11
- params: any,
12
- ): Promise<import('axios').AxiosResponse<any, any>>
13
- export declare function deleteMenuCollectApi(
14
- collectId: any,
15
- ): Promise<import('axios').AxiosResponse<any, any>>
16
- export declare function removeMenuCollectApi(
17
- params: any,
18
- ): Promise<import('axios').AxiosResponse<any, any>>
19
- export declare function getAppListApi(): Promise<import('axios').AxiosResponse<any, any>>
20
- export declare function getMaxTabNumValueApi(): Promise<import('axios').AxiosResponse<any, any>>
21
- //# sourceMappingURL=menu.d.ts.map
1
+ export declare function getPermissionApi(): Promise<import("axios").AxiosResponse<any>>;
2
+ export declare function getMenuHistoryApi(): Promise<import("axios").AxiosResponse<any>>;
3
+ export declare function menuHistoryApi(params: any): Promise<import("axios").AxiosResponse<any>>;
4
+ export declare function deleteMenuHistoryApi(historyId: any): Promise<import("axios").AxiosResponse<any>>;
5
+ export declare function getMenuCollectApi(): Promise<import("axios").AxiosResponse<any>>;
6
+ export declare function addMenuCollectApi(params: any): Promise<import("axios").AxiosResponse<any>>;
7
+ export declare function deleteMenuCollectApi(collectId: any): Promise<import("axios").AxiosResponse<any>>;
8
+ export declare function removeMenuCollectApi(params: any): Promise<import("axios").AxiosResponse<any>>;
9
+ export declare function getAppListApi(): Promise<import("axios").AxiosResponse<any>>;
10
+ export declare function getMaxTabNumValueApi(): Promise<import("axios").AxiosResponse<any>>;
11
+ //# sourceMappingURL=menu.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../../src/api/platform/menu.ts"],"names":[],"mappings":"AAKA,wBAAgB,gBAAgB,qDAE/B;AAED,wBAAgB,iBAAiB,qDAEhC;AAED,wBAAgB,cAAc,CAAC,MAAM,KAAA,oDAEpC;AAED,wBAAgB,oBAAoB,CAAC,SAAS,KAAA,oDAE7C;AAED,wBAAgB,iBAAiB,qDAEhC;AAED,wBAAgB,iBAAiB,CAAC,MAAM,KAAA,oDAEvC;AAED,wBAAgB,oBAAoB,CAAC,SAAS,KAAA,oDAE7C;AAED,wBAAgB,oBAAoB,CAAC,MAAM,KAAA,oDAE1C;AAED,wBAAgB,aAAa,qDAE5B;AAED,wBAAgB,oBAAoB,qDAEnC"}
1
+ {"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../../src/api/platform/menu.ts"],"names":[],"mappings":"AAKA,wBAAgB,gBAAgB,gDAE/B;AAED,wBAAgB,iBAAiB,gDAEhC;AAED,wBAAgB,cAAc,CAAC,MAAM,KAAA,+CAEpC;AAED,wBAAgB,oBAAoB,CAAC,SAAS,KAAA,+CAE7C;AAED,wBAAgB,iBAAiB,gDAEhC;AAED,wBAAgB,iBAAiB,CAAC,MAAM,KAAA,+CAEvC;AAED,wBAAgB,oBAAoB,CAAC,SAAS,KAAA,+CAE7C;AAED,wBAAgB,oBAAoB,CAAC,MAAM,KAAA,+CAE1C;AAED,wBAAgB,aAAa,gDAE5B;AAED,wBAAgB,oBAAoB,gDAEnC"}
@@ -1,17 +1,17 @@
1
- import { ResponseType } from 'axios'
1
+ import { ResponseType } from 'axios';
2
2
  /**
3
3
  * 文档中心下载文件的url,主要用于图片等直接写在 href 里
4
4
  *
5
5
  * @param fileId 文件Id
6
6
  * @returns url
7
7
  */
8
- export declare function getOssFileUrl(fileId?: string): string
8
+ export declare function getOssFileUrl(fileId?: string): string;
9
9
  /**
10
10
  * 文档中心上传文件的url
11
11
  *
12
12
  * @returns url
13
13
  */
14
- export declare function putOssFileUrl(): string
14
+ export declare function putOssFileUrl(): string;
15
15
  /**
16
16
  * 获取文档中心文件
17
17
  *
@@ -19,10 +19,7 @@ export declare function putOssFileUrl(): string
19
19
  * @param responseType 数据类型,支持 arraybuffer | blob | document | json | text | stream
20
20
  * @returns 文件内容
21
21
  */
22
- export declare function getOssFileApi(
23
- fileId: string,
24
- responseType?: ResponseType,
25
- ): Promise<import('axios').AxiosResponse<any, any>>
22
+ export declare function getOssFileApi(fileId: string, responseType?: ResponseType): Promise<import("axios").AxiosResponse<any>>;
26
23
  /**
27
24
  * 将文件上传到文档中心
28
25
  *
@@ -30,19 +27,14 @@ export declare function getOssFileApi(
30
27
  * @param blob 文件的Blob数据
31
28
  * @returns 文件Id
32
29
  */
33
- export declare function putOssFileApi(
34
- filename: string,
35
- blob: Blob,
36
- ): import('axios').AxiosPromise<any>
30
+ export declare function putOssFileApi(filename: string, blob: Blob): import("axios").AxiosPromise<any>;
37
31
  /**
38
32
  * 获取文档中心预览URL
39
33
  *
40
34
  * @param fileId 文件Id
41
35
  * @returns 文件内容
42
36
  */
43
- export declare function getPreviewUrlApi(
44
- fileId: string,
45
- ): Promise<import('axios').AxiosResponse<any, any>>
37
+ export declare function getPreviewUrlApi(fileId: string): Promise<import("axios").AxiosResponse<any>>;
46
38
  /**
47
39
  * 获取文档中心预览URL
48
40
  *
@@ -50,5 +42,5 @@ export declare function getPreviewUrlApi(
50
42
  * @param fileName 文件名
51
43
  * @returns 文件内容
52
44
  */
53
- export declare function downLoadScDcApi(fileId: string, fileName: string): Promise<void>
54
- //# sourceMappingURL=oss.d.ts.map
45
+ export declare function downLoadScDcApi(fileId: string, fileName: string): Promise<void>;
46
+ //# sourceMappingURL=oss.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"oss.d.ts","sourceRoot":"","sources":["../../../src/api/platform/oss.ts"],"names":[],"mappings":"AAEA,OAAO,EAAsB,YAAY,EAAE,MAAM,OAAO,CAAA;AAIxD;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,MAAM,SAAK,UAExC;AAED;;;;GAIG;AACH,wBAAgB,aAAa,WAE5B;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,YAAY,oDAMxE;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,qCAUzD;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,oDAQ9C;AAED;;;;;;GAMG;AACH,wBAAsB,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,iBA0DrE"}
1
+ {"version":3,"file":"oss.d.ts","sourceRoot":"","sources":["../../../src/api/platform/oss.ts"],"names":[],"mappings":"AAEA,OAAO,EAAsB,YAAY,EAAE,MAAM,OAAO,CAAA;AAOxD;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,MAAM,SAAK,UAExC;AAED;;;;GAIG;AACH,wBAAgB,aAAa,WAE5B;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,YAAY,+CAMxE;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,qCAUzD;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,+CAQ9C;AAED;;;;;;GAMG;AACH,wBAAsB,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,iBA0DrE"}
@@ -1,19 +1,12 @@
1
- export declare function loginApi({
2
- userName,
3
- password,
4
- validCodeId,
5
- validCodeInput,
6
- }: {
7
- userName: any
8
- password: any
9
- validCodeId: any
10
- validCodeInput: any
11
- }): Promise<import('axios').AxiosResponse<any, any>>
12
- export declare function getUserInfoApi(): Promise<import('axios').AxiosResponse<any, any>>
13
- export declare function getGlobalPolicyApi(): Promise<import('axios').AxiosResponse<any, any>>
14
- export declare function updatePasswordApi(
15
- data: any,
16
- ): Promise<import('axios').AxiosResponse<any, any>>
17
- export declare function getCaptchaURL(validCodeId: string): string
18
- export declare function logoutApi(): Promise<import('axios').AxiosResponse<any, any>>
19
- //# sourceMappingURL=user.d.ts.map
1
+ export declare function loginApi({ userName, password, validCodeId, validCodeInput }: {
2
+ userName: any;
3
+ password: any;
4
+ validCodeId: any;
5
+ validCodeInput: any;
6
+ }): Promise<import("axios").AxiosResponse<any>>;
7
+ export declare function getUserInfoApi(): Promise<import("axios").AxiosResponse<any>>;
8
+ export declare function getGlobalPolicyApi(): Promise<import("axios").AxiosResponse<any>>;
9
+ export declare function updatePasswordApi(data: any): Promise<import("axios").AxiosResponse<any>>;
10
+ export declare function getCaptchaURL(validCodeId: string): string;
11
+ export declare function logoutApi(): Promise<import("axios").AxiosResponse<any>>;
12
+ //# sourceMappingURL=user.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../src/api/platform/user.ts"],"names":[],"mappings":"AAMA,wBAAgB,QAAQ,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE;;;;;CAAA,oDAQ3E;AAED,wBAAgB,cAAc,qDAE7B;AAED,wBAAgB,kBAAkB,qDAEjC;AAED,wBAAgB,iBAAiB,CAAC,IAAI,KAAA,oDAErC;AAED,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,UAEhD;AAED,wBAAgB,SAAS,qDAExB"}
1
+ {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../src/api/platform/user.ts"],"names":[],"mappings":"AAMA,wBAAgB,QAAQ,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE;;;;;CAAA,+CAQ3E;AAED,wBAAgB,cAAc,gDAE7B;AAED,wBAAgB,kBAAkB,gDAEjC;AAED,wBAAgB,iBAAiB,CAAC,IAAI,KAAA,+CAErC;AAED,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,UAEhD;AAED,wBAAgB,SAAS,gDAExB"}
@@ -1,2 +1,2 @@
1
- export declare function listUserTreeApi(params: any): Promise<any>
2
- //# sourceMappingURL=user.d.ts.map
1
+ export declare function listUserTreeApi(params: any): Promise<any>;
2
+ //# sourceMappingURL=user.d.ts.map
@@ -1,34 +1,34 @@
1
1
  declare const _default: {
2
- title: string
3
- icomId: string
4
- showMenus: boolean
5
- routerBase: string
6
- loginRouteName: string
7
- rootRouteName: string
8
- homeRouteName: string
9
- authServerContext: string
10
- ossServerContext: string
11
- ismAmServerContext: string
12
- ismAcServerContext: string
13
- ismSqServerContext: string
14
- ilmServerContext: string
15
- imgServerContext: string
16
- imaServerContext: string
17
- ucExtServerContext: string
18
- dataManageServerContext: string
19
- kkfilepreviewContext: string
20
- errorMessage: string
21
- leftLockDays: number
22
- labelStyle: {
23
- labelWidthButton: number
24
- labelWidthSmall: number
25
- labelWidthMiddle: number
26
- labelWidthMiddleLarge: number
27
- labelWidthLarge: number
28
- labelWidthSuperLarge: number
29
- }
30
- /** 点击跳转的文字颜色 */
31
- linkColor: string
32
- }
33
- export default _default
34
- //# sourceMappingURL=base.config.d.ts.map
2
+ title: string;
3
+ icomId: string;
4
+ showMenus: boolean;
5
+ routerBase: string;
6
+ loginRouteName: string;
7
+ rootRouteName: string;
8
+ homeRouteName: string;
9
+ authServerContext: string;
10
+ ossServerContext: string;
11
+ ismAmServerContext: string;
12
+ ismAcServerContext: string;
13
+ ismSqServerContext: string;
14
+ ilmServerContext: string;
15
+ imgServerContext: string;
16
+ imaServerContext: string;
17
+ ucExtServerContext: string;
18
+ dataManageServerContext: string;
19
+ kkfilepreviewContext: string;
20
+ errorMessage: string;
21
+ leftLockDays: number;
22
+ labelStyle: {
23
+ labelWidthButton: number;
24
+ labelWidthSmall: number;
25
+ labelWidthMiddle: number;
26
+ labelWidthMiddleLarge: number;
27
+ labelWidthLarge: number;
28
+ labelWidthSuperLarge: number;
29
+ };
30
+ /** 点击跳转的文字颜色 */
31
+ linkColor: string;
32
+ };
33
+ export default _default;
34
+ //# sourceMappingURL=base.config.d.ts.map
@@ -1,4 +1,4 @@
1
1
  export declare function getDevConfig(): {
2
- showMenus: boolean
3
- }
4
- //# sourceMappingURL=dev.config.d.ts.map
2
+ showMenus: boolean;
3
+ };
4
+ //# sourceMappingURL=dev.config.d.ts.map
@@ -1,6 +1,6 @@
1
- declare let config: any
2
- declare function useConfig(isDev?: boolean): any
3
- declare function setConfig(key: any, value: any): void
4
- export default config
5
- export { config, useConfig, setConfig }
6
- //# sourceMappingURL=index.d.ts.map
1
+ declare let config: any;
2
+ declare function useConfig(isDev?: boolean): any;
3
+ declare function setConfig(key: any, value: any): void;
4
+ export default config;
5
+ export { config, useConfig, setConfig };
6
+ //# sourceMappingURL=index.d.ts.map
@@ -1,4 +1,4 @@
1
1
  export declare function getProdConfig(): {
2
- showMenus: boolean
3
- }
4
- //# sourceMappingURL=prod.config.d.ts.map
2
+ showMenus: boolean;
3
+ };
4
+ //# sourceMappingURL=prod.config.d.ts.map
package/types/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export * from './api'
2
- export * from './config'
3
- export * from './utils'
4
- //# sourceMappingURL=index.d.ts.map
1
+ export * from './api';
2
+ export * from './config';
3
+ export * from './utils';
4
+ //# sourceMappingURL=index.d.ts.map