Commit 61dbccc6 authored by 旭艳's avatar 旭艳

修改指令下发样式

parent 59f296ca
......@@ -33,19 +33,32 @@
</div>
<split-pane
:min-percent="18"
:default-percent="80"
:default-percent="defaultPercent"
split="vertical"
class="detail-pane"
>
<template slot="paneL">
<dee-tab :tabs="tabItems" @tabClick="tabClick">
<div slot="0" style="height:100%;box-sizing:border-box">
<dee-as-com
<!-- <dee-as-com
ref="detailComTo"
:key="layConfig.typeName"
:lay-config="layConfig"
:form="searchFormData"
/>
@row-click="rowClick"
/> -->
<dee-up-table
selection-row
:index-row="indexRow"
:columns="columns"
:data="tableData"
:pagination="pagination"
@pagination-current-change="paginationCurrentChange"
@pagination-size-change="handleSizeChange"
@selection-change="selectionChange"
>
<dee-tools slot="header" :tools="tools" mode="normal" />
</dee-up-table>
</div>
<div slot="1" style="height:100%;box-sizing:border-box">
<dee-as-com
......@@ -61,16 +74,16 @@
<div class="sub-title" style="margin:0 10px">
下发班组
</div>
<el-select v-model="group" size="small" placeholder="请选择" style="width:86%;margin:10px" filterable @change="changeGroup">
<!-- <el-select v-model="group" size="small" placeholder="请选择" style="width:86%;margin:10px" filterable @change="changeGroup">
<el-option
v-for="item in groupDropList"
:key="item.id"
:label="item.resName"
:value="item.id"
/>
</el-select>
</el-select> -->
<div class="group-list">
<div v-for="(item, index) in groupDropList" :key="index" class="group-list-box" :class="{'active': group===item.id}">
<div v-for="(item, index) in groupDropList" :key="index" class="group-list-box" :class="{'active': group===item.id}" @click="changeGroup(item)">
<div class="left">
<div class="left-text"> {{ item.resName }}</div>
</div>
......@@ -80,7 +93,19 @@
<div class="right-text"><span>未完成工时:</span><span>{{ item.notFinishWork }}(h)</span></div>
<div class="right-text"><span>当月完成任务:</span><span>{{ item.finishCount }}</span></div>
<div class="right-text"><span>当月完成工时:</span><span>{{ item.finishWork }}(h)</span></div>
<div class="right-text"><span>班组长:</span><span>{{ item.workType }}</span></div>
<el-tooltip placement="top">
<div slot="content">
<span v-for="user in item.extProcessSkillUsers" :key="user.id">
{{ user.dxUserInfo.name }}
</span>
</div>
<div class="right-text overfllowhind">
<span>班组长:</span>
<span v-for="user in item.extProcessSkillUsers" :key="user.id">
{{ user.dxUserInfo.name }}
</span>
</div>
</el-tooltip>
</div>
</div>
</div>
......@@ -100,13 +125,81 @@ export default {
postion: ''
},
group: '',
groupType: '',
groupDropList: [],
tableData: [],
activeName: 0,
// 开工状态
status: null,
title: '未开工',
wordImgUrl: '/icons/startWork1.png'
wordImgUrl: '/icons/startWork1.png',
defaultPercent: 80,
indexRow: {
title: '序号',
align: 'center',
width: '70'
},
columns: [
{ title: '机型', key: 'extProcessPlan.planeType', align: 'left' },
{ title: '架次', key: 'extProcessPlan.sorties', align: 'left' },
{ title: '站位', key: 'extProcessPlan.positionNumber', align: 'left' },
{ title: '指令号', key: 'extProcessPlan.serialNumber', align: 'left' },
{ title: '指令名称', key: 'extProcessPlan.name', align: 'left' },
{ title: '工时定额', key: 'extProcessPlan.workHour', align: 'left' },
{ title: '工艺员', key: 'extProcessPlan.note', align: 'left' },
{ title: '计划开始', key: 'scheduledStart', align: 'left' },
{ title: '计划结束', key: 'scheduledEnd', align: 'left' }
],
tableData: [],
pagination: {
currentPage: 1,
pageSize: 20,
total: 0,
pageSizes: [20, 50, 100]
},
tools: [
{
type: 'icon',
name: '下发',
icon: '/icons/o-Referencedoc.png',
handler: {
click: () => {
this.$confirm('您确认执行该操作吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
const arr = []
this.selectionRow.map(item => {
arr.push(
{
id: item.id,
operator: 'MODIFY',
planState: 'Issued',
extProcessSkillId: item.skill,
extProcessSkillIdType: item.skillType
}
)
})
post('/JoExecutePlan/recursions', arr)
.then((res) => {
this.$message({
type: 'success',
message: '提交成功!'
})
this.getInstructionsIssuedListTo()
})
.catch((err) => console.log(err))
.finally(() => {})
}).catch(() => {
// this.$message({
// type: 'info',
// message: '已取消'
// })
})
}
}
}
]
}
},
computed: {
......@@ -206,7 +299,6 @@ export default {
post('/AircraftSorties/search', params).then(res => {
if (res.items && res.items.content) {
this.sortiesData = res.items.content.map(row => {
console.log(1212, row)
return {
value: row.defCode,
label: row.defName,
......@@ -289,6 +381,11 @@ export default {
},
tabClick(tab) {
this.activeName = tab.index
if (this.activeName === '1') {
this.defaultPercent = 100
} else {
this.defaultPercent = 80
}
this.getTableData()
},
getTableData() {
......@@ -297,16 +394,89 @@ export default {
this.$refs.detailComAlready.$children[0].getData()
}
} else {
this.$refs.detailComTo.$children[0].getData()
this.getInstructionsIssuedListTo()
}
},
changeGroup() {
this.groupDropList.map((item, index) => {
if (item.id === this.group) {
this.groupDropList.unshift(this.groupDropList.splice(index, 1)[0])
getInstructionsIssuedListTo() {
const params = {
'pageFrom': this.pagination.currentPage,
'pageSize': this.pagination.pageSize,
'searchItems': {
'children': [
{
'items': [
{
'fieldName': 'extProcessPlan.sorties',
'operator': 'EQ',
'value': this.searchFormData.sortiesName
},
{
'fieldName': 'extProcessPlan.positionNumber',
'operator': 'EQ',
'value': this.searchFormData.postionName
},
{
'fieldName': 'planState',
'operator': 'EQ',
'value': 'Yes'
}
],
'operator': 'AND'
}
],
'items': [],
'operator': 'AND'
},
'openProps': [
{
'name': 'extProcessPlan',
'openProps': [
{
'name': 'extSupportings'
}
]
}
],
'sortItem': [
{
'fieldName': 'modifyTime',
'sortOrder': 'desc'
}
]
}
post('/JoExecutePlan/getProductionPrepare', params).then(res => {
if (res.items && res.items.content) {
this.tableData = res.items.content
// this.$set(this, 'group', res.items[0] && res.items[0].id || '')
}
})
},
paginationCurrentChange(currentPage) {
this.pagination.currentPage = currentPage
this.getInstructionsIssuedListTo()
},
handleSizeChange(pageSize) {
this.pagination.pageSize = pageSize
this.pagination.currentPage = 1
this.getInstructionsIssuedListTo()
},
selectionChange(val) {
val.forEach(element => {
element.skill = this.group
element.skillType = this.groupType
})
this.selectionRow = val
},
changeGroup(val) {
this.$set(this, 'group', val.id || '')
this.$set(this, 'groupType', val.subTypeName || '')
if (this.selectionRow.length > 0) {
this.selectionRow.forEach(element => {
element.skill = this.group
element.skillType = this.groupType
})
}
},
getGroupList() {
const params = {
'searchItems': {
......@@ -363,9 +533,10 @@ export default {
'toValidateKeys': ''
}
post('/ExtProcessSkill/getSkillWorkDetail', params).then(res => {
if (res.items) {
this.groupDropList = res.items
this.$set(this, 'group', res.items[0] && res.items[0].id || '')
if (res.items && res.items.content) {
this.groupDropList = res.items.content
this.$set(this, 'group', res.items.content[0] && res.items.content[0].id || '')
this.$set(this, 'groupType', res.items.content[0] && res.items.content[0].subTypeName || '')
}
})
},
......@@ -438,7 +609,7 @@ export default {
background: #ffff;
height: 100%;
.group-list{
height: calc(100% - 130px);
height: calc(100% - 100px);
overflow-y: scroll;
margin-bottom: 20px;
.group-list-box{
......@@ -462,6 +633,14 @@ export default {
.right-text{
padding-top: 8px;
}
.overfllowhind{
max-width: 100%;
word-break:keep-all;
white-space:nowrap;
overflow:hidden;
text-overflow:ellipsis;
}
}
}
.active{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment