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
106462c3
Commit
106462c3
authored
Jul 20, 2020
by
renjintao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mesplan--add--edit--
parent
d3f9cf1b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
50 additions
and
18 deletions
+50
-18
add.vue
pages/mesPlan/add.vue
+6
-5
edit.vue
pages/mesPlan/edit.vue
+44
-13
No files found.
pages/mesPlan/add.vue
View file @
106462c3
...
...
@@ -3,9 +3,9 @@
<Form
:model=
"orderSearchForm"
:label-width=
"95"
:rules=
"ruleValidate"
ref=
"formValidate"
>
<Row>
<Col
span=
"8"
>
<FormItem
label=
"产品名称"
style=
"width:100%"
prop=
"
bom
Id"
>
<FormItem
label=
"产品名称"
style=
"width:100%"
prop=
"
product
Id"
>
<Select
v-model=
"orderSearchForm.
bom
Id"
v-model=
"orderSearchForm.
product
Id"
:placeholder=
"placeholdeinfo"
style=
"width:240px;"
>
...
...
@@ -13,8 +13,8 @@
v-for=
"(item,index) in list"
:key=
"item.index"
:value=
"item.value"
style=
"display:none"
:label=
"item.label"
style=
"display:none"
></Option>
<Tree
key=
"mytree"
:data=
"data1"
ref=
"mytree"
:render=
"renderContent"
></Tree>
</Select>
...
...
@@ -24,6 +24,7 @@
<FormItem
label=
"产品图号"
style=
"width:100%"
>
<Input
v-model=
"orderSearchForm.drawnNumber"
style=
"width:240px"
disabled
/>
<Input
v-model=
"orderSearchForm.productName"
style=
"width:240px"
v-show=
"false"
/>
<Input
v-model=
"orderSearchForm.bomId"
style=
"width:240px"
v-show=
"false"
/>
</FormItem>
</Col>
<Col
span=
"8"
>
...
...
@@ -146,7 +147,7 @@ export default {
bomId
:
null
},
ruleValidate
:
{
bom
Id
:
[
product
Id
:
[
{
required
:
true
,
message
:
"请选择产品名称"
,
...
...
@@ -231,7 +232,7 @@ export default {
this
.
selectdata
=
data
;
this
.
list
=
[];
this
.
list
.
push
({
label
:
data
[
0
].
title
,
value
:
data
[
0
].
id
});
if
(
data
[
0
].
isProduct
==
"1"
)
{
if
(
data
[
0
].
isProduct
==
1
)
{
this
.
orderSearchForm
.
productName
=
data
[
0
].
title
;
this
.
orderSearchForm
.
productId
=
data
[
0
].
productId
;
this
.
orderSearchForm
.
drawnNumber
=
data
[
0
].
drawingNo
;
...
...
pages/mesPlan/edit.vue
View file @
106462c3
...
...
@@ -5,9 +5,9 @@
<FormItem
label=
"订单编号"
style=
"width:100%"
>
{{
this
.
orderSearchForm
.
mesCode
}}
</FormItem>
</Col>
<Col
span=
"8"
>
<FormItem
:label=
"l('productName')"
style=
"width:100%"
prop=
"
bom
Id"
>
<FormItem
:label=
"l('productName')"
style=
"width:100%"
prop=
"
product
Id"
>
<Select
v-model=
"orderSearchForm.
bom
Id"
v-model=
"orderSearchForm.
product
Id"
:placeholder=
"placeholdeinfo"
style=
"width:240px;"
>
...
...
@@ -26,6 +26,7 @@
<FormItem
:label=
"l('drawnNumber')"
style=
"width:100%"
>
<Input
v-model=
"orderSearchForm.drawnNumber"
style=
"width:240px"
disabled
/>
<Input
v-model=
"orderSearchForm.productName"
style=
"width:240px"
v-show=
"false"
/>
<Input
v-model=
"orderSearchForm.bomId"
style=
"width:240px"
v-show=
"false"
/>
</FormItem>
</Col>
</Row>
...
...
@@ -120,7 +121,7 @@ export default {
disabled
:
false
,
orderSearchForm
:
{},
ruleValidate
:
{
bom
Id
:
[
product
Id
:
[
{
required
:
true
,
message
:
"请选择产品名称"
,
...
...
@@ -148,7 +149,7 @@ export default {
placeholdeinfo
:
""
,
list
:
[],
data1
:
[],
wfstatu
:
1
wfstatu
:
1
};
},
props
:
{
...
...
@@ -160,7 +161,7 @@ export default {
}
},
mounted
()
{
let
params
=
{
let
params
=
{
id
:
"123327da-42b3-41f6-b785-cf933f137a95"
};
this
.
$api
.
get
(
`
${
workflowUrl
}
/schema/getbyid`
,
params
).
then
(
res
=>
{
...
...
@@ -213,6 +214,7 @@ export default {
return
this
.
$t
(
key
);
},
handleSelect
(
data
)
{
this
.
placeholdeinfo
=
""
;
if
(
data
.
length
>
0
)
{
this
.
selectdata
=
[];
this
.
selectdata
=
data
;
...
...
@@ -242,7 +244,7 @@ export default {
projectNumber
:
""
,
//项目号
batchNumber
:
""
,
//批次号
urgencyLevel
:
null
,
//紧急程度
bomId
:
''
,
bomId
:
""
};
},
loadTree
()
{
...
...
@@ -261,14 +263,23 @@ export default {
});
},
renderContent
(
h
,
{
root
,
node
,
data
})
{
//渲染树的样式
let
type
=
"md-folder"
;
let
title
=
data
.
title
;
if
(
data
.
isProduct
!=
0
)
{
let
version
=
this
.
$store
.
getters
.
dictionaryByCode
(
"material.main.version"
,
data
.
version
);
type
=
"ios-image"
;
if
(
version
)
{
title
=
data
.
title
+
"("
+
data
.
mmcode
+
"/"
+
version
.
name
+
")"
;
}
else
{
title
=
data
.
title
+
"("
+
data
.
mmcode
+
")"
;
}
}
return
h
(
"span"
,
{
style
:
{
color
:
data
.
isProduct
!=
"1"
?
"#249E91"
:
"#333"
,
//根据选中状态设置样式
cursor
:
"pointer"
},
on
:
{
click
:
()
=>
{
let
arrTree
=
[];
...
...
@@ -277,7 +288,25 @@ export default {
}
}
},
data
.
title
[
h
(
"Icon"
,
{
props
:
{
type
:
type
},
style
:
{
marginRight
:
"8px"
}
}),
h
(
"span"
,
{
style
:
{
color
:
data
.
isProduct
==
0
?
"#000"
:
"rgba(38, 128, 235, 1)"
}
},
title
)
]
);
},
//时间相关start
...
...
@@ -328,7 +357,9 @@ export default {
row
(
v
)
{
if
(
v
!=
null
)
{
this
.
orderSearchForm
=
this
.
$u
.
clone
(
this
.
row
);
this
.
placeholdeinfo
=
this
.
orderSearchForm
.
productName
;
//this.placeholdeinfo = this.orderSearchForm.productName;
this
.
list
=
[];
this
.
list
.
push
({
label
:
this
.
orderSearchForm
.
productName
,
value
:
this
.
orderSearchForm
.
productId
});
}
}
}
...
...
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