This commit is contained in:
Fanzink
2022-02-25 15:12:37 +08:00
parent 2628c14e99
commit 64c27487c5
5 changed files with 13 additions and 9 deletions

View File

@@ -12,7 +12,7 @@
>
<el-form ref="dataForm" :model="dataForm" :rules="dataRule" label-width="130px" @keyup.enter.native="dataFormSubmit()">
<el-form-item :label="$t('module.basicData.cache.ShelfName')" prop="name">
<el-input v-model="dataForm.name" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfName')])" clearable />
<el-input v-model="dataForm.shelfName" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfName')])" clearable />
</el-form-item>
<el-form-item :label="$t('module.basicData.cache.ShelfCode')" prop="code">
<el-input v-model="dataForm.code" :placeholder="$i18nForm(['placeholder.input', $t('module.basicData.cache.ShelfCode')])" clearable />
@@ -56,15 +56,17 @@ export default {
visible: false,
isPage: false,
dataForm: {
abbr: 'n',
id: 0,
areaId: '',
name: '',
shelfName: '',
code: '',
shelfNumber: ''
shelfNumber: '',
total: ''
},
areaArr: [],
dataRule: {
name: [
shelfName: [
{ required: true, message: this.$i18nForm(['placeholder.input', this.$t('module.basicData.cache.ShelfName')]), trigger: 'blur' }
],
code: [
@@ -112,6 +114,7 @@ export default {
this.$refs['dataForm'].validate((valid) => {
if (valid) {
const data = this.dataForm
console.log(data)
if (this.dataForm.id) {
shelfUpdate(data).then(res => {
this.$message({