|
|
|
@ -5,7 +5,7 @@ |
|
|
|
<div> |
|
|
|
<div |
|
|
|
class="main" |
|
|
|
id="projectWorkloadSetDayList" |
|
|
|
id="projectWorkloadSetMonthList" |
|
|
|
style="width: 100%; height: 600px; margin: 0 auto" |
|
|
|
></div> |
|
|
|
</div> |
|
|
|
@ -58,7 +58,7 @@ |
|
|
|
:row-style="{ height: '50px' }" |
|
|
|
highlight-current-row |
|
|
|
v-loading="load.list" |
|
|
|
@row-click="rowClick" |
|
|
|
@row-click="rowClick" |
|
|
|
border |
|
|
|
style="width: 100%" |
|
|
|
:header-cell-style="{ 'text-align': 'center' }" |
|
|
|
@ -90,12 +90,14 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】所有工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='workload'" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="primary" slot="reference" >{{scope.row.workload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="primary" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'workload', '', '')" |
|
|
|
>{{ scope.row.workload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="toConfirmWorkload" |
|
|
|
@ -104,13 +106,15 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【待确认】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='toConfirmWorkload'" wstatus="0" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="primary" slot="reference" >{{scope.row.toConfirmWorkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="primary" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'toConfirmWorkload', '0', '')" |
|
|
|
>{{ scope.row.toConfirmWorkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="hadConfirmWorkload" |
|
|
|
@ -119,13 +123,15 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【已确认】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='hadConfirmWorkload'" wstatus="1" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="success" slot="reference" >{{scope.row.hadConfirmWorkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="success" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'hadConfirmWorkload', '1', '')" |
|
|
|
>{{ scope.row.hadConfirmWorkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="notNeedSetWorkload" |
|
|
|
@ -134,13 +140,15 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【无须结算】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='notNeedSetWorkload'" wstatus="1" sstatus="0" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="info" slot="reference" >{{scope.row.notNeedSetWorkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="info" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'notNeedSetWorkload', '1', '0')" |
|
|
|
>{{ scope.row.notNeedSetWorkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="toSetSworkload" |
|
|
|
@ -150,12 +158,14 @@ |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【待结算】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='toSetSworkload'" wstatus="1" sstatus="1" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="warning" slot="reference" >{{scope.row.toSetSworkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
<el-link |
|
|
|
type="warning" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'toSetSworkload', '1', '1')" |
|
|
|
>{{ scope.row.toSetSworkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="hadCommitSworkload" |
|
|
|
@ -164,14 +174,15 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【已提交审核】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='hadCommitSworkload'" wstatus="1" sstatus="2" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="primary" slot="reference" >{{scope.row.hadCommitSworkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
|
|
|
|
</template> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="primary" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'hadCommitSworkload', '1', '2')" |
|
|
|
>{{ scope.row.hadCommitSworkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="hadAgreeSworkload" |
|
|
|
@ -180,14 +191,16 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【已审核】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='hadAgreeSworkload'" wstatus="1" sstatus="3" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="primary" slot="reference" >{{scope.row.hadAgreeSworkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="primary" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'hadAgreeSworkload', '1', '3')" |
|
|
|
>{{ scope.row.hadAgreeSworkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="hadSetSworkload" |
|
|
|
label="已结算" |
|
|
|
@ -195,16 +208,37 @@ |
|
|
|
show-overflow-tooltip |
|
|
|
sortable |
|
|
|
> |
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
<el-popover :title="'【'+ scope.row.bizMonth + '】【已结算】工时记录'"> |
|
|
|
<xm-task-workload-simple-list-for-biz-month :visible="scope.row.bizMonth==editForm.bizMonth && columnProp=='hadSetSworkload'" wstatus="1" sstatus="4" :task-id="filters.taskId" :project-id="filters.project?filters.project.id:null" ref="xmTaskWorkloadSimpleList2" :biz-month="scope.row.bizMonth"></xm-task-workload-simple-list-for-biz-month> |
|
|
|
<el-link type="danger" slot="reference" >{{scope.row.hadSetSworkload}}h</el-link> |
|
|
|
</el-popover> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-link |
|
|
|
type="danger" |
|
|
|
slot="reference" |
|
|
|
style="display: inline" |
|
|
|
@click="showPopover(scope.row, 'hadSetSworkload', '1', '4')" |
|
|
|
>{{ scope.row.hadSetSworkload }}h</el-link |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</el-row> |
|
|
|
|
|
|
|
<el-dialog |
|
|
|
:title=" |
|
|
|
'【' + editForm.bizMonth + '】【' + stateName[columnProp] + '】工时记录' |
|
|
|
" |
|
|
|
append-to-body |
|
|
|
:visible.sync="workloadDialogVisible" |
|
|
|
top="20px" |
|
|
|
width="80%" |
|
|
|
> |
|
|
|
<xm-task-workload-simple-list-for-biz-date |
|
|
|
:visible="workloadDialogVisible" |
|
|
|
:wstatus="wstatus" |
|
|
|
:sstatus="sstatus" |
|
|
|
:task-id="filters.taskId" |
|
|
|
:project-id="filters.project ? filters.project.id : null" |
|
|
|
:biz-month="editForm.bizMonth" |
|
|
|
></xm-task-workload-simple-list-for-biz-date> |
|
|
|
</el-dialog> |
|
|
|
</section> |
|
|
|
</template> |
|
|
|
|
|
|
|
@ -215,10 +249,11 @@ import { mapGetters } from "vuex"; |
|
|
|
|
|
|
|
import XmProjectSelect from "@/views/xm/core/components/XmProjectSelect"; //新增界面 |
|
|
|
import { listProjectWorkloadSetMonth } from "@/api/xm/core/xmTaskWorkload"; |
|
|
|
import XmTaskWorkloadSimpleListForBizMonth from '@/views/xm/core/xmTaskWorkload/XmTaskWorkloadSimpleListForBizDate' |
|
|
|
import XmTaskWorkloadSimpleListForBizDate from "@/views/xm/core/xmTaskWorkload/XmTaskWorkloadSimpleListForBizDate"; |
|
|
|
export default { |
|
|
|
components: { |
|
|
|
XmProjectSelect,XmTaskWorkloadSimpleListForBizMonth, |
|
|
|
XmProjectSelect, |
|
|
|
XmTaskWorkloadSimpleListForBizDate, |
|
|
|
}, |
|
|
|
props: ["xmProduct", "xmProject", "queryScope"], |
|
|
|
computed: { |
|
|
|
@ -241,10 +276,16 @@ export default { |
|
|
|
], |
|
|
|
[ |
|
|
|
"待结算", |
|
|
|
...this.xmProjectWorkloadSetMonths.map((i) => i.toSetSworkload), |
|
|
|
...this.xmProjectWorkloadSetMonths.map((i) => i.toSetSWorkload), |
|
|
|
], |
|
|
|
[ |
|
|
|
"已提交审核", |
|
|
|
...this.xmProjectWorkloadSetMonths.map((i) => i.hadCommitSworkload), |
|
|
|
], |
|
|
|
[ |
|
|
|
"已审核", |
|
|
|
...this.xmProjectWorkloadSetMonths.map((i) => i.hadAgreeSworkload), |
|
|
|
], |
|
|
|
[ "已提交审核", ...this.xmProjectWorkloadSetMonths.map((i) => i.hadCommitSworkload), ], |
|
|
|
['已审核',...this.xmProjectWorkloadSetMonths.map(i=>i.hadAgreeSworkload)], |
|
|
|
[ |
|
|
|
"已结算", |
|
|
|
...this.xmProjectWorkloadSetMonths.map((i) => i.hadSetSworkload), |
|
|
|
@ -277,8 +318,28 @@ export default { |
|
|
|
maxTableHeight: 300, |
|
|
|
visible: false, |
|
|
|
xmProjectWorkloadSetMonths: [], |
|
|
|
editForm:{bizMonth:'',toConfirmWorkload:0,hadConfirmWorkload:0,toSetSWorkload:0,hadAgreeSworkload:0,hadCommitSworkload:0}, |
|
|
|
columnProp:'', |
|
|
|
editForm: { |
|
|
|
bizMonth: "", |
|
|
|
toConfirmWorkload: 0, |
|
|
|
hadConfirmWorkload: 0, |
|
|
|
toSetSWorkload: 0, |
|
|
|
hadAgreeSworkload: 0, |
|
|
|
hadCommitSworkload: 0, |
|
|
|
}, |
|
|
|
columnProp: "", |
|
|
|
workloadDialogVisible: false, |
|
|
|
wstatus: "", |
|
|
|
sstatus: "", |
|
|
|
stateName: { |
|
|
|
workload: "所有", |
|
|
|
toConfirmWorkload: "待确认", |
|
|
|
hadConfirmWorkload: "已确认", |
|
|
|
notNeedSetWorkload:'无需结算', |
|
|
|
toSetSworkload: "待结算", |
|
|
|
hadAgreeSworkload: "已审核待结算", |
|
|
|
hadCommitSworkload: "已提交待审核", |
|
|
|
hadSetSworkload: "已结算", |
|
|
|
}, |
|
|
|
}; //end return |
|
|
|
}, //end data |
|
|
|
methods: { |
|
|
|
@ -298,12 +359,12 @@ export default { |
|
|
|
if (this.filters.taskId) { |
|
|
|
params.taskId = this.filters.taskId; |
|
|
|
} |
|
|
|
this.load.list=true; |
|
|
|
this.load.list = true; |
|
|
|
listProjectWorkloadSetMonth(params).then((res) => { |
|
|
|
this.xmProjectWorkloadSetMonths = res.data.tips.isOk |
|
|
|
? res.data.data |
|
|
|
: this.xmProjectWorkloadSetMonths; |
|
|
|
this.load.list=false; |
|
|
|
this.load.list = false; |
|
|
|
}); |
|
|
|
}, |
|
|
|
initData() { |
|
|
|
@ -322,7 +383,7 @@ export default { |
|
|
|
}, |
|
|
|
drawCharts() { |
|
|
|
this.myChart = this.$echarts.init( |
|
|
|
document.getElementById("projectWorkloadSetDayList") |
|
|
|
document.getElementById("projectWorkloadSetMonthList") |
|
|
|
); |
|
|
|
var that = this; |
|
|
|
this.myChart.on("updateAxisPointer", function (event) { |
|
|
|
@ -397,13 +458,14 @@ export default { |
|
|
|
smooth: true, |
|
|
|
emphasis: { focus: "series" }, |
|
|
|
}, |
|
|
|
|
|
|
|
{ name:'已审核', |
|
|
|
type: 'line', |
|
|
|
seriesLayoutBy: 'row', |
|
|
|
smooth:true, |
|
|
|
emphasis: { focus: 'series' }, |
|
|
|
}, |
|
|
|
|
|
|
|
{ |
|
|
|
name: "已审核", |
|
|
|
type: "line", |
|
|
|
seriesLayoutBy: "row", |
|
|
|
smooth: true, |
|
|
|
emphasis: { focus: "series" }, |
|
|
|
}, |
|
|
|
{ |
|
|
|
name: "已结算", |
|
|
|
type: "line", |
|
|
|
@ -443,12 +505,18 @@ export default { |
|
|
|
|
|
|
|
this.xmProjectWorkloadSetMonths = []; |
|
|
|
}, |
|
|
|
rowClick(row, column, event){ |
|
|
|
this.editForm=row |
|
|
|
this.columnProp=column.property |
|
|
|
} |
|
|
|
rowClick(row, column, event) { |
|
|
|
this.editForm = row; |
|
|
|
this.columnProp = column.property; |
|
|
|
}, |
|
|
|
showPopover(row, fieldName, wstatus, sstatus) { |
|
|
|
this.editForm = row; |
|
|
|
this.workloadDialogVisible = true; |
|
|
|
this.wstatus = wstatus; |
|
|
|
this.sstatus = sstatus; |
|
|
|
}, |
|
|
|
}, //end method |
|
|
|
mounted() { |
|
|
|
mounted() { |
|
|
|
this.initData(); |
|
|
|
}, //end mounted |
|
|
|
}; |
|
|
|
|