2 Achegas 727c541208 ... b6fde10d05

Autor SHA1 Mensaxe Data
  wangqiang b6fde10d05 Merge remote-tracking branch 'origin/master' hai 11 meses
  wangqiang f8be69f41e 移动端相关代码调整 hai 11 meses

+ 2 - 1
api/AppPath.js

@@ -13,4 +13,5 @@ export const PUBLIC_MODULES_PATH = "/public-modules-server";
 //中审
 export const CENTRECAREFUL_PATH = "/centrecareful-server";
 export const ASSESS_PATH = "/assess-server";
-export const FINANCE_PATH = "/finance-server";
+export const FINANCE_PATH = "/finance-server";
+export const LUCKY_PATH = "/lucky-server";

+ 34 - 0
api/centerservice/ccpm/CcpmService.js

@@ -0,0 +1,34 @@
+import request from "../../../common/request"
+import { FLOW_PATH as prefix } from "../../AppPath";
+
+export default {
+  getByIdGenerate: function (id, processDefKey) {
+    return request({
+      url: prefix+'/ccpm_control/getByIdGenerate',
+      method: 'get',
+      params: {id: id, processDefKey: processDefKey}
+    })
+  },
+  reimAudit: function (id, flag, comment, processDefKey) {
+    return request({
+      url: prefix+'/ccpm_reimbursement/reimAudit',
+      method: 'get',
+      params: {id: id, flag: flag, comment: comment, processDefKey: processDefKey}
+    })
+  },
+	invoiceAudit: function (id, flag, comment, processDefKey,jsonData) {
+		return request({
+			url: prefix+'/ccpm_reimbursement/invoiceAudit',
+			method: 'get',
+			params: {id: id, flag: flag, comment: comment, processDefKey: processDefKey, jsonData: jsonData}
+		})
+	},
+	queryByNumber: function(number){
+		return request({
+			url: prefix+'/ccpm_reimbursement/queryByNumber',
+			method: 'get',
+			params: {number: number}
+		})
+
+	}
+}

+ 34 - 28
components/jp-area-select/jp-area-select.vue

@@ -1,33 +1,39 @@
 <template>
-
-    <uni-data-picker :localdata="treeList" v-model="labels" :map="{text:'name', value: 'name'}" popup-title="请选择区域" @change="onchange"></uni-data-picker>
-
+    <uni-data-picker :localdata="treeList" v-model="labels" :map="{text:'name', value: 'code'}" :disabled="disabled" popup-title="请选择区域" @change="onchange"></uni-data-picker>
 </template>
 
 <script>
-  import areaService from "@/api/sys/areaService"
-  export default {
-    props: {
-	  value: String
-	},
-    data() {
-      return {
-		  labels: '',
-		  treeList: []
-      }
-    },
-	mounted() {
-		areaService.treeData().then((data)=>{
-			this.treeList = data
-			this.labels = this.value
-		}).catch((e)=>{
-			 throw e
-		})
-	},
-    methods: {
-      onchange(e) {
-		this.$emit('input', this.labels)
-      }
+    import areaService from "@/api/sys/areaService"
+    export default {
+        props: {
+            value: String,
+            disabled: {
+                type: Boolean,
+                default: false
+            },
+        },
+        data() {
+            return {
+                labels: '',
+                treeList: []
+            }
+        },
+        mounted() {
+            areaService.treeData().then((data) => {
+                this.treeList = data
+            }).catch((e) => {
+                throw e
+            })
+        },
+        watch: {
+            value(newValue) {
+                this.labels = newValue; // 在 value 改变时更新 labels
+            }
+        },
+        methods: {
+            onchange(e) {
+                this.$emit('input', this.labels)
+            }
+        }
     }
-  }
-  </script>
+</script>

+ 9 - 3
pages.json

@@ -217,9 +217,7 @@
 		},
 		{
 			"path" : "pages/test/luckyDraw/LuckyDrawEventsDetail",
-			"style" : {
-				"navigationBarTitleText": "IT兴趣小组招募"
-				}
+			"style" : {}
 		},
 		{
 			"path" : "pages/test/luckyDraw/LuckyDrawRegister",
@@ -238,6 +236,14 @@
 			"style" : {
 				"navigationBarTitleText": "IT兴趣小组招募成员"
 				}
+		},
+		{
+			"path" : "pages/generateForm/GenerateForm",
+			"style" : {}
+		},
+		{
+			"path" : "pages/generateForm/InvoiceUpdateGenerateForm",
+			"style" : {}
 		}
     ],
 	"subPackages": [{

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 773 - 93
pages/cw/invoice/InvoiceFormTask.vue


+ 1 - 0
pages/cw/invoice/InvoiceProjectChoose.vue

@@ -21,6 +21,7 @@
 				<view v-for="item in data" :key="item.id" style="padding: 10px;">
 					<view @tap="onItemClick(item)" style="display: flex; align-items: center;">
 						<view style="flex: 1;text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">{{ item.projectName }}</view>
+<!--						<view v-if="checkType === '2'"  style="flex: 1;text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">{{ item.reportNo }}</view>-->
 						<view v-if="item.checked" style="color: #409eff;">已选择</view>
 					</view>
 				</view>

+ 31 - 15
pages/cw/reimbursementApproval/info/ReimbursementForm.vue

@@ -454,6 +454,7 @@
                 listData: [],
                 reimbursementList: [],
                 inputForm: {
+                    type:'',
                     userName:'',
                     id: '',
                     procInsId: '',
@@ -521,6 +522,10 @@
             formReadOnly: {
                 type: Boolean,
                 default: false
+            },
+            status: {
+                type: String,
+                default: ''
             }
         },
         watch: {
@@ -573,26 +578,37 @@
                 this.inputForm.id = id
                 if (id) {
                     reimbursementApprovalService.findById(id).then((data) => {
-                        this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
-                            if (this.isNotEmpty(data)) {
-                                if (data === '发起人重新申请' || this.isEmpty(data)) {
-                                    this.nodeFlag = false
-                                    this.testFlag = false
-                                } else if (data === '综合管理部主任审批' || data === '公司领导审批' || data === '部门主任审批'){
-                                    this.testFlag = true
-                                    this.nodeFlag = false
-                                } else {
-                                    this.nodeFlag = true
-                                }
-                            }
-                        })
 
-                        if (this.userInfo.id === data.projectManager) {
+                        // 只有从我发起的还有已办事项抄送给我 进入流程页面的时候才会有这个值
+                        console.log('this.status', this.status)
+                        if (this.status === 'testSee') {
+                            this.nodeFlag = false
                             this.testFlag = true
                         } else {
-                            this.testFlag = false
+                            this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
+                                if (this.isNotEmpty(data)) {
+                                    if (data === '发起人重新申请' || this.isEmpty(data)) {
+                                        this.nodeFlag = false
+                                        this.testFlag = false
+                                    } else if (data === '综合管理部主任审批' || data === '公司领导审批' || data === '部门主任审批'){
+                                        this.testFlag = true
+                                        this.nodeFlag = false
+                                    } else {
+                                        this.nodeFlag = true
+                                    }
+                                }
+                            })
+
+                            if (this.userInfo.id === data.projectManager) {
+                                this.testFlag = true
+                            } else {
+                                this.testFlag = false
+                            }
                         }
 
+
+
+
                         this.inputForm = this.recover(this.inputForm, data)
 
                         if (this.inputForm.files) {

+ 20 - 10
pages/dailyOfficeWork/holiday/HolidayForm.vue

@@ -240,6 +240,10 @@
 			formReadOnly: {
 				type: Boolean,
 				default: false
+			},
+			status: {
+				type: String,
+				default: ''
 			}
 		},
 		watch: {
@@ -264,15 +268,21 @@
 				if (id) {
 					holidayService.queryById(id).then((data) => {
 
-						this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
-							if (this.isNotEmpty(data)) {
-								if (data === '调整重新发起' || this.isEmpty(data)) {
-									this.nodeFlag = false
-								} else {
-									this.nodeFlag = true
+						// 只有从我发起的还有已办事项抄送给我 进入流程页面的时候才会有这个值
+						if (this.status === 'testSee') {
+							this.nodeFlag = true
+						} else {
+							this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
+								if (this.isNotEmpty(data)) {
+									if (data === '调整重新发起' || this.isEmpty(data)) {
+										this.nodeFlag = false
+									} else {
+										this.nodeFlag = true
+									}
 								}
-							}
-						})
+							})
+						}
+						
 						this.inputForm = this.recover(this.inputForm, data)
 
 						if (this.inputForm.files) {
@@ -391,7 +401,7 @@
 					this.inputForm.endDay = this.formatDate(this.inputForm.endDay);
 				}
 
-				return new Promise((resolve, reject) => {
+				return new Promise(async (resolve, reject) => {
 
 					let errors = [];
 
@@ -408,7 +418,7 @@
 					if (this.inputForm.type === '1'){
 						if (this.isNotEmpty(this.inputForm.startDay) && this.isNotEmpty(this.inputForm.beginTime)
 							&& this.isNotEmpty(this.inputForm.endDay) && this.isNotEmpty(this.inputForm.endTime)) {
-							holidayService.checkType(this.inputForm).then((data)=>{
+							await holidayService.checkType(this.inputForm).then((data)=>{
 								let day=data.split(",")
 								if (!day[0].includes(this.inputForm.days)){
 									errors.push(data);

+ 236 - 0
pages/generateForm/GenerateForm.vue

@@ -0,0 +1,236 @@
+<template>
+  <view>
+    <view style="padding: 10px 0px 66px 0px;min-height: 100px">
+      <!--标题-->
+      <view style="text-align:center">
+        <text class="title">{{title}}</text>
+      </view>
+      <view class="card">
+        <!--表单-->
+        <test :grids="jsonData" :formData="formData"></test>
+        <transferRecordsModule :historicTaskList="historicTaskList"></transferRecordsModule>
+        <!--审核意见-->
+        <view v-if="type === 'audit'">
+          <view class="divider">
+            <text class="divider-content"><span style="color: red">*</span> 审批意见</text>
+          </view>
+          <textarea :rows="5" maxlength="500" placeholder="请填写审核意见:" v-model="comments" show-word-limit></textarea>
+        </view>
+        <!--操作按钮-->
+        <view class="bottom-wrap  flex">
+          <view class="flex-sub"
+                v-for="(button, index) in buttons" :key="index" >
+            <u-button type="primary" class=" buttonBox" :color="colors[index]" @click="submit(button, buttons)" :text="button.name"></u-button>
+          </view>
+        </view>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script>
+  import Test from './Test.vue';
+  import TransferRecordsModule from './TransferRecordsModule.vue';
+  import ccpmService from '@/api/centerservice/ccpm/CcpmService'
+
+  export default {
+    onLoad: function (option) {
+      this.flow = JSON.parse(decodeURIComponent(option.flow));
+      this.businessId = this.flow.id
+      this.processDefKey = this.flow.processDefKey
+      this.title = this.flow.title
+      this.type = this.flow.type
+      this.jsonData = []
+      this.comments = ''
+    },
+    data () {
+      return {
+        buttons: [
+          {code: '_flow_agree', name: '同意'},
+          {code: '_flow_reject', name: '驳回'},
+          {code: '_flow_close', name: '关闭'},
+        ],
+        colors: [ '#3c9cff', '#f56c6c', '#5ac725', '#f9ae3d', '#89c152',
+          '#c38cc1', '#448aca', '#73d1f1', '#ffb34b', '#f18080',
+          '#88a867', '#bfbf39', '#94d554', '#f19ec2', '#afaae4',
+          '#86cefa', '#98d1ee', '#72dcdc', '#9acdcb', '#77b1cc', '#80a7dc'
+        ],
+        flow: null,
+        formData: {
+          name: '',
+          email: '',
+          remarks: ''
+        },
+        jsonData: {},
+        historicTaskList: [],
+        title: '',
+        businessId: '',
+        loading: false,
+        type: '',
+        processDefKey: '',
+        comments: '' // 审核意见
+      }
+    },
+    activated () {
+      this.init()
+    },
+    created () {
+      this.init()
+    },
+    components: {
+      Test,
+      TransferRecordsModule,
+    },
+    methods: {
+      // 初始化
+      init () {
+        console.log('this.businessId  ', this.businessId)
+        this.$nextTick(async () => {
+          this.loading = true
+          await ccpmService.getByIdGenerate(this.businessId, this.processDefKey).then((data)=>{
+            if (data) {
+              console.log('data',data)
+              this.loading = false
+              this.jsonData = JSON.parse(JSON.stringify(data.list))
+              this.jsonData.files = data.files
+              this.historicTaskList = data.histoicFlow
+            } else {
+              this.loading = false
+            }
+          })
+
+        })
+      },
+      // 关闭
+      close () {
+        this.jsonData = []
+        this.comments = ''
+        uni.navigateTo({
+          url: '/pages/workbench/task/TodoList'
+        })
+      },
+      // 同意
+      agree () {
+        if (this.isEmpty(this.comments)) {
+          uni.showToast({ title: '请填写审批意见!', icon: "error" });
+        } else {
+          this.loading = true
+          ccpmService.reimAudit(this.businessId, 'yes', this.comments, this.processDefKey).then((data) => {
+            this.loading = false
+            if (data.success) {
+              uni.showToast({ title: data.message, icon: "success" });
+              this.close()
+            } else {
+              uni.showToast({ title: data.message, icon: "error" });
+            }
+          }).catch(() => {
+            this.loading = false
+          })
+        }
+      },
+      // 驳回
+      reject () {
+        if (this.isEmpty(this.comments)) {
+          uni.showToast({ title: '请填写审批意见', icon: "error" });
+        } else {
+
+          // 弹窗 二次确认
+          uni.showModal({
+            content: '确定驳回此报销申请吗?',
+            success: async (res) => {
+              if (res.confirm) {
+                ccpmService.reimAudit(this.businessId, 'no', this.comments, this.processDefKey).then((data) => {
+                  this.loading = false
+                  if (data.success) {
+                    uni.showToast({ title: data.message, icon: "success" });
+                    this.close()
+                  } else {
+                    uni.showToast({ title: data.message, icon: "error" });
+                  }
+                }).catch(() => {
+                  this.loading = false
+                })
+              }
+            },
+          })
+        }
+      },
+      isEmpty(value) {
+        let result = false;
+        if (value == null || value == undefined) {
+          result = true;
+        }
+        if (typeof value == 'string' && (value.replace(/\s+/g, "") == "" || value == "")) {
+          result = true;
+        }
+        if (typeof value == "object" && value instanceof Array && value.length === 0) {
+          result = true;
+        }
+        return result;
+      },
+      isNotEmpty (value) {
+        return !this.isEmpty(value)
+      },
+      submit (currentBtn, buttons) {
+
+        switch (currentBtn.code) {
+          case '_flow_agree': // 同意
+            this.agree()
+            break
+          case '_flow_reject': // 驳回
+            this.reject()
+            break
+          case '_flow_close':// 关闭
+            this.close()
+            break
+        }
+      }
+    }
+  }
+</script>
+
+<style scoped>
+  .title {
+    font-size: 24px;
+    font-weight: bold;
+  }
+
+  .card {
+    padding: 15px;
+    background-color: #fff;
+    box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
+  }
+
+  .divider {
+    display: flex;
+    align-items: center;
+    margin-top: 20px;
+  }
+
+  .divider-content {
+    font-size: 16px;
+    color: #333;
+  }
+
+  .FlowFormFooter {
+    display: flex;
+    justify-content: space-around;
+    margin-top: 2em;
+  }
+
+  button {
+    padding: 10px 20px;
+    border: none;
+    border-radius: 5px;
+  }
+
+  button[type=primary] {
+    background-color: #409eff;
+    color: #fff;
+  }
+
+  button[type=danger] {
+    background-color: #f56c6c;
+    color: #fff;
+  }
+</style>

+ 509 - 0
pages/generateForm/InvoiceModule.vue

@@ -0,0 +1,509 @@
+<template>
+    <view>
+        <u--form :model="inputForm" labelWidth="100px" class="u-form" labelPosition="left" :rules="rules" ref="inputForm">
+            <!-- 动态生成发票基本信息 -->
+            <el-row :gutter="15" v-for="(item, index_experience) in inputForm.workInvoiceProjectRelationList" :key="index_experience">
+                <el-col :span="24">
+                    <u-form-item label="">
+                        <u-divider :text="'基本信息 ' + (index_experience + 1)"></u-divider>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="项目名称" :prop="'workInvoiceProjectRelationList[' + index_experience + '].projectName'">
+                        <u--input v-model="item.projectName" :disabled="true" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="合同名称" :prop="'workInvoiceProjectRelationList[' + index_experience + '].workContractName'">
+                        <u--input v-model="item.workContractName" :disabled="true" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="项目编号" :prop="'workInvoiceProjectRelationList[' + index_experience + '].projectNum'">
+                        <u--input v-model="item.projectNum" :disabled="true" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="委托方" :prop="'workInvoiceProjectRelationList[' + index_experience + '].clientName'">
+                        <u--input v-model="item.clientName" :disabled="true" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="报告号" :prop="'workInvoiceProjectRelationList[' + index_experience + '].reportDataNum'">
+                        <u--input v-model="item.reportDataNum" :disabled="true" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+            </el-row>
+            <u-form-item label="">
+                <u-divider :text="`发票详情`"></u-divider>
+            </u-form-item>
+            <u-form-item label="发票类型" prop="invoiceTypeName">
+                <u--input v-model="inputForm.invoiceTypeName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开票类型" prop="newDrawerName">
+                <u--input v-model="inputForm.newDrawerName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="实际开票单位" prop="clientName">
+                <u--input v-model="inputForm.clientName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="纳税人识别号" prop="taxpayerIdentificationNo">
+                <u--input v-model="inputForm.taxpayerIdentificationNo" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="地址" prop="address">
+                <u--input v-model="inputForm.address" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="电话" prop="telephone">
+                <u--input v-model="inputForm.telephone" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开户银行" prop="bank">
+                <u--input v-model="inputForm.bank" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="银行账号" prop="bankNumber">
+                <u--input v-model="inputForm.bankNumber" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="收款类型" prop="chargeType">
+                <u--input v-model="inputForm.chargeType" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开票内容" prop="billingContent">
+                <u--input v-model="inputForm.billingContent" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="发票金额(元)" prop="money">
+                <u--input v-model="inputForm.money" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开票内容要求" prop="content">
+                <u--input v-model="inputForm.content" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开票人" prop="drawerName">
+                <u--input v-model="inputForm.drawerName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="开票时间" prop="invoiceDate" :required="true">
+                <el-date-picker
+                        v-model="inputForm.invoiceDate"
+                        type="date"
+                        placeholder="选择开票时间"
+                        style="width:100%"
+                        size="default"
+                        placement="bottom-start"
+                        clearable>
+                </el-date-picker>
+            </u-form-item>
+            <u-form-item label="领票时间" prop="takeDate">
+                <el-date-picker
+                        v-model="inputForm.takeDate"
+                        type="date"
+                        placeholder="选择领票时间"
+                        style="width:100%"
+                        size="default"
+                        placement="bottom-start"
+                        clearable>
+                </el-date-picker>
+            </u-form-item>
+            <u-form-item label="实际开票人" prop="actualDrawerName">
+                <u--input v-model="inputForm.actualDrawerName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="接收邮箱" prop="actualDrawerEmailAddress">
+                <u--input v-model="inputForm.actualDrawerEmailAddress" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="对账人" prop="accountCheckingUserName">
+                <u--input v-model="inputForm.accountCheckingUserName" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="对账地区" prop="area">
+                <u--input v-model="inputForm.area" :disabled="true" clearable></u--input>
+            </u-form-item>
+            <u-form-item label="备注" prop="remarks">
+                <u--input v-model="inputForm.remarks" :disabled="true" clearable></u--input>
+            </u-form-item>
+
+            <el-row  :gutter="15" :key="item.id" v-for="(item,index_experience) in this.inputForm.workAccountList">
+                <el-col :span="24">
+                    <u-form-item label="" >
+                        <el-divider content-position="left"> 发票明细详情 {{index_experience + 1}}</el-divider>
+                    </u-form-item>
+                </el-col>
+
+                <el-col :span="24">
+                    <u-form-item label="发票代码" :prop="'workAccountList[' + index_experience + '].code'"
+                                 :rules="[
+				     ]">
+                        <u--input v-model="item.code" placeholder="请填写发票代码" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="发票号" :prop="'workAccountList[' + index_experience + '].number'" :required="true"
+                                 :rules="[
+				     ]">
+                        <u--input v-model="item.number" placeholder="请填写发票号" @blur="validateNumber(index_experience)" clearable></u--input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="开票金额(元)" :prop="'workAccountList[' + index_experience + '].account'" :required="true"
+                                 :rules="[
+                    { validator: validateAmount, trigger: 'blur' }
+                 ]">
+                        <u-input v-model="item.account" placeholder="请填写开票金额(元)" clearable @input="handleInput($event, index_experience)" @blur="handleBlur($event, index_experience)"></u-input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="税率(%)" :prop="'workAccountList[' + index_experience + '].rate'"
+                                 :rules="[
+				     ]">
+                        <u-input v-model="item.rate" placeholder="请填写税率(%)" @input="handleRateInput($event, index_experience)" @blur="checkRate($event, index_experience)" clearable></u-input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="金额" :prop="'workAccountList[' + index_experience + '].amount'"
+                                 :rules="[
+				     ]">
+                        <u-input v-model="item.amount" placeholder="请填写金额" readonly clearable></u-input>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24">
+                    <u-form-item label="税额" :prop="'workAccountList[' + index_experience + '].tax'"
+                                 :rules="[
+				     ]">
+                        <u-input v-model="item.tax" placeholder="请填写税额" readonly clearable></u-input>
+                    </u-form-item>
+                </el-col>
+
+                <el-col :span="24" style="text-align: center">
+                    <u-form-item label="" >
+                        <el-button style="width: 100%" type="danger"  @click="removeRow(index_experience)" plain>删除发票明细 {{index_experience + 1}}</el-button>
+                    </u-form-item>
+                </el-col>
+            </el-row>
+            <u-form-item label="" >
+                <el-button style="width: 100%" type="primary" @click="addRow()" plain>新增发票明细</el-button>
+            </u-form-item>
+
+            <u-form-item label="附件">
+                <el-upload
+                        class="upload-demo"
+                        :action="`http://pk2cs5.natappfree.cc/api/public-modules-server/oss/file/webUpload/upload`"
+                        :on-remove="(file, fileList) => handleRemove(file, fileList,'')"
+                        :file-list="inputForm.files"
+                        :on-success="(response, file, fileList) => handleUploadSuccess(response, file, fileList,'')"
+                        :limit="3">
+                    <el-button size="small" type="primary" v-if="false">点击上传</el-button>
+                    <div slot="tip" class="el-upload__tip">只能上传不超过 3 个文件</div>
+                    <template slot="file" slot-scope="{ file }" v-if="shouldShowFile(file)">
+                        <span @click="handleFileClick(file)">{{ file.name }}</span>
+                    </template>
+                </el-upload>
+            </u-form-item>
+        </u--form>
+    </view>
+</template>
+
+
+<script>
+    import ccpmService from '@/api/centerservice/ccpm/CcpmService'
+    import OSSService from "@/api/sys/OSSService";
+    import moment from "moment";
+
+    export default {
+        name: 'DynamicForm',
+        props: {
+            invoice: {
+                type: Array,
+                required: true
+            },
+        },
+        data() {
+            return {
+                inputForm: {
+                    workInvoiceProjectRelationList: [],
+                    workAccountList: [],
+                    invoiceTypeName: "",
+                    newDrawerName: "",
+                    clientName: "",
+                    taxpayerIdentificationNo: "",
+                    address: "",
+                    telephone: "",
+                    bank: "",
+                    bankNumber: "",
+                    chargeType: "",
+                    billingContent: "",
+                    money: "",
+                    content: "",
+                    drawerName: "",
+                    invoiceDate: "",
+                    takeDate: "",
+                    actualDrawerName: "",
+                    actualDrawerEmailAddress: "",
+                    accountCheckingUserName: "",
+                    area: "",
+                    remarks: "",
+                    files: []
+                },
+                rules: {
+                    invoiceDate: [
+                        {
+                            required: true,
+                            message: '开票时间不能为空',
+                            trigger: ['blur', 'change']
+                        }
+                    ],
+                },
+                isDeletingRow: false,  // 标志变量
+            };
+        },
+        ossService: null,
+        created() {
+            this.ossService = new OSSService();
+        },
+        watch: {
+            invoice: {
+                handler(newVal) {
+                    this.assignment();
+                },
+                deep: true,
+                immediate: true
+            }
+        },
+        methods: {
+            getInputForm() {
+                return this.inputForm;
+            },
+            assignment() {
+                if (this.isDeletingRow) {
+                    return;  // 如果正在删除行,则不执行此方法
+                } else {
+                    if (Array.isArray(this.invoice) && this.invoice.length > 0) {
+                        this.inputForm = this.recover(this.inputForm, this.invoice[0])
+                        // this.inputForm = this.invoice[0];
+                        if (this.isEmpty(this.inputForm.invoiceDate)) {
+                            this.inputForm.invoiceDate = moment(new Date()).format('YYYY-MM-DD');
+                        }
+                        if(this.isEmpty(this.inputForm.workAccountList) || this.inputForm.workAccountList.length === 0 ) {
+                            this.inputForm.workAccountList.push({
+                                code: '',
+                                number: '',
+                                account: this.inputForm.money,
+                                rate: '',
+                                amount: '',
+                                tax: '',
+                                allAmount: ''
+                            })
+                        }
+                    }
+                }
+
+            },
+            isEmpty(value) {
+                return value == null || value === undefined || (typeof value === 'string' && value.trim() === '') || (Array.isArray(value) && value.length === 0);
+            },
+            isNotEmpty(value) {
+                return !this.isEmpty(value);
+            },
+            shouldShowFile(file) {
+                if (this.inputForm.files && this.inputForm.files.length > 0) {
+                    return this.inputForm.files.indexOf(file) !== -1;
+                }
+                return false;
+            },
+            async handleFileClick(file) {
+                await this.ossService.getTemporaryUrl(file.url).then((data) => {
+                    file.lsUrl = data;
+                });
+                if (this.isImage(file.name)) {
+                    this.handleImageClick(file.lsUrl);
+                } else {
+                    window.location.href = file.lsUrl;
+                }
+            },
+            isImage(fileName) {
+                const ext = fileName.toLowerCase().split('.').pop();
+                return ['jpg', 'jpeg', 'png', 'gif', 'bmp'].includes(ext);
+            },
+            handleImageClick(url) {
+                uni.previewImage({
+                    current: url,
+                    urls: [url],
+                });
+            },
+            handleDelete(file) {
+                const index = this.inputForm.files.indexOf(file);
+                if (index !== -1) {
+                    this.inputForm.files.splice(index, 1);
+                }
+            },
+            async validateNumber(index) {
+                const numberString = this.inputForm.workAccountList[index].number.trim(); // 去除空格
+                let errorDetected = false; // 布尔变量用于检测是否有错误发生
+
+                if (this.isNotEmpty(numberString)) {
+                    if (!/^\d+$/.test(numberString)) { // 使用正则表达式检查是否只包含数字字符
+                        uni.showToast({
+                            title: '发票号只能输入整数',
+                            icon: 'none',
+                            duration: 2000
+                        });
+                        errorDetected = true; // 如果有错误,设置为 true
+                    }
+
+                    // 验证发票号是否大于 8 位
+                    if (parseInt(numberString) > 99999999) {
+                        uni.showToast({
+                            title: '“发票号” 不可以大于 8 位,请重新输入',
+                            icon: 'none',
+                            duration: 2000
+                        });
+                        errorDetected = true; // 如果有错误,设置为 true
+                    }
+
+                    // 验证是否重复
+                    for (let i = 0; i < this.inputForm.workAccountList.length; i++) {
+                        if (index !== i && numberString === this.inputForm.workAccountList[i].number) {
+                            uni.showToast({
+                                title: '“发票号” 已存在,请重新输入',
+                                icon: 'none',
+                                duration: 2000
+                            });
+                            errorDetected = true; // 如果有错误,设置为 true
+                            break; // 找到重复即可跳出循环
+                        }
+                    }
+
+                    // 查询是否已存在
+                    await ccpmService.queryByNumber(numberString).then((data) => {
+                        if (data === true) {
+                            uni.showToast({
+                                title: '“发票号” 已存在,请重新输入',
+                                icon: 'none',
+                                duration: 2000
+                            });
+                            errorDetected = true; // 如果有错误,设置为 true
+                        }
+                    });
+
+                    // 只在发生错误时清空输入字段
+                    if (errorDetected) {
+                        this.$set(this.inputForm.workAccountList[index], 'number', '');
+                    }
+                }
+
+            },
+            // 根据开票金额和税率计算出金额: 开票金额-税率*开票金额
+            getAmount(rate,rowIndex) {
+                let amount = this.inputForm.workAccountList[rowIndex].amount
+                let account = this.inputForm.workAccountList[rowIndex].account
+                if (!this.isEmpty(account) && !this.isEmpty(rate)) {
+                    amount = parseFloat((parseFloat(account) - parseFloat((parseFloat(account) * parseFloat((parseFloat(rate) / 100).toFixed(4))).toFixed(4))).toFixed(2))
+                } else {
+                    amount = ''
+                }
+                this.$set(this.inputForm.workAccountList[rowIndex], 'amount', amount)
+            },
+            // 根据开票金额和税率计算出税额: 税率*开票金额
+            getTax(rate,rowIndex) {
+                let tax = this.inputForm.workAccountList[rowIndex].tax
+                let account = this.inputForm.workAccountList[rowIndex].account
+                if (!this.isEmpty(account) && !this.isEmpty(rate)) {
+                    tax = parseFloat((parseFloat(account) * parseFloat((parseFloat(rate) / 100).toFixed(4))).toFixed(2))
+                } else {
+                    tax = ''
+                }
+                this.$set(this.inputForm.workAccountList[rowIndex], 'tax', tax)
+            },
+            validateAmount(rule, value, callback) {
+                const reg = /^\d+(\.\d{1,2})?$/;
+                if (!value) {
+                    callback(new Error('请输入开票金额'));
+                } else if (!reg.test(value)) {
+                    callback(new Error('请输入有效的开票金额,最多两位小数'));
+                } else {
+                    callback();
+                }
+            },
+            handleInput(event, index) {
+                const value = event;
+                const reg = /^\d*\.?\d{0,2}$/;
+                if (!reg.test(value)) {
+                    // 保留符合规则的部分
+                    const validValue = value.slice(0, -1);
+
+                    this.$nextTick(() => {
+                        this.$set(this.inputForm.workAccountList[index], 'account', validValue);
+                    });
+                } else {
+                    this.$set(this.inputForm.workAccountList[index], 'account', value);
+                }
+            },
+            handleBlur(event, index) {
+                const value = event;
+                if (!value || isNaN(value)) {
+                    this.$set(this.inputForm.workAccountList[index], 'account', '');
+                } else {
+                    const formattedValue = parseFloat(value).toFixed(2);
+
+                    this.$nextTick(() => {
+                        this.$set(this.inputForm.workAccountList[index], 'account', formattedValue);
+                    });
+                }
+            },
+            handleRateInput(event, rowIndex) {
+                const value = event;
+                const reg = /^\d*\.?\d{0,2}$/;
+                if (!reg.test(value)) {
+                    // 保留符合规则的部分
+                    const validValue = value.slice(0, -1);
+
+                    this.$nextTick(() => {
+                        this.$set(this.inputForm.workAccountList[rowIndex], 'rate', validValue);
+                    });
+                } else {
+                    this.$set(this.inputForm.workAccountList[rowIndex], 'rate', value);
+                }
+            },
+            checkRate(event, rowIndex) {
+                const value = event;
+                if (!value || isNaN(value)) {
+                    this.$set(this.inputForm.workAccountList[rowIndex], 'rate', '');
+                } else {
+                    let validValue = parseFloat(value);
+                    if (!this.isEmpty(value)) {
+                        if (validValue < 1 || validValue > 100) {
+                            uni.showToast({
+                                title: '“税率” 请填写 1 到 100 之间的数字,请重新输入',
+                                icon: 'none',
+                                duration: 2000
+                            });
+                            validValue = '';
+                        } else {
+                            validValue = validValue.toFixed(2);
+                        }
+                    }
+
+                    this.$nextTick(() => {
+                        this.$set(this.inputForm.workAccountList[rowIndex], 'rate', validValue);
+                    });
+                    this.getAmount(validValue, rowIndex);
+                    this.getTax(validValue, rowIndex);
+                }
+
+            },
+            addRow() {
+                this.inputForm.workAccountList.push({
+                    code: '',
+                    number: '',
+                    account: '',
+                    rate: '',
+                    amount: '',
+                    tax: '',
+                    allAmount: ''
+                })
+            },
+            removeRow(index) {
+                this.isDeletingRow = true;  // 设置标志变量
+                this.inputForm.workAccountList.splice(index, 1);
+            },
+        }
+    };
+</script>
+
+
+<style scoped>
+    .upload-demo {
+        margin-top: 10px;
+    }
+</style>

+ 295 - 0
pages/generateForm/InvoiceUpdateGenerateForm.vue

@@ -0,0 +1,295 @@
+<template>
+  <view>
+    <view style="padding: 10px 0px 66px 0px;min-height: 100px">
+      <!--标题-->
+      <view style="text-align:center">
+        <text class="title">{{title}}</text>
+      </view>
+      <view class="card">
+        <!--表单-->
+        <invoiceModule ref="invoiceModule" :invoice="jsonData" :formData="formData"></invoiceModule>
+        <transferRecordsModule :historicTaskList="historicTaskList"></transferRecordsModule>
+        <!--审核意见-->
+        <view v-if="type === 'audit'">
+          <view class="divider">
+            <text class="divider-content"><span style="color: red">*</span> 审批意见</text>
+          </view>
+          <textarea :rows="5" maxlength="500" placeholder="请填写审核意见:" v-model="comments" show-word-limit></textarea>
+        </view>
+        <!--操作按钮-->
+        <view class="bottom-wrap  flex">
+          <view class="flex-sub"
+                v-for="(button, index) in buttons" :key="index" >
+            <u-button type="primary" class=" buttonBox" :color="colors[index]" @click="submit(button, buttons)" :text="button.name"></u-button>
+          </view>
+        </view>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script>
+  import InvoiceModule from './InvoiceModule.vue';
+  import TransferRecordsModule from './TransferRecordsModule.vue';
+  import ccpmService from '@/api/centerservice/ccpm/CcpmService'
+
+  export default {
+    onLoad: function (option) {
+      this.flow = JSON.parse(decodeURIComponent(option.flow));
+      this.businessId = this.flow.id
+      this.processDefKey = this.flow.processDefKey
+      this.title = this.flow.title
+      this.type = this.flow.type
+      this.jsonData = []
+      this.comments = ''
+    },
+    data () {
+      return {
+        buttons: [
+          {code: '_flow_agree', name: '同意'},
+          {code: '_flow_reject', name: '驳回'},
+          {code: '_flow_close', name: '关闭'},
+        ],
+        colors: [ '#3c9cff', '#f56c6c', '#5ac725', '#f9ae3d', '#89c152',
+          '#c38cc1', '#448aca', '#73d1f1', '#ffb34b', '#f18080',
+          '#88a867', '#bfbf39', '#94d554', '#f19ec2', '#afaae4',
+          '#86cefa', '#98d1ee', '#72dcdc', '#9acdcb', '#77b1cc', '#80a7dc'
+        ],
+        flow: null,
+        formData: {
+          name: '',
+          email: '',
+          remarks: ''
+        },
+        jsonData: [],
+        historicTaskList: [],
+        title: '',
+        businessId: '',
+        type: '',
+        processDefKey: '',
+        comments: '' // 审核意见
+      }
+    },
+    activated () {
+      this.init()
+    },
+    created () {
+      this.init()
+    },
+    components: {
+      InvoiceModule,
+      TransferRecordsModule,
+    },
+    methods: {
+      // 初始化
+      init () {
+        this.$nextTick(async () => {
+          await ccpmService.getByIdGenerate(this.businessId, this.processDefKey).then((data)=>{
+            if (data) {
+              this.jsonData = Array.isArray(data) ? data : [data];
+              this.historicTaskList = data.histoicFlow
+            } else {
+            }
+          })
+
+        })
+      },
+      // 关闭
+      close () {
+        this.jsonData = []
+        this.comments = ''
+        uni.navigateTo({
+          url: '/pages/workbench/task/TodoList'
+        })
+      },
+      // 同意
+      async agree () {
+        const inputForm = this.$refs.invoiceModule.getInputForm();
+        return new Promise(  (resolve, reject) => {
+          // 表单规则验证
+          // ...
+
+          let errors = [];
+
+          if (this.isEmpty(inputForm.invoiceDate)) {
+            errors.push('开票时间不能为空');
+          }
+
+          let acc = 0
+          let i = inputForm.workAccountList.length;
+          for (let j = 0; j < i; j++) {
+            let k = j + 1;
+            if (this.isEmpty(inputForm.workAccountList[j].number)) {
+              errors.push('发票明细中第' + k + ' 条数据的 “发票号” 为空');
+            }
+            if (this.isEmpty(inputForm.workAccountList[j].account)) {
+              errors.push('发票明细中第' + k + ' 条数据的 “开票金额” 为空');
+            }
+            acc = (acc + parseFloat(parseFloat(inputForm.workAccountList[j].account).toFixed(2)))
+          }
+
+          if (parseFloat(acc).toFixed(2) !== parseFloat(inputForm.money).toFixed(2)) {
+            errors.push('发票明细中 “开票金额”总和 与发票详情中 “发票金额” 不等');
+          }
+
+          let errorDetected = true; // 布尔变量用于检测是否有错误发生
+          inputForm.workAccountList.forEach( async(item, index) => {
+            const numberString = item.number.trim(); // 去除空格
+            // 查询是否已存在
+            await ccpmService.queryByNumber(numberString).then((data) => {
+              if (data === true) {
+                errorDetected = false
+                errors.push('“发票号” 已存在,请重新输入');
+              }
+            });
+            if (errorDetected) {
+              inputForm.workAccountList.forEach((item2, index2) => {
+                if (index !== index2) {
+                  if (item.number === item2.number) {
+                    errors.push('发票明细中第 ' + (index + 1) + ' 条数据的 “发票号” 存在重复');
+                  }
+
+                }
+              })
+            }
+
+          })
+
+          if (errors.length > 0) {
+            // 存在错误,显示提示信息
+            errors.forEach(error => {
+              uni.showToast({
+                title: error,
+                icon: 'none',
+                duration: 2000
+              });
+            });
+            reject('Form validation failed');
+          } else {
+
+            if (this.isEmpty(this.comments)) {
+              uni.showToast({ title: '请填写审批意见!', icon: "error" });
+            } else {
+              let jsonData = JSON.stringify(inputForm)
+              ccpmService.invoiceAudit(this.businessId, 'yes', this.comments, this.processDefKey,jsonData).then((data) => {
+                if (data.success) {
+                  this.$message.success(data.message)
+                  this.close()
+                } else {
+                  this.$message.error(data.message)
+                }
+              }).catch(() => {
+
+              })
+            }
+          }
+        });
+      },
+      // 驳回
+      reject () {
+        const inputForm = this.$refs.invoiceModule.getInputForm();
+        if (this.isEmpty(this.comments)) {
+          uni.showToast({ title: '请填写审批意见', icon: "error" });
+        } else {
+
+          // 弹窗 二次确认
+          uni.showModal({
+            content: '确定驳回此报销申请吗?',
+            success: async (res) => {
+              if (res.confirm) {
+                let jsonData = JSON.stringify(inputForm)
+                ccpmService.invoiceAudit(this.businessId, 'no', this.comments, this.processDefKey,jsonData).then((data) => {
+
+                  if (data.success) {
+                    this.$message.success(data.message)
+                    this.close()
+                  } else {
+                    this.$message.error(data.message)
+                  }
+                }).catch(() => {
+
+                })
+              }
+            },
+          })
+        }
+      },
+      isEmpty(value) {
+        let result = false;
+        if (value == null || value == undefined) {
+          result = true;
+        }
+        if (typeof value == 'string' && (value.replace(/\s+/g, "") == "" || value == "")) {
+          result = true;
+        }
+        if (typeof value == "object" && value instanceof Array && value.length === 0) {
+          result = true;
+        }
+        return result;
+      },
+      isNotEmpty (value) {
+        return !this.isEmpty(value)
+      },
+      submit (currentBtn, buttons) {
+
+        switch (currentBtn.code) {
+          case '_flow_agree': // 同意
+            this.agree()
+            break
+          case '_flow_reject': // 驳回
+            this.reject()
+            break
+          case '_flow_close':// 关闭
+            this.close()
+            break
+        }
+      }
+    }
+  }
+</script>
+
+<style scoped>
+  .title {
+    font-size: 24px;
+    font-weight: bold;
+  }
+
+  .card {
+    padding: 15px;
+    background-color: #fff;
+    box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
+  }
+
+  .divider {
+    display: flex;
+    align-items: center;
+    margin-top: 20px;
+  }
+
+  .divider-content {
+    font-size: 16px;
+    color: #333;
+  }
+
+  .FlowFormFooter {
+    display: flex;
+    justify-content: space-around;
+    margin-top: 2em;
+  }
+
+  button {
+    padding: 10px 20px;
+    border: none;
+    border-radius: 5px;
+  }
+
+  button[type=primary] {
+    background-color: #409eff;
+    color: #fff;
+  }
+
+  button[type=danger] {
+    background-color: #f56c6c;
+    color: #fff;
+  }
+</style>

+ 357 - 0
pages/generateForm/Test.vue

@@ -0,0 +1,357 @@
+<template>
+    <view>
+        <!-- 动态生成的报销详情表单 -->
+        <u-form>
+            <!-- 动态生成的普通表单 -->
+            <el-row :gutter="15">
+                <el-col :span="24">
+                    <div class="form-grid">
+                        <div v-for="(grid, gridIndex) in gridsTest" :key="grid.key">
+                            <div v-for="(col, colIndex) in grid.columns" :key="col.key" class="form-column">
+                                <div v-for="(field, fieldIndex) in col.list" :key="field.key" class="form-field">
+                                    <div v-if="field.type === 'input'" class="form-item">
+                                        <text>{{ field.name }}:</text>
+                                        <input
+                                                v-model="formModel[field.model]"
+                                                :placeholder="field.options.placeholder"
+                                                :disabled="field.options.disabled"
+                                                :maxlength="field.options.maxlength"
+                                                :class="{'input-field': true, 'input-disabled': field.options.disabled}"
+                                        />
+                                    </div>
+                                    <div v-if="field.type === 'textarea'" class="form-item">
+                                        <text>{{ field.name }}:</text>
+                                        <textarea
+                                                v-model="formModel[field.model]"
+                                                :placeholder="field.options.placeholder"
+                                                :disabled="field.options.disabled"
+                                                :rows="field.options.rows || 2"
+                                                :class="{'textarea-field': true, 'textarea-disabled': field.options.disabled}"
+                                        />
+                                    </div>
+                                </div>
+                            </div>
+                        </div>
+                    </div>
+                </el-col>
+            </el-row>
+
+            <el-row :gutter="15" v-for="(item, index_experience) in formModelDetail" :key="index_experience">
+                <el-col :span="24">
+                    <u-form-item label="">
+                        <u-divider :text="'报销详情 ' + (index_experience + 1)"></u-divider>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24" v-for="(column, colIndex) in gridsDetail[0].tableColumns" :key="colIndex">
+                    <u-form-item :label="column.name" :prop="`formModelDetail[${index_experience}].${column.model}`">
+                        <template v-if="column.type === 'text'">
+                            <u-input v-model="formModelDetail[index_experience][column.model]" :disabled="true" placeholder="" clearable></u-input>
+                        </template>
+                        <template v-else-if="column.type === 'date'">
+                            <el-date-picker v-model="formModelDetail[index_experience][column.model]" :disabled="true" type="date" style="width:100%" size="default" placement="bottom-start" clearable></el-date-picker>
+                        </template>
+                    </u-form-item>
+                </el-col>
+            </el-row>
+
+            <!--   动态生成专用发票信息   -->
+            <el-row :gutter="15" v-for="(item, invoice_index) in invoiceFormModelDetail" :key="invoice_index">
+                <el-col :span="24">
+                    <u-form-item label="">
+                        <u-divider :text="'专用发票信息 ' + (invoice_index + 1)"></u-divider>
+                    </u-form-item>
+                </el-col>
+                <el-col :span="24" v-for="(column, colIndex) in gridsInvoice[0].tableColumns" :key="colIndex">
+                    <u-form-item :label="column.name" :prop="`invoiceFormModelDetail[${invoice_index}].${column.model}`">
+                        <template v-if="column.type === 'text'">
+                            <u-input v-model="invoiceFormModelDetail[invoice_index][column.model]" :disabled="true" placeholder="" clearable></u-input>
+                        </template>
+                        <template v-else-if="column.type === 'date'">
+                            <el-date-picker v-model="invoiceFormModelDetail[invoice_index][column.model]" :disabled="true" type="date" style="width:100%" size="default" placement="bottom-start" clearable></el-date-picker>
+                        </template>
+                    </u-form-item>
+                </el-col>
+            </el-row>
+
+            <u-form-item label="附件">
+                <el-upload
+                        class="upload-demo"
+                        :action="`http://pk2cs5.natappfree.cc/api/public-modules-server/oss/file/webUpload/upload`"
+                        :on-remove="(file, fileList) => handleRemove(file, fileList,'')"
+                        :file-list="files"
+                        :on-success="(response, file, fileList) => handleUploadSuccess(response, file, fileList,'')"
+                        :limit="3">
+                    <el-button size="small" type="primary" v-if="false">点击上传</el-button>
+                    <div slot="tip" class="el-upload__tip">只能上传不超过 3 个文件</div>
+                    <template slot="file" slot-scope="{ file }" v-if="shouldShowFile(file)">
+                        <span @click="handleFileClick(file)">{{ file.name }}</span>
+                        <!--                        <el-button type="text" @click="handleDelete(file,'')"> ✕ </el-button>-->
+                    </template>
+                </el-upload>
+
+            </u-form-item>
+        </u-form>
+    </view>
+</template>
+
+<script>
+    import OSSService from "@/api/sys/OSSService"
+    export default {
+        name: 'DynamicForm',
+        props: {
+            grids: {
+                type: Array,
+                required: true
+            },
+        },
+        data() {
+            return {
+                gridsTest: [],
+                gridsDetail: [],
+                gridsInvoice: [],
+                formModel: {},
+                formModelDetail: [],
+                invoiceFormModelDetail: [],
+                files: [],
+                showFileList: []
+            };
+        },
+        ossService: null,
+        created() {
+            this.ossService = new OSSService()
+        },
+        watch: {
+            grids: {
+                handler(newVal) {
+                    this.initializeFormModel();
+                },
+                deep: true,
+                immediate: true
+            }
+        },
+        methods: {
+            initializeFormModel() {
+                this.files = this.grids.files
+                if (this.files) {
+                    this.files.forEach( (item,index) => {
+                        this.$set(this.showFileList, index, true);
+                    })
+                }
+                this.formModel = {};
+                for (let i = 0; i < this.grids.length; i++) {
+                    const grid = this.grids[i];
+                    //获取报销详情前的基本信息数据
+                    if (this.isNotEmpty(grid.name)) {
+                        // 切掉数组中从当前索引开始的所有元素
+                        this.gridsTest = this.grids.slice(0, i);
+                        break;
+                    }
+                }
+
+                this.gridsTest.forEach(grid => {
+                    grid.columns.forEach(col => {
+                        col.list.forEach(field => {
+                            this.$set(this.formModel, field.model, field.options.defaultValue || '');
+                        });
+                    });
+                });
+
+                this.getReimbursementDetails();
+                this.getInvoiceDetails();
+            },
+            //报销详情数据处理
+            getReimbursementDetails() {
+                this.formModelDetail = [];
+
+                let startIndex = -1;
+                let endIndex = -1;
+
+                // 找到 "报销详情" 和 "专用发票信息" 的索引
+                for (let i = 0; i < this.grids.length; i++) {
+                    const grid = this.grids[i];
+                    if (grid.name === "报销详情") {
+                        startIndex = i;
+                    }
+                    if (grid.name === "专用发票信息") {
+                        endIndex = i;
+                        break;
+                    }
+                }
+
+                // 确保找到的索引是有效的,并且 startIndex 在 endIndex 之前
+                if (startIndex !== -1 && endIndex !== -1 && startIndex < endIndex) {
+                    // 提取 startIndex 和 endIndex 之间的数据(不包括 "报销详情" 和 "专用发票信息" 本身)
+                    this.gridsDetail = this.grids.slice(startIndex + 1, endIndex);
+
+                    // 初始化 formModelDetail
+                    const defaultValueList = this.gridsDetail[0].options.defaultValue || [];
+                    defaultValueList.forEach((defaultValue, index_experience) => {
+                        const data = {};
+                        this.gridsDetail.forEach(grid => {
+                            grid.tableColumns.forEach(column => {
+                                if (defaultValue.hasOwnProperty(column.model)) {
+                                    this.$set(data, column.model, defaultValue[column.model] || '');
+                                }
+                            });
+                        });
+                        this.$set(this.formModelDetail, index_experience, data);
+                    });
+                } else {
+                    // 如果没有找到有效的索引范围,清空 gridsDetail
+                    this.gridsDetail = [];
+                }
+            },
+            // 发票详情数据处理
+            getInvoiceDetails() {
+                this.invoiceFormModelDetail = [];
+
+                let endIndex = -1;
+
+                // 找到 "专用发票信息" 的索引
+                for (let i = 0; i < this.grids.length; i++) {
+                    const grid = this.grids[i];
+                    if (grid.name === "专用发票信息") {
+                        endIndex = i;
+                        break;
+                    }
+                }
+
+                // 确保找到的索引是有效的,并且 startIndex 在 endIndex 之前
+                if (endIndex !== -1 && endIndex < this.grids.length ) {
+                    // 提取 startIndex 和 endIndex 之间的数据(不包括 "报销详情" 和 "专用发票信息" 本身)
+                    this.gridsInvoice = this.grids.slice(endIndex + 1, this.grids.length);
+
+                    // 初始化 invoiceFormModelDetail
+                    const defaultValueList = this.gridsInvoice[0].options.defaultValue || [];
+                    defaultValueList.forEach((defaultValue, invoice_index) => {
+                        const data = {};
+                        this.gridsInvoice.forEach(grid => {
+                            grid.tableColumns.forEach(column => {
+                                if (defaultValue.hasOwnProperty(column.model)) {
+                                    this.$set(data, column.model, defaultValue[column.model] || '');
+                                }
+                            });
+                        });
+                        this.$set(this.invoiceFormModelDetail, invoice_index, data);
+                    });
+                } else {
+                    // 如果没有找到有效的索引范围,清空 gridsInvoice
+                    this.gridsInvoice = [];
+                }
+            },
+            isEmpty(value) {
+                let result = false;
+                if (value == null || value == undefined) {
+                    result = true;
+                }
+                if (typeof value == 'string' && (value.replace(/\s+/g, "") == "" || value == "")) {
+                    result = true;
+                }
+                if (typeof value == "object" && value instanceof Array && value.length === 0) {
+                    result = true;
+                }
+                return result;
+            },
+            isNotEmpty(value) {
+                return !this.isEmpty(value);
+            },
+            shouldShowFile(file) {
+
+                if (this.files && this.files.length > 0) {
+                    // 返回一个布尔值,确定是否显示上传成功后的文件
+                    return this.showFileList[this.files.indexOf(file)];
+                }
+
+
+                return false; // 默认返回 false 或者其他适当的
+            },
+            async handleFileClick(file) {
+                await this.ossService.getTemporaryUrl(file.url).then((data) => {
+                    file.lsUrl = data
+                })
+                if (this.isImage(file.name)) {
+                    // 如果是图片文件,则执行放大显示图片的逻辑
+                    this.handleImageClick(file.lsUrl);
+                } else {
+                    // window.open(file.lsUrl, '_blank')
+                    window.location.href = file.lsUrl
+                    // 如果不是图片文件,则执行其他操作,比如下载文件等
+                }
+            },
+            // 判断文件是否是图片类型
+            isImage(fileName) {
+                const ext = fileName.toLowerCase().split('.').pop(); // 获取文件的后缀名
+                return ['jpg', 'jpeg', 'png', 'gif', 'bmp'].includes(ext); // 判断后缀名是否是图片类型
+            },
+            handleImageClick(url) {
+                let urls = [url]
+                // 大图预览
+                uni.previewImage({
+                    current: url,
+                    urls: urls,
+                })
+                // 在点击图片时执行放大显示的逻辑
+                // this.$alert(`<img src="${file.lsUrl}" style="max-width: 100%; max-height: 100%;" />`, '图片详情', {
+                //     dangerouslyUseHTMLString: true,
+                //     customClass: 'custom-alert'
+                // });
+            },
+            handleDelete(file) {
+                // 处理删除文件的逻辑
+                // 从文件列表中移除文件
+                const index = this.files.indexOf(file);
+                if (index !== -1) {
+                    this.files.splice(index, 1);
+                    this.showFileList.splice(index, 1); // 从showFileList中移除对应的元素
+                }
+
+
+            },
+        }
+    };
+</script>
+
+<style scoped>
+    .form-grid {
+        margin-bottom: 10px; /* 减少外边距 */
+    }
+    .form-column {
+        display: flex;
+        flex-direction: column;
+        margin-bottom: 10px; /* 减少外边距 */
+    }
+    .form-field {
+        margin-bottom: 10px; /* 减少外边距 */
+    }
+    .form-item {
+        display: flex;
+        flex-direction: column;
+    }
+    .input-field, .textarea-field {
+        width: 100%;
+        height: 30px;
+        border: 1px solid #ccc;
+        border-radius: 4px;
+    }
+    .textarea-field {
+        height: 60px;
+    }
+
+    /* 禁用状态样式 */
+    .input-disabled {
+        background-color: #f5f5f5;
+        border-color: #dcdcdc;
+        cursor: not-allowed;
+    }
+
+    .textarea-disabled {
+        background-color: #f5f5f5;
+        border-color: #dcdcdc;
+        cursor: not-allowed;
+    }
+
+    /* 解决父级容器的内边距问题 */
+    .upload-demo {
+        margin-top: 10px; /* 增加间距 */
+    }
+</style>

+ 83 - 0
pages/generateForm/TransferRecordsModule.vue

@@ -0,0 +1,83 @@
+<template>
+    <view>
+        <view class="padding bg-white">
+
+            <view class="cu-timeline" :key="index" v-for="(act, index) in historicTaskList">
+                <view class="cu-time">{{act.beginDate |formatDate('MM-DD')}}</view>
+                <view class="cu-item text-blue">
+                    <view class="content">
+                        <view class="cu-capsule radius">
+                            <view class="cu-tag bg-cyan">{{act.taskName}}</view>
+                        </view>
+
+                        <view class="margin-top">
+                            审批人 : {{act.assigneeName}}
+                        </view>
+<!--                        <view class="margin-top">-->
+<!--                            办理状态 :<view class="cu-tag bg-blue">{{act.comment.status}}</view>-->
+<!--                        </view>-->
+                        <view class="margin-top">
+                            审批意见 : {{act.comment}}
+                        </view>
+                        <view class="margin-top">
+                            开始时间 : {{act.beginDate |formatDate}}
+                        </view>
+                        <view class="margin-top">
+                            结束时间 : {{act.endDate |formatDate}}
+                        </view>
+                        <view class="margin-top">
+                            用时 : {{act.durationTime || '0秒'}}
+                        </view>
+                    </view>
+                </view>
+            </view>
+        </view>
+    </view>
+</template>
+
+<script>
+
+    export default {
+        name: 'TransferRecordsModule',
+        props: {
+            historicTaskList: {
+                type: Array,
+                required: true
+            },
+        },
+        data() {
+            return {
+            };
+        },
+        watch: {
+            historicTaskList: {
+                handler(newVal) {
+                    this.initializeFormModel();
+                },
+                deep: true,
+                immediate: true
+            }
+        },
+        methods: {
+            initializeFormModel() {
+                console.log('this.historicTaskList', this.historicTaskList)
+            },
+            isEmpty(value) {
+                let result = false;
+                if (value == null || value == undefined) {
+                    result = true;
+                }
+                if (typeof value == 'string' && (value.replace(/\s+/g, "") == "" || value == "")) {
+                    result = true;
+                }
+                if (typeof value == "object" && value instanceof Array && value.length === 0) {
+                    result = true;
+                }
+                return result;
+            },
+            isNotEmpty(value) {
+                return !this.isEmpty(value);
+            },
+        }
+    };
+</script>

+ 27 - 16
pages/human/depart/handover/HandoverAddForm.vue

@@ -93,6 +93,10 @@
             formReadOnly: {
                 type: Boolean,
                 default: false
+            },
+            status: {
+                type: String,
+                default: ''
             }
         },
         watch: {
@@ -116,26 +120,33 @@
                 this.inputForm.id = id
                 if (id) {
                     handoverService.findById(id).then((data) => {
-
-                        this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
-                            if (this.isNotEmpty(data)) {
-                                if (data === '调整重新申请' || this.isEmpty(data)) {
-                                    this.nodeFlag = false
-                                } else if (data === '部门主任审批'){
-                                    this.testFlag = true
-                                    this.nodeFlag = true
-                                } else {
-                                    this.nodeFlag = true
+                        // 只有从我发起的还有已办事项抄送给我 进入流程页面的时候才会有这个值
+                        if (this.status === 'testSee') {
+                            this.nodeFlag = true
+                        } else {
+                            this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
+                                if (this.isNotEmpty(data)) {
+                                    if (data === '调整重新申请' || this.isEmpty(data)) {
+                                        this.nodeFlag = false
+                                    } else if (data === '部门主任审批'){
+                                        this.testFlag = true
+                                        this.nodeFlag = true
+                                    } else {
+                                        this.nodeFlag = true
+                                    }
                                 }
-                            }
-                        })
+                            })
 
-                        if (this.userInfo.id === data.projectManager) {
-                            this.testFlag = true
-                        } else {
-                            this.testFlag = false
+                            if (this.userInfo.id === data.projectManager) {
+                                this.testFlag = true
+                            } else {
+                                this.testFlag = false
+                            }
                         }
 
+
+
+
                         this.inputForm = this.recover(this.inputForm, data)
                     })
                 }

+ 4 - 0
pages/human/depart/registration/DepartRegistrationAddForm.vue

@@ -99,6 +99,10 @@
             formReadOnly: {
                 type: Boolean,
                 default: false
+            },
+            status: {
+                type: String,
+                default: ''
             }
         },
         watch: {

+ 31 - 17
pages/materialManagement/collect/CollectForm.vue

@@ -347,6 +347,10 @@
             formReadOnly: {
                 type: Boolean,
                 default: false
+            },
+            status: {
+                type: String,
+                default: ''
             }
         },
         watch: {
@@ -426,15 +430,21 @@
                 if (id) {
                     collectService.findById(id).then((data) => {
 
-                        this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
-                            if (this.isNotEmpty(data)) {
-                                if (data === '重新发起申请' || this.isEmpty(data)) {
-                                    this.nodeFlag = false
-                                } else {
-                                    this.nodeFlag = true
+                        // 只有从我发起的还有已办事项抄送给我 进入流程页面的时候才会有这个值
+                        if (this.status === 'testSee') {
+                            this.nodeFlag = true
+                        } else {
+                            this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
+                                if (this.isNotEmpty(data)) {
+                                    if (data === '重新发起申请' || this.isEmpty(data)) {
+                                        this.nodeFlag = false
+                                    } else {
+                                        this.nodeFlag = true
+                                    }
                                 }
-                            }
-                        })
+                            })
+                        }
+
                         this.inputForm = this.recover(this.inputForm, data)
                         this.inputForm.collectDate = new Date(data.collectDate);
 
@@ -444,17 +454,21 @@
                             })
                         }
 
-                        this.inputForm.detailInfos.forEach( (item,index) => {
-                            if (this.isNotEmpty(item.fileInfoLost)) {
-                                this.fileList3[index] = []
-                                item.fileInfoLost.forEach( (item,index2) => {
-                                    this.fileList3[index].push(item)
-                                    this.$set(this.showFileList2, index2, true);
-                                })
+                        console.log('this.inputForm.detailInfos', this.inputForm.detailInfos)
+                        if (this.isNotEmpty(this.inputForm.detailInfos)){
+                            this.inputForm.detailInfos.forEach( (item,index) => {
+                                if (this.isNotEmpty(item.fileInfoLost)) {
+                                    this.fileList3[index] = []
+                                    item.fileInfoLost.forEach( (item,index2) => {
+                                        this.fileList3[index].push(item)
+                                        this.$set(this.showFileList2, index2, true);
+                                    })
 
-                            }
+                                }
+
+                            })
+                        }
 
-                        })
                     })
                 }
             },

+ 3 - 1
pages/materialManagement/purchase/MyDropdown.vue

@@ -8,6 +8,7 @@
                 @focus="showDropdown"
                 :fetch-suggestions="fetchSuggestions"
                 @select="handleSelect"
+                :disabled="disabled"
         >
             <template slot-scope="{ item }">
                 <span style="width: 100%;">{{ item.tradeName }}</span>
@@ -21,7 +22,8 @@
     export default {
         props: {
             index_experience: Number,
-            inputForm: Object
+            inputForm: Object,
+            disabled: Boolean // 接收传入的 disabled 属性
         },
         data() {
             return {

+ 112 - 49
pages/materialManagement/purchase/PurchaseForm.vue

@@ -49,55 +49,55 @@
                     <u-form-item label="采购人" :prop="'detailInfos[' + index_experience + '].purchaserAgent'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].purchaserAgent" placeholder="请选择采购人" @focus="openUserPullForm(index_experience)" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].purchaserAgent" placeholder="请选择采购人" @focus="openUserPullForm(index_experience)" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="采购人部门" :prop="'detailInfos[' + index_experience + '].procurementOffice'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].procurementOffice" placeholder="" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].procurementOffice" placeholder="" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="采购类型" :prop="'detailInfos[' + index_experience + '].procurementType'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].procurementType" placeholder="请选择采购类型" @focus="showPicker(index_experience)" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].procurementType" placeholder="请选择采购类型" @focus="showPicker(index_experience)" clearable></u--input>
                     </u-form-item>
                     <my-dropdown :index_experience="index_experience" :inputForm="inputForm"></my-dropdown>
                     <!--<u-form-item label="商品名称" :prop="'detailInfos[' + index_experience + '].tradeName'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].tradeName" placeholder="请选择物品名称" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].tradeName" placeholder="请选择物品名称" clearable></u--input>
                     </u-form-item>-->
 
                     <supplier-selector :index_experience="index_experience" :inputForm="inputForm"></supplier-selector>
-<!--                    <u-form-item label="供应商" :prop="'detailInfos[' + index_experience + '].supplierName'" -->
-<!--                                 :rules="[-->
-<!--				     ]">-->
-<!--                        <el-input v-model="inputForm.detailInfos[index_experience].supplierName" placeholder="请选择供应商" @focus="showGoods(index_experience)" clearable></el-input>-->
-<!--                    </u-form-item>-->
+                    <!--                    <u-form-item label="供应商" :prop="'detailInfos[' + index_experience + '].supplierName'" -->
+                    <!--                                 :rules="[-->
+                    <!--				     ]">-->
+                    <!--                        <u--input v-model="inputForm.detailInfos[index_experience].supplierName" placeholder="请选择供应商" @focus="showGoods(index_experience)" clearable></u--input>-->
+                    <!--                    </u-form-item>-->
                     <u-form-item label="商品单价(元)" :prop="'detailInfos[' + index_experience + '].tradePrice'"
                                  :rules="[
 				     ]">
-                        <el-input @input="changeValue" v-model="inputForm.detailInfos[index_experience].tradePrice" placeholder="请输入商品单价(元)" clearable></el-input>
+                        <u--input @blur="onInputCode(index_experience, $event,'tradePrice')" v-model="inputForm.detailInfos[index_experience].tradePrice" placeholder="请输入商品单价(元)" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="商品数量" :prop="'detailInfos[' + index_experience + '].tradeNumber'"
                                  :rules="[
 				     ]">
-                        <el-input @input="changeValue" v-model="inputForm.detailInfos[index_experience].tradeNumber" placeholder="请输入商品数量" clearable></el-input>
+                        <u--input @blur="onInputCode(index_experience, $event,'tradeNumber')" v-model="inputForm.detailInfos[index_experience].tradeNumber" placeholder="请输入商品数量" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="商品总价" :prop="'detailInfos[' + index_experience + '].priceSum'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].priceSum" placeholder="请输入商品总价" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].priceSum" placeholder="请输入商品总价" :readonly="true" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="单位" :prop="'detailInfos[' + index_experience + '].company'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].company"  placeholder="请输入单位" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].company"  placeholder="请输入单位" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="备注" :prop="'detailInfos[' + index_experience + '].remarks'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].remarks"  placeholder="请输入备注" clearable></el-input>
+                        <u--input v-model="inputForm.detailInfos[index_experience].remarks"  placeholder="请输入备注" clearable></u--input>
                     </u-form-item>
                     <u-form-item label="文件上传">
                         <el-upload
@@ -150,7 +150,7 @@
                 <u--input placeholder='自动生成'  v-model="inputForm.purchaseNo" disabled></u--input>
             </u-form-item>
             <u-form-item label="采购名称" borderBottom prop="purchaseSketch" :required="true">
-                <u--input placeholder='请填写采购名称'  v-model="inputForm.purchaseSketch" ></u--input>
+                <u--input placeholder='请填写采购名称' disabled  v-model="inputForm.purchaseSketch" ></u--input>
             </u-form-item>
             <u-form-item label="经办人" borderBottom prop="handledBy">
                 <u--input placeholder=''  v-model="inputForm.handledBy" disabled></u--input>
@@ -160,6 +160,7 @@
             </u-form-item>
             <u-form-item label="采购申请时间" borderBottom prop="purchaseDate" :required="true">
                 <el-date-picker
+                        :disabled="true"
                         v-model="inputForm.purchaseDate"
                         type="date"
                         placeholder="请选择采购申请时间"
@@ -170,13 +171,13 @@
                 </el-date-picker>
             </u-form-item>
             <u-form-item label="采购方式" borderBottom prop="purchaseMode" :required="true">
-                <jp-picker placeholder='请选择采购方式' v-model="inputForm.purchaseMode" rangeKey="label" rangeValue="value" :range="[
+                <jp-picker placeholder='请选择采购方式' v-model="inputForm.purchaseMode" :disabled="true" rangeKey="label" rangeValue="value" :range="[
 						        { label: '办公室采购', value: '1' },
 						        { label: '自行采购', value: '2' },
 						    ]"></jp-picker>
             </u-form-item>
             <u-form-item label="备注" borderBottom prop="remarks">
-                <u--textarea  placeholder='请填写备注信息' :rows="5" :maxlength="500" v-model="inputForm.remarks" ></u--textarea>
+                <u--textarea  placeholder='请填写备注信息' :disabled="true" :rows="5" :maxlength="500" v-model="inputForm.remarks" ></u--textarea>
             </u-form-item>
 
 
@@ -191,64 +192,65 @@
                     <u-form-item label="采购人" :prop="'detailInfos[' + index_experience + '].purchaserAgent'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].purchaserAgent" placeholder="请选择采购人" @focus="openUserPullForm(index_experience)" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].purchaserAgent" :disabled="true" placeholder="请选择采购人" @focus="openUserPullForm(index_experience)" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="采购人部门" :prop="'detailInfos[' + index_experience + '].procurementOffice'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].procurementOffice" placeholder="" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].procurementOffice" :disabled="true" placeholder="" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="采购类型" :prop="'detailInfos[' + index_experience + '].procurementType'" :required="true"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].procurementType" placeholder="请选择采购类型" @focus="showPicker(index_experience)" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].procurementType" :disabled="true" placeholder="请选择采购类型" @focus="showPicker(index_experience)" clearable></el-input>
                     </u-form-item>
-                    <my-dropdown :index_experience="index_experience" :inputForm="inputForm"></my-dropdown>
-<!--                    <u-form-item label="商品名称" :prop="'detailInfos[' + index_experience + '].tradeName'" -->
-<!--                                 :rules="[-->
-<!--				     ]">-->
-<!--                        <el-input v-model="inputForm.detailInfos[index_experience].tradeName" placeholder="请选择物品名称" @focus="showGoods(index_experience)" clearable></el-input>-->
-<!--                    </u-form-item>-->
-                    <supplier-selector :index_experience="index_experience" :inputForm="inputForm"></supplier-selector>
-<!--                    <u-form-item label="供应商" :prop="'detailInfos[' + index_experience + '].supplierName'" -->
-<!--                                 :rules="[-->
-<!--				     ]">-->
-<!--                        <el-input v-model="inputForm.detailInfos[index_experience].supplierName" placeholder="请选择供应商" @focus="showGoods(index_experience)" clearable></el-input>-->
-<!--                    </u-form-item>-->
+                    <my-dropdown :index_experience="index_experience" :disabled="true"  :inputForm="inputForm"></my-dropdown>
+                    <!--                    <u-form-item label="商品名称" :prop="'detailInfos[' + index_experience + '].tradeName'" -->
+                    <!--                                 :rules="[-->
+                    <!--				     ]">-->
+                    <!--                        <el-input v-model="inputForm.detailInfos[index_experience].tradeName" placeholder="请选择物品名称" @focus="showGoods(index_experience)" clearable></el-input>-->
+                    <!--                    </u-form-item>-->
+                    <supplier-selector :index_experience="index_experience" :disabled="true"  :inputForm="inputForm"></supplier-selector>
+                    <!--                    <u-form-item label="供应商" :prop="'detailInfos[' + index_experience + '].supplierName'" -->
+                    <!--                                 :rules="[-->
+                    <!--				     ]">-->
+                    <!--                        <el-input v-model="inputForm.detailInfos[index_experience].supplierName" placeholder="请选择供应商" @focus="showGoods(index_experience)" clearable></el-input>-->
+                    <!--                    </u-form-item>-->
                     <u-form-item label="商品单价(元)" :prop="'detailInfos[' + index_experience + '].tradePrice'"
                                  :rules="[
 				     ]">
-                        <el-input @change="changeValue" v-model="inputForm.detailInfos[index_experience].tradePrice" placeholder="请输入商品单价(元)" clearable></el-input>
+                        <el-input @change="changeValue" :disabled="true" v-model="inputForm.detailInfos[index_experience].tradePrice" placeholder="请输入商品单价(元)" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="商品数量" :prop="'detailInfos[' + index_experience + '].tradeNumber'"
                                  :rules="[
 				     ]">
-                        <el-input @change="changeValue" v-model="inputForm.detailInfos[index_experience].tradeNumber" placeholder="请输入商品数量" clearable></el-input>
+                        <el-input @change="changeValue" v-model="inputForm.detailInfos[index_experience].tradeNumber" :disabled="true" placeholder="请输入商品数量" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="商品总价" :prop="'detailInfos[' + index_experience + '].priceSum'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].priceSum" placeholder="请输入商品总价" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].priceSum" :disabled="true" placeholder="请输入商品总价" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="单位" :prop="'detailInfos[' + index_experience + '].company'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].company"  placeholder="请输入单位" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].company" :disabled="true" placeholder="请输入单位" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="备注" :prop="'detailInfos[' + index_experience + '].remarks'"
                                  :rules="[
 				     ]">
-                        <el-input v-model="inputForm.detailInfos[index_experience].remarks"  placeholder="请输入备注" clearable></el-input>
+                        <el-input v-model="inputForm.detailInfos[index_experience].remarks" :disabled="true" placeholder="请输入备注" clearable></el-input>
                     </u-form-item>
                     <u-form-item label="文件上传">
                         <el-upload
+                                :disabled="true"
                                 class="upload-demo"
                                 :action="`http://pv4uct.natappfree.cc/api/public-modules-server/oss/file/webUpload/upload`"
                                 :on-remove="(file, fileList) => handleRemove(file, fileList, index_experience,'detail')"
                                 :file-list="inputForm.detailInfos[index_experience].fileInfoLost"
                                 :on-success="(response, file, fileList) => handleUploadSuccess(response, file, fileList,index_experience,'detail')"
                                 :limit="3">
-                            <el-button size="small" type="primary">点击上传</el-button>
+                            <el-button size="small" :disabled="true" type="primary">点击上传</el-button>
                             <div slot="tip" class="el-upload__tip">只能上传不超过 3 个文件</div>
                             <template slot="file" slot-scope="{ file }" v-if="shouldShowFile(file,index_experience,'detail') || testFlag">
                                 <span @click="handleFileClick(file)">{{ file.name }}</span>
@@ -260,23 +262,24 @@
 
                 <el-col :span="24" style="text-align: center">
                     <u-form-item label="" >
-                        <el-button style="width: 100%" type="danger" @click="removeRow(index_experience)" plain>删除采购详情 {{index_experience + 1}}</el-button>
+                        <el-button style="width: 100%" :disabled="true" type="danger" @click="removeRow(index_experience)" plain>删除采购详情 {{index_experience + 1}}</el-button>
                     </u-form-item>
                 </el-col>
             </el-row>
             <u-form-item label="" >
-                <el-button style="width: 100%" type="primary" @click="addRow()" plain>新增采购详情</el-button>
+                <el-button style="width: 100%" type="primary" :disabled="true" @click="addRow()" plain>新增采购详情</el-button>
             </u-form-item>
 
             <u-form-item label="附件">
                 <el-upload
+                        :disabled="true"
                         class="upload-demo"
                         :action="`http://pv4uct.natappfree.cc/api/public-modules-server/oss/file/webUpload/upload`"
                         :on-remove="(file, fileList) => handleRemove(file, fileList, '','')"
                         :file-list="inputForm.files"
                         :on-success="(response, file, fileList) => handleUploadSuccess(response, file, fileList,'','')"
                         :limit="3">
-                    <el-button size="small" type="primary">点击上传</el-button>
+                    <el-button size="small" :disabled="true" type="primary">点击上传</el-button>
                     <div slot="tip" class="el-upload__tip">只能上传不超过 3 个文件</div>
                     <template slot="file" slot-scope="{ file }" v-if="shouldShowFile(file) || testFlag">
                         <span @click="handleFileClick(file)">{{ file.name }}</span>
@@ -414,6 +417,10 @@
             formReadOnly: {
                 type: Boolean,
                 default: false
+            },
+            status: {
+                type: String,
+                default: ''
             }
         },
         watch: {
@@ -485,15 +492,22 @@
                 if (id) {
                     materialManagementService.findById(id).then((data) => {
 
-                        this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
-                            if (this.isNotEmpty(data)) {
-                                if (data === '重新发起申请' || this.isEmpty(data)) {
-                                    this.nodeFlag = false
-                                } else {
-                                    this.nodeFlag = true
+                        // 只有从我发起的还有已办事项抄送给我 进入流程页面的时候才会有这个值
+                        if (this.status === 'testSee') {
+                            this.nodeFlag = true
+                        } else {
+                            this.commonApi.getTaskNameByProcInsId(data.procInsId).then((data) => {
+                                if (this.isNotEmpty(data)) {
+                                    if (data === '重新发起申请' || this.isEmpty(data)) {
+                                        this.nodeFlag = false
+                                    } else {
+                                        this.nodeFlag = true
+                                    }
                                 }
-                            }
-                        })
+                            })
+                        }
+
+
                         this.inputForm = this.recover(this.inputForm, data)
                         this.inputForm.purchaseDate = new Date(data.purchaseDate);
 
@@ -941,6 +955,55 @@
                 }
                 return false; // 默认返回 false 或者其他适当的
             },
+            onInputCode(index, event,type) {
+                const inputValue = event
+                const formattedValue = this.formatInput(inputValue);
+                if (type === 'tradePrice') {
+                    this.$set(this.inputForm.detailInfos[index], 'tradePrice', formattedValue)
+                }
+                if (type === 'tradeNumber') {
+                    this.$set(this.inputForm.detailInfos[index], 'tradeNumber', formattedValue)
+                }
+                if (this.isNotEmpty(this.inputForm.detailInfos[index].tradePrice && this.inputForm.detailInfos[index].tradeNumber)) {
+                    let priceSum =
+                        parseFloat(parseFloat(this.inputForm.detailInfos[index].tradePrice) * parseFloat(this.inputForm.detailInfos[index].tradeNumber)).toFixed(2)
+                    this.$set(this.inputForm.detailInfos[index], 'priceSum', priceSum)
+                }
+            },
+            // 通用的输入限制和格式化方法
+            formatInput(inputValue, decimalLimit = 2) {
+                console.log('inputValue', inputValue)
+                // 如果输入值不是数字或者不是有效的小数,则返回空字符串
+                if (!/^\d*\.?\d*$/.test(inputValue)) {
+                    return '';
+                }
+                // 只保留数字和一个小数点
+                let value = inputValue.replace(/[^\d.]/g, '');
+                // 只允许一个小数点
+                const dotIndex = value.indexOf('.');
+                if (dotIndex !== -1) {
+                    const substr = value.substr(dotIndex + 1);
+                    if (substr.indexOf('.') !== -1) {
+                        value = value.substr(0, dotIndex + 1) + substr.replace(/\./g, '');
+                    }
+                }
+                // 限制小数位数为指定的decimalLimit位数
+                if (dotIndex !== -1) {
+                    const integerPart = value.substring(0, dotIndex);
+                    const decimalPart = value.substring(dotIndex + 1);
+                    if (decimalPart.length > decimalLimit) {
+                        uni.showToast({
+                            title: '商品数量小数点后只能输入两位,请正确输入!',
+                            icon: 'none',
+                            duration: 2000
+                        });
+                        return ''; // 返回空字符串
+                    }
+                    value = integerPart + '.' + decimalPart;
+                }
+
+                return value;
+            },
         }
     }
 </script>

+ 3 - 1
pages/materialManagement/purchase/SupplierSelector.vue

@@ -8,6 +8,7 @@
                 @focus="showDropdown"
                 :fetch-suggestions="fetchSuggestions"
                 @select="handleSelect"
+                :disabled="disabled"
         >
             <template slot-scope="{ item }">
                 <span style="width: 100%;">{{ item.name }}</span>
@@ -21,7 +22,8 @@
     export default {
         props: {
             index_experience: Number,
-            inputForm: Object
+            inputForm: Object,
+            disabled: Boolean // 接收传入的 disabled 属性
         },
         data() {
             return {

+ 1 - 0
pages/workbench/task/ApplyList.vue

@@ -225,6 +225,7 @@
 				  procInsId: row.processInstanceId,
 				  procDefId: row.processDefinitionId
 				}).then((data) => {
+					data.status = 'testSee'
 					let query = {readOnly: true, title: row.vars.title, formTitle: row.vars.title, ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title', 'businessId')}
 					uni.navigateTo({
 					   url: '/pages/workbench/task/TaskFormDetail?flow='+JSON.stringify(query)

+ 1 - 0
pages/workbench/task/FlowCopyList.vue

@@ -140,6 +140,7 @@
 			  procInsId: row.procInsId,
 			  procDefId: row.procDefId
 			}).then((data) => {
+				data.status = 'testSee'
 				let query = {readOnly: true, title: row.procInsName, formTitle: row.procInsName, ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title', 'businessId')}
 				uni.navigateTo({
 				   url: '/pages/workbench/task/TaskFormDetail?flow='+JSON.stringify(query)

+ 1 - 0
pages/workbench/task/HistoryList.vue

@@ -104,6 +104,7 @@
 				  procInsId: row.processInstanceId,
 				  procDefId: row.processDefinitionId
 				}).then((data) => {
+					data.status = 'testSee'
 					let query = {readOnly: true, taskId: row.executionId, title: `${row.name}【${row.name}】`, formTitle: `${row.name}`, ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title', 'businessId')}
 					uni.navigateTo({
 					   url: '/pages/workbench/task/TaskFormDetail?flow='+JSON.stringify(query)

+ 85 - 40
pages/workbench/task/TaskForm.vue

@@ -1,7 +1,7 @@
 <template>
 	<view>
 		<u-subsection
-			:list="procInsId?['表单信息', '流转记录']:['表单信息']"
+			:list="procInsId?['表单信息']:['表单信息']"
 			mode="button"
 			:fontSize="16"
 			:current="tabIndex"
@@ -52,30 +52,30 @@
 						<view class="flex-sub"  v-show="button.isHide === '0'"
 						 v-for="(button, index) in buttons" :key="index" >
 						 <u-button type="primary" class=" buttonBox" :color="colors[index]" @click="submit(button, buttons)" :text="button.name"></u-button>
-						</view>						
+						</view>
 					</view>
 				</u--form>
 			</view>
 			<u-gap height="70"></u-gap>
 		</scroll-view>
 		</view>
-		<view v-show="1 === tabIndex">
+		<!--<view v-show="1 === tabIndex">
 			<view class="padding bg-white">
-	
+
 				<view class="cu-timeline" :key="index" v-for="(act, index) in historicTaskList">
 					<view class="cu-time">{{act.histIns.startTime |formatDate('MM-DD')}}</view>
 					<view class="cu-item text-blue">
 						<view class="content">
 							<view class="cu-capsule radius">
 								<view class="cu-tag bg-cyan">{{act.histIns.activityName}}</view>
-								<!-- <view class="cu-tag line-cyan">{{act.histIns.activityName}}</view> -->
+								&lt;!&ndash; <view class="cu-tag line-cyan">{{act.histIns.activityName}}</view> &ndash;&gt;
 							</view>
-							
+
 							<view class="margin-top">
 								审批人 : {{act.assigneeName}}
 							</view>
 							<view class="margin-top">
-								办理状态 :<view class="cu-tag bg-blue">{{act.comment.status}}</view> 
+								办理状态 :<view class="cu-tag bg-blue">{{act.comment.status}}</view>
 							</view>
 							<view class="margin-top">
 								审批意见 : {{act.comment.message}}
@@ -93,6 +93,40 @@
 					</view>
 				</view>
 			</view>
+		</view>-->
+		<u-divider :text="'流转记录'"></u-divider>
+		<view class="padding bg-white">
+
+			<view class="cu-timeline" :key="index" v-for="(act, index) in historicTaskList">
+				<view class="cu-time">{{act.histIns.startTime |formatDate('MM-DD')}}</view>
+				<view class="cu-item text-blue">
+					<view class="content">
+						<view class="cu-capsule radius">
+							<view class="cu-tag bg-cyan">{{act.histIns.activityName}}</view>
+							<!-- <view class="cu-tag line-cyan">{{act.histIns.activityName}}</view> -->
+						</view>
+
+						<view class="margin-top">
+							审批人 : {{act.assigneeName}}
+						</view>
+						<view class="margin-top">
+							办理状态 :<view class="cu-tag bg-blue">{{act.comment.status}}</view>
+						</view>
+						<view class="margin-top">
+							审批意见 : {{act.comment.message}}
+						</view>
+						<view class="margin-top">
+							开始时间 : {{act.histIns.startTime |formatDate}}
+						</view>
+						<view class="margin-top">
+							结束时间 : {{act.histIns.endTime |formatDate}}
+						</view>
+						<view class="margin-top">
+							用时 : {{act.durationTime || '0秒'}}
+						</view>
+					</view>
+				</view>
+			</view>
 		</view>
 	</view>
 </template>
@@ -149,10 +183,10 @@
 				  uni.showToast({ title: '没有关联流程表单!', icon: "none" });
 				} else {
 				  // uniapp 不支持动态组件,所以通过名称匹配决定调用的表单组件
-				  if(this.formUrl.endsWith('TestActivitiLeaveForm')){ 
-					  
+				  if(this.formUrl.endsWith('TestActivitiLeaveForm')){
+
 					  this.form = TestActivitiLeaveForm
-				  }else if(this.formUrl.endsWith('EnrollmentRegistrationAddForm')){ 
+				  }else if(this.formUrl.endsWith('EnrollmentRegistrationAddForm')){
 					  this.form = EnrollmentRegistrationAddForm
 				  }else if(this.formUrl.endsWith('DepartRegistrationAddForm')){
 					  this.form = DepartRegistrationAddForm
@@ -173,7 +207,7 @@
 				  }else{
 					  uni.showToast({ title: '没有关联流程表单!', icon: "none" });
 				  }
-				    
+
 				}
 			  } else { // 动态表单
 			  // 读取流程表单
@@ -263,8 +297,8 @@
 				buttons: [],
 				isCC: false,
 				isAssign: false,
-				colors: [ '#3c9cff', '#f56c6c', '#5ac725', '#f9ae3d', '#89c152',  
-						  '#c38cc1', '#448aca', '#73d1f1', '#ffb34b', '#f18080', 
+				colors: [ '#3c9cff', '#f56c6c', '#5ac725', '#f9ae3d', '#89c152',
+						  '#c38cc1', '#448aca', '#73d1f1', '#ffb34b', '#f18080',
 						  '#88a867', '#bfbf39', '#94d554', '#f19ec2', '#afaae4',
 						  '#86cefa', '#98d1ee', '#72dcdc', '#9acdcb', '#77b1cc', '#80a7dc'
 				],
@@ -315,9 +349,9 @@
 									  input.value =  JSON.parse(input.options.defaultValue)
 								  }else{
 									  input.value =  input.options.defaultValue
-								  } 
+								  }
 							}else{
-								
+
 								 input.value =  input.options.defaultValue || ''
 							}
 						}else{
@@ -331,7 +365,7 @@
 								   input.value = item.value
 							  }
 						}
-						
+
 						input.readable = item.readable
 						input.writable = item.writable
 					}else{
@@ -382,20 +416,23 @@
 			  },
 			// 暂存草稿
 			 save () {
-	  
+
 			 },
 			// 启动流程
 			start (vars) {
 			  if (this.formType === '2') { // 外置表单启动
 				this.$refs.form.saveForm((businessTable, businessId,inputForm) => {
-
-					if (inputForm.days){
-						this.days=inputForm.days
-					}
 					let assignee = this.auditForm.assignee
-					if (inputForm.assignee) {
-						assignee = inputForm.assignee
+					if (inputForm) {
+						if (inputForm.days){
+							this.days=inputForm.days
+						}
+
+						if (inputForm.assignee) {
+							assignee = inputForm.assignee
+						}
 					}
+
 				  taskService.start({
 					procDefKey: this.procDefKey,
 					businessTable: businessTable,
@@ -407,7 +444,7 @@
 				  }).then((data) => {
 					  uni.showToast({ title: "启动成功", icon: "success" });
 					  uni.navigateTo({
-						  url: '/pages/workbench/task/TodoList'
+						  url: '/pages/index/index'
 					  })
 					  this.cc(data)
 				  })
@@ -421,7 +458,7 @@
 				}, (data) => {
 					uni.showToast({ title: "启动成功", icon: "success" });
 					uni.navigateTo({
-						url: '/pages/workbench/task/TodoList'
+						url: '/pages/index/index'
 					})
 					this.cc(data)
 				})
@@ -460,17 +497,22 @@
 					}
 					this.$refs.form.reapplyForm((businessTable, businessId, inputForm,recordType) => {
 						vars = {...vars, ...inputForm,recordType}
-						if (inputForm.procDefId) {
-							param.procDefId = inputForm.procDefId
-						}
-						if (inputForm.days) {
-							this.days=inputForm.days
-						}
+
 						let assignee = this.auditForm.assignee
-						if (inputForm.assignee) {
-							assignee = inputForm.assignee
+						if (inputForm) {
+							if (inputForm.procDefId) {
+								param.procDefId = inputForm.procDefId
+							}
+							if (inputForm.days) {
+								this.days=inputForm.days
+							}
+
+							if (inputForm.assignee) {
+								assignee = inputForm.assignee
+							}
 						}
 
+
 						console.log('recordType', recordType)
 						this.recordType=recordType
 						console.log('this.recordType', this.recordType)
@@ -564,7 +606,7 @@
 			},
 			// 减签
 			delMultiInstance () {
-	  
+
 			},
 			// 转办
 			transfer () {
@@ -625,7 +667,7 @@
 			},
 			// 打印
 			print () {
-	  
+
 			},
 			// 关闭
 			close () {
@@ -648,9 +690,12 @@
 				}
 				 if (this.formType === '2') { //外置表单审批
 					this.$refs.form.agreeForm((businessTable, businessId,inputForm) => {
-						if (inputForm.days) {
-							this.days = inputForm.days
+						if (inputForm) {
+							if (inputForm.days) {
+								this.days = inputForm.days
+							}
 						}
+
 					  taskService.audit({
 						taskId: this.taskId,
 						taskDefKey: this.taskDefKey,
@@ -672,7 +717,7 @@
 				this.$refs.form.submitTaskFormData(vars, this.procInsId, this.taskId, this.auditForm.assignee, this.auditForm, (data) => {
 					uni.showToast({ title: "启动成功", icon: "success" });
 					uni.navigateTo({
-						url: '/pages/workbench/task/TodoList'
+						url: '/pages/index/index'
 					})
 					//抄送
 					this.cc(data)
@@ -681,7 +726,7 @@
 		},
 			submit (currentBtn, buttons) {
 			  let vars = {} // 存储流程变量
-	  
+
 			  // 把当前操作对应的自定义按钮(以_flow_开头的是系统按钮,排除在外)的编码,存储为对应的流程变量,值设置为true,其余自定义按钮编码对应的流程变量值为false。
 			  buttons.forEach((btn) => {
 				if (btn.code && !btn.code.startsWith('_flow_')) {
@@ -695,7 +740,7 @@
 			  vars.assignee = this.auditForm.assignee // 指定的下一步骤处理人
 			  this.auditForm.type = currentBtn.code // 提交类型
 			  this.auditForm.status = currentBtn.name // 按钮文字
-			  
+
 			  switch (currentBtn.code) {
 				case '_flow_start': // 自动流程
 				  this.start(vars)

+ 1 - 1
pages/workbench/task/TaskFormDetail.vue

@@ -9,7 +9,7 @@
 		></u-subsection>
 		<view v-show="0 === tabIndex">
 			<scroll-view scroll-y>
-				<component :formReadOnly="formReadOnly" :class="formReadOnly?'readonly':''"  ref="form" :businessId="businessId" :is="form"></component>
+				<component :formReadOnly="formReadOnly" :class="formReadOnly?'readonly':''"  ref="form" :status="status" :businessId="businessId" :is="form"></component>
 				<PreviewForm :formData="formData"  v-if="formType !== '2'"  :processDefinitionId="procDefId" :edit="false" ref="form"></PreviewForm>
 				<u-gap height="40" bgColor="#fff"></u-gap>
 			</scroll-view>

+ 69 - 2
pages/workbench/task/TodoList.vue

@@ -17,8 +17,8 @@
 							}
 						}]">
 						  <u-cell-group>
-							  <u-cell @click="todo(row)">
-								  <view slot="title" class="content">
+							  <u-cell @click="todoCcpm(row)" v-if="row.belongProject === 'ccpm'">
+								  <view slot="title" class="content" >
 										<view class="text-bold text-grey">
 											<view class="ellipsis-description">
 												标题:{{row.vars.title}}
@@ -37,6 +37,26 @@
 									<u-tag  text="等待审核" plain shape="circle" type="error"></u-tag>
 								  </view>
 								</u-cell>
+							  <u-cell @click="todo(row)" v-else>
+								  <view slot="title" class="content" >
+									  <view class="text-bold text-grey">
+										  <view class="ellipsis-description">
+											  标题:{{row.vars.title}}
+										  </view>
+									  </view>
+									  <view class="text-grey text-sm">
+										  <view class="ellipsis-description">
+											  当前环节:{{row.task && row.task.name}}
+										  </view>
+									  </view>
+									  <view class="text-grey text-sm">
+										  执行时间:{{row.task.createTime | formatDate}}
+									  </view>
+								  </view>
+								  <view slot="right-icon" class="action">
+									  <u-tag  text="等待审核" plain shape="circle" type="error"></u-tag>
+								  </view>
+							  </u-cell>
 						  </u-cell-group>
 						</u-swipe-action-item>
 				</view>
@@ -93,6 +113,53 @@
 					})
 				  })
 		      },
+			// 审核方法
+			todoCcpm (row) {
+				if (row.task.processDefKey === '108' || row.task.processDefKey === '109' || row.task.processDefKey === '13'|| row.task.processDefKey === '102') {
+					let id = row.vars.notifyId
+					let title = '报销申请审批'
+					this.toCenterForm(id, title, row.task.processDefKey, 'audit') // 跳转
+				} else if (row.task.processDefKey === '21' || row.task.processDefKey === '213') {
+
+					let id = row.vars.notifyId
+					let title = '发票申请审批'
+					this.toInvoiceUpdateCenterForm(id, title, row.task.processDefKey, 'audit') // 跳转
+				} else {
+					this.$message.warning('此流程的跨系统审核暂未开放,请前往所属系统进行审核')
+				}
+			},
+			// 审核页面跳转
+			toCenterForm (id, title, processDefKey, type) {
+				// 生成参数对象
+				const query = {
+					id: id,
+					backPath: '/workbench/task/TodoList',
+					title: title,
+					processDefKey: processDefKey,
+					type: type
+				};
+
+				// 使用 uni.navigateTo 进行页面跳转
+				uni.navigateTo({
+					url: '/pages/generateForm/GenerateForm?flow=' + JSON.stringify(query)
+				});
+			},
+			// 发票审核页面跳转(财务审批)
+			toInvoiceUpdateCenterForm (id, title, processDefKey, type) {
+				// 生成参数对象
+				const query = {
+					id: id,
+					backPath: '/workbench/task/TodoList',
+					title: title,
+					processDefKey: processDefKey,
+					type: type
+				};
+
+				// 使用 uni.navigateTo 进行页面跳转
+				uni.navigateTo({
+					url: '/pages/generateForm/InvoiceUpdateGenerateForm?flow=' + JSON.stringify(query)
+				});
+			},
 			// 输入监听
 			inputWord(e){
 				this.searchTimer && clearTimeout(this.searchTimer)