|
@@ -31,6 +31,8 @@
|
|
|
|
|
|
<el-menu-item index="1-10" v-if="permissions.reportAllTimely || permissions.reportTimely"><p @click="ssl(9)">员工填报及时率</p></el-menu-item>
|
|
<el-menu-item index="1-10" v-if="permissions.reportAllTimely || permissions.reportTimely"><p @click="ssl(9)">员工填报及时率</p></el-menu-item>
|
|
<el-menu-item index="1-11" v-if="permissions.reportAuditRate"><p @click="ssl(10)">日报待审核统计</p></el-menu-item>
|
|
<el-menu-item index="1-11" v-if="permissions.reportAuditRate"><p @click="ssl(10)">日报待审核统计</p></el-menu-item>
|
|
|
|
+ <el-menu-item index="1-12" v-if="permissions.reportPersonnel || permissions.reportResponsible"><p @click="ssl(11)">人员工时统计表</p></el-menu-item>
|
|
|
|
+ <!-- <el-menu-item index="1-12"><p @click="ssl(11)">人员工时统计表</p></el-menu-item> -->
|
|
</el-submenu>
|
|
</el-submenu>
|
|
</el-menu>
|
|
</el-menu>
|
|
</el-col>
|
|
</el-col>
|
|
@@ -63,7 +65,7 @@
|
|
</el-select>
|
|
</el-select>
|
|
</template>
|
|
</template>
|
|
<!-- 时间段筛选 -->
|
|
<!-- 时间段筛选 -->
|
|
- <template v-if="ins == 6 || ins == 8 || ins == 9 || ins == 10">
|
|
|
|
|
|
+ <template v-if="ins == 6 || ins == 8 || ins == 9 || ins == 10 || ins == 11">
|
|
<span class="demonstration" style="color:#999;padding:0 10px">时间段</span>
|
|
<span class="demonstration" style="color:#999;padding:0 10px">时间段</span>
|
|
<el-date-picker v-model="rangeDatas" type="daterange" value-format="yyyy-MM-dd" placeholder="选择开始日期" @change="picks()" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" style="width:300px" :clearable="false" size="small"> </el-date-picker>
|
|
<el-date-picker v-model="rangeDatas" type="daterange" value-format="yyyy-MM-dd" placeholder="选择开始日期" @change="picks()" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" style="width:300px" :clearable="false" size="small"> </el-date-picker>
|
|
</template>
|
|
</template>
|
|
@@ -74,7 +76,7 @@
|
|
<el-option label="查看部门审核人" :value="0"></el-option>
|
|
<el-option label="查看部门审核人" :value="0"></el-option>
|
|
</el-select> -->
|
|
</el-select> -->
|
|
<!-- 项目筛选 -->
|
|
<!-- 项目筛选 -->
|
|
- <el-select v-if="ins != 4 && ins != 8 && ins != 9 && ins != 10" v-model="proJuctId" placeholder="请选择项目" clearable filterable size="small" @change="selcts()" style="margin-left:10px">
|
|
|
|
|
|
+ <el-select v-if="ins != 4 && ins != 8 && ins != 9 && ins != 10 && ins != 11" v-model="proJuctId" placeholder="请选择项目" clearable filterable size="small" @change="selcts()" style="margin-left:10px">
|
|
<el-option v-for="(item) in proListOvertime" :key="item.id" :label="item.projectName + (item.projectCode ? item.projectCode : '')" :value="item.id">
|
|
<el-option v-for="(item) in proListOvertime" :key="item.id" :label="item.projectName + (item.projectCode ? item.projectCode : '')" :value="item.id">
|
|
<span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
|
|
<span style="float: left;color: #8492a6;">{{ item.projectCode }}</span>
|
|
<span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
|
|
<span style="float: right;font-size: 13px;margin-left: 20px">{{ item.projectName }}</span>
|
|
@@ -82,13 +84,19 @@
|
|
</el-select>
|
|
</el-select>
|
|
|
|
|
|
<!-- 部门筛选 -->
|
|
<!-- 部门筛选 -->
|
|
- <el-cascader v-if="(ins == 9 && permissions.reportAllTimely) || (ins == 8 && permissions.reportAllTimeDivide) || (ins == 6 && permissions.reportAllOvertime)" v-model="departmentIdArray" :options="departmentList" placeholder="请选择部门"
|
|
|
|
|
|
+ <el-cascader v-if="(ins == 9 && (permissions.reportAllTimely || permissions.reportTimely)) || (ins == 8 && (permissions.reportAllTimeDivide || permissions.reportTimeDivide)) || (ins == 6 && (permissions.reportAllOvertime || permissions.reportOvertime)) || (ins == 11 && (permissions.reportPersonnel || permissions.reportResponsible))" v-model="departmentIdArray" :options="departmentList" placeholder="请选择部门"
|
|
:props="{ checkStrictly: false,expandTrigger: 'hover' }" :show-all-levels="false" clearable
|
|
:props="{ checkStrictly: false,expandTrigger: 'hover' }" :show-all-levels="false" clearable
|
|
@change="selcts(9)" size="small" style="margin-left:10px"
|
|
@change="selcts(9)" size="small" style="margin-left:10px"
|
|
></el-cascader>
|
|
></el-cascader>
|
|
|
|
|
|
|
|
+ <!-- 任务筛选 -->
|
|
|
|
+ <el-select v-if="ins == 1" v-model="taskTypeId" placeholder="请选择类型" clearable filterable size="small" @change="selcts()" style="margin-left:10px">
|
|
|
|
+ <el-option v-for="(item) in taskTypeObj" :key="item.id" :label="item.value" :value="item.id">
|
|
|
|
+ </el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+
|
|
<!-- 人员筛选 -->
|
|
<!-- 人员筛选 -->
|
|
- <el-select v-if="ins == 6 || ins == 8 || ins == 9 || ins == 10" v-model="userId" placeholder="请选择人员" @change="selcts()" clearable filterable size="small" style="margin-left:10px;width:150px">
|
|
|
|
|
|
+ <el-select v-if="ins == 6 || ins == 8 || ins == 9 || ins == 10 || ins == 11" v-model="userId" placeholder="请选择人员" @change="selcts()" clearable filterable size="small" style="margin-left:10px;width:150px">
|
|
<el-option v-for="(item, index) in selUserList" :key="index" :label="item.name" :value="item.id"></el-option>
|
|
<el-option v-for="(item, index) in selUserList" :key="index" :label="item.name" :value="item.id"></el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</div>
|
|
</div>
|
|
@@ -456,6 +464,27 @@
|
|
<el-table-column prop="departmentName" label="所属部门" min-width="200" align="center"></el-table-column>
|
|
<el-table-column prop="departmentName" label="所属部门" min-width="200" align="center"></el-table-column>
|
|
<el-table-column prop="num" label="待审核条数" min-width="200" align="center"></el-table-column>
|
|
<el-table-column prop="num" label="待审核条数" min-width="200" align="center"></el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
|
|
+
|
|
|
|
+ <!-- 人员工时统计表 -->
|
|
|
|
+ <el-table v-if="ins == 11" key="11" border :data="personnelList" highlight-current-row v-loading="listLoading" :height="tableHeight" style="width: 100%;">
|
|
|
|
+ <el-table-column prop="name" label="姓名" min-width="200" align="center"></el-table-column>
|
|
|
|
+ <el-table-column prop="departmentName" label="部门" min-width="200" align="center"></el-table-column>
|
|
|
|
+ <el-table-column prop="planHours" label="计划工时" min-width="200" align="center">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ <div v-if="scope.row.planHours">
|
|
|
|
+ {{scope.row.planHours}}h
|
|
|
|
+ </div>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="workingTime" label="实际工时" min-width="200" align="center">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ <div v-if="scope.row.workingTime">
|
|
|
|
+ {{scope.row.workingTime}}h
|
|
|
|
+ </div>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="proportion" label="实际占比" min-width="200" align="center"></el-table-column>
|
|
|
|
+ </el-table>
|
|
|
|
|
|
|
|
|
|
<!--工具条-->
|
|
<!--工具条-->
|
|
@@ -609,6 +638,8 @@ export default {
|
|
title:'',
|
|
title:'',
|
|
childrenList:[],
|
|
childrenList:[],
|
|
taskTypeTxt:["任务", "里程碑", "风险"],
|
|
taskTypeTxt:["任务", "里程碑", "风险"],
|
|
|
|
+ taskTypeObj: [{id: '0',value: '任务'},{id: '1',value: '里程碑'},{id: '2',value: '风险'}],
|
|
|
|
+ taskTypeId: null,
|
|
taskStatusTxt:["进行中","已完成","已撤销"],
|
|
taskStatusTxt:["进行中","已完成","已撤销"],
|
|
statusTxt:["-","进行中","已完成","已撤销"],
|
|
statusTxt:["-","进行中","已完成","已撤销"],
|
|
importanceList:[{id:1,label:'正常'},{id:2,label:'紧急'},{id:3,label:'重要'},{id:4,label:'重要且紧急'}],
|
|
importanceList:[{id:1,label:'正常'},{id:2,label:'紧急'},{id:3,label:'重要'},{id:4,label:'重要且紧急'}],
|
|
@@ -670,7 +701,9 @@ export default {
|
|
departmentOrProject: 1,
|
|
departmentOrProject: 1,
|
|
|
|
|
|
allWrong: true,
|
|
allWrong: true,
|
|
- defaultActive: '1-1'
|
|
|
|
|
|
+ defaultActive: '1-1',
|
|
|
|
+
|
|
|
|
+ personnelList: [], //'人员工时统计表'
|
|
};
|
|
};
|
|
},
|
|
},
|
|
computed: {},
|
|
computed: {},
|
|
@@ -725,14 +758,15 @@ export default {
|
|
if(this.permissions.reportProject) {this.ssl(0);this.defaultActive = '1-1';return} else
|
|
if(this.permissions.reportProject) {this.ssl(0);this.defaultActive = '1-1';return} else
|
|
if(this.permissions.reportTask) {this.ssl(1);this.defaultActive = '1-2';return} else
|
|
if(this.permissions.reportTask) {this.ssl(1);this.defaultActive = '1-2';return} else
|
|
if(this.permissions.reportCostOf) {this.ssl(2);this.defaultActive = '1-3';return} else
|
|
if(this.permissions.reportCostOf) {this.ssl(2);this.defaultActive = '1-3';return} else
|
|
- if(this.permissions.reportTimeDivide) {this.ssl(8);this.defaultActive = '1-9';return} else
|
|
|
|
|
|
+ if(this.permissions.reportTimeDivide || this.permissions.reportAllTimeDivide) {this.ssl(8);this.defaultActive = '1-9';return} else
|
|
if(this.permissions.reportCostWarning) {this.ssl(7);this.defaultActive = '1-4';return} else
|
|
if(this.permissions.reportCostWarning) {this.ssl(7);this.defaultActive = '1-4';return} else
|
|
if(this.permissions.reportBalance) {this.ssl(3);this.defaultActive = '1-5';return} else
|
|
if(this.permissions.reportBalance) {this.ssl(3);this.defaultActive = '1-5';return} else
|
|
if(this.permissions.reportProfits) {this.ssl(4);this.defaultActive = '1-6';return} else
|
|
if(this.permissions.reportProfits) {this.ssl(4);this.defaultActive = '1-6';return} else
|
|
if(this.permissions.reportPhase) {this.ssl(5);this.defaultActive = '1-7';return} else
|
|
if(this.permissions.reportPhase) {this.ssl(5);this.defaultActive = '1-7';return} else
|
|
- if(this.permissions.reportOvertime) {this.ssl(6);this.defaultActive = '1-8';return} else
|
|
|
|
- if(this.permissions.reportTimely) {this.ssl(9);this.defaultActive = '1-10';return} else
|
|
|
|
- if(this.permissions.reportAuditRate) {this.ssl(10);this.defaultActive = '1-11';return} else {this.allWrong = false}
|
|
|
|
|
|
+ if(this.permissions.reportOvertime || this.permissions.reportAllOvertime) {this.ssl(6);this.defaultActive = '1-8';return} else
|
|
|
|
+ if(this.permissions.reportTimely || this.permissions.reportAllTimely) {this.ssl(9);this.defaultActive = '1-10';return} else
|
|
|
|
+ if(this.permissions.reportAuditRate) {this.ssl(10);this.defaultActive = '1-11';return} else
|
|
|
|
+ if(this.permissions.reportPersonnel || this.permissions.reportResponsible) {this.ssl(11);this.defaultActive = '1-12';return}{this.allWrong = false}
|
|
},
|
|
},
|
|
rowspan(spanArr,position,spanName){
|
|
rowspan(spanArr,position,spanName){
|
|
this.list1.forEach((item,index) => {
|
|
this.list1.forEach((item,index) => {
|
|
@@ -934,6 +968,8 @@ export default {
|
|
this.getReportTimelyList()
|
|
this.getReportTimelyList()
|
|
} else if (this.ins == 10) {
|
|
} else if (this.ins == 10) {
|
|
this.getAuditRateList()
|
|
this.getAuditRateList()
|
|
|
|
+ } else if(this.ins == 11) {
|
|
|
|
+ this.getPersonnelList()
|
|
}
|
|
}
|
|
},
|
|
},
|
|
exportExcel() {
|
|
exportExcel() {
|
|
@@ -986,6 +1022,17 @@ export default {
|
|
if(this.userId){
|
|
if(this.userId){
|
|
sl.userId = this.userId
|
|
sl.userId = this.userId
|
|
}
|
|
}
|
|
|
|
+ } else if(this.ins == 11){
|
|
|
|
+ fName = "人员工时统计.xls"
|
|
|
|
+ url += "/exportUserWorkingTimeStatic"
|
|
|
|
+ sl.startDate = this.rangeDatas[0]
|
|
|
|
+ sl.endDate = this.rangeDatas[1]
|
|
|
|
+ if(this.userId){
|
|
|
|
+ sl.userId = this.userId
|
|
|
|
+ }
|
|
|
|
+ if(this.departmentIdArray.length != 0){
|
|
|
|
+ sl.departmentId = this.departmentIdArray[this.departmentIdArray.length - 1]
|
|
|
|
+ }
|
|
}
|
|
}
|
|
this.http.post(url, sl,
|
|
this.http.post(url, sl,
|
|
res => {
|
|
res => {
|
|
@@ -1035,6 +1082,41 @@ export default {
|
|
this.selUserList = this.userList
|
|
this.selUserList = this.userList
|
|
this.getList();
|
|
this.getList();
|
|
},
|
|
},
|
|
|
|
+ // 获取人员工时统计表
|
|
|
|
+ getPersonnelList() {
|
|
|
|
+ let parameter = {
|
|
|
|
+ startDate: this.rangeDatas[0],
|
|
|
|
+ endDate: this.rangeDatas[1],
|
|
|
|
+ pageIndex: this.page,
|
|
|
|
+ pageSize: this.size
|
|
|
|
+ }
|
|
|
|
+ if(this.userId){
|
|
|
|
+ parameter.userId = this.userId
|
|
|
|
+ }
|
|
|
|
+ if(this.departmentIdArray.length != 0){
|
|
|
|
+ parameter.departmentId = this.departmentIdArray[this.departmentIdArray.length - 1]
|
|
|
|
+ }
|
|
|
|
+ this.listLoading = true;
|
|
|
|
+ this.http.post('/project/getUserWorkingTimeStatic', parameter,
|
|
|
|
+ res => {
|
|
|
|
+ if (res.code == "ok") {
|
|
|
|
+ this.personnelList = res.data.result;
|
|
|
|
+ this.total = res.data.total;
|
|
|
|
+ this.listLoading = false;
|
|
|
|
+ } else {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: res.msg,
|
|
|
|
+ type: "error"
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ error => {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: error,
|
|
|
|
+ type: "error"
|
|
|
|
+ });
|
|
|
|
+ });
|
|
|
|
+ },
|
|
getCustomerProjectInAndOut() {
|
|
getCustomerProjectInAndOut() {
|
|
this.listLoading = true;
|
|
this.listLoading = true;
|
|
this.http.post('/project/getCustomerProjectInAndOut', {
|
|
this.http.post('/project/getCustomerProjectInAndOut', {
|
|
@@ -1150,11 +1232,16 @@ export default {
|
|
},
|
|
},
|
|
getProjectTask() {
|
|
getProjectTask() {
|
|
this.listLoading = true;
|
|
this.listLoading = true;
|
|
- this.http.post('/project/getProjectTask', {
|
|
|
|
- pageIndex: this.page,
|
|
|
|
- pageSize: this.size,
|
|
|
|
- projectId: this.proJuctId
|
|
|
|
- },
|
|
|
|
|
|
+ let ginseng = {
|
|
|
|
+ pageIndex: this.page,
|
|
|
|
+ pageSize: this.size,
|
|
|
|
+ projectId: this.proJuctId
|
|
|
|
+ }
|
|
|
|
+ console.log(this.taskTypeId)
|
|
|
|
+ if(this.taskTypeId != 'null' && this.taskTypeId != null && this.taskTypeId != '') {
|
|
|
|
+ ginseng.taskType = this.taskTypeId
|
|
|
|
+ }
|
|
|
|
+ this.http.post('/project/getProjectTask', ginseng,
|
|
res => {
|
|
res => {
|
|
if (res.code == "ok") {
|
|
if (res.code == "ok") {
|
|
for(var i in res.data.records) {
|
|
for(var i in res.data.records) {
|
|
@@ -1511,6 +1598,9 @@ export default {
|
|
if(this.ins == 10){
|
|
if(this.ins == 10){
|
|
this.getAuditRateList()
|
|
this.getAuditRateList()
|
|
}
|
|
}
|
|
|
|
+ if(this.ins == 11){
|
|
|
|
+ this.getPersonnelList()
|
|
|
|
+ }
|
|
},
|
|
},
|
|
// 日期
|
|
// 日期
|
|
getCurrentRangeTime() {
|
|
getCurrentRangeTime() {
|