123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255 |
- <template>
- <view class="task-page">
- <div class="title">{{item.hdangerTitle}}</div>
- <div class="info">
- <div class="item">
- <view class="name">上报人</view>
- <view class="cont">{{item.curAccountName}}</view>
- </div>
- <div class="item">
- <view class="name">所属部门</view>
- <view class="cont">{{item.curGroupName}}</view>
- </div>
- <div class="item">
- <view class="name">发布时间</view>
- <view class="cont">{{parseTime(item.curActivityBeginTime)}}</view>
- </div>
- </div>
- <div class="status" v-if="flowData">
- <div class="head">整改过程</div>
- <template>
- <view class="flow-head">
- <span class="flow-user">{{flowData.groupName}}-{{flowData.accountName||'***'}}</span>
- <view class="flow-time">{{parseTime(flowData.actionTime)}}</view>
- </view>
- <div class="desc">{{flowData.actionRemark}}</div>
- <div class="attach">
- <view class="attach-item" v-for="(attach,index) in flowData.attachList" :key="'attach-'+index">
- <image class="image" :src="attach.fileUrl" mode="widthFix"></image>
- </view>
- </div>
- </template>
- </div>
- <view class="footer" @click="onSubmit">验收</view>
- </template>
- <script>
- import { getWorkflowById } from '@/api/system/wfApi'
- import {parseTime} from '@/libs/index.js'
- export default {
- data() {
- return {
- item:{
- },
- flowData:{
- status:"",
- time:"",
- desc:"",
- attachList:[]
- },
- check:{
- status:"",
- time:"",
- desc:"",
- attachList:[]
- }
- }
- },
- onLoad() {
- this.getTask()
- },
- methods: {
- parseTime,
- init(){
- // let title="待验收"
- // this.flow={
- // status:-1,
- // user:"王麻子",
- // time:new Date(),
- // desc:"处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述",
- // attachList:[
- // {url:"/static/preview/1.png"},
- // {url:"/static/preview/2.png"},
- // {url:"/static/preview/3.png"}
- // ]
- // }
- // /*已经验收 未通过*/
- // this.check={
- // status:0,
- // user:"王麻子",
- // time:new Date(),
- // desc:"处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述处置过程描述",
- // attachList:[
- // {url:"/static/preview/1.png"},
- // {url:"/static/preview/2.png"},
- // {url:"/static/preview/3.png"}
- // ]
- // }
- // // 验收完成
- // if(this.check.status===1){
- // uni.setNavigationBarTitle({
- // title: '已完成'
- // });
- // }
- // if(this.check.status===0){
- // uni.setNavigationBarTitle({
- // title: '待验收'
- // });
- // }
- },
- getTask(){
- let data=uni.getStorageSync('danger-info')
- this.item=data
- getWorkflowById(data.wfInsId).then((resp) => {
- this.listLoading = false
- const { code, data, msg } = resp
- if (code === 0) {
- this.flowData = data.activityInsRecordList.filter(item=>item.formCode==='rectify')[0]
- } else {
- this.$message.error(msg)
- }
- })
- },
- onSubmit(){
- uni.navigateTo({
- url:'/pages/risk/check/form/form'
- })
- },
- onRectify(){
- uni.navigateTo({
- url:'/pages/risk/rectify/form/form'
- })
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .task-page{
- background-color: #F3F5FB;
- padding-bottom: 120rpx;
- height: 100vh;
- overflow-y: auto;
- .title{
- font-family: 'Source Han Sans CN';
- font-style: normal;
- font-weight: 700;
- font-size: 36rpx;
- line-height: 54rpx;
- color: #212121;
- padding:0 32rpx;
- }
- .info{
- padding: 0 32rpx;
- margin: 40rpx 0;
- background: #FFFFFF;
- border-radius: 32rpx 32rpx 0px 0px;
- .item{
- border-bottom: 1rpx solid #EFF1F3;
- padding: 40rpx 32rpx;
- .name{
- font-size: 28rpx;
- color: #999999;
- line-height: 1;
- }
- .cont{
- font-size: 30rpx;
- color: #212121;
- line-height: 1.5;
- padding-top: 12rpx;
- }
- &:last-child{
- border-bottom:none;
- }
- }
- }
- .status{
- background-color: #FFFFFF;
- border-radius: 32rpx 32rpx 0px 0px;
- padding: 48rpx 32rpx;
- &.check{
- margin-top: 24rpx;
- background-repeat: no-repeat;
- background-position: right top;
- &.pass{
- background-image: url('/static/icon/pass.png');
- }
- &.reject{
- background-image: url('/static/icon/reject.png');
- }
- }
- .head{
- color: #212121;
- font-size: 34rpx;
- line-height:1;
- font-weight: 700;
- }
- .icon-empty{
- display: block;
- width: 160rpx;
- margin: 64rpx auto 0;
- }
- p{
- font-size: 24rpx;
- line-height: 28rpx;
- color: #D5D5D5;
- text-align: center;
- }
- .flow-head{
- display: flex;
- justify-content: space-between;
- align-items: center;
- font-family: 'Abhaya Libre';
- font-style: normal;
- font-weight: 400;
- font-size: 24rpx;
- line-height: 48rpx;
- padding: 30rpx 0 24rpx 0;
- color: #999;
- }
- .desc{
- font-family: 'SF Pro Text';
- font-style: normal;
- font-weight: 500;
- font-size: 30rpx;
- line-height: 42rpx;
- color: #434343;
- padding-bottom: 24rpx;
- }
- .attach{
- display: flex;
- flex-wrap: wrap;
- .attach-item{
- width: 224rpx;
- overflow: hidden;
- margin-right: 7rpx;
- margin-bottom: 20rpx;
- &:nth-child(3n){
- margin-right: 0;
- }
- .image{
- display: block;
- width: 224rpx;
- border-radius: 8px;
- }
- }
- }
- }
- .footer{
- width: 100%;
- height: 136upx;
- background: #FFFFFF;
- border-radius: 16upx 16upx 0px 0px;
- position: fixed;
- left: 0;
- bottom: 0;
- text-align: center;
- color: #168DEC;
- font-size: 32upx;
- padding-top: 20upx;
- letter-spacing: 2px;
- border: 1px solid #eaeaea;
- }
- }
- </style>
|