From b5d3561a2e06106ed9cce2c6bcc9c2463951e998 Mon Sep 17 00:00:00 2001
From: 819527061@qq.com <123456>
Date: 星期五, 15 十一月 2024 11:06:26 +0800
Subject: [PATCH] 新增申请页面不显示发运通知单的问题修改
---
pages/approval-history/approval-history.vue | 174 ++++++++++++++++++++++++++++++++++++----------------------
1 files changed, 108 insertions(+), 66 deletions(-)
diff --git a/pages/approval-history/approval-history.vue b/pages/approval-history/approval-history.vue
index deef4e6..bf6cdff 100644
--- a/pages/approval-history/approval-history.vue
+++ b/pages/approval-history/approval-history.vue
@@ -1,119 +1,161 @@
<template>
- <!-- 瀹℃壒鍘嗗彶 -->
<view class="approval-history">
- <combined-title title="鏌ョ湅杩涘害"></combined-title>
- <view class="historyTable">
+ <combined-title title="瀹℃壒鍘嗗彶"></combined-title>
+ <u-empty v-if="scheduleData.length == 0"
+ mode="data"
+ icon="http://cdn.uviewui.com/uview/empty/data.png"
+ width="100px"
+ height="150px"
+ >
+ </u-empty>
+ <view class="scheduleTable" v-for="(item,index) in scheduleData" :key="index">
<uni-table border stripe emptyText="鏆傛棤鏇村鏁版嵁">
<!-- 琛ㄦ牸鏁版嵁琛� -->
<uni-tr>
<uni-th align="center">浠诲姟鍚嶇О</uni-th>
- <uni-td>{{yibanData.renwu}}</uni-td>
+ <uni-td>{{ item.name }}</uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">澶勭悊浜�</uni-th>
- <uni-td>XXX XXX XXX XXX</uni-td>
+ <uni-td>
+ <view class="assigneesContainer">
+ <u-tag :text="role.nickname" type="primary" size="mini" plain v-for="(role,roleIndex) in item.assignees" :key="roleIndex"></u-tag>
+ </view>
+ </uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">瀹℃壒鎿嶄綔</uni-th>
- <uni-td>鈥斺��</uni-td>
+ <uni-td>{{item.deleteReason}}</uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">瀹℃壒鎰忚</uni-th>
- <uni-td>{{yibanData.shenpiyijian}}</uni-td>
+ <uni-td>{{ item.comment=='undefined'?item.endTime?'鏈~鍐�':'':item.comment|| item.endTime?'鏈~鍐�':'' }}</uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">鑰楁椂</uni-th>
- <uni-td>{{yibanData.haoshi}}</uni-td>
+ <uni-td>{{
+ item.duration >= 86400000
+ ? parseInt(item.duration / 86400000 + '澶�' + parseInt(item.duration % 86400000) / 3600000 + '鏃�' + parseInt(item.duration % 3600000) / 60000 + '鍒�')
+ : item.duration >= 3600000
+ ? parseInt(item.duration / 3600000) + '鏃�' + parseInt((item.duration / 3600000) % 3600000) + '鍒�'
+ : parseInt(item.duration / 60000) + '鍒�'
+ }}
+ </uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">鍒涘缓鏃堕棿</uni-th>
- <uni-td>{{yibanData.createTime}}</uni-td>
+ <uni-td>{{ item.createTime }}</uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">瀹屾垚鏃堕棿</uni-th>
- <uni-td>鈥斺��</uni-td>
+ <uni-td>{{ item.endTime ||'' }}</uni-td>
</uni-tr>
<uni-tr>
<uni-th align="center">鐘舵��</uni-th>
- <uni-td style="color:#007AFF" >寰呭鐞�</uni-td>
+ <uni-td :style="{color:(item.endTime==null?'#969696':'#007AFF')}">{{ item.endTime ==null? '寰呭鐞�' : '宸插姙鐞�' }}</uni-td>
</uni-tr>
</uni-table>
</view>
-
+
<!-- 鑿滃崟鏍� -->
<popup-menu @menuShow="menushow" ref="menuRef"></popup-menu>
</view>
</template>
<script>
- import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
- import combinedTitle from '@/components/common/combined-title/combined-title.vue';
- export default {
- data() {
- return {
- yibanData:
- {
- meizhongshenqing:'钁涙硥鐭跨敵璇凤細鐓ょ煾鐭�',
- renwu:'鍙戣繍瀹℃壒',
- liucheng:'鍙戣繍閫氱煡鍗�',
- faqiren:'钁涙硥鐭�',
- shenpiCaozuo:'瀹℃壒閫氳繃',
- shenpiyijian:'鍚屾剰',
- haoshi:'19绉�',
- createTime:'2022-5-25 12:06:15'
- },
- menuShow:false
- };
- },
- // 鐐瑰嚮瀵艰埅鏍忚彍鍗曞悗
- onNavigationBarButtonTap(e) {
- // console.log(e);
+import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
+import combinedTitle from '@/components/common/combined-title/combined-title.vue';
+export default {
+ data() {
+ return {
+ scheduleData: [],
+ // meizhongshenqing: '钁涙硥鐭跨敵璇凤細鐓ょ煾鐭�',
+ // renwu: '鍙戣繍瀹℃壒',
+ // liucheng: '鍙戣繍閫氱煡鍗�',
+ // faqiren: '钁涙硥鐭�',
+ // shenpiCaozuo: '瀹℃壒閫氳繃',
+ // shenpiyijian: '鍚屾剰',
+ // haoshi: '19绉�',
+ // createTime: '2022-5-25 12:06:15'
+ applicationId:null,
+ menuShow:false,
+ ifEmpty:false
+ };
+ },
+ onLoad(options){
+ this.applicationId = JSON.parse(options.index);
+ },
+ // 鐐瑰嚮瀵艰埅鏍忚彍鍗曞悗
+ onNavigationBarButtonTap(e) {
+ // console.log(e);
+ this.$refs.menuRef.menuClick();
+ },
+ onShow(){
+ if(this.menuShow == true){
this.$refs.menuRef.menuClick()
+ }
+ this.init();
+ },
+ components: {
+ combinedTitle,
+ popupMenu
+ },
+ methods: {
+ init(){
+ this.historicFlow()
},
- onShow(){
- if(this.menuShow == true){
- this.$refs.menuRef.menuClick()
- }
+ historicFlow(){
+ this.$reqGet('historicFlow',{},this.applicationId).then(res=>{
+ console.log('瀹℃壒鍘嗗彶',res);
+
+ if(res.code == 0){
+ if(res.data == null){
+ this.ifEmpty = true
+ } else{
+ this.scheduleData = res.data
+ }
+ }
+ })
},
- components: {
- combinedTitle,
- popupMenu
- },
- methods:{
- menushow(e){
- this.menuShow = e
- }
+ menushow(e){
+ this.menuShow = e
}
}
+};
</script>
<style lang="scss" scoped>
-.approval-history{
+::v-deep.approval-history {
width: 100%;
height: 100%;
- // 琛ㄦ牸
- .historyTable{
- margin:0 auto;
- width:91%;
- .uni-table{
-
- .uni-table-tr{
- .uni-table-th{
- width:vww(88);
- height:vww(40);
- background-color: #F5F5F5;
- color:#111111;
- font-size:vww(13);
+ .scheduleTable {
+ margin: vww(10) auto 0;
+ width: 91%;
+ .uni-table {
+ .uni-table-tr {
+ .uni-table-th {
+ width: vww(88);
+ height: vww(40);
+ background-color: #f5f5f5;
+ color: #111111;
+ font-size: vww(13);
font-weight: 500;
}
- .uni-table-td{
- width:vww(240);
- height:vww(40);
- background-color: #FFFFFF;
- color:#111111;
- font-size:vww(13);
+ .uni-table-td {
+ width: vww(240);
+ height: vww(40);
+ background-color: #ffffff;
+ color: #111111;
+ font-size: vww(13);
}
}
+ // 澶勭悊浜烘爣绛惧鍣�
+ .assigneesContainer{
+ .u-transition{
+ display:inline-block;
+ margin-left: vww(3);
+ }
+ }
}
// 杈规
// .table--border{
--
Gitblit v1.9.1