Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
lxyl-vue
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
李苏
lxyl-vue
Commits
f8d39ca9
Commit
f8d39ca9
authored
May 23, 2024
by
李苏
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cell调整
parent
9463fe06
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
130 additions
and
104 deletions
+130
-104
index.vue
src/views/ccgl/wcsrwgl/wcsrw/index.vue
+130
-104
No files found.
src/views/ccgl/wcsrwgl/wcsrw/index.vue
View file @
f8d39ca9
...
@@ -35,10 +35,37 @@
...
@@ -35,10 +35,37 @@
saveSelected
:
false
saveSelected
:
false
},
},
config
:
{
config
:
{
cellStyle
({
row
,
column
,
})
{
// 定义样式变量
let
cellStyle
;
switch
(
row
.
zt
)
{
case
'W'
:
cellStyle
=
'color:#dcc40e'
;
break
;
case
'D'
:
cellStyle
=
'color:#76b82a'
;
break
;
case
'C'
:
cellStyle
=
'color:#60b5ff'
;
break
;
case
'CF'
:
cellStyle
=
'color:#666'
;
break
;
default
:
cellStyle
=
''
;
}
if
(
column
.
label
==
"状态"
)
{
return
cellStyle
}
},
/* 基本配置*/
/* 基本配置*/
url
:
'lxyl/wcs/wcsTask'
,
url
:
'lxyl/wcs/wcsTask'
,
tableTitle
:
[
tableTitle
:
[{
{
title
:
"状态"
,
title
:
"状态"
,
field
:
"zt"
,
field
:
"zt"
,
width
:
80
,
width
:
80
,
...
@@ -66,16 +93,16 @@
...
@@ -66,16 +93,16 @@
{
{
title
:
"起始位"
,
title
:
"起始位"
,
field
:
"gwName"
,
field
:
"gwName"
,
formatter
(
row
,
b
,
v
)
{
formatter
(
row
,
b
,
v
)
{
return
row
.
kwName
||
row
.
gwName
return
row
.
kwName
||
row
.
gwName
},
},
width
:
140
,
width
:
140
,
},
},
{
{
title
:
"目标位"
,
title
:
"目标位"
,
field
:
"mbkwCode"
,
field
:
"mbkwCode"
,
formatter
(
row
,
b
,
v
)
{
formatter
(
row
,
b
,
v
)
{
return
row
.
mbkwCode
||
row
.
mbgwCode
||
row
.
gwName
return
row
.
mbkwCode
||
row
.
mbgwCode
||
row
.
gwName
},
},
width
:
140
,
width
:
140
,
},
},
...
@@ -197,8 +224,7 @@
...
@@ -197,8 +224,7 @@
],
],
[
[{
{
label
:
'任务号'
,
label
:
'任务号'
,
prop
:
'djid'
,
prop
:
'djid'
,
span
:
8
,
span
:
8
,
...
@@ -235,72 +261,72 @@
...
@@ -235,72 +261,72 @@
},
},
methods
:
{
methods
:
{
execute
(
ctx
){
execute
(
ctx
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
this
.
$confirm
(
'确定要重新执行任务吗?'
,
'提示'
,
{
this
.
$confirm
(
'确定要重新执行任务吗?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(
res
=>
{
}).
then
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
true
ctx
.
$refs
.
TablePager
.
loading
=
true
this
.
$post
(
'lxyl/wcs/wcsTask/start'
,
{
this
.
$post
(
'lxyl/wcs/wcsTask/start'
,
{
id
:
ctx
.
singleItem
.
id
id
:
ctx
.
singleItem
.
id
}).
then
(
res
=>
{
}).
then
(
res
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
this
.
$success
(
'操作成功'
)
this
.
$success
(
'操作成功'
)
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
refresh
()
ctx
.
refresh
()
}
}
}).
finally
(
res
=>
{
}).
finally
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
})
})
})
})
}
else
{
}
else
{
this
.
$warning
(
'请选中一条数据'
)
this
.
$warning
(
'请选中一条数据'
)
}
}
},
},
close
(
ctx
){
close
(
ctx
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
this
.
$confirm
(
'确定要关闭任务吗?'
,
'提示'
,
{
this
.
$confirm
(
'确定要关闭任务吗?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(
res
=>
{
}).
then
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
true
ctx
.
$refs
.
TablePager
.
loading
=
true
this
.
$post
(
'lxyl/wcs/wcsTask/close'
,
{
this
.
$post
(
'lxyl/wcs/wcsTask/close'
,
{
id
:
ctx
.
singleItem
.
id
id
:
ctx
.
singleItem
.
id
}).
then
(
res
=>
{
}).
then
(
res
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
this
.
$success
(
'操作成功'
)
this
.
$success
(
'操作成功'
)
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
refresh
()
ctx
.
refresh
()
}
}
}).
finally
(
res
=>
{
}).
finally
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
})
})
})
})
}
else
{
}
else
{
this
.
$warning
(
'请选中一条数据'
)
this
.
$warning
(
'请选中一条数据'
)
}
}
},
},
complete
(
ctx
){
complete
(
ctx
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
if
(
ctx
.
singleItem
&&
ctx
.
singleItem
.
id
)
{
this
.
$confirm
(
'确定要完成任务吗?'
,
'提示'
,
{
this
.
$confirm
(
'确定要完成任务吗?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
type
:
'warning'
}).
then
(
res
=>
{
}).
then
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
true
ctx
.
$refs
.
TablePager
.
loading
=
true
this
.
$post
(
'lxyl/wcs/wcsTask/complete'
,
{
this
.
$post
(
'lxyl/wcs/wcsTask/complete'
,
{
id
:
ctx
.
singleItem
.
id
id
:
ctx
.
singleItem
.
id
}).
then
(
res
=>
{
}).
then
(
res
=>
{
if
(
res
.
success
)
{
if
(
res
.
success
)
{
this
.
$success
(
'操作成功'
)
this
.
$success
(
'操作成功'
)
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
refresh
()
ctx
.
refresh
()
}
}
}).
finally
(
res
=>
{
}).
finally
(
res
=>
{
ctx
.
$refs
.
TablePager
.
loading
=
false
ctx
.
$refs
.
TablePager
.
loading
=
false
})
})
})
})
}
else
{
}
else
{
...
...
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