Commit 793d06df authored by 周远喜's avatar 周远喜

ok

parent 978a2b50
......@@ -30,43 +30,21 @@
</Col>
<Col :span="24">
<h4>扩展属性</h4>
<Table border :columns="columns" :data="checkList" height="450">
<Table border :columns="columns" :data="checkList">
<template slot-scope="{ row, index }" slot="title">
<div v-if="row.fieldType==1||row.fieldType==2">{{row.title}}</div>
<Input
v-if="row.fieldType==3"
v-model="row.title"
placeholder="请输入"
placeholder="请输入名称"
@on-blur="setRow(row,index)"
/>
</template>
<template slot-scope="{ row, index }" slot="note">
<div v-if="row.fieldType==1">{{row.note}}</div>
<Input v-model="row.note" placeholder="请输入" @on-blur="setRow(row,index)" v-else />
</template>
<template slot-scope="{ row, index }" slot="dataType">
<Row>
<Col :span="12">
<state
v-if="row.fieldType==1"
code="materail.category.dataType"
:value="row.dataType"
type="text"
></state>
<Dictionary
v-else
@on-change="setRow(row,index)"
v-model="row.dataType"
code="materail.category.dataType"
type="select"
:value="row.dataType"
:key="row.dataType"
></Dictionary>
</Col>
<Col :span="12" v-if="row.dataType==3">
<div v-if="row.fieldType==1">'/'+{{row.dictionaryCode}}</div>
<Select
v-model="row.dictionaryCode"
<!-- <Input v-if="row.dataType==3" v-model="row.note" placeholder="请输入字典编码" @on-blur="setRow(row,index)" /> -->
<Select
v-if="row.dataType==3"
v-model="row.note"
clearable
transfer
v-else
......@@ -78,22 +56,27 @@
:key="item.code"
>{{ item.name }}</Option>
</Select>
</Col>
</Row>
<span v-else>{{row.note}}</span>
</template>
<template slot-scope="{ row, index }" slot="dataType">
<Dictionary
@on-change="setRow(row,index)"
v-model="row.dataType"
code="materail.category.dataType"
type="select"
:value="row.dataType"
:key="row.dataType"
></Dictionary>
</template>
<template slot-scope="{ row, index }" slot="unitName">
<state
v-if="row.fieldType==1"
code="material.main.unitName"
:value="row.unitName"
type="text"
></state>
<Dictionary
v-else
v-if="row.dataType==1||row.dataType==2"
@on-change="setRow(row,index)"
v-model="row.unitName"
code="material.main.unitName"
type="select"
placeholder="请选择单位"
:value="row.unitName"
:key="row.unitName"
></Dictionary>
......@@ -157,28 +140,13 @@ export default {
key: "dataType",
align: "center",
slot: "dataType",
width:150
width:200
},
{
title: "备注",
title: "设置",
key: "note",
align: "center",
slot: "note",
width: "150"
},
// {
// title: "是否显示",
// key: "result",
// align: "center",
// slot: "result"
// },
{
title: "属性类型",
key: "dataType",
align: "center",
slot: "dataType",
width: "200"
slot: "note",
},
{
title: "单位",
......@@ -202,6 +170,7 @@ export default {
width:80
},
{
width:80,
title: "操作",
slot: "action",
align: "center"
......@@ -244,7 +213,7 @@ export default {
this.checkList = arr.filter(function(item) {
item.mid=item.id;
delete item["id"]; //删除属性id
return item;
return item.fieldType>1;
});
}
});
......
......@@ -68,7 +68,7 @@
<MasterData ref="dataTable" @on-edit="editRow" :root="root" @on-ok="ok" />
</Content>
</Layout>
<Modal v-model="modal" :title="title" width="1200" footer-hide :mask-closable="false">
<Modal v-model="modal" :title="title" width="1500" footer-hide :mask-closable="false">
<component
:is="detail"
:eid="curId"
......
......@@ -47,9 +47,9 @@
class="w100"
></InputNumber>
<Dictionary v-if="li.dataType==3" v-model="entity[li.field]" :code="li.note"></Dictionary>
<Input v-if="li.dataType==4" v-model="entity[li.filed]"></Input>
<Input v-if="li.dataType==5" type="textarea" v-model="entity[li.filed]"></Input>
<DatePicker
v-if="li.dataType==5"
v-if="li.dataType==4"
v-model="entity[li.field]"
type="date"
:placeholder="'选择'+li.title"
......@@ -58,6 +58,7 @@
<!-- <files ref="refFile" :parms="parms" fileFormat :Photos="true" @clickItem="clickData" /> -->
<InputFile v-if="li.dataType==7" v-model="entity[li.field]"></InputFile>
<Input v-if="li.dataType==8" type="textarea" v-model="entity[li.field]"></Input>
<state v-if="li.unitName" :value="li.unitName" code="material.main.unitName" type="tag"></state>
</FormItem>
</Col>
<!-- <Col :span="24">
......
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