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
3760a310
Commit
3760a310
authored
Oct 13, 2020
by
骆瑛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改排产工序生产设备样式
parent
0af9f71f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
44 additions
and
23 deletions
+44
-23
edit.vue
pages/aps/aps/components/edit.vue
+44
-23
No files found.
pages/aps/aps/components/edit.vue
View file @
3760a310
...
@@ -2,20 +2,28 @@
...
@@ -2,20 +2,28 @@
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"100"
>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"100"
>
<Row>
<Row>
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
:label=
"l('tASKSEQ')"
prop=
"tASKSEQ"
>
{{
this
.
entity
.
task_seq
}}
</FormItem>
<FormItem
:label=
"l('tASKSEQ')"
prop=
"tASKSEQ"
>
{{
this
.
entity
.
task_seq
}}
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
:label=
"l('tASKNAME')"
prop=
"tASKNAME"
>
{{
this
.
entity
.
task_name
}}
</FormItem>
<FormItem
:label=
"l('tASKNAME')"
prop=
"tASKNAME"
>
{{
this
.
entity
.
task_name
}}
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
label=
"生产设备"
>
<FormItem
label=
"生产设备"
>
<EquipSelect
v-model=
"entity.eQUIPID"
></EquipSelect>
<!--
<EquipSelect
v-model=
"entity.eQUIPID"
></EquipSelect>
-->
<ResourceSelect
v-model=
"entity.eQUIPID"
></ResourceSelect>
<!-- @on-change="resourceChange" -->
</FormItem>
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
v-model=
"entity.rUNTIME"
>
<Col
:span=
"12"
v-model=
"entity.rUNTIME"
>
<FormItem
:label=
"l('rUNTIME')"
prop=
"rUNTIME"
>
<FormItem
:label=
"l('rUNTIME')"
prop=
"rUNTIME"
>
<InputTime
v-model=
"entity.run_time"
></InputTime>
<InputTime
v-model=
"entity.run_time"
></InputTime>
</FormItem>
</FormItem>
</Col>
</Col>
<Col
:span=
"12"
>
<Col
:span=
"12"
>
...
@@ -36,13 +44,12 @@ export default {
...
@@ -36,13 +44,12 @@ export default {
name
:
"Edit"
,
name
:
"Edit"
,
data
()
{
data
()
{
return
{
return
{
entity
:
{},
entity
:
{},
orderCatList
:
[],
orderCatList
:
[],
rules
:
{
rules
:
{
name
:
[{
required
:
true
,
message
:
"必填"
,
trigger
:
"blur"
}]
name
:
[{
required
:
true
,
message
:
"必填"
,
trigger
:
"blur"
}]
,
},
},
single
:
false
single
:
false
,
};
};
},
},
props
:
{
props
:
{
...
@@ -50,24 +57,41 @@ export default {
...
@@ -50,24 +57,41 @@ export default {
type
:
Object
,
type
:
Object
,
default
:
()
=>
{
default
:
()
=>
{
return
null
;
return
null
;
}
}
,
}
}
,
},
},
methods
:
{
methods
:
{
resourceChange
(
v
,
items
)
{
// this.entity.resourceId = v[1];
// this.entity.resourceType = v[0];
// this.entity.resourceCode = items[1].__label;
// if (v != null) {
// this.rules.equipTypeId[0].required = false;
// this.rules.resourceType[0].required = true;
// } else {
// if (this.entity.equipTypeId != null && this.entity.equipTypeId > 0) {
// this.rules.equipTypeId[0].required = true;
// this.rules.resourceType[0].required = false;
// } else {
// this.rules.equipTypeId[0].required = true;
// this.rules.resourceType[0].required = true;
// }
// }
},
load
(
v
)
{
load
(
v
)
{
this
.
entity
=
v
;
this
.
entity
=
v
;
},
},
handleSubmit
()
{
handleSubmit
()
{
this
.
$refs
.
form
.
validate
(
v
=>
{
this
.
$refs
.
form
.
validate
(
(
v
)
=>
{
if
(
v
)
{
if
(
v
)
{
let
parmsUp
=
{
let
parmsUp
=
{
run_time
:
this
.
entity
.
run_time
,
run_time
:
this
.
entity
.
run_time
,
first_equip
:
this
.
entity
.
eQUIPID
,
first_equip
:
this
.
entity
.
eQUIPID
,
id
:
this
.
entity
.
id
id
:
this
.
entity
.
id
,
};
};
Api
.
updatesetuptimeandfirstequip
(
parmsUp
)
Api
.
updatesetuptimeandfirstequip
(
parmsUp
)
.
then
(
res
=>
{
.
then
(
(
res
)
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
if
(
!
this
.
single
)
{
if
(
!
this
.
single
)
{
this
.
$Message
.
success
(
"保存成功"
);
this
.
$Message
.
success
(
"保存成功"
);
...
@@ -79,11 +103,10 @@ export default {
...
@@ -79,11 +103,10 @@ export default {
task_seq
:
this
.
entity
.
task_seq
,
//工序号
task_seq
:
this
.
entity
.
task_seq
,
//工序号
resource_id
:
this
.
entity
.
eQUIPID
,
//设备id
resource_id
:
this
.
entity
.
eQUIPID
,
//设备id
runtime
:
this
.
entity
.
run_time
,
//单件工时
runtime
:
this
.
entity
.
run_time
,
//单件工时
department_id
:
0
//班组ID
department_id
:
0
,
//班组ID
};
};
Api
.
apsupdate
(
parms
)
Api
.
apsupdate
(
parms
)
.
then
(
r
=>
{
.
then
((
r
)
=>
{
if
(
r
.
success
)
{
if
(
r
.
success
)
{
this
.
$Message
.
success
(
"保存成功"
);
this
.
$Message
.
success
(
"保存成功"
);
this
.
$emit
(
"on-option-ok"
);
this
.
$emit
(
"on-option-ok"
);
...
@@ -91,8 +114,7 @@ export default {
...
@@ -91,8 +114,7 @@ export default {
this
.
$Message
.
error
(
"保存失败"
);
this
.
$Message
.
error
(
"保存失败"
);
}
}
})
})
.
catch
(
err
=>
{
.
catch
((
err
)
=>
{
this
.
$Message
.
error
(
"保存失败"
);
this
.
$Message
.
error
(
"保存失败"
);
console
.
warn
(
err
);
console
.
warn
(
err
);
});
});
...
@@ -101,8 +123,7 @@ export default {
...
@@ -101,8 +123,7 @@ export default {
this
.
$Message
.
error
(
"保存失败"
);
this
.
$Message
.
error
(
"保存失败"
);
}
}
})
})
.
catch
(
err
=>
{
.
catch
((
err
)
=>
{
this
.
$Message
.
error
(
"保存失败"
);
this
.
$Message
.
error
(
"保存失败"
);
console
.
warn
(
err
);
console
.
warn
(
err
);
});
});
...
@@ -115,7 +136,7 @@ export default {
...
@@ -115,7 +136,7 @@ export default {
l
(
key
)
{
l
(
key
)
{
key
=
"mes_op_task_execute"
+
"."
+
key
;
key
=
"mes_op_task_execute"
+
"."
+
key
;
return
this
.
$t
(
key
);
return
this
.
$t
(
key
);
}
}
,
},
},
watch
:
{
watch
:
{
row
(
v
)
{
row
(
v
)
{
...
@@ -123,7 +144,7 @@ export default {
...
@@ -123,7 +144,7 @@ export default {
//alert(JSON.stringify(v))
//alert(JSON.stringify(v))
this
.
entity
=
v
;
this
.
entity
=
v
;
}
}
}
}
,
}
}
,
};
};
</
script
>
</
script
>
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