Commit ab18ca7a authored by 仇晓婷's avatar 仇晓婷

库房

parent 5b3ab026
......@@ -2,57 +2,47 @@
<Form ref="form" :model="entity" :rules="rules" :label-width="100">
<Row>
<Col :span="12">
<FormItem :label="l('storeTitle')" prop="storeId">
<FormItem :label="l('storeTitle')+':'">
<div style="color:#515a6e">{{rootName}}</div>
<!-- <StoreSelect v-model="entity.storeId" @on-change="storeChange"></StoreSelect> -->
</FormItem>
</Col>
<Col :span="12">
<FormItem :label="l('creator')" prop="creator">{{entity.creator}}</FormItem>
<FormItem :label="l('creator')+':'">{{entity.creator}}</FormItem>
</Col>
<Col :span="12">
<FormItem :label="l('name')" prop="materialId">
<Materiel v-model="entity.materialId" @on-change="change" :materialType="materialType"></Materiel>
</FormItem>
</Col>
<!-- <Col :span="12">
<FormItem :label="l('certificateOfApproval')" prop="certificateOfApproval">
<Input v-model="entity.certificateOfApproval"></Input>
</FormItem>
</Col>-->
<Col :span="12">
<FormItem :label="l('inputTotal')" prop="total">
<InputNumber v-model="entity.total" style="width:280px"></InputNumber>
</FormItem>
</Col>
<!-- <Col :span="12">
<FormItem :label="l('unitPrice')" prop="unitPrice">
<InputNumber v-model="entity.unitPrice" style="width:280px"></InputNumber>
</FormItem>
</Col>
<Col :span="12">
<FormItem :label="l('batch')" prop="batch">
<Input v-model="entity.batch"></Input>
</FormItem>
</Col>
<Col :span="12">
<FormItem :label="l('originalManufacturer')" prop="originalManufacturer">
<Input v-model="entity.originalManufacturer"></Input>
</FormItem>
</Col>-->
<Col :span="24">
<FormItem :label="l('remark')" prop="remark">
<Input v-model="entity.remark" type="textarea" :rows="5"></Input>
</FormItem>
</Col>
</Row>
<div>
<Divider orientation="left">物料属性</Divider>
</div>
<Divider orientation="left">物料属性</Divider>
<Col :span="12" v-if="entity.materialId">
<FormItem label="物料名称:">
<span>{{entity.name}}</span>
</FormItem>
</Col>
<Col :span="12" v-if="entity.materialId">
<FormItem label="物料编码:">
<span>{{entity.materialCode}}</span>
</FormItem>
</Col>
<Row>
<Col v-for="li in fileds" :key="li.field" :span="li.span">
<FormItem :label="li.title" :prop="li.name">
<FormItem :label="li.title" :prop="li.name" v-if="li.title!='物料名称'&&li.title!='物料编码'">
<Input v-if="li.dataType==0" v-model="entity.json[li.field]"></Input>
<InputNumber
v-if="li.dataType==1||li.dataType==2"
......@@ -113,8 +103,6 @@ export default {
remark: "",
json: {},
},
materialId: null,
rules: {
materialId: [
{
......@@ -142,9 +130,7 @@ export default {
storeTitle: String,
materialType: String,
},
mounted() {
},
mounted() {},
methods: {
handleSubmit() {
this.$refs.form.validate((v) => {
......@@ -175,9 +161,10 @@ export default {
},
change(e) {
this.entity.name = e.name;
this.materialId = e.materialId;
this.entity.materialId = e.materialId;
this.entity.materialCode = e.mmcode;
this.entity.json.name = e.name;
this.entity.json.materialCode = e.mmcode;
Api.getmaterialdefinitionproperty({ materialId: e.materialId }).then(
(r) => {
if (r.result) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment