Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mes-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
周远喜
mes-ui
Commits
18eb33e9
Commit
18eb33e9
authored
Jun 17, 2020
by
仇晓婷
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ting-p' into product
parents
e8ca494d
92432624
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
123 additions
and
58 deletions
+123
-58
add.vue
pages/materiel/classification/add.vue
+58
-28
api.js
pages/materiel/classification/api.js
+3
-1
edit.vue
pages/materiel/classification/edit.vue
+50
-16
masterData.vue
pages/materiel/classification/masterData.vue
+1
-1
sonAdd.vue
pages/materiel/classification/sonAdd.vue
+2
-2
add.vue
pages/materiel/masterData/add.vue
+5
-5
edit.vue
pages/materiel/masterData/edit.vue
+4
-5
No files found.
pages/materiel/classification/add.vue
View file @
18eb33e9
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
</Col>
</Col>
<Col
:span=
"24"
>
<Col
:span=
"24"
>
<h4>
扩展属性
</h4>
<h4>
扩展属性
</h4>
<Table
border
:columns=
"columns"
:data=
"checkList"
height=
"
30
0"
>
<Table
border
:columns=
"columns"
:data=
"checkList"
height=
"
45
0"
>
<template
slot-scope=
"
{ row, index }" slot="title">
<template
slot-scope=
"
{ row, index }" slot="title">
<div
v-if=
"row.fieldType==1||row.fieldType==2"
>
{{
row
.
title
}}
</div>
<div
v-if=
"row.fieldType==1||row.fieldType==2"
>
{{
row
.
title
}}
</div>
<Input
<Input
...
@@ -45,36 +45,57 @@
...
@@ -45,36 +45,57 @@
<Input
v-model=
"row.note"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
v-else
/>
<Input
v-model=
"row.note"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
v-else
/>
</
template
>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"dataType"
>
<
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"
clearable
transfer
v-else
@
on-change=
"setRow(row,index)"
>
<Option
v-for=
"item in codeList"
:value=
"item.code"
:key=
"item.code"
>
{{
item
.
name
}}
</Option>
</Select>
</Col>
</Row>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"unitName"
>
<state
<state
v-if=
"row.fieldType==1"
v-if=
"row.fieldType==1"
code=
"mater
ail.category.dataTyp
e"
code=
"mater
ial.main.unitNam
e"
:value=
"row.
dataTyp
e"
:value=
"row.
unitNam
e"
type=
"text"
type=
"text"
></state>
></state>
<Dictionary
<Dictionary
v-else
v-else
@
on-change=
"setRow(row,index)"
@
on-change=
"setRow(row,index)"
v-model=
"row.
dataTyp
e"
v-model=
"row.
unitNam
e"
code=
"mater
ail.category.dataTyp
e"
code=
"mater
ial.main.unitNam
e"
type=
"select"
type=
"select"
:value=
"row.dataType"
:value=
"row.unitName"
:key=
"row.dataType"
:key=
"row.unitName"
></Dictionary>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"dataType"
>
<!--
<state
v-if=
"row.fieldType==1"
code=
"materail.main.company"
:value=
"row.company"
type=
"text"
></state>
-->
<Dictionary
@
on-change=
"setRow(row,index)"
v-model=
"row.company"
code=
"materail.main.company"
type=
"select"
:value=
"row.company"
:key=
"row.company"
></Dictionary>
></Dictionary>
</
template
>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"required"
>
<
template
slot-scope=
"{ row, index }"
slot=
"required"
>
...
@@ -118,6 +139,7 @@ export default {
...
@@ -118,6 +139,7 @@ export default {
codeRuleId
:
this
.
nodeInfo
.
codeRuleId
codeRuleId
:
this
.
nodeInfo
.
codeRuleId
},
},
disabled
:
false
,
disabled
:
false
,
codeList
:
[],
columns
:
[
columns
:
[
{
{
title
:
"序号"
,
title
:
"序号"
,
...
@@ -135,19 +157,22 @@ export default {
...
@@ -135,19 +157,22 @@ export default {
title
:
"备注"
,
title
:
"备注"
,
key
:
"note"
,
key
:
"note"
,
align
:
"center"
,
align
:
"center"
,
slot
:
"note"
slot
:
"note"
,
width
:
"150"
},
},
{
{
title
:
"属性类型"
,
title
:
"属性类型"
,
key
:
"dataType"
,
key
:
"dataType"
,
align
:
"center"
,
align
:
"center"
,
slot
:
"dataType"
slot
:
"dataType"
,
width
:
"200"
},
},
{
{
title
:
"单位"
,
title
:
"单位"
,
key
:
"
company
"
,
key
:
"
unitName
"
,
align
:
"center"
,
align
:
"center"
,
slot
:
"company"
slot
:
"unitName"
,
width
:
"150"
},
},
{
{
title
:
"是否必填"
,
title
:
"是否必填"
,
...
@@ -164,7 +189,7 @@ export default {
...
@@ -164,7 +189,7 @@ export default {
{
{
title
:
"操作"
,
title
:
"操作"
,
slot
:
"action"
,
slot
:
"action"
,
width
:
100
,
align
:
"center"
align
:
"center"
}
}
],
],
...
@@ -208,6 +233,11 @@ export default {
...
@@ -208,6 +233,11 @@ export default {
});
});
}
}
});
});
Api
.
getChildren
({
id
:
582
}).
then
(
r
=>
{
if
(
r
.
result
)
{
this
.
codeList
=
r
.
result
;
}
});
},
},
remove
(
index
,
row
)
{
remove
(
index
,
row
)
{
if
(
row
.
add
==
0
)
{
if
(
row
.
add
==
0
)
{
...
...
pages/materiel/classification/api.js
View file @
18eb33e9
...
@@ -26,5 +26,7 @@ export default {
...
@@ -26,5 +26,7 @@ export default {
delete
(
id
)
{
delete
(
id
)
{
return
Api
.
delete
(
`
${
systemUrl
}
/category/delete`
,{
params
:{
id
:
id
}});
return
Api
.
delete
(
`
${
systemUrl
}
/category/delete`
,{
params
:{
id
:
id
}});
},
},
getChildren
(
params
){
return
Api
.
get
(
`
${
systemUrl
}
/Dictionary/getChildren`
,
params
);
//字典
},
}
}
\ No newline at end of file
pages/materiel/classification/edit.vue
View file @
18eb33e9
...
@@ -33,7 +33,7 @@
...
@@ -33,7 +33,7 @@
</Col>
</Col>
<Col
:span=
"24"
style=
"padding:20px 0 0px 10px;margin-bottom:10px;"
class=
"table-solt"
>
<Col
:span=
"24"
style=
"padding:20px 0 0px 10px;margin-bottom:10px;"
class=
"table-solt"
>
<!--fieldType 1.固有,2.默认,3自定义; -->
<!--fieldType 1.固有,2.默认,3自定义; -->
<Table
border
:columns=
"columns"
:data=
"checkList"
class=
"tableCommon"
height=
"
30
0"
>
<Table
border
:columns=
"columns"
:data=
"checkList"
class=
"tableCommon"
height=
"
45
0"
>
<template
slot-scope=
"
{ row, index }" slot="title">
<template
slot-scope=
"
{ row, index }" slot="title">
<div
v-if=
"row.fieldType==1||row.fieldType==2"
>
{{
row
.
title
}}
</div>
<div
v-if=
"row.fieldType==1||row.fieldType==2"
>
{{
row
.
title
}}
</div>
<Input
v-else
v-model=
"row.title"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
/>
<Input
v-else
v-model=
"row.title"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
/>
...
@@ -43,25 +43,59 @@
...
@@ -43,25 +43,59 @@
<Input
v-model=
"row.note"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
v-else
/>
<Input
v-model=
"row.note"
placeholder=
"请输入"
@
on-blur=
"setRow(row,index)"
v-else
/>
</
template
>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"dataType"
>
<
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"
clearable
transfer
v-else
@
on-change=
"setRow(row,index)"
>
<Option
v-for=
"item in codeList"
:value=
"item.code"
:key=
"item.code"
>
{{
item
.
name
}}
</Option>
</Select>
</Col>
</Row>
</
template
>
<
template
slot-scope=
"{ row, index }"
slot=
"unitName"
>
<state
<state
v-if=
"row.fieldType==1"
v-if=
"row.fieldType==1"
code=
"mater
ail.category.dataTyp
e"
code=
"mater
ial.main.unitNam
e"
:value=
"row.
dataTyp
e"
:value=
"row.
unitNam
e"
type=
"text"
type=
"text"
></state>
></state>
<Dictionary
<Dictionary
v-else
v-else
@
on-change=
"setRow(row,index)"
@
on-change=
"setRow(row,index)"
v-model=
"row.
dataTyp
e"
v-model=
"row.
unitNam
e"
code=
"mater
ail.category.dataTyp
e"
code=
"mater
ial.main.unitNam
e"
type=
"select"
type=
"select"
:value=
"row.
dataTyp
e"
:value=
"row.
unitNam
e"
:key=
"row.
dataTyp
e"
:key=
"row.
unitNam
e"
></Dictionary>
></Dictionary>
</
template
>
</
template
>
<!-- <template slot-scope="{ row, index }" slot="result">
<Input v-model="row.result" placeholder="请输入" @on-blur="setRow(row,index)" />
</template>-->
<
template
slot-scope=
"{ row, index }"
slot=
"required"
>
<
template
slot-scope=
"{ row, index }"
slot=
"required"
>
<Checkbox
v-model=
"row.required"
@
on-change=
"setRow(row,index)"
></Checkbox>
<Checkbox
v-model=
"row.required"
@
on-change=
"setRow(row,index)"
></Checkbox>
</
template
>
</
template
>
...
@@ -129,12 +163,12 @@ export default {
...
@@ -129,12 +163,12 @@ export default {
align
:
"center"
,
align
:
"center"
,
slot
:
"dataType"
slot
:
"dataType"
},
},
//
{
{
// title: "是否显示
",
title
:
"单位
"
,
// key: "result
",
key
:
"unitName
"
,
//
align: "center",
align
:
"center"
,
// slot: "result
"
slot
:
"unitName
"
//
},
},
{
{
title
:
"是否必填"
,
title
:
"是否必填"
,
key
:
"required"
,
key
:
"required"
,
...
...
pages/materiel/classification/masterData.vue
View file @
18eb33e9
...
@@ -111,7 +111,7 @@ export default {
...
@@ -111,7 +111,7 @@ export default {
},
},
methods
:
{
methods
:
{
search
()
{
search
()
{
alert
(
JSON
.
stringify
(
this
.
easySearch
));
//
alert(JSON.stringify(this.easySearch));
console
.
log
(
this
.
easySearch
);
console
.
log
(
this
.
easySearch
);
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
this
.
$refs
.
grid
.
reload
(
this
.
easySearch
);
},
},
...
...
pages/materiel/classification/sonAdd.vue
View file @
18eb33e9
...
@@ -7,11 +7,11 @@
...
@@ -7,11 +7,11 @@
<Input
v-model=
"upName"
placeholder=
"请输入"
disabled
></Input>
<Input
v-model=
"upName"
placeholder=
"请输入"
disabled
></Input>
</FormItem>
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<
!--
<
Col
:span=
"12"
>
<FormItem
label=
"编码"
prop=
"code"
>
<FormItem
label=
"编码"
prop=
"code"
>
<Input
v-model=
"entity.code"
placeholder=
"请输入"
disabled
></Input>
<Input
v-model=
"entity.code"
placeholder=
"请输入"
disabled
></Input>
</FormItem>
</FormItem>
</Col>
</Col>
-->
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
label=
"名称"
prop=
"name"
>
<FormItem
label=
"名称"
prop=
"name"
>
<Input
v-model=
"entity.name"
placeholder=
"请输入"
></Input>
<Input
v-model=
"entity.name"
placeholder=
"请输入"
></Input>
...
...
pages/materiel/masterData/add.vue
View file @
18eb33e9
...
@@ -2,27 +2,27 @@
...
@@ -2,27 +2,27 @@
<div>
<div>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"90"
>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"90"
>
<Row>
<Row>
<Col
:span=
"12"
>
<
!--
<
Col
:span=
"12"
>
<FormItem
label=
"编码"
prop=
"code"
>
<FormItem
label=
"编码"
prop=
"code"
>
<Input
v-model=
"entity.code"
placeholder=
"请输入"
disabled
></Input>
<Input
v-model=
"entity.code"
placeholder=
"请输入"
disabled
></Input>
</FormItem>
</FormItem>
</Col>
</Col>
-->
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
label=
"名称"
prop=
"name"
>
<FormItem
label=
"名称"
prop=
"name"
>
<Input
v-model=
"entity.name"
placeholder=
"请输入"
></Input>
<Input
v-model=
"entity.name"
placeholder=
"请输入"
></Input>
</FormItem>
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<
!--
<
Col
:span=
"12"
>
<FormItem
label=
"状态"
prop=
"status"
placeholder=
"请选择"
>
<FormItem
label=
"状态"
prop=
"status"
placeholder=
"请选择"
>
<Dictionary
<Dictionary
code=
"mater
ail.category
.status"
code=
"mater
ial.main
.status"
v-model=
"entity.status"
v-model=
"entity.status"
type=
"select"
type=
"select"
:value=
"entity.status"
:value=
"entity.status"
:key=
"entity.status"
:key=
"entity.status"
></Dictionary>
></Dictionary>
</FormItem>
</FormItem>
</Col>
</Col>
-->
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
label=
"版本"
prop=
"version"
>
<FormItem
label=
"版本"
prop=
"version"
>
<Input
v-model=
"entity.version"
placeholder=
"请输入"
></Input>
<Input
v-model=
"entity.version"
placeholder=
"请输入"
></Input>
...
...
pages/materiel/masterData/edit.vue
View file @
18eb33e9
...
@@ -13,9 +13,9 @@
...
@@ -13,9 +13,9 @@
</FormItem>
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
label=
"状态"
prop=
"status"
placeholder=
"请选择"
>
<FormItem
label=
"状态"
prop=
"status"
placeholder=
"请选择"
v-if=
"entity.status==3||entity.status==2"
>
<Dictionary
<Dictionary
code=
"mater
ail.category
.status"
code=
"mater
ial.main
.status"
v-model=
"entity.status"
v-model=
"entity.status"
type=
"select"
type=
"select"
:value=
"entity.status"
:value=
"entity.status"
...
@@ -46,7 +46,7 @@
...
@@ -46,7 +46,7 @@
<
script
>
<
script
>
import
Api
from
"./api"
;
import
Api
from
"./api"
;
export
default
{
export
default
{
props
:
[
"nodeInfo"
,
'eid'
],
props
:
[
"nodeInfo"
,
"eid"
],
data
()
{
data
()
{
return
{
return
{
arr
:
[],
arr
:
[],
...
@@ -79,7 +79,6 @@ export default {
...
@@ -79,7 +79,6 @@ export default {
},
},
remove
(
index
,
row
)
{
remove
(
index
,
row
)
{
// if (row.add == 0) {
// if (row.add == 0) {
// //新增的删除,直接删
// //新增的删除,直接删
// this.checkList.splice(index, 1);
// this.checkList.splice(index, 1);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment