|
@@ -2,18 +2,18 @@
|
|
|
<div class="app-container">
|
|
|
<!-- 产品表表单 -->
|
|
|
<el-dialog
|
|
|
- :title="textMap[editType]+'产品'"
|
|
|
+ :title="textMap[editType] + '产品'"
|
|
|
:visible.sync="editShow"
|
|
|
:before-close="handleClose"
|
|
|
:close-on-click-modal="false"
|
|
|
>
|
|
|
<el-form
|
|
|
ref="editForm"
|
|
|
- :rules="editType==='update'?rules:rules"
|
|
|
+ :rules="editType === 'update' ? rules : rules"
|
|
|
:model="editForm"
|
|
|
label-position="right"
|
|
|
label-width="8rem"
|
|
|
- style="width: 90%; margin-left:2%;"
|
|
|
+ style="width: 90%; margin-left: 2%"
|
|
|
>
|
|
|
<el-form-item label="产品名称" prop="securities">
|
|
|
<el-input v-model="editForm.securities" />
|
|
@@ -34,15 +34,26 @@
|
|
|
<template slot="append">枚</template>
|
|
|
</el-input>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="类型" prop="tag">
|
|
|
+ <el-select v-model="editForm.tag" class="filter-item" placeholder="请选择">
|
|
|
+ <el-option
|
|
|
+ v-for="item in $commonArray.options['tagOpt']"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
</el-form>
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
<el-button type="danger" @click="handleClose">关 闭</el-button>
|
|
|
<el-button
|
|
|
- v-show="editType!=='view'"
|
|
|
+ v-show="editType !== 'view'"
|
|
|
type="primary"
|
|
|
:disabled="isDisable"
|
|
|
@click="confirmClick"
|
|
|
- >保 存</el-button>
|
|
|
+ >保 存</el-button
|
|
|
+ >
|
|
|
</span>
|
|
|
</el-dialog>
|
|
|
</div>
|
|
@@ -65,6 +76,7 @@ export default {
|
|
|
spec: [{ required: true, message: '规格不能为空', trigger: 'change' }],
|
|
|
crownPrefix: [{ required: true, message: '冠字号代码不能为空', trigger: 'change' }],
|
|
|
boxAmount: [{ required: true, message: '整拍箱数不能为空', trigger: 'change' }],
|
|
|
+ tag: [{ required: true, message: '请选择类型', trigger: 'change' }],
|
|
|
amountPerBox: [{ required: true, message: '整箱枚数不能为空', trigger: 'change' }]
|
|
|
}
|
|
|
}
|