|
@@ -0,0 +1,230 @@
|
|
|
+<template>
|
|
|
+ <el-container class="BackgroundCloth">
|
|
|
+ <el-header class="public_header setLine">
|
|
|
+ <div class="Layout_space_between">
|
|
|
+ <div class="Layout_flex_start">
|
|
|
+ <div class="report-title">{{ details.reportName }}</div>
|
|
|
+ <div class="details-statusString">{{ details.statusString }}</div>
|
|
|
+ </div>
|
|
|
+ <div>
|
|
|
+ <span v-if="details.status === 0 ? true : false" class="didi-hover" @click="dailyButtom(3)">发送</span>
|
|
|
+ <span v-if="details.status === 0 ? true : false" style="margin: 0 30px;" class="didi-hover" @click="dailyButtom(2)">编辑</span>
|
|
|
+ <span v-if="details.status === 0 ? true : false" class="didi-hover" @click="dialog_testData = true">删除</span>
|
|
|
+ <span v-if="details.status === 3 ? true : false" class="didi-hover" @click="dailyButtom(4)">复制</span>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-header>
|
|
|
+ <el-container>
|
|
|
+ <el-main class="report-main">
|
|
|
+ <div class="title"><div class="blur-column" /> 报告内容</div>
|
|
|
+ <div v-html="details.content" />
|
|
|
+ <icon-display :details="details" />
|
|
|
+ </el-main>
|
|
|
+ <el-aside width="400px">
|
|
|
+ <el-container>
|
|
|
+ <el-header class="report-mains">
|
|
|
+ <div class="title"><div class="blur-column" /> 用户信息</div>
|
|
|
+ <div class="Layout_flex_start task-bot">
|
|
|
+ <div class="title-name">报告人 : </div>
|
|
|
+ <div class="task-name">{{ details.reportorObject ? details.reportorObject.name : '' }}</div>
|
|
|
+ </div>
|
|
|
+ <div class="Layout_flex_start task-bot">
|
|
|
+ <div class="title-name">收件人 : </div>
|
|
|
+ <div v-for="(item, index) in details.sendToObject" :key="index" class="task-name"> {{ item.name }} <span v-if="index < details.sendToObject.length - 1"> , </span></div>
|
|
|
+ </div>
|
|
|
+ <div class="Layout_flex_start task-bot">
|
|
|
+ <div class="title-name">抄送人 : </div>
|
|
|
+ <div v-for="(item, index) in details.sendCcObject" :key="index" class="task-name">{{ item.name }} <span v-if="index < details.sendCcObject.length - 1"> , </span></div>
|
|
|
+ </div>
|
|
|
+ </el-header>
|
|
|
+ <el-main class="report-mains">
|
|
|
+ <div class="title"><div class="blur-column" /> 时间</div>
|
|
|
+ <div class="Layout_flex_start task-bot">
|
|
|
+ <div class="title-name">创建时间 : </div>
|
|
|
+ <div class="task-name">{{ details.gmtCreate }}</div>
|
|
|
+ </div>
|
|
|
+ <div class="Layout_flex_start task-bot">
|
|
|
+ <div class="title-name">发送时间 : </div>
|
|
|
+ <div class="task-name">{{ details.reportTime }}</div>
|
|
|
+ </div>
|
|
|
+ </el-main>
|
|
|
+ <el-footer class="report-mains">
|
|
|
+ <div class="title"><div class="blur-column" /> 关联任务</div>
|
|
|
+ <div v-for="(item, index) in details.taskDetailList" :key="index" class="Layout_flex_start task-bot">
|
|
|
+ <div class="task-id">{{ item.taskId }}</div>
|
|
|
+ <el-tooltip class="item" effect="dark" :content="item.name" placement="top-start">
|
|
|
+ <div class="task-name didi-hover" @click="goTaskDetails(item.id)">{{ item.name.slice(0,12) + '...' }}</div>
|
|
|
+ </el-tooltip>
|
|
|
+ </div>
|
|
|
+ </el-footer>
|
|
|
+ </el-container>
|
|
|
+ </el-aside>
|
|
|
+ </el-container>
|
|
|
+ <el-dialog title="删除确认" :visible.sync="dialog_testData" width="30%" :close-on-click-modal="false">
|
|
|
+ <div style="position: absolute; top: 23px; left: 12px;width:4px;height:17px;background:#409EFF;border-radius:1px;" />
|
|
|
+ <div align="center">
|
|
|
+ <div>是否删除以下测试日报?</div>
|
|
|
+ <div style="color: #f79232;">{{ details.reportName }}</div>
|
|
|
+ </div>
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
+ <el-button type="primary" size="mini" @click="deleteDaily()">确 定</el-button>
|
|
|
+ <el-button type="danger" size="mini" @click="dialog_testData = false">取 消</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
+ <DailyReport v-if="dialogDaily" ref="DailyReport" @getList="getReportContent(reportId)" />
|
|
|
+ </el-container>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import '@/styles/PublicStyle/index.scss'
|
|
|
+import { dailyReportGetV2, dailyReportDelete } from '@/api/reportTemplate'
|
|
|
+import iconDisplay from '@/views/reportManagement/daily/components/iconDisplay.vue'
|
|
|
+import DailyReport from '@/views/reportManagement/components/DailyReport' // 日报
|
|
|
+export default {
|
|
|
+ components: {
|
|
|
+ DailyReport,
|
|
|
+ iconDisplay
|
|
|
+ },
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ dialogDaily: false, // 日报弹窗
|
|
|
+ dialog_testData: false, // 操作弹窗
|
|
|
+ reportId: this.$route.query.id,
|
|
|
+ details: {}
|
|
|
+ }
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.getReportContent(this.reportId)
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ // 获取日报data
|
|
|
+ async getReportContent(e) {
|
|
|
+ const res = await dailyReportGetV2(e)
|
|
|
+ if (res.code === 200) {
|
|
|
+ this.details = res.data
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 测试报告
|
|
|
+ dailyButtom(e) {
|
|
|
+ this.dialogDaily = true
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.$refs.DailyReport.init(e, this.details)
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ goTaskDetails(id) {
|
|
|
+ this.$router.push({ name: '任务详情', query: { id: id }})
|
|
|
+ },
|
|
|
+ // 删除日报‘
|
|
|
+ async deleteDaily() {
|
|
|
+ const res = await dailyReportDelete(this.details.id)
|
|
|
+ if (res.code === 200) {
|
|
|
+ this.dialog_testData = false
|
|
|
+ this.$router.push({ name: '报告' })
|
|
|
+ this.$message({ type: 'success', message: '删除成功' })
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss" scoped>
|
|
|
+.BackgroundCloth {
|
|
|
+.report-Header {
|
|
|
+ margin: 10px 10px 0;
|
|
|
+ background: #FFF;
|
|
|
+ border-radius:4px;
|
|
|
+}
|
|
|
+
|
|
|
+.details-id {
|
|
|
+ font-size:12px;
|
|
|
+ font-family:PingFang SC;
|
|
|
+ font-weight:400;
|
|
|
+ line-height:20px;
|
|
|
+ color:rgba(51,59,74,1);
|
|
|
+ opacity:0.5;
|
|
|
+}
|
|
|
+
|
|
|
+.report-title {
|
|
|
+ font-size:20px;
|
|
|
+ font-family:PingFangSC-Medium;
|
|
|
+ line-height:28px;
|
|
|
+ color:rgba(51,59,74,1);
|
|
|
+ opacity:1;
|
|
|
+}
|
|
|
+
|
|
|
+.details-statusString {
|
|
|
+ font-size:14px;
|
|
|
+ font-family:MicrosoftYaHei;
|
|
|
+ line-height:17px;
|
|
|
+ padding: 5px 8px;
|
|
|
+ margin-left: 15px;
|
|
|
+ color:rgba(111,124,147,1);
|
|
|
+ border:1px solid rgba(191,198,220,1);
|
|
|
+ opacity:1;
|
|
|
+ border-radius:4px;
|
|
|
+}
|
|
|
+
|
|
|
+.report-main {
|
|
|
+ margin: 10px;
|
|
|
+ background: #FFF;
|
|
|
+ border-radius:4px;
|
|
|
+}
|
|
|
+.report-mains {
|
|
|
+ min-height: 200px;
|
|
|
+ padding: 20px 30PX;
|
|
|
+ margin: 10px 10px 0 0;
|
|
|
+ background: #FFF;
|
|
|
+ border-radius:4px;
|
|
|
+}
|
|
|
+.title {
|
|
|
+ font-size:16px;
|
|
|
+ font-family:PingFangSC-Medium;
|
|
|
+ margin-bottom: 10px;
|
|
|
+ color:rgba(51,59,74,1);
|
|
|
+ opacity:1;
|
|
|
+}
|
|
|
+
|
|
|
+.title-name {
|
|
|
+ width:100px;
|
|
|
+ font-size:14px;
|
|
|
+ font-family:PingFangSC-Regular;
|
|
|
+ line-height:20px;
|
|
|
+ color:rgba(102,102,102,1);
|
|
|
+ opacity:1;
|
|
|
+}
|
|
|
+
|
|
|
+.task-id {
|
|
|
+ width:100px;
|
|
|
+ font-size:14px;
|
|
|
+ font-family:MicrosoftYaHei;
|
|
|
+ line-height:17px;
|
|
|
+ color:rgba(102,102,102,1);
|
|
|
+ opacity:1;
|
|
|
+}
|
|
|
+
|
|
|
+.task-name {
|
|
|
+ font-size:14px;
|
|
|
+ font-family:MicrosoftYaHei;
|
|
|
+ line-height:17px;
|
|
|
+ color:rgba(51,51,51,1);
|
|
|
+ opacity:1;
|
|
|
+}
|
|
|
+
|
|
|
+.blur-column {
|
|
|
+ width:4px;
|
|
|
+ height:15px;
|
|
|
+ display:inline-block;
|
|
|
+ vertical-align: middle;
|
|
|
+ background:#409EFF;
|
|
|
+ border-radius:1px;
|
|
|
+}
|
|
|
+
|
|
|
+.task-bot {
|
|
|
+ margin-bottom: 10px;
|
|
|
+}
|
|
|
+}
|
|
|
+.setLine {
|
|
|
+ padding: 10px 20px;
|
|
|
+}
|
|
|
+</style>
|