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
54059f9d
Commit
54059f9d
authored
Apr 29, 2020
by
康振飞
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
层级&工步
parent
7b229c05
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
255 additions
and
132 deletions
+255
-132
add.vue
pages/technology/details/routingStep/add.vue
+214
-124
edit.vue
pages/technology/details/routingStep/edit.vue
+31
-3
index.vue
pages/technology/details/routingStep/index.vue
+9
-4
index.vue
pages/technology/index.vue
+1
-1
No files found.
pages/technology/details/routingStep/add.vue
View file @
54059f9d
<
template
>
<Form
ref=
"form"
:model=
"entity"
:rules=
"rules"
:label-width=
"90"
>
<Row>
<Col
:span=
"12"
><FormItem
:label=
"l('creationTime')"
prop=
"creationTime"
>
<DatePicker
type=
"date"
v-model=
"entity.creationTime"
></DatePicker>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('creatorUserId')"
prop=
"creatorUserId"
>
<InputNumber
v-model=
"entity.creatorUserId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('lastModificationTime')"
prop=
"lastModificationTime"
>
<DatePicker
type=
"date"
v-model=
"entity.lastModificationTime"
></DatePicker>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('lastModifierUserId')"
prop=
"lastModifierUserId"
>
<InputNumber
v-model=
"entity.lastModifierUserId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('isDeleted')"
prop=
"isDeleted"
>
<Input
v-model=
"entity.isDeleted"
>
</Input>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('deleterUserId')"
prop=
"deleterUserId"
>
<InputNumber
v-model=
"entity.deleterUserId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('deletionTime')"
prop=
"deletionTime"
>
<DatePicker
type=
"date"
v-model=
"entity.deletionTime"
></DatePicker>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('routingHeaderId')"
prop=
"routingHeaderId"
>
<InputNumber
v-model=
"entity.routingHeaderId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('routingDetailId')"
prop=
"routingDetailId"
>
<InputNumber
v-model=
"entity.routingDetailId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('classId')"
prop=
"classId"
>
<InputNumber
v-model=
"entity.classId"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('stepSeq')"
prop=
"stepSeq"
>
<InputNumber
v-model=
"entity.stepSeq"
></InputNumber>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('name')"
prop=
"name"
>
<Input
v-model=
"entity.name"
>
</Input>
</FormItem></Col>
<Col
:span=
"24"
><FormItem
:label=
"l('description')"
prop=
"description"
>
<Input
v-model=
"entity.description"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('status')"
prop=
"status"
>
<Dictionary
code=
"Process.Status"
v-model=
"entity.status"
></Dictionary>
</FormItem></Col>
<Col
:span=
"24"
><FormItem
:label=
"l('remark')"
prop=
"remark"
>
<Input
v-model=
"entity.remark"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem></Col>
<Col
:span=
"24"
><FormItem
:label=
"l('stepContent')"
prop=
"stepContent"
>
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem></Col>
<Col
:span=
"12"
><FormItem
:label=
"l('extend')"
prop=
"extend"
>
<Input
v-model=
"entity.extend"
>
</Input>
</FormItem></Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('routingHeaderId')"
prop=
"routingHeaderId"
>
<InputNumber
style=
"width:200px"
v-model=
"entity.routingHeaderId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('routingDetailId')"
prop=
"routingDetailId"
>
<InputNumber
style=
"width:200px"
v-model=
"entity.routingDetailId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('stepSeq')"
prop=
"stepSeq"
>
<!--
<InputNumber
v-model=
"entity.stepSeq"
></InputNumber>
-->
<Input
style=
"width:300px"
v-model=
"entity.stepSeq"
></Input>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('name')"
prop=
"name"
>
<Input
style=
"width:350px"
v-model=
"entity.name"
></Input>
</FormItem>
</Col>
<Col
:span=
"24"
>
<FormItem
:label=
"l('stepContent')"
prop=
"stepContent"
>
<i-quill
v-model=
"entity.stepContent"
:height=
"260"
v-paste=
"handleImg"
/>
<!--
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:rows=
"5"
></Input>
-->
<!--
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:minRows=
"3"
,
:maxRows=
"7"
></Input>
-->
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('status')"
prop=
"status"
>
<RadioGroup
v-model=
"entity.status"
>
<Radio
:label=
"1"
>
是
</Radio>
<Radio
:label=
"0"
>
否
</Radio>
</RadioGroup>
<!--
<Dictionary
style=
"width:100px"
code=
"Process.Status"
v-model=
"entity.status"
></Dictionary>
-->
</FormItem>
</Col>
<!--
<Col
:span=
"24"
>
<FormItem
:label=
"l('description')"
prop=
"description"
>
<Input
v-model=
"entity.description"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('creationTime')"
prop=
"creationTime"
>
<DatePicker
type=
"date"
v-model=
"entity.creationTime"
></DatePicker>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('creatorUserId')"
prop=
"creatorUserId"
>
<InputNumber
v-model=
"entity.creatorUserId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('lastModificationTime')"
prop=
"lastModificationTime"
>
<DatePicker
type=
"date"
v-model=
"entity.lastModificationTime"
></DatePicker>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('lastModifierUserId')"
prop=
"lastModifierUserId"
>
<InputNumber
v-model=
"entity.lastModifierUserId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('isDeleted')"
prop=
"isDeleted"
>
<Input
v-model=
"entity.isDeleted"
></Input>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('deleterUserId')"
prop=
"deleterUserId"
>
<InputNumber
v-model=
"entity.deleterUserId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('deletionTime')"
prop=
"deletionTime"
>
<DatePicker
type=
"date"
v-model=
"entity.deletionTime"
></DatePicker>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('classId')"
prop=
"classId"
>
<InputNumber
v-model=
"entity.classId"
></InputNumber>
</FormItem>
</Col>
<Col
:span=
"24"
>
<FormItem
:label=
"l('remark')"
prop=
"remark"
>
<Input
v-model=
"entity.remark"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem>
</Col>
<Col
:span=
"12"
>
<FormItem
:label=
"l('extend')"
prop=
"extend"
>
<Input
v-model=
"entity.extend"
></Input>
</FormItem>
</Col>
-->
</Row>
</Row>
<FormItem>
<Button
type=
"primary"
@
click=
"handleSubmit"
:disabled=
"disabled"
>
保存
</Button>
<Button
@
click=
"handleClose"
class=
"ml20"
>
取消
</Button>
</FormItem>
</Form>
</
template
>
</
template
>
<
script
>
import
Api
from
'./api'
export
default
{
name
:
'Add'
,
import
Api
from
"./api"
;
import
iQuill
from
'@/components/quill'
export
default
{
name
:
"Add"
,
components
:
{
iQuill
},
data
()
{
return
{
disabled
:
false
,
entity
:
{
creationTime
:
null
,
creatorUserId
:
null
,
lastModificationTime
:
null
,
lastModifierUserId
:
null
,
isDeleted
:
null
,
deleterUserId
:
null
,
deletionTime
:
null
,
routingHeaderId
:
null
,
routingDetailId
:
null
,
classId
:
null
,
stepSeq
:
null
,
name
:
""
,
description
:
""
,
status
:
null
,
remark
:
""
,
stepContent
:
""
,
extend
:
""
},
entity
:
{
creationTime
:
null
,
creatorUserId
:
null
,
lastModificationTime
:
null
,
lastModifierUserId
:
null
,
isDeleted
:
null
,
deleterUserId
:
null
,
deletionTime
:
null
,
routingHeaderId
:
null
,
routingDetailId
:
null
,
classId
:
null
,
stepSeq
:
null
,
name
:
""
,
description
:
""
,
status
:
null
,
remark
:
""
,
stepContent
:
""
,
extend
:
""
},
rules
:
{
name
:
[{
required
:
true
,
message
:
'必填'
,
trigger
:
'blur'
}]
}
name
:
[{
required
:
true
,
message
:
"必填"
,
trigger
:
"blur"
}]
}
};
},
props
:
{
v
:
Object
,
...
...
@@ -82,27 +149,50 @@ extend: ""},
},
methods
:
{
handleSubmit
()
{
this
.
$refs
.
form
.
validate
((
v
)
=>
{
this
.
$refs
.
form
.
validate
(
v
=>
{
if
(
v
)
{
this
.
disabled
=
true
;
Api
.
create
(
this
.
entity
).
then
((
r
)
=>
{
Api
.
create
(
this
.
entity
)
.
then
(
r
=>
{
this
.
disabled
=
false
;
if
(
r
.
success
)
{
this
.
$Message
.
success
(
'保存成功'
)
this
.
$emit
(
'on-ok'
)
this
.
$Message
.
success
(
"保存成功"
);
this
.
$emit
(
"on-ok"
);
}
else
{
this
.
$Message
.
error
(
'保存失败'
)
this
.
$Message
.
error
(
"保存失败"
);
}
}).
catch
(
err
=>
{
this
.
disabled
=
false
;
this
.
$Message
.
error
(
'保存失败'
)
console
.
warn
(
err
)
})
.
catch
(
err
=>
{
this
.
disabled
=
false
;
this
.
$Message
.
error
(
"保存失败"
);
console
.
warn
(
err
);
});
}
})
});
},
handleImg
(
e
)
{
console
.
warn
(
e
)
// let file = null
// if (
// e.clipboardData &&
// e.clipboardData.items[0] &&
// e.clipboardData.items[0].type &&
// e.clipboardData.items[0].type.indexOf('image') > -1
// ) {
// //这里就是判断是否有粘贴进来的文件且文件为图片格式
// file = e.clipboardData.items[0].getAsFile()
// let reader = new FileReader()
// reader.readAsDataURL(file)
// setTimeout(() => {
// var img = '
<
img
src
=
"' + reader.result + '"
alt
=
""
/>
'
// this.bugForm.content += img
// }, 1000)
// // new R
// }
},
handleClose() {
this
.
$emit
(
'on-close'
)
this.$emit("on-close");
},
load(v) {
Api.get({ id: v }).then(r => {
...
...
@@ -112,12 +202,12 @@ extend: ""},
},
l(key) {
key = "routing_step" + "." + key;
return
this
.
$t
(
key
)
return this.$t(key);
}
},
watch: {
v() {
this
.
entity
=
this
.
$u
.
clone
(
this
.
v
)
this.entity = this.$u.clone(this.v);
},
eid(v) {
if (v > 0) {
...
...
@@ -125,5 +215,5 @@ extend: ""},
}
}
}
}
</
script
>
\ No newline at end of file
};
</
script
>
\ No newline at end of file
pages/technology/details/routingStep/edit.vue
View file @
54059f9d
...
...
@@ -14,7 +14,12 @@
</Col>
<Col
:span=
"24"
>
<FormItem
:label=
"l('stepContent')"
prop=
"stepContent"
>
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:rows=
"5"
></Input>
<i-quill
v-model=
"entity.stepContent"
:height=
"260"
v-paste=
"handleImg"
/>
<!--
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:rows=
"5"
></Input>
-->
<!--
<Input
v-model=
"entity.stepContent"
type=
"textarea"
:minRows=
"3"
,
:maxRows=
"7"
></Input>
-->
</FormItem>
</Col>
...
...
@@ -27,12 +32,12 @@
<!--
<Dictionary
style=
"width:100px"
code=
"Process.Status"
v-model=
"entity.status"
></Dictionary>
-->
</FormItem>
</Col>
<Col
:span=
"24"
>
<
!--
<
Col
:span=
"24"
>
<FormItem
:label=
"l('description')"
prop=
"description"
>
<Input
v-model=
"entity.description"
type=
"textarea"
:rows=
"5"
></Input>
</FormItem>
</Col>
<
!--
<
Col
:span=
"12"
>
<Col
:span=
"12"
>
<FormItem
:label=
"l('creationTime')"
prop=
"creationTime"
>
<DatePicker
type=
"date"
v-model=
"entity.creationTime"
></DatePicker>
</FormItem>
...
...
@@ -101,8 +106,10 @@
</
template
>
<
script
>
import
Api
from
"./api"
;
import
iQuill
from
'@/components/quill'
export
default
{
name
:
"Edit"
,
components
:
{
iQuill
},
data
()
{
return
{
disabled
:
false
,
...
...
@@ -150,6 +157,27 @@ export default {
}
});
},
handleImg
(
e
)
{
console
.
warn
(
e
)
// let file = null
// if (
// e.clipboardData &&
// e.clipboardData.items[0] &&
// e.clipboardData.items[0].type &&
// e.clipboardData.items[0].type.indexOf('image') > -1
// ) {
// //这里就是判断是否有粘贴进来的文件且文件为图片格式
// file = e.clipboardData.items[0].getAsFile()
// let reader = new FileReader()
// reader.readAsDataURL(file)
// setTimeout(() => {
// var img = '
<
img
src
=
"' + reader.result + '"
alt
=
""
/>
'
// this.bugForm.content += img
// }, 1000)
// // new R
// }
},
handleClose() {
this.$emit("on-close");
},
...
...
pages/technology/details/routingStep/index.vue
View file @
54059f9d
...
...
@@ -81,13 +81,13 @@ export default {
{
key
:
"routingHeaderId"
,
title
:
this
.
l
(
"routingHeaderId"
),
hi
de
:
true
,
hi
gh
:
true
,
align
:
"left"
},
{
key
:
"routingDetailId"
,
title
:
this
.
l
(
"routingDetailId"
),
hi
de
:
true
,
hi
gh
:
true
,
align
:
"left"
},
{
key
:
"classId"
,
title
:
this
.
l
(
"classId"
),
hide
:
true
,
align
:
"left"
},
...
...
@@ -103,8 +103,13 @@ export default {
key
:
"description"
,
title
:
this
.
l
(
"description"
),
align
:
"left"
,
easy
:
true
,
high
:
true
hide
:
true
},
{
key
:
"stepContent"
,
title
:
this
.
l
(
"stepContent"
),
align
:
"left"
,
hide
:
true
},
{
key
:
"status"
,
...
...
pages/technology/index.vue
View file @
54059f9d
...
...
@@ -16,7 +16,7 @@
right: 0;
// bottom:100%;
// right: 100%;
z-index:
990
;
z-index:
898
;
background-color: white;
// background: red;
.top {
...
...
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