opt:印尼项目国际化
This commit is contained in:
@@ -379,22 +379,22 @@ export default {
|
||||
permission: {},
|
||||
rules: {
|
||||
point_code: [
|
||||
{ required: true, message: '点位编码不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.pointCodeRequired'), trigger: 'blur' }
|
||||
],
|
||||
point_name: [
|
||||
{ required: true, message: '点位名称不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.pointNameRequired'), trigger: 'blur' }
|
||||
],
|
||||
point_type: [
|
||||
{ required: true, message: '点位类型不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.pointTypeRequired'), trigger: 'blur' }
|
||||
],
|
||||
point_status: [
|
||||
{ required: true, message: '点位状态不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.pointStatusRequired'), trigger: 'blur' }
|
||||
],
|
||||
region_id: [
|
||||
{ required: true, message: '区域类型不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.regionRequired'), trigger: 'blur' }
|
||||
],
|
||||
lock_type: [
|
||||
{ required: true, message: '锁定类型不能为空', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('common.lockTypeRequired'), trigger: 'blur' }
|
||||
]
|
||||
|
||||
}
|
||||
@@ -436,18 +436,18 @@ export default {
|
||||
return is_used === '1'
|
||||
},
|
||||
changeEnabled(data, val) {
|
||||
let msg = '此操作将停用点位,是否继续!'
|
||||
let msg = this.$t('common.confirmDisable')
|
||||
if (val !== '1') {
|
||||
msg = '此操作将启用点位,是否继续!'
|
||||
msg = this.$t('common.confirmEnable')
|
||||
}
|
||||
this.$confirm(msg, '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
this.$confirm(msg, this.$t('common.tip'), {
|
||||
confirmButtonText: this.$t('common.confirm'),
|
||||
cancelButtonText: this.$t('common.cancel'),
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
changeActive(data).then(res => {
|
||||
this.crud.toQuery()
|
||||
this.crud.notify('操作成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.notify(this.$t('common.operationSuccess'), CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
}).catch(() => {
|
||||
data.is_used = !data.is_used
|
||||
})
|
||||
@@ -485,7 +485,7 @@ export default {
|
||||
},
|
||||
changeUsed(data, flag) { // 更改启用状态
|
||||
crudPoint.changeActives(data).then(res => {
|
||||
this.crud.notify('操作成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.notify(this.$t('common.operationSuccess'), CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
})
|
||||
},
|
||||
@@ -494,16 +494,16 @@ export default {
|
||||
param.data = data
|
||||
param.lock_type = flag
|
||||
crudPoint.changeLock(param).then(res => {
|
||||
this.crud.notify('操作成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.notify(this.$t('common.operationSuccess'), CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
})
|
||||
},
|
||||
sync() {
|
||||
this.sync_flag = true
|
||||
crudPoint.sync().then(res => {
|
||||
this.crud.notify('同步成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.notify(this.$t('common.syncSuccess'), CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.sync_flag = false
|
||||
}).cache(() => {
|
||||
}).catch(() => {
|
||||
this.sync_flag = false
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user