zmdms-utils 0.0.18 → 0.0.19

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.
@@ -3,7 +3,7 @@ function getBaseUrl(processObj) {
3
3
  var ENV = processObj.REACT_APP_ENV; // 获取当前环境变量
4
4
  // api各个环境地址
5
5
  var apiBaseUrlObj = {
6
- dev: processObj.REACT_APP_API_DEV || "http://192.168.0.83:8000",
6
+ dev: processObj.REACT_APP_API_DEV || "http://192.168.0.134:8000",
7
7
  test: processObj.REACT_APP_API_TEST || window.location.origin,
8
8
  stage: processObj.REACT_APP_API_STAGE || window.location.origin,
9
9
  product: processObj.REACT_APP_API_PRODUCT || window.location.origin,
package/dist/es/common.js CHANGED
@@ -179,7 +179,7 @@ function getFileExtension(fileName) {
179
179
  }
180
180
  var lastPointIndex = fileName.lastIndexOf("."); // 从最后取点
181
181
  var filePreName = fileName.substring(0, lastPointIndex); // 前面的名字
182
- var fileExtension = fileName.substring(lastPointIndex + 1); // 后面的文件后缀
182
+ var fileExtension = fileName.substring(lastPointIndex + 1).toLowerCase(); // 后面的文件后缀
183
183
  return [filePreName, fileExtension];
184
184
  }
185
185
  /**
@@ -0,0 +1,18 @@
1
+ /**
2
+ * 子应用 通知 父应用
3
+ */
4
+ declare const EMITTER_CCP_KEY = "emitter-ccp-key";
5
+ /**
6
+ * 父应用 通知 子应用订阅
7
+ */
8
+ declare const EMITTER_PCC_KEY = "emitter-pcc-key";
9
+ declare const EMITTER_TYPE: {
10
+ delTab: string;
11
+ addTab: string;
12
+ delTabs: string;
13
+ routes: string;
14
+ treeSearchWhitePath: string;
15
+ treeSearchSet: string;
16
+ };
17
+
18
+ export { EMITTER_CCP_KEY, EMITTER_PCC_KEY, EMITTER_TYPE };
@@ -0,0 +1,23 @@
1
+ // 薪酬中心-app name
2
+ var SALARY_CENTER_APPNAME = "cicohr-salary";
3
+ // 人事中心-app name
4
+ var PERSONNEL_CENTER_APPNAME = "cicohr-personnel";
5
+ // 发布订阅的常量 parent call children
6
+ /**
7
+ * 子应用 通知 父应用
8
+ */
9
+ var EMITTER_CCP_KEY = "emitter-ccp-key";
10
+ /**
11
+ * 父应用 通知 子应用订阅
12
+ */
13
+ var EMITTER_PCC_KEY = "emitter-pcc-key";
14
+ var EMITTER_TYPE = {
15
+ delTab: "delTab",
16
+ addTab: "addTab",
17
+ delTabs: "delTabs",
18
+ routes: "routes",
19
+ treeSearchWhitePath: "treeSearchWhitePath",
20
+ treeSearchSet: "treeSearchSet", // 父应用传递搜索树的值
21
+ };
22
+
23
+ export { EMITTER_CCP_KEY, EMITTER_PCC_KEY, EMITTER_TYPE, PERSONNEL_CENTER_APPNAME, SALARY_CENTER_APPNAME };
package/dist/index.d.ts CHANGED
@@ -10,3 +10,4 @@ export { divide, exactRound, formatUnit, minus, plus, times } from './es/math.js
10
10
  export { validatePassword } from './es/passwordValidate.js';
11
11
  export { emailValidate, idCardValidate, morePhoneValidate, phoneValidate, strLenValidate } from './es/validate.js';
12
12
  export { batchDownloadFiles, createDeleteFileLink, createDownloadLink, createOriginalLink, createThumbnailLink, createUploadFileLink, downloadFile, exportBolb, previewFile } from './es/file.js';
13
+ export { EMITTER_CCP_KEY, EMITTER_PCC_KEY, EMITTER_TYPE } from './es/constants.js';
package/dist/index.js CHANGED
@@ -10,3 +10,4 @@ export { divide, exactRound, formatUnit, minus, plus, times } from './es/math.js
10
10
  export { validatePassword } from './es/passwordValidate.js';
11
11
  export { emailValidate, idCardValidate, morePhoneValidate, phoneValidate, strLenValidate } from './es/validate.js';
12
12
  export { batchDownloadFiles, createDeleteFileLink, createDownloadLink, createOriginalLink, createThumbnailLink, createUploadFileLink, downloadFile, exportBolb, previewFile } from './es/file.js';
13
+ export { EMITTER_CCP_KEY, EMITTER_PCC_KEY, EMITTER_TYPE } from './es/constants.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zmdms-utils",
3
- "version": "0.0.18",
3
+ "version": "0.0.19",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
package/src/baseUrl.ts CHANGED
@@ -4,7 +4,7 @@ export function getBaseUrl(processObj: any) {
4
4
 
5
5
  // api各个环境地址
6
6
  const apiBaseUrlObj: any = {
7
- dev: processObj.REACT_APP_API_DEV || "http://192.168.0.83:8000",
7
+ dev: processObj.REACT_APP_API_DEV || "http://192.168.0.134:8000",
8
8
  test: processObj.REACT_APP_API_TEST || window.location.origin,
9
9
  stage: processObj.REACT_APP_API_STAGE || window.location.origin,
10
10
  product: processObj.REACT_APP_API_PRODUCT || window.location.origin,
package/src/common.ts CHANGED
@@ -186,7 +186,7 @@ export function getFileExtension(fileName: string): [string, string] {
186
186
  }
187
187
  const lastPointIndex = fileName.lastIndexOf("."); // 从最后取点
188
188
  const filePreName = fileName.substring(0, lastPointIndex); // 前面的名字
189
- const fileExtension = fileName.substring(lastPointIndex + 1); // 后面的文件后缀
189
+ const fileExtension = fileName.substring(lastPointIndex + 1).toLowerCase(); // 后面的文件后缀
190
190
  return [filePreName, fileExtension];
191
191
  }
192
192
 
@@ -0,0 +1,25 @@
1
+ // 薪酬中心-app name
2
+ export const SALARY_CENTER_APPNAME = "cicohr-salary";
3
+
4
+ // 人事中心-app name
5
+ export const PERSONNEL_CENTER_APPNAME = "cicohr-personnel";
6
+
7
+ // 发布订阅的常量 parent call children
8
+ /**
9
+ * 子应用 通知 父应用
10
+ */
11
+ export const EMITTER_CCP_KEY = "emitter-ccp-key";
12
+
13
+ /**
14
+ * 父应用 通知 子应用订阅
15
+ */
16
+ export const EMITTER_PCC_KEY = "emitter-pcc-key";
17
+
18
+ export const EMITTER_TYPE = {
19
+ delTab: "delTab", // 删除单个页签
20
+ addTab: "addTab", // 增加单个页签
21
+ delTabs: "delTabs", // 删除多个页签
22
+ routes: "routes", // 传递路由信息
23
+ treeSearchWhitePath: "treeSearchWhitePath", // 子应用传递搜索树的路由白名单
24
+ treeSearchSet: "treeSearchSet", // 父应用传递搜索树的值
25
+ };
package/src/index.ts CHANGED
@@ -39,3 +39,8 @@ export {
39
39
  createUploadFileLink,
40
40
  createDeleteFileLink,
41
41
  } from "./file";
42
+
43
+ /**
44
+ * 常量相关
45
+ */
46
+ export { EMITTER_CCP_KEY, EMITTER_PCC_KEY, EMITTER_TYPE } from "./constants";