From 66a13e6edec73319f8467965a915ebed8e488344 Mon Sep 17 00:00:00 2001 From: ival <610568032@qq.com> Date: Fri, 9 Aug 2019 09:33:35 +0800 Subject: [PATCH 001/172] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=BF=90=E8=A1=8C?= =?UTF-8?q?=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmap/theme/beijing_01/planConvert.js | 9 ++++++--- src/jmap/theme/fuzhou_01/planConvert.js | 9 ++++++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/jmap/theme/beijing_01/planConvert.js b/src/jmap/theme/beijing_01/planConvert.js index ef5489b20..669b123bc 100644 --- a/src/jmap/theme/beijing_01/planConvert.js +++ b/src/jmap/theme/beijing_01/planConvert.js @@ -97,6 +97,7 @@ export default { /** 按服务遍历数据*/ data.serviceNumberDataList.forEach((service) => { /** 按车次遍历数据*/ + var isBackup = true; var opt = { name: '', markPointData: [], data: [] }; if (service.tripNumberDataList && service.tripNumberDataList.length) { service.tripNumberDataList.forEach((train, j) => { @@ -131,7 +132,7 @@ export default { }); /** 计算折返点车次坐标点集合*/ - if (!service.backup && train.reentry && service.tripNumberDataList[j + 1] && service.tripNumberDataList[j + 1].stationTimeList) { + if (!train.backup && train.reentry && service.tripNumberDataList[j + 1] && service.tripNumberDataList[j + 1].stationTimeList) { lastPoint = train.stationTimeList[idx - 1]; nextPoint = service.tripNumberDataList[j + 1].stationTimeList[1]; num = this.computedReentryNumber(train.tripNumber); @@ -140,7 +141,7 @@ export default { } /** 如果是备用车,按车次添加线*/ - if (service.backup) { + if (train.backup) { /** 创建一条完成的服务数据*/ opt.name += j; var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); @@ -149,10 +150,12 @@ export default { opt = { name: '', markPointData: [], data: [] }; } } + + isBackup = train.backup; }); // 不是备用车,按服务添加线 - if (!service.backup) { + if (!isBackup) { /** 创建一条完成的服务数据*/ var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); if (model) { diff --git a/src/jmap/theme/fuzhou_01/planConvert.js b/src/jmap/theme/fuzhou_01/planConvert.js index 5b80c8115..c3baf6d93 100644 --- a/src/jmap/theme/fuzhou_01/planConvert.js +++ b/src/jmap/theme/fuzhou_01/planConvert.js @@ -124,6 +124,7 @@ export default { /** 按服务遍历数据*/ data.serviceNumberDataList.forEach((service) => { /** 按车次遍历数据*/ + var isBackup = true; var opt = { name: '', markPointData: [], data: [] }; if (service.tripNumberDataList && service.tripNumberDataList.length) { service.tripNumberDataList.forEach((train, j) => { @@ -149,7 +150,7 @@ export default { }); /** 计算折返点车次坐标点集合*/ - if (!service.backup && train.reentry && service.tripNumberDataList[j + 1] && service.tripNumberDataList[j + 1].stationTimeList) { + if (!train.backup && train.reentry && service.tripNumberDataList[j + 1] && service.tripNumberDataList[j + 1].stationTimeList) { lastPoint = train.stationTimeList[idx]; nextPoint = service.tripNumberDataList[j + 1].stationTimeList[0]; opt.data.push([lastPoint.secondTime, this.getCoordYByElem(stations, kmRangeCoordMap, lastPoint, train.directionCode, true), lastPoint.stationCode]); @@ -157,7 +158,7 @@ export default { } /** 如果是备用车,按车次添加线*/ - if (service.backup) { + if (train.backup) { /** 创建一条完成的服务数据*/ opt.name += j; var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); @@ -166,10 +167,12 @@ export default { opt = { name: '', markPointData: [], data: [] }; } } + + isBackup = train.backup; }); // 不是备用车,按服务添加线 - if (!service.backup) { + if (!isBackup) { /** 创建一条完成的服务数据*/ var model = createSeriesModel(opt, Object.assign({ color: hexColor.toCreate() }, lineStyle)); if (model) { From 13d7e5df8b9e34ed7910987c74a6bda3183d366b Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Mon, 12 Aug 2019 18:54:32 +0800 Subject: [PATCH 002/172] =?UTF-8?q?=E8=B0=83=E6=95=B4=EF=BC=9A=E5=9B=BD?= =?UTF-8?q?=E9=99=85=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/i18n/langs/en/error.js | 7 +- src/i18n/langs/en/global.js | 7 +- src/i18n/langs/en/index.js | 4 +- src/i18n/langs/en/orderAuthor.js | 93 +++++++++++++++ src/i18n/langs/en/tip.js | 12 +- src/i18n/langs/zh/error.js | 7 +- src/i18n/langs/zh/global.js | 8 +- src/i18n/langs/zh/index.js | 4 +- src/i18n/langs/zh/orderAuthor.js | 95 +++++++++++++++ src/i18n/langs/zh/tip.js | 12 +- src/views/orderauthor/author/index.vue | 56 ++++----- src/views/orderauthor/commodity/index.vue | 62 +++++----- src/views/orderauthor/order/addGoods.vue | 32 ++--- src/views/orderauthor/order/canDistribute.vue | 12 +- src/views/orderauthor/order/draft.vue | 110 +++++++++--------- src/views/orderauthor/order/list.vue | 58 ++++----- src/views/orderauthor/permission/index.vue | 72 ++++++------ 17 files changed, 442 insertions(+), 209 deletions(-) create mode 100644 src/i18n/langs/en/orderAuthor.js create mode 100644 src/i18n/langs/zh/orderAuthor.js diff --git a/src/i18n/langs/en/error.js b/src/i18n/langs/en/error.js index b2b723a92..b08772104 100644 --- a/src/i18n/langs/en/error.js +++ b/src/i18n/langs/en/error.js @@ -6,5 +6,10 @@ export default { resetFailed: 'Reset failure', startTrainingFailed: 'Failure to start training', saveBackgroundFailed: 'Failed to save background', - deleteFailed: 'Failed to delete' + deleteFailed: 'Failed to delete', + requestFailed: 'Failed to request', + transferredQRCodeFailed: 'Failed to acquiring transferred qrcode', + loadingDataFailed: 'Failed to loading data', + addingFailure: 'Failure to add', + cancelled: 'Cancelled' }; diff --git a/src/i18n/langs/en/global.js b/src/i18n/langs/en/global.js index d8b9e9f2a..89bd3a41e 100644 --- a/src/i18n/langs/en/global.js +++ b/src/i18n/langs/en/global.js @@ -10,5 +10,10 @@ export default { operate: 'Operate', edit: 'Edit', delete: 'Delete', - add: 'Add' + add: 'Add', + close: 'Close', + create: 'Create', + update: 'Update', + return: 'Return', + toBeDeveloped: 'Functions to be developed' }; diff --git a/src/i18n/langs/en/index.js b/src/i18n/langs/en/index.js index 66cd504d8..604621405 100644 --- a/src/i18n/langs/en/index.js +++ b/src/i18n/langs/en/index.js @@ -8,6 +8,7 @@ import rules from './rules'; import scriptRecord from './scriptRecord'; import tip from './tip'; import system from './system'; +import orderAuthor from './orderAuthor'; export default { ...enLocale, @@ -19,5 +20,6 @@ export default { rules, scriptRecord, tip, - system + system, + orderAuthor }; diff --git a/src/i18n/langs/en/orderAuthor.js b/src/i18n/langs/en/orderAuthor.js new file mode 100644 index 000000000..7efb71076 --- /dev/null +++ b/src/i18n/langs/en/orderAuthor.js @@ -0,0 +1,93 @@ +export default { + name: 'Name', + productType: 'ProductType', + map: 'Map', + state: 'State', + commodityName: 'CommodityName', + mapName: 'MapName', + courseName: 'CourseName', + price: 'Price', + describtion: 'Describtion', + creationTime: 'CreationTime', + setupFailure: 'SetupFailure', + setupEffective: 'SetupEffective', + organizationOrEnterprise: 'Organization/Enterprise', + userName: 'UserName', + permissionType: 'PermissionType', + permissionNumber: 'PermissionNumber', + permanenceOrNot: 'PermanenceOrNot', + startDate: 'StartDate', + purchaseMonths: 'PurchaseMonths', + totalPrice: 'TotalPrice', + paymentMethod: 'PaymentMethod', + creationDate: 'CreationDate', + orderType: 'OrderType', + contractNumber: 'ContractNumber', + businessType: 'BusinessType', + paymentStatus: 'PaymentStatus', + salesman: 'Salesman', + obtainQrCode: 'ObtainQrCode', + userMobile: 'UserMobile', + mapProductName: 'MapProductName', + publicOrPrivate: 'Public/Private', + totalPermissions: 'TotalPermissions', + residualPermissionNumber: 'ResidualPermissionNumber', + authorityStatus: 'AuthorityStatus', + startTime: 'StartTime', + endTime: 'EndTime', + courseAuthorityStatus: 'CourseAuthorityStatus', + source: 'Source', + founderPhone: 'FounderPhone', + founder: 'Founder', + privilegePackaging: 'PrivilegePackaging', + unpacking: 'Unpacking', + authorityDetails: 'AuthorityDetails', + renew: 'Renew', + productName: 'ProductName', + updateProductTip: 'Will this operation modify the commodity status?', + deleteProductTip: 'This operation will delete the item. Do you want to continue?', + recovery: 'Recovery', + permissionPack: 'PermissionPack', + privilegeTransferQRCode: 'PrivilegeTransferQRCode', + getQRCodeFailure: '获取打包权限二维码失败', + recoveryPrivilegeTip: '此操作将回收权限, 是否继续?', + unpackingTip: '此操作将解包, 是否继续?', + generatingQRCode: '生成二维码', + transferQRCode: '转赠二维码', + today: 'Today', + yesterday: 'Yesterday', + aWeekAgo: 'AWeekAgo', + updateOrder: 'UpdateOrder', + renewOrder: 'RenewOrder', + unknownRouter: 'UnknownRouter', + increasePurchaseTime: 'IncreasePurchaseTime', + choosePurchaseTime: 'ChoosePurchaseTime', + increasePermissionNumber: 'IncreasePermissionNumber', + choosePermissionNumber: 'ChoosePermissionNumber', + itemPricing: 'itemPricing', + organizationInput: '请输入组织或者企业名称', + productSelect: '请选择商品', + itemPricingInput: '请输入商品单价', + orderTypeSelect: '请选择订单类型', + contractNumberInput: '请输入合同编号', + contractNumberLimit: '长度在 1 到 25 个字符', + salesmanInput: '请选择销售人员', + foreverRadio: '请选择', + amountInput: '请输入购买的权限个数', + amountInputError: '请输入有效权限个数', + totalPriceInput: '请输入总价格', + totalPriceInputError1: '请输入的价格在两位小数', + totalPriceInputError2: '请输入有效总价格', + monthAmountInput: '请输入购买月数', + monthAmountInputError: '请输入有效购买月数', + startTimePick: '请选择开始日期', + bizTypeSelect: '请选择业务类型', + payWaysSelect: '请选择支付方式', + payStatusSelect: '请选择支付状态', + addOrganizationPrefix: '是否添加 "', + addOrganizationSuffix: '" 组织/企业条目信息?', + publicAuthority: '公用权限', + privateAuthority: '专用权限', + optionPrivilegeTransfer: '选择权限转赠', + trainingList: 'TrainingList' +}; diff --git a/src/i18n/langs/en/tip.js b/src/i18n/langs/en/tip.js index 26cb49e78..dbe220393 100644 --- a/src/i18n/langs/en/tip.js +++ b/src/i18n/langs/en/tip.js @@ -2,6 +2,7 @@ export default { confirm: '确 定', cancel: '取 消', creatingSuccessful: '创建成功!', + creatingFailed: '创建失败', confirmDeletion: '是否确认删除?', hint: '提示', cancelledDelete: '已取消删除', @@ -13,5 +14,14 @@ export default { cannotCoincide: '起始坐标和结束坐标不能重合', - meter: '米' + meter: '米', + + operationSuccessfully: '操作成功', + operationFailed: '操作失败', + setupSuccessfully: '设置成功', + setupFailed: '设置失败', + recoveryPrivilegesSuccessful: '回收权限成功', + recoveryPrivilegesFailed: '回收权限失败', + unpackingSuccessful: '解包成功', + unpackingFailed: '解包失败' }; diff --git a/src/i18n/langs/zh/error.js b/src/i18n/langs/zh/error.js index 7cd8432d8..eaa84281c 100644 --- a/src/i18n/langs/zh/error.js +++ b/src/i18n/langs/zh/error.js @@ -6,5 +6,10 @@ export default { resetFailed: '重置失败', startTrainingFailed: '开始实训失败', saveBackgroundFailed: '保存背景失败', - deleteFailed: '删除失败' + deleteFailed: '删除失败', + requestFailed: '请求失败', + transferredQRCodeFailed: '获取转赠二维码失败', + loadingDataFailed: '加载数据错误', + addingFailure: '加载失败', + cancelled: '已取消' }; diff --git a/src/i18n/langs/zh/global.js b/src/i18n/langs/zh/global.js index 37ccc8dca..6c96dad68 100644 --- a/src/i18n/langs/zh/global.js +++ b/src/i18n/langs/zh/global.js @@ -10,5 +10,11 @@ export default { operate: '操 作', edit: '编 辑', delete: '删 除', - add: '新 增' + add: '新 增', + close: '关 闭', + create: '创 建', + update: '更 新', + return: '返 回', + toBeDeveloped: '功能待开发', + choose: '选 择' }; diff --git a/src/i18n/langs/zh/index.js b/src/i18n/langs/zh/index.js index fcbdce9f0..e1f4f0b32 100644 --- a/src/i18n/langs/zh/index.js +++ b/src/i18n/langs/zh/index.js @@ -8,6 +8,7 @@ import rules from './rules'; import scriptRecord from './scriptRecord'; import tip from './tip'; import system from './system'; +import orderAuthor from './orderAuthor'; export default { ...cnLocale, @@ -19,5 +20,6 @@ export default { rules, scriptRecord, tip, - system + system, + orderAuthor }; diff --git a/src/i18n/langs/zh/orderAuthor.js b/src/i18n/langs/zh/orderAuthor.js new file mode 100644 index 000000000..8084d4408 --- /dev/null +++ b/src/i18n/langs/zh/orderAuthor.js @@ -0,0 +1,95 @@ +export default { + name: '名称', + productType: '产品类型', + map: '地图', + state: '状态', + commodityName: '商品名称', + mapName: '地图名称', + courseName: '课程名称', + price: '价格', + describtion: '描述', + creationTime: '创建时间', + setupFailure: '设置失效', + setupEffective: '设置有效', + organizationOrEnterprise: '组织机构/企业', + userName: '用户名称', + permissionType: '权限类型', + permissionNumber: '权限个数', + permanenceOrNot: '是否永久', + startDate: '开始日期', + purchaseMonths: '购买月数', + totalPrice: '购买总价', + paymentMethod: '支付方式', + creationDate: '创建日期', + orderType: '订单类型', + contractNumber: '合同编号', + businessType: '业务类型', + paymentStatus: '支付状态', + salesman: '销售人员', + obtainQrCode: '获取二维码', + userMobile: '用户手机号', + mapProductName: '地图产品名称', + publicOrPrivate: '公用/专用', + totalPermissions: '权限总数', + residualPermissionNumber: '剩余权限数量', + authorityStatus: '权限状态', + startTime: '开始时间', + endTime: '结束时间', + courseAuthorityStatus: '课程权限状态', + source: '来源', + founderPhone: '创建人手机号', + founder: '创建人员', + privilegePackaging: '权限打包', + unpacking: '解包', + authorityDetails: '权限详情', + renew: '续费', + productName: '产品名称', + updateProductTip: '此操作将修改商品状态?', + deleteProductTip: '此操作将删除该商品, 是否继续?', + recovery: '回收', + permissionPack: '权限包', + privilegeTransferQRCode: '权限转赠二维码', + getQRCodeFailure: '获取打包权限二维码失败', + recoveryPrivilegeTip: '此操作将回收权限, 是否继续?', + unpackingTip: '此操作将解包, 是否继续?', + updatePrivilegeTip: '此操作将修改权限状态?', + generatingQRCode: '生成二维码', + transferQRCode: '转赠二维码', + today: '今天', + yesterday: '昨天', + aWeekAgo: '一周前', + addOrder: '添加订单', + updateOrder: '修改订单', + renewOrder: '订单续费', + unknownRouter: '未知路由', + increasePurchaseTime: '增加购买时长', + choosePurchaseTime: '选择购买时长', + increasePermissionNumber: '增加权限数量', + choosePermissionNumber: '选择权限数量', + itemPricing: '商品单价', + organizationInput: '请输入组织或者企业名称', + productSelect: '请选择商品', + itemPricingInput: '请输入商品单价', + orderTypeSelect: '请选择订单类型', + contractNumberInput: '请输入合同编号', + contractNumberLimit: '长度在 1 到 25 个字符', + salesmanInput: '请选择销售人员', + foreverRadio: '请选择', + amountInput: '请输入购买的权限个数', + amountInputError: '请输入有效权限个数', + totalPriceInput: '请输入总价格', + totalPriceInputError1: '请输入的价格在两位小数', + totalPriceInputError2: '请输入有效总价格', + monthAmountInput: '请输入购买月数', + monthAmountInputError: '请输入有效购买月数', + startTimePick: '请选择开始日期', + bizTypeSelect: '请选择业务类型', + payWaysSelect: '请选择支付方式', + payStatusSelect: '请选择支付状态', + addOrganizationPrefix: '是否添加 "', + addOrganizationSuffix: '" 组织/企业条目信息?', + publicAuthority: '公用权限', + privateAuthority: '专用权限', + optionPrivilegeTransfer: '选择权限转赠', + trainingList: '实训列表' +}; diff --git a/src/i18n/langs/zh/tip.js b/src/i18n/langs/zh/tip.js index 26cb49e78..dbe220393 100644 --- a/src/i18n/langs/zh/tip.js +++ b/src/i18n/langs/zh/tip.js @@ -2,6 +2,7 @@ export default { confirm: '确 定', cancel: '取 消', creatingSuccessful: '创建成功!', + creatingFailed: '创建失败', confirmDeletion: '是否确认删除?', hint: '提示', cancelledDelete: '已取消删除', @@ -13,5 +14,14 @@ export default { cannotCoincide: '起始坐标和结束坐标不能重合', - meter: '米' + meter: '米', + + operationSuccessfully: '操作成功', + operationFailed: '操作失败', + setupSuccessfully: '设置成功', + setupFailed: '设置失败', + recoveryPrivilegesSuccessful: '回收权限成功', + recoveryPrivilegesFailed: '回收权限失败', + unpackingSuccessful: '解包成功', + unpackingFailed: '解包失败' }; diff --git a/src/views/orderauthor/author/index.vue b/src/views/orderauthor/author/index.vue index 3092fc010..04deb3e24 100644 --- a/src/views/orderauthor/author/index.vue +++ b/src/views/orderauthor/author/index.vue @@ -32,15 +32,15 @@ queryObject: { 'userMobile': { type: 'text', - label: '用户手机号' + label: this.$t('orderAuthor.userMobile') }, 'userName': { type: 'text', - label: '用户姓名' + label: this.$t('orderAuthor.userName') }, 'type': { type: 'select', - label: '权限类型', + label: this.$t('orderAuthor.permissionType'), config: { data: [] } @@ -53,34 +53,34 @@ indexShow: true, columns: [ { - title: '用户名称', + title: this.$t('orderAuthor.userName'), prop: 'userName' }, { - title: '用户手机号', + title: this.$t('orderAuthor.userMobile'), prop: 'userMobile' }, { - title: '地图名称', + title: this.$t('orderAuthor.mapName'), prop: 'mapName', }, { - title: '地图产品名称', + title: this.$t('orderAuthor.mapProductName'), prop: 'mapProductName', }, { - title: '课程名称', + title: this.$t('orderAuthor.courseName'), prop: 'lessonName', }, { - title: '权限类型', + title: this.$t('orderAuthor.permissionType'), prop: 'type', type: 'tag', columnValue: (row) => { return this.$convertField(row.type, this.PermissionTypeList, ['value', 'label']) }, tagType: (row) => { return '' } }, { - title: '是否永久', + title: this.$t('orderAuthor.permanenceOrNot'), prop: 'forever', type: 'tag', columnValue: (row) => { return this.$ConstSelect.translate(row.forever, 'Whether') }, @@ -92,7 +92,7 @@ } }, { - title: '公用/专用', + title: this.$t('orderAuthor.publicOrPrivate'), prop: 'canDistribute', type: 'tag', columnValue: (row) => { return this.$ConstSelect.translate(row.canDistribute, 'PermissionUseList') }, @@ -104,28 +104,28 @@ } }, { - title: '权限总数', + title: this.$t('orderAuthor.totalPermissions'), prop: 'amount' }, { - title: '剩余权限数量', + title: this.$t('orderAuthor.residualPermissionNumber'), prop: 'remains' }, { - title: '开始时间', + title: this.$t('orderAuthor.startTime'), prop: 'startTime', type: 'formatter', formatter: this.formatterDate }, { - title: '结束时间', + title: this.$t('orderAuthor.endTime'), prop: 'endTime', type: 'formatter', formatter: this.formatterDate }, { - title: '课程权限状态', + title: this.$t('orderAuthor.courseAuthorityStatus'), prop: 'status', type: 'tag', columnValue: (row) => { return this.$convertField(row.status, this.EffectiveTypeList, ['value', 'label']) }, @@ -138,11 +138,11 @@ }, { type: 'button', - title: '操作', + title: this.$t('global.operate'), width: '250', buttons: [ { - name: '设置失效', + name: this.$t('orderAuthor.setupFailure'), type: 'warning', handleClick: this.handleSetFailure, showControl: (row) => { @@ -150,7 +150,7 @@ } }, { - name: '设置有效', + name: this.$t('orderAuthor.setupEffective'), type: 'primary', handleClick: this.handleSetFailure, showControl: (row) => { @@ -158,7 +158,7 @@ } }, { - name: '续费', + name: this.$t('orderAuthor.renew'), type: "warning", handleClick: this.handleRenewAdd, showControl: (row) => { @@ -166,7 +166,7 @@ } }, { - name: '来源', + name: this.$t('orderAuthor.source'), type: '', handleClick: this.handleSource, }, @@ -207,16 +207,16 @@ return getLessonPermissonPageList(params); }, handleSetFailure(index, row) { - this.$confirm('此操作将修改权限状态?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.updatePrivilegeTip'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { setLessonPermisson({ id: row.id, status: row.status == 1 ? '0' : '1' }).then(res => { - this.$message.success('设置成功'); + this.$message.success(this.$t('tip.setupSuccessfully')); this.reloadTable(); }).catch(error => { - this.$messageBox(`设置失败`); + this.$messageBox(this.$t('tip.setupFailed')); }) }).catch(() => { }) }, @@ -236,9 +236,9 @@ let res = await getDistribute(row.distributeId); this.$refs.authorDetail.show(res.data); } catch (error) { - this.$messageBox(`请求失败`); + this.$messageBox(this.$t('tip.requestFailed')); } } } } - \ No newline at end of file + diff --git a/src/views/orderauthor/commodity/index.vue b/src/views/orderauthor/commodity/index.vue index 913c29417..a0a40d39a 100644 --- a/src/views/orderauthor/commodity/index.vue +++ b/src/views/orderauthor/commodity/index.vue @@ -26,25 +26,25 @@ queryObject: { name: { type: 'text', - label: '名称' + label: this.$t('orderAuthor.name') }, productType: { type: 'select', - label: '产品类型', + label: this.$t('orderAuthor.productType'), config: { data: [] } }, mapId: { type: 'select', - label: '地图', + label: this.$t('orderAuthor.map'), config: { data: [] } }, status: { type: 'select', - label: '状态', + label: this.$t('orderAuthor.state'), config: { data: this.$ConstSelect.Status } @@ -57,34 +57,34 @@ indexShow: true, columns: [ { - title: '商品名称', + title: this.$t('orderAuthor.commodityName'), prop: 'name' }, { - title: '产品类型', + title: this.$t('orderAuthor.productType'), prop: 'productType', type: 'tag', columnValue: (row) => { return this.$convertField(row.productType, this.productTypeList, ['value', 'label']) }, tagType: (row) => { return 'success' } }, { - title: '地图名称', + title: this.$t('orderAuthor.mapName'), prop: 'mapName', }, { - title: '产品名称', + title: this.$t('orderAuthor.productName'), prop: 'prdName', }, { - title: '课程名称', + title: this.$t('orderAuthor.courseName'), prop: 'lessonName', }, { - title: '价格', + title: this.$t('orderAuthor.price'), prop: 'price' }, { - title: '状态', + title: this.$t('orderAuthor.state'), prop: 'status', type: 'tag', columnValue: (row) => { return this.$convertField(row.status, this.EffectiveTypeList, ['value', 'label']) }, @@ -96,25 +96,25 @@ } }, { - title: '描述', + title: this.$t('orderAuthor.describtion'), prop: 'remarks' }, { - title: '创建时间', + title: this.$t('orderAuthor.creationTime'), prop: 'createTime' }, { type: 'button', - title: '操作', + title: this.$t('global.operate'), width: '250', buttons: [ { - name: '编辑', + name: this.$t('global.edit'), type: 'primary', handleClick: this.handleEdit }, { - name: '设置失效', + name: this.$t('orderAuthor.setupFailure'), handleClick: this.handleEfficacy, type: 'warning', showControl: (row) => { @@ -122,7 +122,7 @@ } }, { - name: '设置有效', + name: this.$t('orderAuthor.setupEffective'), type: 'primary', handleClick: this.handleEfficacy, showControl: (row) => { @@ -130,7 +130,7 @@ } }, { - name: '删除', + name: this.$t('global.delete'), type: 'danger', handleClick: this.handleDelete, }, @@ -138,7 +138,7 @@ } ], actions: [ - { text: '新增', handler: this.handleAdd }, + { text: this.$t('global.add'), handler: this.handleAdd }, ] }, @@ -183,32 +183,32 @@ }, // 设置失效 handleEfficacy(index, row) { - this.$confirm('此操作将修改商品状态?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.updateProductTip'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { setCommodityStatus(row.id).then(res => { - this.$message.success('操作成功'); + this.$message.success(this.$t('tip.operationSuccessfully')); this.reloadTable() }).catch(err => { - this.$messageBox('操作失败'); + this.$messageBox(this.$t('tip.operationFailed')); this.reloadTable() }) }).catch(() => { }) }, handleDelete(index, row) { - this.$confirm('此操作将删除该商品, 是否继续?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.deleteProductTip'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { delCommodity(row.id).then(response => { - this.$message.success('删除成功') + this.$message.success(this.$t('tip.successfullyDelete')); this.reloadTable() }).catch(error => { - this.reloadTable() - this.$messageBox('删除失败') + this.reloadTable(); + this.$messageBox(this.$t('tip.failDelete')) }) }).catch(() => { }) }, @@ -218,4 +218,4 @@ } } } - \ No newline at end of file + diff --git a/src/views/orderauthor/order/addGoods.vue b/src/views/orderauthor/order/addGoods.vue index 3b784f069..ecaf003d8 100644 --- a/src/views/orderauthor/order/addGoods.vue +++ b/src/views/orderauthor/order/addGoods.vue @@ -1,5 +1,5 @@ @@ -30,7 +30,7 @@ show() { return this.dialogShow; }, - title() { return '选择转赠权限'; } + title() { return this.$t('orderAuthor.optionPrivilegeTransfer'); } }, methods: { doShow(data) { @@ -51,4 +51,4 @@ } } } - \ No newline at end of file + diff --git a/src/views/orderauthor/order/draft.vue b/src/views/orderauthor/order/draft.vue index 5a6baddb4..2702a22f1 100644 --- a/src/views/orderauthor/order/draft.vue +++ b/src/views/orderauthor/order/draft.vue @@ -14,10 +14,10 @@
- 创建 - 更新 - 续费 - 返回 + {{$t('global.create')}} + {{$t('global.update')}} + {{$t('orderAuthor.renew')}} + {{$t('global.return')}}
@@ -79,19 +79,19 @@ }, DatePicker: { shortcuts: [{ - text: '今天', + text: this.$t('orderAuthor.today'), onClick(picker) { picker.$emit('pick', new Date()); } }, { - text: '昨天', + text: this.$t('orderAuthor.yesterday'), onClick(picker) { const date = new Date(); date.setTime(date.getTime() - 3600 * 1000 * 24); picker.$emit('pick', date); } }, { - text: '一周前', + text: this.$t('orderAuthor.aWeekAgo'), onClick(picker) { const date = new Date(); date.setTime(date.getTime() - 3600 * 1000 * 24 * 7); @@ -115,13 +115,13 @@ return (this.type === 'RENEW') && !isNaN(Number(this.$route.params.orderId)); }, title() { - return this.isAdd ? '添加订单' : (this.isEdit ? '修改订单' : this.isReNew ? '订单续费' : '未知路由'); + return this.isAdd ? this.$t('orderAuthor.addOrder') : (this.isEdit ? this.$t('orderAuthor.updateOrder') : this.isReNew ? this.$t('orderAuthor.renewOrder') : this.$t('orderAuthor.unknownRouter')); }, monthsTitle() { - return this.isReNew ? '增加购买时长' : '选择购买时长'; + return this.isReNew ? this.$t('orderAuthor.increasePurchaseTime') : this.$t('orderAuthor.choosePurchaseTime'); }, totalTitle() { - return this.isReNew ? '增加权限数量' : '选择权限数量'; + return this.isReNew ? this.$t('orderAuthor.increasePermissionNumber') : this.$t('orderAuthor.choosePermissionNumber'); }, isShowStartDate() { return !this.formModel.forever && (this.formModel.bizType !== '02'); //非永久的非续费类型显示开始时间 @@ -161,21 +161,21 @@ let form = { labelWidth: '145px', items: [ - { prop: 'organizationId', label: '组织机构/企业', type: 'select', required: false, disabled: this.isDisabled, options: this.OrganizationList, allowCreate: true, onChange: this.onChange }, + { prop: 'organizationId', label: this.$t('orderAuthor.organizationOrEnterprise'), type: 'select', required: false, disabled: this.isDisabled, options: this.OrganizationList, allowCreate: true, onChange: this.onChange }, // { prop: 'goodsId', label: '商品名称', type: 'select', required: false, disabled: this.isDisabled, options: this.goodsList, change: true, onChange: this.selectCommodity }, - { prop: 'goodsName', label: '商品名称', type: 'text', required: false, disabled: true, rightWidth: true, disabled: true, buttontip: '选择商品', buttonClick: this.buttonClick }, - { prop: 'price', label: '商品单价', type: 'number', required: false, disabled: true, min: 0, message: '元' }, - { prop: 'orderType', label: '订单类型', type: 'select', required: false, disabled: this.isDisabled, options: this.OrderTypeList }, - { prop: 'sellerId', label: '销售人员', type: 'select', required: false, show: this.isShowSeller, disabled: this.isDisabled, options: this.SellerList }, - { prop: 'contractNo', label: '合同编号', type: 'text', required: false, show: this.isShowContractNo }, + { prop: 'goodsName', label: this.$t('orderAuthor.commodityName'), type: 'text', required: false, disabled: true, rightWidth: true, disabled: true, buttontip: '选择商品', buttonClick: this.buttonClick }, + { prop: 'price', label: this.$t('orderAuthor.itemPricing'), type: 'number', required: false, disabled: true, min: 0, message: '元' }, + { prop: 'orderType', label: this.$t('orderAuthor.orderType'), type: 'select', required: false, disabled: this.isDisabled, options: this.OrderTypeList }, + { prop: 'sellerId', label: this.$t('orderAuthor.salesman'), type: 'select', required: false, show: this.isShowSeller, disabled: this.isDisabled, options: this.SellerList }, + { prop: 'contractNo', label: this.$t('orderAuthor.contractNumber'), type: 'text', required: false, show: this.isShowContractNo }, { prop: 'amount', label: this.totalTitle, type: 'number', required: false, show: true, min: 0 }, - { prop: 'forever', label: '是否永久', type: 'radio', required: false, options: this.$ConstSelect.Whether, disabled: this.foreverIsDisabled }, - { prop: 'startTime', label: '开始日期', type: 'date', required: false, show: this.isShowStartDate, viewFormat: "yyyy-MM-dd", valueFormat: "yyyy-MM-dd", picker: this.DatePicker }, + { prop: 'forever', label: this.$t('orderAuthor.permanenceOrNot'), type: 'radio', required: false, options: this.$ConstSelect.Whether, disabled: this.foreverIsDisabled }, + { prop: 'startTime', label: this.$t('orderAuthor.startDate'), type: 'date', required: false, show: this.isShowStartDate, viewFormat: "yyyy-MM-dd", valueFormat: "yyyy-MM-dd", picker: this.DatePicker }, { prop: 'monthAmount', label: this.monthsTitle, type: 'number', required: false, show: this.isShowMonths, min: 0, message: '月' }, - { prop: 'totalPrice', label: '购买总价', type: 'number', required: false, show: this.isShowPrice, min: 0, message: '元' }, - { prop: 'bizType', label: '业务类型', type: 'select', required: false, disabled: true, options: this.BizTypeList }, - { prop: 'payWays', label: '支付方式', type: 'select', required: false, disabled: this.payTypeIsDisabled, show: this.isShowPayType, options: this.PayTypeList }, - { prop: 'payStatus', label: '支付状态', type: 'select', required: false, disabled: this.payStatusDisabled, show: this.isShowPayStatus, options: this.PayStatusTypeList }, + { prop: 'totalPrice', label: this.$t('orderAuthor.totalPrice'), type: 'number', required: false, show: this.isShowPrice, min: 0, message: '元' }, + { prop: 'bizType', label: this.$t('orderAuthor.businessType'), type: 'select', required: false, disabled: true, options: this.BizTypeList }, + { prop: 'payWays', label: this.$t('orderAuthor.paymentMethod'), type: 'select', required: false, disabled: this.payTypeIsDisabled, show: this.isShowPayType, options: this.PayTypeList }, + { prop: 'payStatus', label: this.$t('orderAuthor.paymentStatus'), type: 'select', required: false, disabled: this.payStatusDisabled, show: this.isShowPayStatus, options: this.PayStatusTypeList }, ] } return form @@ -184,84 +184,84 @@ rules() { let baseRules = { organizationId: [ - { required: true, message: '请输入组织或者企业名称', trigger: 'blur' } + { required: true, message: this.$t('orderAuthor.organizationInput'), trigger: 'blur' } ], // goodsId: [ // { required: true, message: '请选择商品', trigger: 'change' } // ], goodsName: [ - { required: true, message: '请选择商品', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.productSelect'), trigger: 'change' } ], price: [ - { required: true, message: '请输入商品单价', trigger: 'blur' } + { required: true, message: this.$t('orderAuthor.itemPricingInput'), trigger: 'blur' } ], orderType: [ - { required: true, message: '请选择订单类型', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.orderTypeSelect'), trigger: 'change' } ], contractNo: [ - { required: true, message: '请输入合同编号', trigger: 'blur' }, - { min: 1, max: 25, message: '长度在 1 到 25 个字符', trigger: 'blur' } + { required: true, message: this.$t('orderAuthor.contractNumberInput'), trigger: 'blur' }, + { min: 1, max: 25, message: this.$t('orderAuthor.contractNumberLimit'), trigger: 'blur' } ], sellerId: [ - { required: true, message: '请选择销售人员', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.salesmanInput'), trigger: 'change' } ], forever: [ - { required: true, message: '请选择', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.foreverRadio'), trigger: 'change' } ], amount: [ - { required: true, message: '请输入购买的权限个数', trigger: 'change' }, + { required: true, message: this.$t('orderAuthor.amountInput'), trigger: 'change' }, { validator(rule, value, callback) { if (Number.isInteger(Number(value)) && Number(value) > 0) { callback(); } else { - callback(new Error("请输入有效权限个数")); + callback(new Error(this.$t('orderAuthor.amountInputError'))); } }, trigger: 'blur', } ], totalPrice: [ - { required: true, message: '请输入总价格', trigger: 'change' }, + { required: true, message: this.$t('orderAuthor.totalPriceInput'), trigger: 'change' }, { validator(rule, value, callback) { if (Number(value) >= 0) { if (String(value).split('.')[1] && String(value).split('.')[1].length > 2) { - callback(new Error("请输入的价格在两位小数")); + callback(new Error(this.$t('orderAuthor.totalPriceInputError1'))); } else { callback(); } } else { - callback(new Error("请输入有效总价格")); + callback(new Error(this.$t('orderAuthor.totalPriceInputError2'))); } }, trigger: 'blur', } ], monthAmount: [ - { required: true, message: '请输入购买月数', trigger: 'change' }, + { required: true, message: this.$t('orderAuthor.monthAmountInput'), trigger: 'change' }, { validator(rule, value, callback) { if (Number.isInteger(Number(value)) && Number(value) > 0) { callback(); } else { - callback(new Error("请输入有效购买月数")); + callback(new Error(this.$t('orderAuthor.monthAmountInputError'))); } }, trigger: 'blur', } ], startTime: [ - { required: true, message: '请选择开始日期', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.startTimePick'), trigger: 'change' } ], bizType: [ - { required: true, message: '请选择订单类型', trigger: 'change' } + { required: true, message: this.$t('orderAuthor.bizTypeSelect'), trigger: 'change' } ], payWays: [ - { required: true && this.isShowPayType, message: '请选择支付方式', trigger: 'change' } + { required: true && this.isShowPayType, message: this.$t('orderAuthor.payWaysSelect'), trigger: 'change' } ], payStatus: [ - { required: true && this.isShowPayStatus, message: '请选择支付状态', trigger: 'change' } + { required: true && this.isShowPayStatus, message: this.$t('orderAuthor.payStatusSelect'), trigger: 'change' } ] } @@ -325,7 +325,7 @@ this.$Dictionary.orderType().then(list => { this.$convertList(list, this.OrderTypeList, elem => { - return elem.code !== '01' //过滤个人 + return elem.code !== '01' //过滤个人 }); }); @@ -355,8 +355,8 @@ if (this.type === 'ADD') { this.formModel.bizType = '01'; //正常购买 } else if (this.type === 'EDIT') { - this.$alert('功能待开发', '提示', { - confirmButtonText: '确定', + this.$alert(this.$t('global.toBeDeveloped'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), callback: action => { this.turnback(); } @@ -372,7 +372,7 @@ this.formModel.contractNo = ''; }); }).catch(error => { - this.$messageBox('加载数据错误'); + this.$messageBox(this.$t('error.loadingDataFailed')); }); } @@ -405,19 +405,19 @@ }; //如果需要添加的条目,不存在List当中,则需要提示是否添加条目,并且增加对应的处理 - this.$confirm('是否添加 "' + input + '" 组织/企业条目信息?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.addOrganizationPrefix') + input + this.$t('orderAuthor.addOrganizationSuffix'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { addOrganization({ name: input }).then(response => { this.OrgzList.push(response.data); }).catch(error => { - this.$messageBox('添加失败'); + this.$messageBox(this.$t('error.addingFailure')); }) }).catch(() => { this.formModel.organizationId = ''; - this.$message.info('已取消'); + this.$message.info(this.$t('error.cancelled')); }); }, selectCommodity(data) { @@ -480,10 +480,10 @@ createOrder(this.buildModel()).then(response => { this.turnback(); this.loading = false; - this.$message.success('创建成功'); + this.$message.success(this.$t('tip.creatingSuccessful')); }).catch(error => { this.loading = false; - this.$messageBox("创建失败"); + this.$messageBox(this.$t('tip.creatingFailed')); }); }); }, @@ -493,10 +493,10 @@ updateOrder(this.buildModel()).then(response => { this.turnback(); this.loading = false; - this.$message.success('更新成功'); + this.$message.success(this.$t('tip.updateSuccessfully')); }).catch(error => { this.loading = false; - this.$messageBox("更新失败") + this.$messageBox(this.$t('tip.updateFailed')) }); }) }, @@ -548,4 +548,4 @@ text-align: center; margin: 20px auto; } - \ No newline at end of file + diff --git a/src/views/orderauthor/order/list.vue b/src/views/orderauthor/order/list.vue index 87e4e288e..e22a440aa 100644 --- a/src/views/orderauthor/order/list.vue +++ b/src/views/orderauthor/order/list.vue @@ -44,18 +44,18 @@ queryObject: { 'organizationId': { type: 'select', - label: '组织机构/企业', + label: this.$t('orderAuthor.organizationOrEnterprise'), config: { data: [] } }, 'userName': { type: 'text', - label: '用户名称' + label: this.$t('orderAuthor.userName'), }, 'permissionType': { type: 'select', - label: '权限类型', + label: this.$t('orderAuthor.permissionType'), config: { data: [] } @@ -68,33 +68,33 @@ indexShow: true, columns: [ { - title: '组织机构/企业', + title: this.$t('orderAuthor.organizationOrEnterprise'), prop: 'organizationName', type: 'tag', columnValue: (row) => { return row.organizationName }, tagType: (row) => { return '' } }, { - title: '用户名称', + title: this.$t('orderAuthor.userName'), prop: 'userName' }, { - title: '商品名称', + title: this.$t('orderAuthor.commodityName'), prop: 'goodsName', }, { - title: '权限类型', + title: this.$t('orderAuthor.permissionType'), prop: 'permissionType', type: 'tag', columnValue: (row) => { return this.$convertField(row.permissionType, this.PermissionTypeList, ['value', 'label']) }, tagType: (row) => { return '' } }, { - title: '权限个数', + title: this.$t('orderAuthor.permissionNumber'), prop: 'amount' }, { - title: '是否永久', + title: this.$t('orderAuthor.permanenceOrNot'), prop: 'forever', type: 'tag', columnValue: (row) => { return this.$ConstSelect.translate(row.forever, 'Whether') }, @@ -103,50 +103,50 @@ } }, { - title: '开始日期', + title: this.$t('orderAuthor.startDate'), prop: 'startTime', type: 'formatter', format: 'yyyy-MM-dd' }, { - title: '购买月数', + title: this.$t('orderAuthor.purchaseMonths'), prop: 'monthAmount' }, { - title: '购买总价', + title: this.$t('orderAuthor.totalPrice'), prop: 'totalPrice' }, { - title: '支付方式', + title: this.$t('orderAuthor.paymentMethod'), prop: 'payWays', type: 'tag', columnValue: (row) => { return this.$convertField(row.payWays, this.PayTypeList, ['value', 'label']) }, tagType: (row) => { return 'success' } }, { - title: '创建日期', + title: this.$t('orderAuthor.creationDate'), prop: 'createTime' }, { - title: '订单类型', + title: this.$t('orderAuthor.orderType'), prop: 'orderType', type: 'tag', columnValue: (row) => { return this.$convertField(row.orderType, this.OrderTypeList, ['value', 'label']) }, tagType: (row) => { return 'success' } }, { - title: '合同编号', + title: this.$t('orderAuthor.contractNumber'), prop: 'contractNo' }, { - title: '业务类型', + title: this.$t('orderAuthor.businessType'), prop: 'bizType', type: 'tag', columnValue: (row) => { return this.$convertField(row.bizType, this.BizTypeList, ['value', 'label']) }, tagType: (row) => { return 'success' } }, { - title: '支付状态', + title: this.$t('orderAuthor.paymentStatus'), prop: 'payStatus', type: 'tag', columnValue: (row) => { return this.$convertField(row.payStatus, this.PayStatusList, ['value', 'label']) }, @@ -159,7 +159,7 @@ } }, { - title: '销售人员', + title: this.$t('orderAuthor.salesman'), prop: 'sellerName', type: 'tag', columnValue: (row) => { return row.sellerName }, @@ -167,21 +167,21 @@ }, { type: 'button', - title: '操作', + title: this.$t('global.operate'), width: '260', buttons: [ { - name: '编辑', + name: this.$t('global.edit'), handleClick: this.handleEdit }, { - name: '获取二维码', + name: this.$t('orderAuthor.obtainQrCode'), type: "warning", handleClick: this.handleCanDistribute, showControl: (row) => { return row.bizType !== '02' && row.orderType !== '01' && row.qrCodeGenerated } }, { - name: '生成二维码', + name: this.$t('orderAuthor.generatingQRCode'), type: "warning", handleClick: this.handleCanDistribute, showControl: (row) => { return row.bizType !== '02' && row.orderType !== '01' && !row.qrCodeGenerated } @@ -190,7 +190,7 @@ }, ], actions: [ - { text: '新增', btnCode: 'employee_insert', handler: this.handleNormalAdd }, + { text: this.$t('global.add'), btnCode: 'employee_insert', handler: this.handleNormalAdd }, ] } } @@ -259,8 +259,8 @@ this.$router.push({ path: `${UrlConfig.orderauthor.orderDraft}/add/0` }) }, handleEdit(index, data) { - this.$alert('功能待开发', '提示', { - confirmButtonText: '确定', + this.$alert('功能待开发', this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), callback: action => { } }); @@ -294,12 +294,12 @@ if (data.qrCodeGenerated) { this.$refs.qrCode.doShow({ url: response.data, - title: '转赠二维码' + title: this.$t('orderAuthor.transferQRCode') }); } }).catch(error => { - this.$messageBox("获取转赠二维码错误"); + this.$messageBox(this.$t('error.transferredQRCodeFailed')); }); }, reloadTable() { @@ -309,4 +309,4 @@ } } } - \ No newline at end of file + diff --git a/src/views/orderauthor/permission/index.vue b/src/views/orderauthor/permission/index.vue index 6747d1727..2c7c9bb17 100644 --- a/src/views/orderauthor/permission/index.vue +++ b/src/views/orderauthor/permission/index.vue @@ -31,22 +31,22 @@ queryObject: { 'userMobile': { type: 'text', - label: '创建人手机号' + label: this.$t('orderAuthor.founderPhone') }, 'userName': { type: 'text', - label: '创建人员' + label: this.$t('orderAuthor.founder') }, 'permissionType': { type: 'select', - label: '权限类型', + label: this.$t('orderAuthor.permissionType'), config: { data: [] } }, 'status': { type: 'select', - label: '权限状态', + label: this.$t('orderAuthor.authorityStatus'), value: '1', config: { data: [] @@ -60,38 +60,38 @@ indexShow: true, columns: [ { - title: '组织机构/企业', + title: this.$t('orderAuthor.organizationOrEnterprise'), prop: 'organizationName' }, { - title: '创建人员', + title: this.$t('orderAuthor.founder'), prop: 'userName' }, { - title: '创建人手机号', + title: this.$t('orderAuthor.founderPhone'), prop: 'userMobile' }, { - title: '地图名称', + title: this.$t('orderAuthor.mapName'), prop: 'mapName', }, { - title: '地图产品名称', + title: this.$t('orderAuthor.mapProductName'), prop: 'mapProductName', }, { - title: '课程名称', + title: this.$t('orderAuthor.courseName'), prop: 'lessonName', }, { - title: '权限类型', + title: this.$t('orderAuthor.permissionType'), prop: 'permissionType', type: 'tag', columnValue: (row) => { return this.$convertField(row.permissionType, this.PermissionTypeList, ['value', 'label']) }, tagType: (row) => { return '' } }, { - title: '公用/专用', + title: this.$t('orderAuthor.publicOrPrivate'), prop: 'canDistribute', type: 'tag', columnValue: (row) => { return this.$ConstSelect.translate(row.canDistribute, 'PermissionUseList') }, @@ -103,7 +103,7 @@ } }, { - title: '是否永久', + title: this.$t('orderAuthor.permanenceOrNot'), prop: 'forever', type: 'tag', columnValue: (row) => { return this.$ConstSelect.translate(row.forever, 'Whether') }, @@ -115,20 +115,20 @@ } }, { - title: '开始时间', + title: this.$t('orderAuthor.startTime'), prop: 'startTime', type: 'formatter', formatter: this.formatterDate }, { - title: '结束时间', + title: this.$t('orderAuthor.endTime'), prop: 'endTime', type: 'formatter', formatter: this.formatterDate }, { - title: '权限状态', + title: this.$t('orderAuthor.authorityStatus'), prop: 'status', type: 'tag', columnValue: (row) => { return this.$convertField(row.status, this.EffectiveTypeList, ['value', 'label']) }, @@ -141,30 +141,30 @@ }, { type: 'button', - title: '操作', + title: this.$t('global.operate'), width: '300', hide: (row) => { return this.$store.state.user.roles.indexOf(superAdmin) < 0; }, buttons: [ { - name: '获取二维码', + name: this.$t('orderAuthor.obtainQrCode'), handleClick: this.handleRtCodeShow, type: '', showControl: (row) => { return true } }, { - name: '权限详情', + name: this.$t('orderAuthor.authorityDetails'), handleClick: this.handlePermissionDetail, type: '', showControl: (row) => { return row.status == '1' && (row.source == '02' || row.source == '04') } }, { - name: '回收', + name: this.$t('orderAuthor.recovery'), handleClick: this.handleRestore, type: 'danger', showControl: (row) => { return row.status == '1' && row.source == '04' } }, { - name: '解包', + name: this.$t('orderAuthor.unpacking'), handleClick: this.handleUnPackage, type: 'danger', showControl: (row) => { return row.status == '1' && row.source == '02' } @@ -173,7 +173,7 @@ } ], actions: [ - { text: '权限打包', btnCode: 'employee_insert', handler: this.handlePackage }, + { text: this.$t('orderAuthor.privilegePackaging'), btnCode: 'employee_insert', handler: this.handlePackage }, ] } } @@ -199,7 +199,7 @@ this.$convertList(list, this.PermissionTypeList, elem => { return true; }); - this.PermissionTypeList.push({ value: undefined, label: '权限包' }); + this.PermissionTypeList.push({ value: undefined, label: this.$t('orderAuthor.permissionPack') }); }); }, formatterDate(row, porpInfo) { @@ -222,37 +222,37 @@ getPackageQrCode({ id: row.id }).then(resp => { this.$refs.qrCode.doShow({ url: resp.data, - title: '权限转赠二维码' + title: this.$t('orderAuthor.privilegeTransferQRCode') }); }).catch(error => { - this.$messageBox('获取打包权限二维码失败'); + this.$messageBox(this.$t('orderAuthor.getQRCodeFailure')); }) }, handleRestore(index, row) { - this.$confirm('此操作将回收权限, 是否继续?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.recoveryPrivilegeTip'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { restorePackagePermission(row.id).then(resp => { this.reloadTable(); - this.$message.success('回收权限成功!'); + this.$message.success(this.$t('tip.recoveryPrivilegesSuccessful')); }).catch(error => { - this.$messageBox('回收权限失败'); + this.$messageBox(this.$t('tip.recoveryPrivilegesFailed')); }) }).catch(() => { }); }, handleUnPackage(index, row) { - this.$confirm('此操作将解包, 是否继续?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', + this.$confirm(this.$t('orderAuthor.unpackingTip'), this.$t('tip.hint'), { + confirmButtonText: this.$t('tip.confirm'), + cancelButtonText: this.$t('tip.cancel'), type: 'warning' }).then(() => { permissionDistributeUnPackage(row.id).then(resp => { this.reloadTable(); - this.$message.success('解包成功!'); + this.$message.success(this.$t('tip.unpackingSuccessful')); }).catch(error => { - this.$messageBox('解包失败'); + this.$messageBox(this.$t('tip.unpackingFailed')); }) }).catch(() => { }); }, @@ -261,4 +261,4 @@ } } } - \ No newline at end of file + From 61fe3c2b2db2845d93205c953a4708b52064ede8 Mon Sep 17 00:00:00 2001 From: ival <610568032@qq.com> Date: Tue, 13 Aug 2019 09:09:10 +0800 Subject: [PATCH 003/172] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=9B=9E=E6=94=BE?= =?UTF-8?q?=E7=95=8C=E9=9D=A2=E5=B8=83=E5=B1=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/display/menuReplay.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/views/display/menuReplay.vue b/src/views/display/menuReplay.vue index 453526bb1..0dd4e80b2 100644 --- a/src/views/display/menuReplay.vue +++ b/src/views/display/menuReplay.vue @@ -52,7 +52,8 @@ export default { required: true }, offset: { - type: Number + type: Number, + required: true } }, data() { @@ -155,6 +156,7 @@ export default { position: absolute; display: inline; bottom: 10px; + right: 0px; .draft-menu { position: static; From 8725104c7b0212d5dd0c15a879af342a856dba2c Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Tue, 13 Aug 2019 09:20:49 +0800 Subject: [PATCH 004/172] =?UTF-8?q?=E8=B0=83=E6=95=B4=EF=BC=9A=E5=9B=BD?= =?UTF-8?q?=E9=99=85=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/i18n/langs/en/tip.js | 33 ++++++++++++++++++--------------- src/i18n/langs/zh/tip.js | 12 +++++++++++- 2 files changed, 29 insertions(+), 16 deletions(-) diff --git a/src/i18n/langs/en/tip.js b/src/i18n/langs/en/tip.js index d59b4aeca..a1ac6a5d1 100644 --- a/src/i18n/langs/en/tip.js +++ b/src/i18n/langs/en/tip.js @@ -2,9 +2,12 @@ export default { confirm: '确 定', cancel: '取 消', creatingSuccessful: '创建成功!', + creatingFailed: '创建失败', confirmDeletion: '是否确认删除?', + confirmBatchGeneration: '是否确认批量生成?', hint: '提示', cancelledDelete: '已取消删除', + cancelGeneration: '已取消批量生成', updateSuccessfully: '更新成功', updateFailed: '更新失败', @@ -12,22 +15,22 @@ export default { failDelete: '删除失败', cannotCoincide: '起始坐标和结束坐标不能重合', - cannotMerged: '存在非物理区段,不能合并', - linkCannotMerged: '不在同一Link上的物理区段不能合并', + cannotMerged: '存在非物理区段,不能合并', + linkCannotMerged: '不在同一Link上的物理区段不能合并', - selectedSectionEmpty: '选择的区段为空', + selectedSectionEmpty: '选择的区段为空', - stationFont: '车站字体', - kilometerFont: '公里标字体', - meter: '米', - angle: '度', + stationFont: '车站字体', + kilometerFont: '公里标字体', + meter: '米', + angle: '度', - operationSuccessfully: '操作成功', - operationFailed: '操作失败', - setupSuccessfully: '设置成功', - setupFailed: '设置失败', - recoveryPrivilegesSuccessful: '回收权限成功', - recoveryPrivilegesFailed: '回收权限失败', - unpackingSuccessful: '解包成功', - unpackingFailed: '解包失败' + operationSuccessfully: '操作成功', + operationFailed: '操作失败', + setupSuccessfully: '设置成功', + setupFailed: '设置失败', + recoveryPrivilegesSuccessful: '回收权限成功', + recoveryPrivilegesFailed: '回收权限失败', + unpackingSuccessful: '解包成功', + unpackingFailed: '解包失败' }; diff --git a/src/i18n/langs/zh/tip.js b/src/i18n/langs/zh/tip.js index 91b6f76d7..a1ac6a5d1 100644 --- a/src/i18n/langs/zh/tip.js +++ b/src/i18n/langs/zh/tip.js @@ -2,6 +2,7 @@ export default { confirm: '确 定', cancel: '取 消', creatingSuccessful: '创建成功!', + creatingFailed: '创建失败', confirmDeletion: '是否确认删除?', confirmBatchGeneration: '是否确认批量生成?', hint: '提示', @@ -22,5 +23,14 @@ export default { stationFont: '车站字体', kilometerFont: '公里标字体', meter: '米', - angle: '度' + angle: '度', + + operationSuccessfully: '操作成功', + operationFailed: '操作失败', + setupSuccessfully: '设置成功', + setupFailed: '设置失败', + recoveryPrivilegesSuccessful: '回收权限成功', + recoveryPrivilegesFailed: '回收权限失败', + unpackingSuccessful: '解包成功', + unpackingFailed: '解包失败' }; From 0eaa4dbe1fe48f1c59ae46b1162106366c4c1cc7 Mon Sep 17 00:00:00 2001 From: ival <610568032@qq.com> Date: Tue, 13 Aug 2019 11:10:55 +0800 Subject: [PATCH 005/172] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=9B=BD=E9=99=85?= =?UTF-8?q?=E5=8C=96=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/QrCode/index.vue | 2 +- src/components/QueryListPage/QueryForm.vue | 20 +- .../QueryListPage/QueryListPage.vue | 12 +- src/components/TurnbackBar/index.vue | 2 +- src/i18n/langs/en/error.js | 7 +- src/i18n/langs/en/global.js | 48 +- src/i18n/langs/en/system.js | 4 +- src/i18n/langs/zh/error.js | 7 +- src/i18n/langs/zh/global.js | 49 +- src/i18n/langs/zh/system.js | 4 +- src/layout/components/Entry.vue | 2 +- src/main.js | 2 +- src/views/components/PopMenu/index.vue | 6 +- src/views/components/filterCity/index.vue | 5 +- src/views/components/font/index.vue | 122 ++-- src/views/components/limits/distribute.vue | 392 ++++++------ src/views/components/limits/index.vue | 229 +++---- src/views/components/limits/transfer.vue | 406 ++++++------- src/views/components/pay/commit.vue | 375 ++++++------ src/views/components/pay/confirm.vue | 565 +++++++++--------- src/views/components/pay/finish.vue | 149 ++--- src/views/components/pay/index.vue | 231 +++---- src/views/dashboard/index.vue | 4 +- src/views/management/dictionary/index.vue | 6 +- .../management/dictionaryDetail/index.vue | 28 +- .../management/userControl/correlationMap.vue | 157 +++-- src/views/management/userControl/edit.vue | 194 +++--- src/views/management/userExam/edit.vue | 204 ++++--- src/views/management/userExam/index.vue | 257 ++++---- src/views/management/userSimulation/add.vue | 388 ++++++------ src/views/management/userSimulation/edit.vue | 208 ++++--- src/views/management/userSimulation/index.vue | 300 +++++----- 32 files changed, 2262 insertions(+), 2123 deletions(-) diff --git a/src/components/QrCode/index.vue b/src/components/QrCode/index.vue index 697006b51..1ae436cfa 100644 --- a/src/components/QrCode/index.vue +++ b/src/components/QrCode/index.vue @@ -4,7 +4,7 @@ - 关闭 + {{ $t('global.close') }} diff --git a/src/components/QueryListPage/QueryForm.vue b/src/components/QueryListPage/QueryForm.vue index 6f4cc8efd..5ef16def7 100644 --- a/src/components/QueryListPage/QueryForm.vue +++ b/src/components/QueryListPage/QueryForm.vue @@ -32,7 +32,7 @@ v-model="formModel[name]" type="date" :value-format="field.valueFormat || 'yyyy-MM-dd'" - :placeholder="field.placeholder || '选择日期'" + :placeholder="field.placeholder || $t('global.chooseDate')" /> @@ -42,7 +42,7 @@ v-model="formModel[name]" type="daterange" :value-format="field.valueFormat || 'yyyy-MM-dd'" - range-separator="至" + :range-separator="$t('global.to')" /> @@ -52,7 +52,7 @@ v-model="formModel[name]" type="time" :value-format="field.valueFormat || 'HH:mm:ss'" - :placeholder="field.placeholder || '选择时间'" + :placeholder="field.placeholder || $t('global.chooseTime')" /> @@ -63,7 +63,7 @@ type="timerange" is-range :value-format="field.valueFormat || 'HH:mm:ss'" - range-separator="至" + :range-separator="$t('global.to')" /> @@ -73,7 +73,7 @@ v-model="formModel[name]" type="datetime" :value-format="field.valueFormat || 'yyyy-MM-dd HH:mm:ss'" - :placeholder="field.placeholder || '选择日期时间'" + :placeholder="field.placeholder || $t('global.chooseDateTime')" /> @@ -83,7 +83,7 @@ v-model="formModel[name]" type="datetimerange" :value-format="field.valueFormat || 'yyyy-MM-dd HH:mm:ss'" - range-separator="至" + :range-separator="$t('global.to')" /> @@ -95,7 +95,7 @@ v-model="formModel[name]" :multiple="field.config.multiple" clearable - :placeholder="field.placeholder || '请选择'" + :placeholder="field.placeholder || $t('global.choose')" filterable @change="selectChange(field, formModel)" > @@ -128,9 +128,9 @@ - 查询 - 重置 - 导出 + {{ $t('global.query') }} + {{ $t('global.reset') }} + {{ $t('global.export') }}