jinhui.wang

配置修改

......@@ -24,9 +24,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
#图文版使用指南
VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/operating-guide.pdf'
#隐私政策
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html'
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
#使用条款
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html'
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
#营业执照
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'
#快递业务经营许可证
......
......@@ -16,9 +16,9 @@ VUE_APP_BASE_LOGINOUT = '/'
#图文版使用指南
VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclaration-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf'
#隐私政策
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html'
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
#使用条款
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html'
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
#营业执照
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'
#快递业务经营许可证
......
......@@ -20,9 +20,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
#图文版使用指南
VUE_APP_FEDEX_HANDBOOK = 'http://47.103.140.98/IcTw/圖文版使用指南.pdf'
#隐私政策
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html'
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
#使用条款
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html'
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
#营业执照
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'
#快递业务经营许可证
......
......@@ -21,9 +21,9 @@ VUE_APP_REDIRECT_FCL = 'https://www.fedex.com/secure-login/#login-credentials?re
#图文版使用指南
VUE_APP_FEDEX_HANDBOOK = 'https://exportdeclarationuat-tw.apac.fedex.com/IcTw/圖文版使用指南.pdf'
#隐私政策
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/zh-tw/privacy-policy.html'
VUE_APP_PRIVACT_POLICY = 'https://www.fedex.com/en-cn/privacy-policy.html'
#使用条款
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/zh-tw/terms-of-use.html'
VUE_APP_TERMS_OF_USE = 'https://www.fedex.com/en-cn/terms-of-use.html'
#营业执照
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'
#快递业务经营许可证
......
......@@ -30,10 +30,10 @@ export default {
userTitle: "Enter your user ID and password to log in",
create: "註冊線上申報平臺帳號",
userNum: "User ID",
passWord: "password",
passWord: "Password",
checkPassWord: "Remember my user ID.",
loginBtn: "Log in",
loggingBtn: "Logging in",
loginBtn: "LOG IN",
loggingBtn: "LOGGING IN",
forgetPassWord: "忘記了您的用戶密碼?",
resetPassWord: "重置您的密碼",
resetPassWordBtn: "提交重置",
......@@ -80,11 +80,11 @@ export default {
},
// 全局入口页
layout: {
register: "Login",
fedexLogin: "Fedex.com user account login",
register: "Register/Login",
fedexLogin: "fedex.com user account login",
fedexRegister: "Employee log in",
onlineDeclare: "線上申報平臺帳號登錄",
registerNumber: "Register a Fedex.com account",
registerNumber: "register a fedex.com account",
userInfo: "用戶信息維護",
logOut: "log out",
logOutDia: "Are you sure to log out and exit the system?",
......
......@@ -43,7 +43,7 @@ import tableHeaders from "@/assets/languages/tableHeaders";
import dictLabels from "@/assets/languages/dictLabels.js";
import settings from "./settings.js";
import * as filters from "./utils/filters.js";
import { toHead } from "@/utils/index";
import { toHead, numberRound, base64ConvertFile, b64ToBlob, titleCase } from "@/utils/index";
// 全局方法挂载
Vue.prototype.parseTime = parseTime;
......@@ -62,6 +62,10 @@ Vue.prototype.dictLabels = dictLabels;
Vue.prototype.settings = settings;
Vue.prototype.regExp = regExp;
Vue.prototype.toHead = toHead;
Vue.prototype.numberRound = numberRound
Vue.prototype.base64ConvertFile = base64ConvertFile
Vue.prototype.b64ToBlob = b64ToBlob
Vue.prototype.titleCase = titleCase
Vue.prototype.msgSuccess = function (msg) {
this.$message({ showClose: true, message: msg, type: "success" });
};
......
......@@ -558,3 +558,62 @@ export function filterRepeatNewData(arr, key, time) {
);
return result;
}
export function numberRound(num, i) {
// if (num.toString().indexOf('.') < 0) return Number(num)
// else {
// let arr = num.toString().split('.')
// let decimal = Number(`0.${arr[1]}`).toPrecision(i)
// if (decimal.toString().split('.')[0] != '0') {
// num = Number(`${Number(arr[0]) + Number(decimal.toString().split('.')[0])}.${decimal.toString().split('.')[1]}`)
// } else {
// num = Number(`${arr[0]}.${decimal.toString().split('.')[1]}`)
// }
// return num
// }
if (num >= 0) {
var tempNumber = parseInt((num * Math.pow(10, i) + 0.5)) / Math.pow(10, i);
return tempNumber;
} else {
let numberRound1 = -num;
var tempNumber = parseInt((numberRound1 * Math.pow(10, i) + 0.5)) / Math.pow(10, i);
return -tempNumber;
}
}
//base64转file类型
export function base64ConvertFile(urlData, filename) {
let arr = urlData.split(",");
let type = arr[0].match(/:(.*?);/)[1];
let fileExt = type.split("/")[1];
let bstr = atob(arr[1]);
let n = bstr.length;
let u8arr = new Uint8Array(n);
while (n--) {
u8arr[n] = bstr.charCodeAt(n);
}
return new File([u8arr], filename, {
type: type,
});
}
// 将Base64字符串转换为Blob对象
export function b64ToBlob(b64data) {
let parts = b64data.split(';base64,');
let contentType = parts[0].split(':')[1];
let raw = window.atob(parts[1]);
let rawLength = raw.length;
let uInt8Array = new Uint8Array(rawLength);
for (let i = 0; i < rawLength; ++i) {
uInt8Array[i] = raw.charCodeAt(i);
}
return new Blob([uInt8Array], { type: contentType });
}
\ No newline at end of file
......
......@@ -59,7 +59,7 @@ service.interceptors.response.use(
// 获取错误信息
const msg = errorCode[code] || res.data.msg || errorCode["default"];
if (code === 301) {
MessageBox.confirm(
MessageBox.alert(
"The login status has expired. You can continue to stay on this page or log in again.",
"System prompt",
{
......