Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
T
TF-MOM-WEB
Project
Project
Details
Activity
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
TFMOM
TF-MOM-WEB
Commits
ae2fec0c
Commit
ae2fec0c
authored
Aug 09, 2023
by
arvin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
装配单元路线 设置排序
parent
2e599a44
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
628 additions
and
83 deletions
+628
-83
gatt.vue
...-mes/src/privateComponents/components/MBOMConfig/gatt.vue
+8
-8
sortUnit.vue
.../src/privateComponents/components/MBOMConfig/sortUnit.vue
+109
-0
step.vue
...-mes/src/privateComponents/components/MBOMConfig/step.vue
+1
-4
unit.vue
...-mes/src/privateComponents/components/MBOMConfig/unit.vue
+506
-12
view.vue
...-mes/src/privateComponents/components/MBOMConfig/view.vue
+4
-59
No files found.
applications/dee-mes/src/privateComponents/components/MBOMConfig/gatt.vue
View file @
ae2fec0c
...
...
@@ -9,9 +9,9 @@
<dee-tools
mode=
"normal"
:tools=
"tools"
/>
</div>
<div
class=
"content-model"
>
<step
ref=
"ExtPosition"
v-show=
"viewType === 'ExtPosition'
"
:show-flag=
"viewType === 'ExtPosition'"
:node=
"node"
/>
<unit
ref=
"unit"
v-show=
"viewType === 'unit'
"
:show-flag=
"viewType === 'unit'"
:node=
"node"
/>
<view2
ref=
"AircraftSorties"
v-show=
"viewType === 'AircraftSorties'
"
:show-flag=
"viewType === 'AircraftSorties'"
:node=
"node"
/>
<step
v-if=
"viewType === 'ExtPosition'"
ref=
"ExtPosition
"
:show-flag=
"viewType === 'ExtPosition'"
:node=
"node"
/>
<unit
v-if=
"viewType === 'unit'"
ref=
"unit
"
:show-flag=
"viewType === 'unit'"
:node=
"node"
/>
<view2
v-if=
"viewType === 'AircraftSorties'"
ref=
"AircraftSorties
"
:show-flag=
"viewType === 'AircraftSorties'"
:node=
"node"
/>
</div>
</div>
</
template
>
...
...
@@ -73,7 +73,7 @@ export default {
icon
:
'/icons/check.png'
,
handler
:
{
click
:
()
=>
{
this
.
config
()
this
.
settings
()
}
}
})
...
...
@@ -102,13 +102,13 @@ export default {
this
.
node
=
params
},
export
()
{
this
.
$refs
[
this
.
viewType
].
export
()
this
.
$refs
[
this
.
viewType
].
export
&&
this
.
$refs
[
this
.
viewType
].
export
()
},
save
()
{
this
.
$refs
[
this
.
viewType
].
save
()
this
.
$refs
[
this
.
viewType
].
save
&&
this
.
$refs
[
this
.
viewType
].
save
()
},
config
()
{
this
.
$refs
[
this
.
viewType
].
config
()
settings
()
{
this
.
$refs
[
this
.
viewType
].
settings
&&
this
.
$refs
[
this
.
viewType
].
settings
()
}
}
}
...
...
applications/dee-mes/src/privateComponents/components/MBOMConfig/sortUnit.vue
0 → 100644
View file @
ae2fec0c
<
template
>
<dee-dialog
title=
"设置排序"
:dialog-visible
.
sync=
"visibleSort"
width=
"500px"
:before-close=
"()=>
{$emit('close')}"
close-on-click-modal
>
<div>
<el-button
type=
"text"
@
click=
"selectAll"
>
全选
</el-button>
<el-button
type=
"text"
@
click=
"selectNothings"
>
全清
</el-button>
<el-button
type=
"text"
@
click=
"selectToggle"
>
反选
</el-button>
<el-tree
v-if=
"visibleSort"
ref=
"treeSort"
:data=
"unitList"
node-key=
"id"
show-checkbox
draggable
:allow-drop=
"collapseSort"
@
node-drop=
"nodeDrop"
>
<span
slot-scope=
"
{ node, data }" class="custom-tree-node">
<span>
{{
node
.
label
}}
</span>
序号:
<el-input
v-model=
"data.sort"
:style=
"
{width:'50px'}" size="mini" @change="changeSort($event,data)" />
</span>
</el-tree>
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
@
click=
"saveSort"
>
确 定
</el-button>
<el-button
@
click=
"()=>
{$emit('close')}">取 消
</el-button>
</span>
</dee-dialog>
</
template
>
<
script
>
export
default
{
name
:
'TfMomWebSortUnit'
,
props
:
{
unitList
:
{
type
:
Array
,
default
:
()
=>
[]
},
dialogFlag
:
{
type
:
Boolean
,
default
:
false
}
},
data
()
{
return
{
visibleSort
:
false
}
},
watch
:
{
dialogFlag
(
val
)
{
this
.
visibleSort
=
val
},
visibleSort
(
val
)
{
!
val
&&
this
.
$emit
(
'close'
)
}
},
mounted
()
{
},
methods
:
{
selectAll
()
{
const
ids
=
this
.
unitList
.
map
(
r
=>
r
.
id
)
this
.
$refs
.
treeSort
.
setCheckedKeys
(
ids
)
},
selectNothings
()
{
this
.
$refs
.
treeSort
.
setCheckedKeys
([])
},
selectToggle
()
{
const
ids
=
this
.
unitList
.
map
(
r
=>
r
.
id
)
const
checkedIds
=
this
.
$refs
.
treeSort
.
getCheckedKeys
()
const
selecteds
=
ids
.
filter
(
r
=>
!
checkedIds
.
includes
(
r
))
this
.
$refs
.
treeSort
.
setCheckedKeys
(
selecteds
)
},
collapseSort
(
draggingNode
,
dropNode
,
type
)
{
return
type
!==
'inner'
},
nodeDrop
()
{
this
.
unitList
.
forEach
((
p
,
index
)
=>
{
p
.
sort
=
index
+
1
p
.
defaultSort
=
index
+
1
})
},
saveSort
()
{
var
params
=
this
.
$refs
.
treeSort
.
getCheckedNodes
().
map
((
p
,
index
)
=>
{
return
{
operator
:
'MODIFY'
,
id
:
p
.
id
,
dictSeq
:
index
}
})
this
.
$api
.
recursion
(
'ExtProcessPlan'
,
params
,
true
).
then
(()
=>
{
this
.
$emit
(
'refresh'
)
this
.
$emit
(
'close'
)
})
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
</
style
>
applications/dee-mes/src/privateComponents/components/MBOMConfig/step.vue
View file @
ae2fec0c
...
...
@@ -232,9 +232,6 @@ export default {
}
ganttAg
.
clearAll
()
ganttAg
.
parse
(
data
)
setTimeout
(()
=>
{
ganttAg
.
autoSchedule
()
},
1000
)
}
})
// 在将新链接添加到甘特图之前触发
...
...
@@ -254,7 +251,7 @@ export default {
refreshGantt
()
{
const
val
=
this
.
ganttData
if
(
!
val
||
!
val
.
length
)
{
this
.
gantt
.
parse
({
data
:
[]
}
)
this
.
gantt
.
clearAll
(
)
return
}
const
params
=
{
...
...
applications/dee-mes/src/privateComponents/components/MBOMConfig/unit.vue
View file @
ae2fec0c
This diff is collapsed.
Click to expand it.
applications/dee-mes/src/privateComponents/components/MBOMConfig/view.vue
View file @
ae2fec0c
...
...
@@ -41,65 +41,7 @@ export default {
}
},
computed
:
{
columns
()
{
const
ganttIns
=
this
.
gantt
return
[
{
name
:
''
,
label
:
'节点'
,
align
:
'left'
,
width
:
60
,
resize
:
true
,
template
:
function
(
task
)
{
return
(
"<span class='gantt_grid_wbs'>"
+
(
ganttIns
.
getWBSCode
(
task
)
||
''
)
+
'</span>'
)
}
},
{
name
:
'text'
,
label
:
'站位号'
,
align
:
'left'
,
width
:
160
,
tree
:
true
,
resize
:
true
},
{
name
:
'edition'
,
label
:
'版本'
,
align
:
'center'
,
width
:
50
,
resize
:
true
},
{
name
:
'duration'
,
label
:
'工期(时)'
,
align
:
'center'
,
width
:
60
,
resize
:
true
,
template
:
function
(
task
)
{
return
Math
.
round
((
task
.
duration
||
0
)
/
(
3
*
60
))
}
},
{
name
:
'predecessors'
,
label
:
'前置'
,
width
:
60
,
align
:
'center'
,
template
:
function
(
task
)
{
var
links
=
task
.
$target
var
labels
=
[]
for
(
var
i
=
0
;
i
<
links
.
length
;
i
++
)
{
var
link
=
ganttIns
.
getLink
(
links
[
i
])
var
label
=
ganttIns
.
getWBSCode
(
ganttIns
.
getTask
(
link
.
source
))
if
(
!
labels
.
includes
(
label
))
{
labels
.
push
(
label
)
}
}
return
"<span class='gantt_grid_predecessors'>"
+
labels
.
join
(
', '
)
+
'</span>'
}
}
]
}
},
watch
:
{
...
...
@@ -203,6 +145,9 @@ export default {
}
},
getData
()
{
if
(
this
.
loading
&&
(
this
.
currentId
===
this
.
node
.
id
))
{
return
}
this
.
currentId
=
this
.
node
.
id
this
.
gantt
.
clearAll
()
if
(
!
this
.
node
||
!
this
.
node
.
children
.
length
)
{
...
...
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