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
dfd83c51
Commit
dfd83c51
authored
Oct 19, 2020
by
renjintao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
state
parent
1586601e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
220 additions
and
241 deletions
+220
-241
add.vue
pages/technology/details/routingsupporting/add.vue
+220
-241
No files found.
pages/technology/details/routingsupporting/add.vue
View file @
dfd83c51
<
template
>
<
template
>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"120"
>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"120"
>
<Row>
<Row>
<!--
<!--
<Col
:span=
"12"
>
<Col
:span=
"12"
>
...
@@ -37,12 +37,7 @@
...
@@ -37,12 +37,7 @@
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
:label=
"l('routingDetailName')"
prop=
"routingDetailId"
>
<FormItem
:label=
"l('routingDetailName')"
prop=
"routingDetailId"
>
<Select
v-model=
"entity.routingDetailId"
>
<Select
v-model=
"entity.routingDetailId"
>
<Option
<Option
v-for=
"(item, index) in routingDetailList"
:value=
"item.value"
:key=
"index"
>
{{
item
.
label
}}
</Option>
v-for=
"(item, index) in routingDetailList"
:value=
"item.value"
:key=
"index"
>
{{
item
.
label
}}
</Option
>
</Select>
</Select>
</FormItem>
</FormItem>
</Col>
</Col>
...
@@ -59,24 +54,9 @@
...
@@ -59,24 +54,9 @@
<Materiel
:bomId=
"productBomId"
v-model=
"entity.materialId"
@
on-change=
"change"
></Materiel>
<Materiel
:bomId=
"productBomId"
v-model=
"entity.materialId"
@
on-change=
"change"
></Materiel>
</FormItem>
-->
</FormItem>
-->
<FormItem
:label=
"l('nameMaterial')"
prop=
"materialId"
>
<FormItem
:label=
"l('nameMaterial')"
prop=
"materialId"
>
<Select
<Select
v-model=
"entity.materialId"
placeholder=
"请选择"
style=
"width: 300px"
>
v-model=
"entity.materialId"
<Option
v-for=
"(item, index) in listData"
:key=
"index"
:value=
"item.value"
:label=
"item.label"
style=
"display: none"
></Option>
placeholder=
"请选择"
<Tree
key=
"mytree"
:data=
"dataTree"
ref=
"mytree"
:render=
"renderContent"
></Tree>
style=
"width: 300px"
>
<Option
v-for=
"(item, index) in listData"
:key=
"index"
:value=
"item.value"
:label=
"item.label"
style=
"display: none"
></Option>
<Tree
key=
"mytree"
:data=
"dataTree"
ref=
"mytree"
:render=
"renderContent"
></Tree>
</Select>
</Select>
<!--
<Materiel
<!--
<Materiel
v-model=
"entity.materialId"
v-model=
"entity.materialId"
...
@@ -93,10 +73,7 @@
...
@@ -93,10 +73,7 @@
</Col>
-->
</Col>
-->
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
:label=
"l('quantity')"
prop=
"quantity"
>
<FormItem
:label=
"l('quantity')"
prop=
"quantity"
>
<InputNumber
<InputNumber
v-model=
"entity.quantity"
style=
"width: 100%"
></InputNumber>
v-model=
"entity.quantity"
style=
"width: 100%"
></InputNumber>
</FormItem>
</FormItem>
</Col>
</Col>
<Divider
orientation=
"left"
>
物料属性
</Divider>
<Divider
orientation=
"left"
>
物料属性
</Divider>
...
@@ -153,9 +130,11 @@
...
@@ -153,9 +130,11 @@
<Button
type=
"primary"
@
click=
"handleSubmit"
v-noClick
>
保存
</Button>
<Button
type=
"primary"
@
click=
"handleSubmit"
v-noClick
>
保存
</Button>
<Button
@
click=
"handleClose"
class=
"ml20"
>
取消
</Button>
<Button
@
click=
"handleClose"
class=
"ml20"
>
取消
</Button>
</FormItem>
</FormItem>
</Form>
</Form>
</
template
>
</
template
>
<
script
>
<
script
>
import
Api
from
"./api"
;
import
Api
from
"./api"
;
import
ApiDetail
from
"../api"
;
import
ApiDetail
from
"../api"
;
export
default
{
export
default
{
...
@@ -180,36 +159,30 @@ export default {
...
@@ -180,36 +159,30 @@ export default {
texture
:
""
,
texture
:
""
,
procurementStandards
:
""
,
procurementStandards
:
""
,
qualityGrade
:
""
,
qualityGrade
:
""
,
state
:
null
,
state
:
0
,
extend
:
""
,
extend
:
""
,
remark
:
""
,
remark
:
""
,
drawNum
:
""
,
drawNum
:
""
,
json
:
{},
json
:
{},
},
},
rules
:
{
rules
:
{
routingDetailId
:
[
routingDetailId
:
[{
{
required
:
true
,
required
:
true
,
message
:
"请选择工序"
,
message
:
"请选择工序"
,
type
:
"number"
,
type
:
"number"
,
trigger
:
"change"
,
trigger
:
"change"
,
},
},
],
],
materialId
:
[{
materialId
:
[
{
required
:
true
,
required
:
true
,
message
:
"请选择工序"
,
message
:
"请选择工序"
,
trigger
:
"change"
,
trigger
:
"change"
,
},
},
],
],
quantity
:
[{
quantity
:
[
{
required
:
true
,
required
:
true
,
type
:
"number"
,
type
:
"number"
,
message
:
"请选择工序"
,
message
:
"请选择工序"
,
trigger
:
"blur"
,
trigger
:
"blur"
,
},
},
],
],
},
},
routingDetailList
:
[],
routingDetailList
:
[],
};
};
...
@@ -228,11 +201,14 @@ export default {
...
@@ -228,11 +201,14 @@ export default {
this
.
getData
();
this
.
getData
();
},
},
methods
:
{
methods
:
{
renderContent
(
h
,
{
root
,
node
,
data
})
{
renderContent
(
h
,
{
root
,
node
,
data
})
{
//渲染树的样式
//渲染树的样式
return
h
(
return
h
(
"span"
,
"span"
,
{
{
style
:
{
style
:
{
cursor
:
"pointer"
,
cursor
:
"pointer"
,
},
},
...
@@ -262,14 +238,18 @@ export default {
...
@@ -262,14 +238,18 @@ export default {
this
.
entity
.
materialNumber
=
data
.
mmcode
;
this
.
entity
.
materialNumber
=
data
.
mmcode
;
this
.
entity
.
json
.
nameMaterial
=
data
.
name
;
this
.
entity
.
json
.
nameMaterial
=
data
.
name
;
this
.
entity
.
json
.
materialNumber
=
data
.
mmcode
;
this
.
entity
.
json
.
materialNumber
=
data
.
mmcode
;
Api
.
getMaterial
({
id
:
data
.
materialId
}).
then
((
r
)
=>
{
Api
.
getMaterial
({
id
:
data
.
materialId
}).
then
((
r
)
=>
{
if
(
r
.
result
)
{
if
(
r
.
result
)
{
this
.
forItem
=
r
.
result
;
this
.
forItem
=
r
.
result
;
}
}
});
});
},
},
getData
()
{
getData
()
{
Api
.
alltree
({
id
:
this
.
productBomId
}).
then
((
r
)
=>
{
Api
.
alltree
({
id
:
this
.
productBomId
}).
then
((
r
)
=>
{
if
(
r
.
success
)
{
if
(
r
.
success
)
{
this
.
dataTree
=
r
.
result
;
this
.
dataTree
=
r
.
result
;
// this.$Message.success("获取物料成功");
// this.$Message.success("获取物料成功");
...
@@ -344,8 +324,7 @@ export default {
...
@@ -344,8 +324,7 @@ export default {
}
}
},
},
productBomId
(
v
)
{
productBomId
(
v
)
{
if
(
v
>
0
)
{
if
(
v
>
0
)
{}
}
},
},
},
},
};
};
...
...
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