jinhui.wang

配置修改

...@@ -24,9 +24,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re ...@@ -24,9 +24,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
24 #图文版使用指南 24 #图文版使用指南
25 VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/operating-guide.pdf' 25 VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/operating-guide.pdf'
26 #隐私政策 26 #隐私政策
27 -VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html' 27 +VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
28 #使用条款 28 #使用条款
29 -VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html' 29 +VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
30 #营业执照 30 #营业执照
31 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg' 31 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg'
32 #快递业务经营许可证 32 #快递业务经营许可证
......
...@@ -16,9 +16,9 @@ VUE_APP_BASE_LOGINOUT = '/' ...@@ -16,9 +16,9 @@ VUE_APP_BASE_LOGINOUT = '/'
16 #图文版使用指南 16 #图文版使用指南
17 VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclaration-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf' 17 VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclaration-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf'
18 #隐私政策 18 #隐私政策
19 -VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html' 19 +VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
20 #使用条款 20 #使用条款
21 -VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html' 21 +VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
22 #营业执照 22 #营业执照
23 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg' 23 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg'
24 #快递业务经营许可证 24 #快递业务经营许可证
......
...@@ -20,9 +20,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re ...@@ -20,9 +20,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
20 #图文版使用指南 20 #图文版使用指南
21 VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/圖文版使用指南.pdf' 21 VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/圖文版使用指南.pdf'
22 #隐私政策 22 #隐私政策
23 -VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html' 23 +VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
24 #使用条款 24 #使用条款
25 -VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html' 25 +VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
26 #营业执照 26 #营业执照
27 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg' 27 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg'
28 #快递业务经营许可证 28 #快递业务经营许可证
......
...@@ -21,9 +21,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re ...@@ -21,9 +21,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
21 #图文版使用指南 21 #图文版使用指南
22 VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclarationuat-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf' 22 VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclarationuat-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf'
23 #隐私政策 23 #隐私政策
24 -VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html' 24 +VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
25 #使用条款 25 #使用条款
26 -VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html' 26 +VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
27 #营业执照 27 #营业执照
28 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg' 28 VUE_APP_BUSINESS_LICENSE = 'https://www.fedex.com/content/dam/fedex/apac-asia-pacific/MVP-APAC/images/2019/Q3/CN_EN_2019_1_Master_image_NA_business_license_marketing_913515423.jpg'
29 #快递业务经营许可证 29 #快递业务经营许可证
......
...@@ -30,10 +30,10 @@ export default { ...@@ -30,10 +30,10 @@ export default {
30 userTitle: "Enter your user ID and password to log in", 30 userTitle: "Enter your user ID and password to log in",
31 create: "註冊線上申報平臺帳號", 31 create: "註冊線上申報平臺帳號",
32 userNum: "User ID", 32 userNum: "User ID",
33 - passWord: "password", 33 + passWord: "Password",
34 checkPassWord: "Remember my user ID.", 34 checkPassWord: "Remember my user ID.",
35 - loginBtn: "Log in", 35 + loginBtn: "LOG IN",
36 - loggingBtn: "Logging in", 36 + loggingBtn: "LOGGING IN",
37 forgetPassWord: "忘記了您的用戶密碼?", 37 forgetPassWord: "忘記了您的用戶密碼?",
38 resetPassWord: "重置您的密碼", 38 resetPassWord: "重置您的密碼",
39 resetPassWordBtn: "提交重置", 39 resetPassWordBtn: "提交重置",
...@@ -80,11 +80,11 @@ export default { ...@@ -80,11 +80,11 @@ export default {
80 }, 80 },
81 // 全局入口页 81 // 全局入口页
82 layout: { 82 layout: {
83 - register: "Login", 83 + register: "Register/Login",
84 - fedexLogin: "Fedex.com user account login", 84 + fedexLogin: "fedex.com user account login",
85 fedexRegister: "Employee log in", 85 fedexRegister: "Employee log in",
86 onlineDeclare: "線上申報平臺帳號登錄", 86 onlineDeclare: "線上申報平臺帳號登錄",
87 - registerNumber: "Register a Fedex.com account", 87 + registerNumber: "register a fedex.com account",
88 userInfo: "用戶信息維護", 88 userInfo: "用戶信息維護",
89 logOut: "log out", 89 logOut: "log out",
90 logOutDia: "Are you sure to log out and exit the system?", 90 logOutDia: "Are you sure to log out and exit the system?",
......
...@@ -43,7 +43,7 @@ import tableHeaders from "@/assets/languages/tableHeaders"; ...@@ -43,7 +43,7 @@ import tableHeaders from "@/assets/languages/tableHeaders";
43 import dictLabels from "@/assets/languages/dictLabels.js"; 43 import dictLabels from "@/assets/languages/dictLabels.js";
44 import settings from "./settings.js"; 44 import settings from "./settings.js";
45 import * as filters from "./utils/filters.js"; 45 import * as filters from "./utils/filters.js";
46 -import { toHead } from "@/utils/index"; 46 +import { toHead, numberRound, base64ConvertFile, b64ToBlob, titleCase } from "@/utils/index";
47 47
48 // 全局方法挂载 48 // 全局方法挂载
49 Vue.prototype.parseTime = parseTime; 49 Vue.prototype.parseTime = parseTime;
...@@ -62,6 +62,10 @@ Vue.prototype.dictLabels = dictLabels; ...@@ -62,6 +62,10 @@ Vue.prototype.dictLabels = dictLabels;
62 Vue.prototype.settings = settings; 62 Vue.prototype.settings = settings;
63 Vue.prototype.regExp = regExp; 63 Vue.prototype.regExp = regExp;
64 Vue.prototype.toHead = toHead; 64 Vue.prototype.toHead = toHead;
65 +Vue.prototype.numberRound = numberRound
66 +Vue.prototype.base64ConvertFile = base64ConvertFile
67 +Vue.prototype.b64ToBlob = b64ToBlob
68 +Vue.prototype.titleCase = titleCase
65 Vue.prototype.msgSuccess = function (msg) { 69 Vue.prototype.msgSuccess = function (msg) {
66 this.$message({ showClose: true, message: msg, type: "success" }); 70 this.$message({ showClose: true, message: msg, type: "success" });
67 }; 71 };
......
...@@ -558,3 +558,62 @@ export function filterRepeatNewData(arr, key, time) { ...@@ -558,3 +558,62 @@ export function filterRepeatNewData(arr, key, time) {
558 ); 558 );
559 return result; 559 return result;
560 } 560 }
561 +
562 +export function numberRound(num, i) {
563 + // if (num.toString().indexOf('.') < 0) return Number(num)
564 + // else {
565 + // let arr = num.toString().split('.')
566 + // let decimal = Number(`0.${arr[1]}`).toPrecision(i)
567 + // if (decimal.toString().split('.')[0] != '0') {
568 + // num = Number(`${Number(arr[0]) + Number(decimal.toString().split('.')[0])}.${decimal.toString().split('.')[1]}`)
569 + // } else {
570 + // num = Number(`${arr[0]}.${decimal.toString().split('.')[1]}`)
571 + // }
572 + // return num
573 + // }
574 +
575 + if (num >= 0) {
576 +
577 + var tempNumber = parseInt((num * Math.pow(10, i) + 0.5)) / Math.pow(10, i);
578 + return tempNumber;
579 +
580 + } else {
581 +
582 + let numberRound1 = -num;
583 +
584 + var tempNumber = parseInt((numberRound1 * Math.pow(10, i) + 0.5)) / Math.pow(10, i);
585 +
586 + return -tempNumber;
587 +
588 + }
589 +
590 +}
591 +
592 +//base64转file类型
593 +export function base64ConvertFile(urlData, filename) {
594 + let arr = urlData.split(",");
595 + let type = arr[0].match(/:(.*?);/)[1];
596 + let fileExt = type.split("/")[1];
597 + let bstr = atob(arr[1]);
598 + let n = bstr.length;
599 + let u8arr = new Uint8Array(n);
600 + while (n--) {
601 + u8arr[n] = bstr.charCodeAt(n);
602 + }
603 + return new File([u8arr], filename, {
604 + type: type,
605 + });
606 +}
607 +
608 +// 将Base64字符串转换为Blob对象
609 +export function b64ToBlob(b64data) {
610 + let parts = b64data.split(';base64,');
611 + let contentType = parts[0].split(':')[1];
612 + let raw = window.atob(parts[1]);
613 + let rawLength = raw.length;
614 + let uInt8Array = new Uint8Array(rawLength);
615 + for (let i = 0; i < rawLength; ++i) {
616 + uInt8Array[i] = raw.charCodeAt(i);
617 + }
618 + return new Blob([uInt8Array], { type: contentType });
619 +}
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -59,7 +59,7 @@ service.interceptors.response.use( ...@@ -59,7 +59,7 @@ service.interceptors.response.use(
59 // 获取错误信息 59 // 获取错误信息
60 const msg = errorCode[code] || res.data.msg || errorCode["default"]; 60 const msg = errorCode[code] || res.data.msg || errorCode["default"];
61 if (code === 301) { 61 if (code === 301) {
62 - MessageBox.confirm( 62 + MessageBox.alert(
63 "The login status has expired. You can continue to stay on this page or log in again.", 63 "The login status has expired. You can continue to stay on this page or log in again.",
64 "System prompt", 64 "System prompt",
65 { 65 {
......