移动端
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

158 rader
5.9 KiB

  1. <template>
  2. <div>
  3. <van-nav-bar
  4. title="待办事项"
  5. />
  6. <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white" style="width: 96%;margin: 2%;height:128px;border-radius: 6px;">
  7. <van-swipe-item v-for="(image,index) in images" :key="index">
  8. <img :src="image" style="width:100%;height: 128px"/>
  9. </van-swipe-item>
  10. </van-swipe>
  11. <van-cell-group @click="goDetail(item)" v-for="(item,index) in taskList" :key="index" style="width: 96%;margin:2%;border-radius: 6px;overflow: hidden;padding-top: 10px;padding-bottom: 10px;box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);">
  12. <van-cell>
  13. <template #title>
  14. <van-row style="">
  15. <van-col span="23" :offset="1">
  16. <h3 style="display: inline-block;line-height: 30px;margin-left: 6px;width: 100%;overflow: hidden;">
  17. <van-image
  18. height="20"
  19. width="20"
  20. style="vertical-align: middle;margin-right: 10px"
  21. src="../../../../static/images/onlineHome/done.png"></van-image>{{item.projectName}}</h3>
  22. </van-col>
  23. </van-row>
  24. </template>
  25. </van-cell>
  26. <van-cell>
  27. <template #title>
  28. <van-row>
  29. <van-col span="6" :offset="1">
  30. <p style="color: #878787">{{item.createTime?item.createTime.substring(0,10):item.startTime.substring(0,10)}}</p>
  31. </van-col>
  32. <van-col span="10" :offset="1">
  33. <p style="color: #878787">{{item.formData.activityBusinessType}}</p>
  34. </van-col>
  35. <van-col span="5" :offset="1">
  36. <p style="font-size: 14px;font-weight:bold;text-align: right;color: #1D6FE9">{{activeName=='1'?'待审批':'已审批'}}</p>
  37. </van-col>
  38. </van-row>
  39. </template>
  40. </van-cell>
  41. </van-cell-group>
  42. <van-empty v-if="taskList.length<1" description="暂无事项" />
  43. <yinnongIndex></yinnongIndex>
  44. </div>
  45. </template>
  46. <script>
  47. import onlineHomeIndex from "../../onlineHomeIndex";
  48. import yinnongIndex from "../../yinnongIndex";
  49. import {ListDone, ListTodo} from "../../../api/onlineHome/done";
  50. export default {
  51. components: {
  52. onlineHomeIndex,
  53. yinnongIndex
  54. },
  55. name: "done",
  56. data(){
  57. return{
  58. taskList:[],
  59. activeName:this.$route.query.activeName?this.$route.query.activeName:'1',
  60. total:0,
  61. queryParams: {
  62. pageNum: 1,
  63. pageSize: 100,
  64. },
  65. activityBusinessTypeOptions:[],
  66. images:['../../../../static/images/onlineHome/banner_03.png'],
  67. }
  68. },
  69. created() {
  70. this.getDicts("activity_business_type").then((response) => {
  71. this.activityBusinessTypeOptions = response.data;
  72. if(this.$route.query.activeName){
  73. this.activeName = this.$route.query.activeName
  74. }
  75. this.getList();
  76. });
  77. console.log(this.$route.query.fr)
  78. if(this.$route.query.fr){
  79. this.$cookies.set("from",this.$route.query.fr,"0")
  80. }
  81. },
  82. methods: {
  83. goOnlineHomeIndex(){
  84. if(this.$cookies.get("from")=="my"){
  85. this.$router.push({name:"yinnongMy"})
  86. }else{
  87. this.$router.push({name:"yinnongWorkbench"})
  88. }
  89. },
  90. getList() {
  91. this.taskList = []
  92. this.$set(this.queryParams, "systemType", '4');
  93. ListTodo(this.queryParams).then((response) => {
  94. response.rows.map(res => {
  95. if(res.tableName?res.tableName.indexOf('house')>0:""){
  96. res.tableName = '来自农村宅基地管理系统'
  97. }else if(res.tableName?res.tableName.indexOf('sys_seal')>0:""){
  98. res.tableName = '来自银农直联审批管理系统'
  99. }else if(res.tableName?res.tableName.indexOf('yinnong')>0:""){
  100. res.tableName = '来自银农直联审批管理系统'
  101. }
  102. if(this.activityBusinessTypeOptions){
  103. this.activityBusinessTypeOptions.map(t => {
  104. if(t.dictValue == res.formData.activityBusinessType){
  105. res.formData.activityBusinessType = t.dictLabel
  106. this.taskList.push(res)
  107. }
  108. });
  109. }
  110. })
  111. })
  112. },
  113. goDetail(item){
  114. console.log(item)
  115. let type = item.formData.processKey;
  116. switch (type) {
  117. case 'baseApply':
  118. case 'landscope':
  119. case 'accepting':
  120. this.$router.push({name:'approvalForm',query: {id:item.formData.id,taskId:item.taskId,instanceId:item.formData.instanceId,type:item.type}})
  121. break;
  122. case 'toReviewTransferProcess':
  123. case 'yinnong_transfer':
  124. if(item.formData.transferType == '10'){
  125. this.$router.push({name:'approvalApproval10',query: {id:item.formData.id,taskId:item.taskId,type:item.type}})
  126. break;
  127. }
  128. if(item.formData.transferType == '11'){
  129. this.$router.push({name:'approvalApproval11',query: {id:item.formData.id,taskId:item.taskId,type:item.type}})
  130. break;
  131. }
  132. if(item.formData.transferType == '12'){
  133. this.$router.push({name:'approvalApproval12',query: {id:item.formData.id,taskId:item.taskId,type:item.type}})
  134. break;
  135. }
  136. if(item.formData.transferType != '10'&&item.formData.transferType != '11'&&item.formData.transferType != '12'){
  137. this.$router.push({name:'approvalApproval',query: {id:item.formData.id,taskId:item.taskId,type:item.type}})
  138. break;
  139. }
  140. }
  141. }
  142. },
  143. }
  144. </script>
  145. <style scoped>
  146. >>>.my-swipe .van-swipe-item {
  147. color: #fff;
  148. font-size: 20px;
  149. line-height: 144px;
  150. text-align: center;
  151. }
  152. </style>