123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276 |
- <script>
- import {downFileBase64, reminderDetails} from "@/api/commitment";
- import buriedPoint from "@/utils/dd.buriedPoint";
- export default {
- watch: {
- /* 提醒uuid */
- '$route.query.uuid': {
- handler() {
- if (this.$route.query.uuid && this.$route.path === '/subPages/pages/commitment/remindDetail/index') {
- this.handleGetDetail()
- }
- },
- immediate: true,
- deep: true
- }
- },
- activated() {
- this.handleGetDetail()
- },
- data() {
- return {
- reminderDetail: {},
- }
- },
- onLoad(){
- buriedPoint('提醒详情','3-2','subPages/pages/commitment/remindDetail/index')
- },
- methods: {
- handleGetDetail() {
- reminderDetails({
- uuid: this.$route.query.uuid,
- type: this.$route.query.type // 0:整改提醒 1:系统提醒
- }).then(res => {
- if (res) {
- this.reminderDetail = res.data
- }
- })
- },
- /* 附件下载 */
- handleFileDown(uuid) {
- downFileBase64({
- uuid: uuid
- }).then(res => {
- if (res) {
- const a = document.createElement('a')
- a.href = res.data
- a.download = '附件'
- a.click()
- }
- })
- },
- handleClose() {
- window.history.go(-1)
- },
- handleIndicateBody(indicatorInputBody) {
- if (indicatorInputBody.includes('&')) {
- return this.reminderDetail.inputBody ? indicatorInputBody.replace('&', this.reminderDetail.inputBody + this.reminderDetail.inputSegment) : indicatorInputBody
- } else {
- return indicatorInputBody
- }
- }
- }
- }
- </script>
- <template>
- <view class="remind-page">
- <view class="remind-content">
- <view class="top">
- <view class="title">提醒编号:{{ reminderDetail.code }}</view>
- <view class="status">
- <span v-if="$route.query.type === '0'" style="color: #D9001B">红灯提醒</span>
- <span v-if="$route.query.type === '1'" style="color: #F59A23">黄灯提醒</span>
- </view>
- </view>
- <view class="remind">
- {{ reminderDetail.content }}
- </view>
- <van-divider></van-divider>
- <view>
- <view class="indicator-body">
- {{ reminderDetail.indicatorInputBody ? handleIndicateBody(reminderDetail.indicatorInputBody) : '' }}
- </view>
- <view>
- <view class="other-title">
- 监管核查
- <view style="color: #FF6B00" v-if="reminderDetail.approvalStatus === 0">
- 审批状态:待审批
- </view>
- <view style="color: #15BE50" v-if="reminderDetail.approvalStatus === 1">
- 审批状态:已通过
- </view>
- <view style="color: #D40000" v-if="reminderDetail.approvalStatus === 2">
- 审批状态:已拒绝
- </view>
- </view>
- <van-divider/>
- <van-form>
- <!--核查结果-->
- <van-field
- name="auditResult"
- label="核查结果"
- >
- <template #input>
- <view v-if="reminderDetail.auditResult === 0">符合</view>
- <view v-if="reminderDetail.auditResult === 1">整改</view>
- <view v-if="reminderDetail.auditResult === 2">整改扣分</view>
- </template>
- </van-field>
- <!--核查得分-->
- <van-field
- name="auditScore"
- label="核查得分"
- >
- <template #input>
- <span v-if="reminderDetail.auditResult === 1">
- 0分
- </span>
- <span v-if="reminderDetail.auditResult === 2">
- -10分
- </span>
- </template>
- </van-field>
- <!--核查说明-->
- <van-field
- name="auditRemark"
- label="核查说明"
- >
- <template #input>
- <view>{{ reminderDetail.auditRemark }}</view>
- </template>
- </van-field>
- <van-field
- name="expandStr"
- label="附件"
- >
- <template #input>
- <view v-if="reminderDetail.expandStr" class="file-style">
- <view v-for="(item,index) in reminderDetail.expandStr.split(',')" :key="index"
- @click="handleFileDown(item.uuid)">
- 附件{{ index + 1 }}
- </view>
- </view>
- </template>
- </van-field>
- <!--核查人员-->
- <van-field
- style="margin-top: 16px"
- name="auditor"
- label="核查人员"
- >
- <template #input>
- {{ reminderDetail.auditor }}
- </template>
- </van-field>
- <!--核查时间-->
- <van-field
- name="auditTime"
- label="核查时间"
- >
- <template #input>
- {{ reminderDetail.updateTime | date }}
- </template>
- </van-field>
- </van-form>
- </view>
- </view>
- </view>
- <view class="page-bottom">
- <van-button plain type="primary" @click="handleClose">关闭</van-button>
- <van-button type="info" @click="handleFileDown(reminderDetail.attachmentId)">下载PDF</van-button>
- </view>
- </view>
- </template>
- <style scoped lang="scss">
- .remind-page {
- height: 100vh;
- background-color: #fff;
- padding: 20px;
- overflow: hidden;
- display: flex;
- box-sizing: border-box;
- flex-direction: column;
- }
- .remind {
- margin-top: 10px;
- }
- .remind-page .top {
- display: flex;
- font-weight: bold;
- justify-content: space-between;
- align-items: center;
- .title {
- font-size: 28rpx;
- color: #333333;
- }
- .status {
- font-size: 24rpx;
- }
- }
- .indicator-body {
- margin-top: 40px;
- background: #F6F6F6;
- border-radius: 4px;
- font-weight: 400;
- font-size: 15px;
- color: #666666;
- text-align: justify;
- padding: 5px;
- min-height: 40px;
- }
- .other-title {
- font-size: 14px;
- font-weight: bold;
- color: #333;
- margin-top: 10px;
- display: flex;
- justify-content: space-between;
- view {
- font-size: 12px;
- }
- }
- .file-style {
- font-size: 14px;
- font-weight: 400;
- color: #1492FF;
- margin-top: 10px;
- display: flex;
- flex-direction: column;
- cursor: pointer;
- }
- .remind-content {
- flex: 1;
- overflow-y: auto;
- }
- .page-bottom {
- height: 50px;
- display: flex;
- width: 100%;
- }
- /* 默认情况下,每个按钮平分空间 */
- .page-bottom .van-button {
- flex: 1;
- margin-right: 10px;
- }
- /* 取消最后一个按钮的右侧间距 */
- .page-bottom .van-button:last-child {
- margin-right: 0;
- }
- /* 当只有两个按钮时的样式 */
- .page-bottom .van-button:first-child:nth-last-child(2) {
- flex: 1; /* 第一个按钮占 1/3 */
- }
- .page-bottom .van-button:nth-child(2):last-child {
- flex: 3; /* 第二个按钮占 2/3 */
- }
- </style>
|