|
@@ -111,7 +111,6 @@
|
|
<el-button v-if="(user.id == item1.id) && (item1.state == 0 || item1.state == -1)" type="normal" :loading="logining" size="small" @click="cancel(item1)">撤回</el-button>
|
|
<el-button v-if="(user.id == item1.id) && (item1.state == 0 || item1.state == -1)" type="normal" :loading="logining" size="small" @click="cancel(item1)">撤回</el-button>
|
|
<el-button v-if="(user.role == 1 || user.role == 2 || user.id == item1.data[0].inchargerId) && item1.state == 1" type="normal" :loading="logining" size="small" @click="showDenyDialog(item1.id,1, item1)">撤销</el-button>
|
|
<el-button v-if="(user.role == 1 || user.role == 2 || user.id == item1.data[0].inchargerId) && item1.state == 1" type="normal" :loading="logining" size="small" @click="showDenyDialog(item1.id,1, item1)">撤销</el-button>
|
|
<el-button v-if="item1.state >= 2 && user.id == item1.id" type="primary" size="small" @click="isSubstitude=false; fillInReport(index1,0)">编辑日报</el-button>
|
|
<el-button v-if="item1.state >= 2 && user.id == item1.id" type="primary" size="small" @click="isSubstitude=false; fillInReport(index1,0)">编辑日报</el-button>
|
|
- <el-button v-if="user.role == 1 || user.role == 2 " type="primary" size="small" @click="guanli(item1)">删除</el-button>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="one_daily_body">
|
|
<div class="one_daily_body">
|
|
<el-timeline>
|
|
<el-timeline>
|
|
@@ -125,6 +124,7 @@
|
|
<span style="margin-left:15px;color:#FF0000;" v-else-if="item2.state == 2">[ 已驳回 ] 原因:{{item2.rejectReason}}</span>
|
|
<span style="margin-left:15px;color:#FF0000;" v-else-if="item2.state == 2">[ 已驳回 ] 原因:{{item2.rejectReason}}</span>
|
|
<span style="margin-left:15px;color:#FF0000;" v-else-if="item2.state == 3">[ 已撤回 ]</span>
|
|
<span style="margin-left:15px;color:#FF0000;" v-else-if="item2.state == 3">[ 已撤回 ]</span>
|
|
</span>
|
|
</span>
|
|
|
|
+ <el-button v-if="(user.role == 1 || user.role == 2) && item2.state != 1" size="mini" @click="guanli(item2, item1)" style="float: right;">删除</el-button>
|
|
<span v-if="user.company.packageEngineering == 1">
|
|
<span v-if="user.company.packageEngineering == 1">
|
|
<span style="margin-left:15px;color:#DAA520;" v-if="item2.state == -1">[ 待审核 ]</span>
|
|
<span style="margin-left:15px;color:#DAA520;" v-if="item2.state == -1">[ 待审核 ]</span>
|
|
<span style="margin-left:15px;color:#DAA520;" v-if="item2.state == 0 && item2.departmentAuditState == -1">[ 待专业审核 ]</span>
|
|
<span style="margin-left:15px;color:#DAA520;" v-if="item2.state == 0 && item2.departmentAuditState == -1">[ 待专业审核 ]</span>
|
|
@@ -476,10 +476,10 @@
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<!-- <el-table-column align="center" v-for="(item, index) in projectList" :key="item.id" :label="item.projectName" width="200"> -->
|
|
<!-- <el-table-column align="center" v-for="(item, index) in projectList" :key="item.id" :label="item.projectName" width="200"> -->
|
|
- <el-table-column align="center" v-for="(item, index) in projectList" :key="item.id" :label="item.projectName" width="200" v-if="index < changdu">
|
|
|
|
|
|
+ <el-table-column align="center" v-for="item in projectList" :key="item.id" :label="item.projectName" width="200">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<!-- <el-input v-model="scope.row[item.projectName]" style="width:120px;" @input="zhoZhi(scope.row, scope.$index)"></el-input> -->
|
|
<!-- <el-input v-model="scope.row[item.projectName]" style="width:120px;" @input="zhoZhi(scope.row, scope.$index)"></el-input> -->
|
|
- <el-popover placement="top" width="450" trigger="click">
|
|
|
|
|
|
+ <!-- <el-popover placement="top" width="450" trigger="click">
|
|
<div>
|
|
<div>
|
|
<div class="zhoFel" v-if="reportTimeType.type == 2">
|
|
<div class="zhoFel" v-if="reportTimeType.type == 2">
|
|
<p>选择时间</p>
|
|
<p>选择时间</p>
|
|
@@ -513,7 +513,17 @@
|
|
<el-button v-if="scope.row[item.projectName].time != null && scope.row[item.projectName].time != '' && reportTimeType.type == 2" type="text" slot="reference">{{scope.row[item.projectName].time[0]}} - {{scope.row[item.projectName].time[1]}}</el-button>
|
|
<el-button v-if="scope.row[item.projectName].time != null && scope.row[item.projectName].time != '' && reportTimeType.type == 2" type="text" slot="reference">{{scope.row[item.projectName].time[0]}} - {{scope.row[item.projectName].time[1]}}</el-button>
|
|
<el-button v-else type="text" >请填写</el-button>
|
|
<el-button v-else type="text" >请填写</el-button>
|
|
</div>
|
|
</div>
|
|
- </el-popover>
|
|
|
|
|
|
+ </el-popover> -->
|
|
|
|
+ <div v-if="reportTimeType.multiWorktime == 0" slot="reference" @click="tianxies(scope.row[item.projectName], scope.$index, item.projectName)">
|
|
|
|
+ <el-button v-if="scope.row[item.projectName].workingTime != null && scope.row[item.projectName].workingTime != '' && reportTimeType.type == 3 && scope.row[item.projectName].workingTime > 0" type="text" slot="reference">{{scope.row[item.projectName].workingTime}} h</el-button>
|
|
|
|
+ <el-button v-else-if="scope.row[item.projectName].workingTime != null && scope.row[item.projectName].workingTime != '' && reportTimeType.type == 1 && scope.row[item.projectName].workingTime > 0" type="text" slot="reference">{{scope.row[item.projectName].workingTime}} h</el-button>
|
|
|
|
+ <el-button v-else-if="scope.row[item.projectName].time != null && scope.row[item.projectName].time != '' && reportTimeType.type == 2" type="text" slot="reference">{{scope.row[item.projectName].time[0]}} - {{scope.row[item.projectName].time[1]}}</el-button>
|
|
|
|
+ <el-button v-else type="text" >请填写</el-button>
|
|
|
|
+ </div>
|
|
|
|
+ <div v-if="reportTimeType.multiWorktime == 1" slot="reference" @click="tianxies(scope.row[item.projectName], scope.$index, item.projectName)">
|
|
|
|
+ <el-button v-if="scope.row[item.projectName].time != null && scope.row[item.projectName].time != '' && reportTimeType.type == 2" type="text" slot="reference">{{scope.row[item.projectName].time[0]}} - {{scope.row[item.projectName].time[1]}}</el-button>
|
|
|
|
+ <el-button v-else type="text" >请填写</el-button>
|
|
|
|
+ </div>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column fixed="right" prop="he" label="合计(h)" width="120">
|
|
<el-table-column fixed="right" prop="he" label="合计(h)" width="120">
|
|
@@ -540,6 +550,37 @@
|
|
</span>
|
|
</span>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
|
|
|
|
+ <!-- 按周填报弹窗 -->
|
|
|
|
+ <el-dialog title="请填写" :visible.sync="tianxieDialogVisible" width="30%" :before-close="handleClose">
|
|
|
|
+ <div>
|
|
|
|
+ <div class="zhoFel" v-if="reportTimeType.type == 2">
|
|
|
|
+ <p>选择时间</p>
|
|
|
|
+ <el-time-picker style="width: 355px" is-range v-model="zhoBao.time" format="HH:mm" value-format="HH:mm" range-separator="至" start-placeholder="开始时间" end-placeholder="结束时间" placeholder="选择时间范围"></el-time-picker>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="zhoFel" v-if="reportTimeType.type == 1">
|
|
|
|
+ <p>选择时长</p>
|
|
|
|
+ <el-select clearable v-model="zhoBao.workingTime" style="width: 355px;" placeholder="请选择工作时长">
|
|
|
|
+ <el-option v-for="item in timeRange" :key="item" :value="item.toFixed(1)">{{item.toFixed(1)}}</el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="zhoFel" v-if="reportTimeType.type == 3">
|
|
|
|
+ <p>用时占比</p>
|
|
|
|
+ <div style="width:355px;display: flex;align-items: center;">
|
|
|
|
+ <el-col span="23"><el-slider style="margin-left: 5px;width:249px;" v-model="zhoBao.progress" :min="0" :show-tooltip="false" :step="10" @input="zhoBao.workingTime = (reportTimeType.allday*zhoBao.progress/100).toFixed(1)"></el-slider></el-col>
|
|
|
|
+ <el-col span="10"><span style="float:right;"><span style="margin-right:10px;">{{zhoBao.progress || 0}}%</span>{{zhoBao.workingTime | amounts}}小时</span></el-col>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="zhoFel">
|
|
|
|
+ <p>工作事项</p>
|
|
|
|
+ <el-input type="textarea" v-model="zhoBao.con" placeholder="请输入工作事项" style="width: 355px" clearable></el-input>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
|
+ <el-button @click="tianxieDialogVisible = false">取 消</el-button>
|
|
|
|
+ <el-button type="primary" @click="btnTianxiaes()">确 定</el-button>
|
|
|
|
+ </span>
|
|
|
|
+ </el-dialog>
|
|
|
|
+
|
|
<!-- 批量日报审核 -->
|
|
<!-- 批量日报审核 -->
|
|
<el-dialog title="批量日报审核" :visible.sync="approveDialogVisible" width="500px" >
|
|
<el-dialog title="批量日报审核" :visible.sync="approveDialogVisible" width="500px" >
|
|
<el-checkbox v-model="isAllSelect" label="全选" style="margin-left:24px;" @change="selectAll" v-if="reportNames.length > 0"></el-checkbox>
|
|
<el-checkbox v-model="isAllSelect" label="全选" style="margin-left:24px;" @change="selectAll" v-if="reportNames.length > 0"></el-checkbox>
|
|
@@ -922,7 +963,17 @@
|
|
zhoRqi: [],
|
|
zhoRqi: [],
|
|
btnZho: false,
|
|
btnZho: false,
|
|
zhoLoading: false,
|
|
zhoLoading: false,
|
|
- changdu: 6
|
|
|
|
|
|
+ changdu: 6,
|
|
|
|
+ tianxieDialogVisible: false,
|
|
|
|
+ scopess: {},
|
|
|
|
+ zhoBao: {
|
|
|
|
+ time: '',
|
|
|
|
+ workingTime: '',
|
|
|
|
+ progress: '',
|
|
|
|
+ con: '',
|
|
|
|
+ },
|
|
|
|
+ zhoBaoIdx: '',
|
|
|
|
+ zhoBaoName: ''
|
|
};
|
|
};
|
|
},
|
|
},
|
|
filters: {
|
|
filters: {
|
|
@@ -1703,8 +1754,8 @@
|
|
|
|
|
|
},
|
|
},
|
|
// 管理员删除日报
|
|
// 管理员删除日报
|
|
- guanli(item) {
|
|
|
|
- console.log(item, 123)
|
|
|
|
|
|
+ guanli(item, items) {
|
|
|
|
+ console.log(item, items)
|
|
this.$confirm("确定要删除该日报吗?","提示", {
|
|
this.$confirm("确定要删除该日报吗?","提示", {
|
|
confirmButtonText: "确定",
|
|
confirmButtonText: "确定",
|
|
cancelButtonText: "取消",
|
|
cancelButtonText: "取消",
|
|
@@ -1713,7 +1764,7 @@
|
|
.then(() => {
|
|
.then(() => {
|
|
this.listLoading = true;
|
|
this.listLoading = true;
|
|
this.http.post('/report/delete',{
|
|
this.http.post('/report/delete',{
|
|
- userId: item.id,
|
|
|
|
|
|
+ userId: item.creatorId,
|
|
date: this.workForm.createDate
|
|
date: this.workForm.createDate
|
|
},
|
|
},
|
|
res => {
|
|
res => {
|
|
@@ -2489,6 +2540,29 @@
|
|
this.dialogVisible = true;
|
|
this.dialogVisible = true;
|
|
|
|
|
|
},
|
|
},
|
|
|
|
+ // 按周填报里内容的填写
|
|
|
|
+ tianxies(item, i, names) {
|
|
|
|
+ this.tianxieDialogVisible = true
|
|
|
|
+ this.scopess = item
|
|
|
|
+ var sss = {}
|
|
|
|
+ sss.con = item.con
|
|
|
|
+ sss.progress = item.progress
|
|
|
|
+ sss.time = item.time
|
|
|
|
+ sss.workingTime = item.workingTime
|
|
|
|
+ this.zhoBaoIdx = i
|
|
|
|
+ this.zhoBaoName = names
|
|
|
|
+ this.zhoBao = sss
|
|
|
|
+ },
|
|
|
|
+ // 按周填报里内容的填写点击确定
|
|
|
|
+ btnTianxiaes() {
|
|
|
|
+ this.tianxieDialogVisible = false
|
|
|
|
+ var zhong = this.zhoData
|
|
|
|
+ zhong[this.zhoBaoIdx][this.zhoBaoName] = this.zhoBao
|
|
|
|
+ this.zhoData = zhong
|
|
|
|
+ if(this.reportTimeType.type == 1) this.zhoXuan(this.zhoBao, this.zhoBaoIdx)
|
|
|
|
+ if(this.reportTimeType.type == 2) this.zhoTimes(this.zhoBao, this.zhoBaoIdx)
|
|
|
|
+ if(this.reportTimeType.type == 3) this.addBli(this.zhoBao, this.zhoBaoIdx)
|
|
|
|
+ },
|
|
// 获取本周
|
|
// 获取本周
|
|
getCurrentWeek() {
|
|
getCurrentWeek() {
|
|
const currentDate = new Date()
|
|
const currentDate = new Date()
|