sangwenwei 1 rok pred
rodič
commit
3d7334ef09

+ 130 - 0
src/api/jy/JyFinanceInvoiceService.js

@@ -0,0 +1,130 @@
+import request from "@/utils/httpRequest";
+import { BUSINESS_PATH as prefix } from "../AppPath";
+
+export default {
+	list: function (params) {
+		return request({
+			url: prefix + "/cw_finance/invoice/list",
+			method: "get",
+			params: params,
+		});
+	},
+	queryById: function (id) {
+		return request({
+			url: prefix + "/cw_finance/invoice/queryById",
+			method: "get",
+			params: { id: id },
+		});
+	},
+	queryByNumber: function (number, id) {
+		return request({
+			url: prefix + "/cw_finance/invoice/queryByNumber",
+			method: "get",
+			params: { number: number, id: id },
+		});
+	},
+	save: function (inputForm) {
+		return request({
+			url: prefix + `/cw_finance/invoice/save`,
+			method: "post",
+			data: inputForm,
+		});
+	},
+	delete: function (ids) {
+		return request({
+			url: prefix + "/cw_finance/invoice/delete",
+			method: "delete",
+			params: { ids: ids },
+		});
+	},
+	updateStatusById: function (data) {
+		return request({
+			url: prefix + "/cw_finance/invoice/updateStatusById",
+			method: "post",
+			data: data,
+		});
+	},
+	isReceivables: function (data) {
+		return request({
+			url: prefix + "/cw_finance/invoice/isReceivables",
+			method: "post",
+			data: data,
+		});
+	},
+	saveForm: function (inputForm) {
+		return request({
+			url: prefix + `/cw_finance/invoice/saveForm`,
+			method: "post",
+			data: inputForm,
+		});
+	},
+	saveFormInvalid: function (inputForm) {
+		return request({
+			url: prefix + `/cw_finance/invoice/saveFormInvalid`,
+			method: "post",
+			data: inputForm,
+		});
+	},
+	queryIdByInvalidId: function (id) {
+		return request({
+			url: prefix + "/cw_finance/invoice/queryIdByInvalidId",
+			method: "get",
+			params: { id: id },
+		});
+	},
+	importDetail: function (data) {
+		return request({
+			url: prefix + "/cw_finance/invoice/importDetail",
+			method: "post",
+			data: data,
+		});
+	},
+	exportTemplate: function () {
+		return request({
+			url: prefix + "/cw_finance/invoice/importDetail/template",
+			method: "get",
+			responseType: "blob",
+		});
+	},
+	getByIds: function (projectId, invoiceForm) {
+		return request({
+			url: prefix + "/cw_finance/invoice/getByIds",
+			method: "get",
+			params: { projectId: projectId, ...invoiceForm },
+		});
+	},
+	getByContractId: function (contractId, invoiceForm) {
+		return request({
+			url: prefix + "/cw_finance/invoice/getByContractId",
+			method: "get",
+			params: { contractId: contractId, ...invoiceForm },
+		});
+	},
+	getIdByClientId: function (clientId, invoiceForm) {
+		return request({
+			url: prefix + "/cw_finance/invoice/getIdByClientId",
+			method: "get",
+			params: { clientId: clientId, ...invoiceForm },
+		});
+	},
+	exportFile: function (params) {
+		return request({
+			url: prefix + "/cw_finance/invoice/export",
+			method: "get",
+			params: params,
+			responseType: "blob",
+		});
+	},
+
+	getLabelById:function (param) {
+		return request({
+			url: prefix+"/cwProjectRecords/getLabelById",
+			method:"get",
+			params: {id: param}
+		})
+
+	}
+
+
+
+};

+ 8 - 0
src/api/jy/WorkClientService.js

@@ -93,4 +93,12 @@ export default class WorkClientService {
       params: {id: id, name: name}
     })
   }
+
+	getBillingListByClientId(params) {
+		return request({
+			url: prefix + "/JyWorkClientInfo/workClientInfo/getBillingListByClientId",
+			method: "get",
+			params: params,
+		});
+	}
 }

+ 5 - 1
src/views/flowable/task/TaskForm.vue

@@ -716,6 +716,8 @@ export default {
 		// Process_1701946907362 嘉溢-借款归还
 		// Process_1702002020267 嘉溢-付款管理\
 		// Process_1702277270803 嘉溢-报销管理
+		// Process_1702434644158 嘉溢-发票审核
+		// Process_1702435147188 嘉溢-发票作废
 
 		// 驳回
 		reject(vars) {
@@ -776,7 +778,9 @@ export default {
 				this.procDefId.includes('Process_1701936620599') ||
 				this.procDefId.includes('Process_1701946907362') ||
 				this.procDefId.includes('Process_1702002020267') ||
-				this.procDefId.includes('Process_1702277270803')
+				this.procDefId.includes('Process_1702277270803') ||
+				this.procDefId.includes('Process_1702434644158') ||
+				this.procDefId.includes('Process_1702435147188')
 			) {
 				console.log('进入新版驳回')
 				this.$confirm(`确定驳回流程吗?`, '提示', {

+ 162 - 0
src/views/jy/finance/ContractForm.vue

@@ -0,0 +1,162 @@
+<template>
+  <div>
+    <el-dialog
+      title="选择合同"
+      :close-on-click-modal="false"
+	  draggable
+      width="1100px"
+      height="500px"
+      @close="close"
+      append-to-body
+      v-model="visible">
+      <div style="height: calc(100% - 80px);">
+        <el-form :inline="true" class="query-form" ref="searchForm" :model="searchForm" @submit.native.prevent>
+          <!-- 搜索框-->
+          <el-form-item label="合同名称" prop="name">
+            <el-input v-model="searchForm.name" placeholder="请输入合同名称" clearable></el-input>
+          </el-form-item>
+          <el-form-item label="委派方" prop="clientName">
+            <el-input v-model="searchForm.clientName" placeholder="请输入委派方" clearable></el-input>
+          </el-form-item>
+
+          <el-form-item>
+            <el-button type="primary" @click="list()" icon="el-icon-search">查询</el-button>
+            <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
+          </el-form-item>
+        </el-form>
+
+        <vxe-table
+          border="inner"
+          auto-resize
+          resizable
+          height="400px"
+          :loading="loading"
+          ref="workContractTable"
+          show-header-overflow
+          show-overflow
+          highlight-hover-row
+          :menu-config="{}"
+          :print-config="{}"
+          :sort-config="{remote:true}"
+          :data="dataList"
+          :row-config="{isCurrent: true}"
+          :radio-config="{trigger: 'row'}">
+          <vxe-column type="seq" width="60" title="序号"></vxe-column>
+          <vxe-column type="radio" width="40px"></vxe-column>
+
+          <vxe-column width="200px" title="合同编号" field="no"></vxe-column>
+          <vxe-column  title="合同名称" field="name"></vxe-column>
+          <vxe-column width="150px" title="委派方" field="clientName"></vxe-column>
+          <vxe-column width="150px" title="合同类型" field="contractType">
+            <template #default="scope">
+              {{ $dictUtils.getDictLabel("contract_type", scope.row.contractType, '-') }}
+            </template>
+          </vxe-column>
+          <vxe-column width="150px" title="创建时间" field="createDate"></vxe-column>
+          <vxe-column width="100px" title="创建人" field="createBy"></vxe-column>
+
+        </vxe-table>
+        <vxe-pager
+          background
+          :current-page="tablePage.currentPage"
+          :page-size="tablePage.pageSize"
+          :total="tablePage.total"
+          :page-sizes="[10, 20, 100, 1000, {label: '全量数据', value: 1000000}]"
+          :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
+          @page-change="currentChangeHandle">
+        </vxe-pager>
+      </div>
+		<template #footer>
+			<span class="dialog-footer">
+			  <el-button @click="close()" icon="el-icon-circle-close">关闭</el-button>
+			  <el-button type="primary" v-if="method != 'view'" @click="getContract()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>
+			</span>
+		</template>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+  import ProgramProjectListInfoService from '@/api/program/ProgramProjectListInfoService'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visible: false,
+        loading: false,
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+        dataList: [],
+        searchForm: {
+          clientName: '',
+          name: '',
+          contractDates: [],
+          type: '',
+          filedType: '',
+          contractAmounts: [],
+          createBy: this.$store.state.user.id,
+          procInsId: '',
+          processDefinitionId: ''
+        },
+        rowId: ''
+      }
+    },
+    programProjectListInfoService: null,
+    created () {
+      this.programProjectListInfoService = new ProgramProjectListInfoService()
+    },
+    components: {
+    },
+    methods: {
+      init (id) {
+        // if (!this.commonJS.isEmpty(id)) {
+        //   this.$refs.workContractTable.setCurrentRow(id)
+        // }
+        this.visible = true
+        this.list()
+      },
+      // 表单提交
+      getContract () {
+        let row = this.$refs.workContractTable.getRadioRecord()
+        if (this.commonJS.isEmpty(row)) {
+          this.$message.error('请选择一条数据')
+          return
+        }
+        this.close()
+        this.$emit('getContract', row)
+      },
+      list () {
+        this.loading = true
+        this.searchForm.createBy = this.$store.state.user.id
+        this.programProjectListInfoService.findContractPageList({
+          'current': this.tablePage.currentPage,
+          'size': this.tablePage.pageSize,
+          'orders': this.tablePage.orders,
+          ...this.searchForm
+        }).then((data) => {
+          this.dataList = data.records
+          this.tablePage.total = data.total
+          this.loading = false
+        })
+      },
+      // 当前页
+      currentChangeHandle ({currentPage, pageSize}) {
+        this.tablePage.currentPage = currentPage
+        this.tablePage.pageSize = pageSize
+        this.list()
+      },
+      resetSearch () {
+        this.$refs.searchForm.resetFields()
+        this.list()
+      },
+      close () {
+        this.visible = false
+      }
+    }
+  }
+</script>

Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 1318 - 0
src/views/jy/finance/InvoiceForm.vue


Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 1708 - 0
src/views/jy/finance/InvoiceFormTask.vue


Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 1254 - 0
src/views/jy/finance/InvoiceFormTaskInvalid.vue


+ 965 - 0
src/views/jy/finance/InvoiceList.vue

@@ -0,0 +1,965 @@
+<template>
+  <div class="page">
+    <el-form :inline="true"
+			 class="query-form m-b-10"
+			 v-if="searchVisible"
+			 ref="searchForm"
+			 :model="searchForm"
+			 @keyup.enter.native="refreshList()"
+			 @submit.native.prevent>
+      <!-- 搜索框-->
+      <el-row :gutter="0">
+        <el-form-item prop="no" label="发票申请编号">
+          <el-input v-model="searchForm.no" placeholder="请输入发票申请编号" clearable></el-input>
+        </el-form-item>
+        <el-form-item prop="number" label="发票号">
+          <el-input v-model="searchForm.number" placeholder="请输入发票号" clearable></el-input>
+        </el-form-item>
+<!--        <el-form-item prop="programName" label="项目名称">-->
+<!--          <el-input  v-model="searchForm.programName" placeholder="请输入项目名称" clearable @clear="clearProgram">-->
+<!--            <el-button slot="append" @click="openProgramPageForm()" icon="el-icon-search"></el-button>-->
+<!--          </el-input>-->
+<!--        </el-form-item>-->
+        <el-form-item v-if="showHideItem" prop="accountBegin" label="开票总金额">
+          <el-input-number
+            v-model="searchForm.accountBegin"
+            controls-position="right"
+            :controls="false"
+            style="width:100%;"
+            :precision="2"
+            placeholder="请填写开票总金额"
+            :step="0.01"
+            :min="0"
+            clearable>
+          </el-input-number>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="accountEnd" label="-">
+          <el-input-number
+            v-model="searchForm.accountEnd"
+            controls-position="right"
+            :controls="false"
+            style="width:100%;"
+            :precision="2"
+            placeholder="请填写开票总金额"
+            :step="0.01"
+            :min="0"
+            clearable>
+          </el-input-number>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="reconciliationPeopleName" label="对账人">
+          <UserSelect :limit='1' :modelValue="searchForm.reconciliationPeopleName" @update:modelValue='(value, label) => {searchForm.reconciliationPeopleName = label}'></UserSelect>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" label="经办人" prop="operator">
+          <UserSelect :limit='1' :modelValue="searchForm.operator" @update:modelValue='(value, label) => {searchForm.operator = label}'></UserSelect>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="operatorOffice" label="经办人部门">
+          <SelectTree
+            ref="officeTree"
+            :props="{
+                  value: 'id',             // ID字段名
+                  label: 'name',         // 显示名称
+                  children: 'children'    // 子级字段名
+                }"
+
+            :url="`/system-server/sys/office/treeData?type=2`"
+            :value="searchForm.operatorOffice"
+            :clearable="true"
+            :accordion="true"
+			size="default"
+            @getValue="(value) => {searchForm.operatorOffice=value}"/>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="billingWorkplaceReal" label="开票单位">
+          <el-input v-model="searchForm.billingWorkplaceReal" placeholder="请输入开票单位" clearable></el-input>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="receivablesStatus" label="是否收款">
+          <el-select v-model="searchForm.receivablesStatus" placeholder="请选择是否收款" clearable>
+            <el-option
+              v-for="item in this.$dictUtils.getDictList('collect_not')"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value">
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="type" label="发票类型">
+          <el-select v-model="searchForm.type" placeholder="请选择发票类型" clearable>
+            <el-option
+              v-for="item in this.$dictUtils.getDictList('invoice_type')"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value">
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="receivablesType" label="收款类型">
+          <el-select v-model="searchForm.receivablesType" placeholder="请选择收款类型" clearable>
+            <el-option
+              v-for="item in $dictUtils.getDictList('invoice_receivables_type')"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value">
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="billingContent" label="开票内容">
+          <el-select v-model="searchForm.billingContent" placeholder="请选择开票内容" clearable>
+            <el-option
+              v-for="item in $dictUtils.getDictList('invoice_billing_content')"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value">
+            </el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="reconciliationArea" label="对账地区">
+          <SelectTree
+            ref="areaTree"
+            :props="{
+                    value: 'id',             // ID字段名
+                    label: 'name',         // 显示名称
+                    children: 'children'    // 子级字段名
+                  }"
+            url="/system-server/sys/area/treeData"
+            :value="searchForm.reconciliationArea"
+            :clearable="true"
+            :accordion="true"
+			size="default"
+            @getValue="(value) => {searchForm.reconciliationArea=value}"/>
+        </el-form-item>
+
+        <el-form-item v-if="showHideItem" prop="billingDateList" label="开票日期">
+          <el-date-picker
+            @change="changeBillingDateList"
+            v-model="searchForm.billingDateList"
+            type="daterange"
+            value-format="YYYY-MM-DD"
+            range-separator="至"
+            style="width: 100%  "
+            start-placeholder="开始日期"
+            end-placeholder="结束日期"
+            placement="bottom-start"
+            clearabl>
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item v-if="showHideItem" prop="remittanceDateList" label="收款日期">
+          <el-date-picker
+            v-model="searchForm.remittanceDateList"
+            type="daterange"
+            value-format="YYYY-MM-DD"
+            range-separator="至"
+            style="width: 100%  "
+            start-placeholder="开始日期"
+            end-placeholder="结束日期"
+            placement="bottom-start"
+            clearable>
+          </el-date-picker>
+        </el-form-item>
+
+        <el-form-item>
+          <el-button type="default" @click="showHide" :icon="showHideIcon">{{showHideName}}</el-button>
+          <el-button type="primary" @click="refreshList()" icon="el-icon-search">查询</el-button>
+          <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
+        </el-form-item>
+      </el-row>
+    </el-form>
+    <div class="jp-table top" style="">
+      <vxe-toolbar :refresh="{query: refreshList}" ref="toolbarRef" export custom>
+        <template #buttons>
+          <el-button v-if="hasPermission('cw_finance:invoice:add')" type="primary" icon="el-icon-plus" @click="start()">新建</el-button>
+<!--          <el-button v-if="hasPermission('cw_finance:invoice:del')" type="danger"   icon="el-icon-delete" @click="del()" :disabled="$refs.invoiceTable && $refs.invoiceTable.getCheckboxRecords().length === 0" plain>删除</el-button>-->
+        </template>
+		  <template #tools>
+			  <vxe-button
+				  text
+				  type="primary"
+				  :title="searchVisible ? '收起检索' : '展开检索'"
+				  icon="vxe-icon-search"
+				  class="tool-btn"
+				  @click="searchVisible = !searchVisible"
+			  ></vxe-button>
+		  </template>
+      </vxe-toolbar>
+      <div style="height: calc(100% - 90px)">
+        <vxe-table
+          border="inner"
+          auto-resize
+          resizable
+          height="auto"
+          :loading="loading"
+          ref="invoiceTable"
+          show-header-overflow
+          show-overflow
+          highlight-hover-row
+          :menu-config="{}"
+          @sort-change="sortChangeHandle"
+          :export-config="{
+                    remote: true,
+                    filename: `兴光会计发票数据${moment(new Date()).format('YYYY-MM-DD')}`,
+                    sheetName: `兴光会计发票数据${moment(new Date()).format('YYYY-MM-DD')}`,
+                    exportMethod: exportMethod,
+                    types: ['xls'],
+                    modes: ['current', 'selected', 'all']
+                  }"
+          :sort-config="{remote:true}"
+          :data="dataList"
+          :checkbox-config="{}">
+          <vxe-column type="seq" width="60" title="序号"></vxe-column>
+          <vxe-column type="checkbox" width="60" ></vxe-column>
+          <vxe-column min-width="150" title="项目名称" align="center" field="programName">
+            <template #default="scope">
+              <el-link  type="primary" :underline="false" @click="viewProject(scope.row)">{{scope.row.programName}}</el-link>
+            </template>
+          </vxe-column>
+          <vxe-column min-width="150" title="发票申请编号" align="center" field="no">
+            <template #default="scope">
+              <el-link  type="primary" :underline="false" @click="view(false, scope.row)">{{scope.row.no}}</el-link>
+            </template>
+          </vxe-column>
+          <vxe-column min-width="150" title="发票号" align="center" field="number"></vxe-column>
+          <vxe-column min-width="150" title="实际开票单位" align="center" field="billingWorkplaceReal"></vxe-column>
+          <vxe-column min-width="150" title="经办人" align="center" field="operator"></vxe-column>
+          <vxe-column min-width="150" title="经办人部门" align="center" field="operatorOffice"></vxe-column>
+          <vxe-column min-width="150" title="开票总金额(元)" align="center" field="account"></vxe-column>
+          <vxe-column min-width="150" title="发票金额(元)" align="center" field="account"></vxe-column>
+          <vxe-column min-width="120" title="开票内容" align="center" field="billingContent">
+            <template #default="scope">
+              {{$dictUtils.getDictLabel('invoice_billing_content', scope.row.billingContent, '')}}
+            </template>
+          </vxe-column>
+          <vxe-column min-width="100" title="收款类型" align="center" field="receivablesType">
+            <template #default="scope">
+              {{$dictUtils.getDictLabel('invoice_receivables_type', scope.row.receivablesType, '')}}
+            </template>
+          </vxe-column>
+          <vxe-column min-width="100" title="发票类型" align="center" field="type">
+            <template #default="scope">
+              {{$dictUtils.getDictLabel('invoice_type', scope.row.type, '')}}
+            </template>
+          </vxe-column>
+          <vxe-column min-width="120" title="开票日期" align="center" field="billingDate"></vxe-column>
+          <vxe-column min-width="120" title="收款日期" align="center" field="receivablesDate"></vxe-column>
+          <vxe-column min-width="110"  align="center" title="是否收款" field="receivablesStatus">
+            <template #default="scope">
+              {{$dictUtils.getDictLabel('collect_not', scope.row.receivablesStatus, '')}}
+            </template>
+          </vxe-column>
+          <vxe-column min-width="110"  align="center" title="是否作废" field="invalidStatus">
+            <template #default="scope">
+              {{scope.row.invalidStatus === '1'?'已作废':'未作废'}}
+            </template>
+
+          </vxe-column>
+          <vxe-column  min-width="110"  align="center" title="状态" field="status" >
+            <template #default="scope">
+              <el-button @click="invoiceDetail(scope.row)" :type="$dictUtils.getDictLabel('invoice_status_info', scope.row.status, '')" effect="dark" >{{$dictUtils.getDictLabel("invoice_status", scope.row.status, '')}} </el-button>
+            </template>
+          </vxe-column>
+          <vxe-column min-width="110" title="操作"  fixed="right" align="center">
+            <template  #default="scope">
+              <div v-if="isAdmin">
+                <el-button v-if="(scope.row.status === '5')" text type="primary"  @click="editForm(scope.row.id)">修改</el-button>
+                <el-button v-if="(scope.row.status === '5')" text type="primary"  @click="del(scope.row.id)">删除</el-button>
+              </div>
+              <div v-else>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit')&&scope.row.createBy.id === $store.state.user.id&&(scope.row.status === '1'||scope.row.status === '3')" text type="primary" @click="invoicePush(scope.row)">修改</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit')&&scope.row.createBy.id === $store.state.user.id&&scope.row.status === '2'" text type="primary"  @click="invoiceReback(scope.row)">撤回</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit:detail')&&scope.row.status === '5'&&scope.row.receivablesStatus !== '1'" text type="primary"  @click="editDetail(scope.row.id)">修改发票明细</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit:receivables')&&scope.row.status === '5'&&scope.row.receivablesStatus !== '1'" text type="primary"  @click="view(true, scope.row.id)">收款</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit:is_receivables')&&scope.row.status === '5'&&scope.row.receivablesStatus !== '1'" text type="primary"  @click="isReceivables(scope.row)">确认收款</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit:is_receivables')&&scope.row.status === '5'&&scope.row.receivablesStatus === '1'" text type="primary" @click="recallReceivables(scope.row)">撤回收款</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit')&&scope.row.createBy.id === $store.state.user.id&&(scope.row.status === '5'||scope.row.status === '7')" text type="primary"  @click="invoiceInvalidPush(scope.row)">作废</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit')&&scope.row.createBy.id === $store.state.user.id&&scope.row.status === '6'" text type="primary" @click="invoiceInvalidReBack(scope.row)">作废撤回</el-button>
+              <el-button v-if="hasPermission('cw_finance:invoice:edit')&&scope.row.createBy.id === $store.state.user.id&&(scope.row.status === '1'||scope.row.status === '3')" text type="primary"  @click="del(scope.row.id)">删除</el-button>
+<!--              审核  发票申请-->
+              <el-button v-if="scope.row.status==='2' && checkIsAudit(scope.row)" text type="primary"  @click="examine(scope.row)">审核</el-button>
+<!--              <el-button v-if="scope.row.status==='5' && $store.state.user.officeId==='1602911350533177346'" text type="primary"  @click="examine(scope.row)">审核</el-button>-->
+<!--              被驳回后当前申请人重新调整  发票申请-->
+              <el-button v-if="scope.row.createBy.id === $store.state.user.id&&scope.row.status === '4'" text type="primary"  @click="adjust(scope.row)">驳回调整</el-button>
+<!--              审核  发票作废-->
+              <el-button v-if="scope.row.status==='6' && checkIsAuditInvalid(scope.row)" text type="primary"  @click="examineInvalid(scope.row)">作废审核</el-button>
+<!--              被驳回后当前申请人重新调整  发票作废-->
+              <el-button v-if="scope.row.createBy.id === $store.state.user.id&&scope.row.status === '8'" text type="primary" @click="adjustInvalid(scope.row)">驳回调整</el-button>
+              </div>
+            </template>
+          </vxe-column>
+        </vxe-table>
+        <vxe-pager
+          background
+          :current-page="tablePage.currentPage"
+          :page-size="tablePage.pageSize"
+          :total="tablePage.total"
+          :page-sizes="[10, 20, 100, 1000, {label: '全量数据', value: 1000000}]"
+          :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
+          @page-change="currentChangeHandle">
+        </vxe-pager>
+      </div>
+    </div>
+    <InvoiceForm  ref="invoiceForm" @refreshDataList="refreshList"></InvoiceForm>
+    <ProgramPageForm ref="programPageForm" @getProgram="getProgram"></ProgramPageForm>
+<!--    <ProgramForm ref="programForm"></ProgramForm>-->
+    <InvoiceUpdateForm ref="invoiceUpdateForm" @refreshDataList="refreshList"></InvoiceUpdateForm>
+	  <ProjectForm ref="projectForm"></ProjectForm>
+	  <ReportManagementForm ref="reportManagementForm"></ReportManagementForm>
+  </div>
+
+	<el-dialog title="详情信息" v-model="dialogFormVisible">
+		<el-form :model="form">
+			<el-row  :gutter="15">
+				<el-col :span="21">
+					<el-form-item label="详情" prop="programName">
+						<el-input :readonly="true" style="width: 100%" type="textarea" maxlength="500" v-model="searchForm.programName" show-word-limit>{{this.searchForm.programName}}</el-input>
+					</el-form-item>
+				</el-col>
+			</el-row>
+		</el-form>
+		<div slot="footer" class="dialog-footer">
+			<el-button type="primary" @click="dialogFormVisible = false">确 定</el-button>
+		</div>
+	</el-dialog>
+
+
+</template>
+
+<script>
+  import financeInvoiceService from '@/api/jy/JyFinanceInvoiceService'
+  import ProgramForm from './ProgramForm'
+  import InvoiceForm from './InvoiceForm'
+  import pick from 'lodash.pick'
+  import taskService from '@/api/flowable/TaskService'
+  import processService from '@/api/flowable/ProcessService'
+  import userService from '@/api/sys/UserService'
+  import UserSelect from '@/components/userSelect'
+  import SelectTree from '@/components/treeSelect/treeSelect.vue'
+  import ProgramPageForm from '@/views/finance/invoice/ProgramPageForm'
+  import InvoiceUpdateForm from './InvoiceUpdateForm'
+  import ProjectForm from '@/views/jy/project/ProjectDia'
+  import ReportManagementForm from '@/views/cw/reportManagement/ReportManagementForm'
+  import ProjectInfoService from "@/api/jy/ProjectInfoService";
+  export default {
+    data () {
+      return {
+	    dialogFormVisible:false,
+		searchVisible: true,
+        showHideItem: false,
+        showHideIcon: 'el-icon-arrow-down',
+        showHideName: '展示',
+        searchForm: {
+          number: '',
+          accountBegin: undefined,
+          accountEnd: undefined,
+          billingDateList: [],
+          billingDateBegin: '',
+          billingDateEnd: '',
+          remittanceDateList: [],
+          remittanceDateBegin: '',
+          remittanceDateEnd: '',
+          programName: '',
+		  programId: '',
+          reconciliationPeopleName: '',
+          operator: '',
+          operatorOffice: '',
+		  label:'',
+		  loginName:this.$store.state.user.name,
+		  reportType:''
+        },
+        dataList: [],
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+        loading: false,
+        processDefinitionId: '',
+        procDefKey: '',
+        processDefinitionInvalidId: '',
+        procDefInvalidKey: '',
+        isAdmin: false,
+	    financeInvoiceBaseDTOList:[],
+		  recordType:''
+      }
+    },
+    computed: {
+      userName () {
+        return this.$store.state.user.name
+      }
+    },
+	  ProjectInfoService:null,
+    created () {
+		this.projectInfoService=new ProjectInfoService()
+    },
+    components: {
+      InvoiceForm,
+      UserSelect,
+      SelectTree,
+      ProgramPageForm,
+      ProgramForm,
+      InvoiceUpdateForm,
+	  ProjectForm,
+		ReportManagementForm,
+    },
+    mounted () {
+		this.$nextTick(() => {
+			//将表格和工具栏进行关联
+			const $table = this.$refs.invoiceTable;
+			const $toolbar = this.$refs.toolbarRef;
+			$table.connect($toolbar);
+		})
+      this.refreshList()
+    },
+    activated () {
+      this.refreshList()
+    },
+    methods: {
+      showHide () {
+        if (this.showHideItem === false) {
+          this.showHideItem = true
+          this.showHideIcon = 'el-icon-arrow-up'
+          this.showHideName = '隐藏'
+        } else {
+          this.showHideItem = false
+          this.showHideIcon = 'el-icon-arrow-down'
+          this.showHideName = '展示'
+        }
+      },
+      // 查询当前用户是否是管理员用户
+      checkIsAdmin () {
+        userService.is().then((data) => {
+          this.isAdmin = data
+        })
+      },
+      // 新增
+      add () {
+        this.$refs.invoiceForm.init('add', '')
+      },
+      editForm (id) {
+        this.$refs.invoiceUpdateForm.init('edit', id)
+      },
+      // 修改发票明细
+      editDetail (id) {
+        id = id || this.$refs.invoiceTable.getCheckboxRecords().map(item => {
+          return item.id
+        })[0]
+        this.$refs.invoiceForm.init(false, id, true)
+      },
+      // 查看 flag为true时,弹窗为收款,其他值为查看发票详情
+      view (flag, row) {
+        this.$refs.invoiceForm.init(flag, row.id)
+      },
+      // 查看项目数据
+      viewProject (row) {
+		console.log(row)
+
+      	if (row.recordType=='1'){
+			this.projectInfoService.findById(row.programId).then((data)=>{
+				this.$refs.projectForm.init('view', data.id,data.auditId1, data.auditId2, data.auditId3,data.sealId,data.outInstanceId,data.reportsSubmitId,data.archiveId,data.eiaId)
+			})
+		}else if (row.recordType=='2'){
+			this.$refs.reportManagementForm.init('view', row.programId, '报告审核单下载')
+		}else if (row.recordType=='0'){
+			this.dialogFormVisible=true
+			this.searchForm.programName=row.programName
+		}
+
+      },
+      // 获取数据列表
+      refreshList () {
+        this.loading = true
+        if (!this.commonJS.isEmpty(this.searchForm.billingDateList)) {
+          if (!this.commonJS.isEmpty(this.searchForm.billingDateList[0]) && !this.commonJS.isEmpty(this.searchForm.billingDateList[1])) {
+            this.searchForm.billingDateBegin = this.searchForm.billingDateList[0]
+            this.searchForm.billingDateEnd = this.searchForm.billingDateList[1]
+          }
+        } else {
+          this.searchForm.billingDateBegin = ''
+          this.searchForm.billingDateEnd = ''
+        }
+        if (!this.commonJS.isEmpty(this.searchForm.remittanceDateList)) {
+          if (!this.commonJS.isEmpty(this.searchForm.remittanceDateList[0]) && !this.commonJS.isEmpty(this.searchForm.remittanceDateList[1])) {
+            this.searchForm.remittanceDateBegin = this.searchForm.remittanceDateList[0]
+            this.searchForm.remittanceDateEnd = this.searchForm.remittanceDateList[1]
+          }
+        } else {
+          this.searchForm.remittanceDateBegin = ''
+          this.searchForm.remittanceDateEnd = ''
+        }
+        financeInvoiceService.list({
+          'current': this.tablePage.currentPage,
+          'size': this.tablePage.pageSize,
+          'orders': this.tablePage.orders,
+          ...this.searchForm
+        }).then((data) => {
+        	console.log('data',data.records)
+        	this.dataList=data.records
+          // this.dataList.forEach(item => {
+          //   item.account = parseFloat(item.account).toFixed(2)
+          //   if (!this.commonJS.isEmpty(item.financeInvoiceBaseDTOList)) {
+          //     let pName = ''
+          //     if (this.commonJS.isNotEmpty(item.financeInvoiceBaseDTOList)) {
+          //       if (item.financeInvoiceBaseDTOList.length === 1) {
+          //         if (this.commonJS.isEmpty(item.financeInvoiceBaseDTOList[0].programId)) {
+          //           pName = '其他: '
+          //         }
+          //       }
+          //     }
+          //     item.financeInvoiceBaseDTOList.forEach((program, index) => {
+          //       if ((index + 1) !== item.financeInvoiceBaseDTOList.length) {
+          //         pName = pName + program.programName + ','
+          //       } else {
+          //         pName = pName + program.programName
+          //       }
+          //     })
+          //     item.programName = pName
+          //   } else {
+          //     item.programName = ''
+          //   }
+          // })
+          this.tablePage.total = data.total
+          this.loading = false
+        })
+        this.checkIsAdmin()
+        processService.getByName('嘉溢-发票审核').then((data) => {
+          if (!this.commonJS.isEmpty(data.id)) {
+            this.processDefinitionId = data.id
+            this.procDefKey = data.key
+          }
+        })
+        processService.getByName('嘉溢-发票作废').then((data) => {
+          if (!this.commonJS.isEmpty(data.id)) {
+            this.processDefinitionInvalidId = data.id
+            this.procDefInvalidKey = data.key
+          }
+        })
+      },
+      // 当前页
+      currentChangeHandle ({ currentPage, pageSize }) {
+        this.tablePage.currentPage = currentPage
+        this.tablePage.pageSize = pageSize
+        this.refreshList()
+      },
+      // 排序
+      sortChangeHandle (column) {
+        this.tablePage.orders = []
+        if (column.order != null) {
+          this.tablePage.orders.push({column: this.$utils.toLine(column.property), asc: column.order === 'asc'})
+        }
+        this.refreshList()
+      },
+      // 删除
+      del (id) {
+        let ids = id || this.$refs.invoiceTable.getCheckboxRecords().map(item => {
+          return item.id
+        }).join(',')
+        this.$confirm(`确定删除所选项吗?`, '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          this.loading = true
+          financeInvoiceService.delete(ids).then((data) => {
+            this.$message.success(data)
+            this.refreshList()
+            this.loading = false
+          })
+        })
+      },
+      resetSearch () {
+        this.searchForm = {
+          number: '',
+          accountBegin: undefined,
+          accountEnd: undefined,
+          billingDateList: [],
+          billingDateBegin: '',
+          billingDateEnd: '',
+          remittanceDateList: [],
+          remittanceDateBegin: '',
+          remittanceDateEnd: '',
+          programName: '',
+          programId: '',
+          reconciliationPeopleName: '',
+          operator: '',
+          operatorOffice: '',
+		  reportType:'',
+        }
+        this.$refs.searchForm.resetFields()
+        this.refreshList()
+      },
+      start () {
+        // 读取流程表单
+        let tabTitle = `发起流程【会计-发票申请】`
+        let processTitle = `${this.userName} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了 [会计-发票申请]`
+        taskService.getTaskDef({ procDefId: this.processDefinitionId,
+          status: 'startAndHold'}).then((data) => {
+            this.$router.push({
+              path: '/flowable/task/TaskForm',
+              query: {
+                ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title'),
+                procDefId: this.processDefinitionId,
+                procDefKey: this.procDefKey,
+                status: 'startAndHold',
+                title: tabTitle,
+                formType: data.formType,
+                formUrl: data.formUrl,
+                formTitle: processTitle,
+                businessId: 'false',
+                isShow: false,
+                routePath: '/jy/finance/InvoiceList'
+              }
+            })
+          })
+      },
+      // 发起发票申请审批
+      invoicePush (row) {
+        // 读取流程表单
+        let title = `发起流程【嘉溢-发票申请】`
+        let processTitle = `${this.userName} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了[嘉溢-发票申请]`
+        let status = 'startAndHold'
+        if (row.status === '3') {
+          status = 'startAndClose'
+        } else if (row.status === '4') {
+          status = 'reapplyFlag'
+        }
+        taskService.getTaskDef({ procDefId: this.processDefinitionId,
+          businessId: row.id,
+          businessTable: 'jy_finance_invoice'}).then((data) => {
+            this.$router.push({
+              path: '/flowable/task/TaskForm',
+              query: {
+                ...pick(data,  'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title'),
+                procDefId: this.processDefinitionId,
+                procDefKey: this.procDefKey,
+                title: title,
+                formType: data.formType,
+                formUrl: data.formUrl,
+                formTitle: processTitle,
+                businessTable: 'jy_finance_invoice',
+                businessId: row.id,
+                isShow: 'false',
+                status: status,
+                routePath: '/jy/finance/InvoiceList'
+              }
+            })
+          })
+      },
+      // 发起发票作废审批
+      invoiceInvalidPush (row) {
+        // 读取流程表单
+        let title = `发起流程【发票作废】`
+        let processTitle = `${this.userName} 发起了 ${row.no} [发票作废]`
+        let status = 'startAndHold'
+        if (row.status === '7') {
+          status = 'startAndClose'
+        } else if (row.status === '8') {
+          status = 'reapplyFlag'
+        }
+        taskService.getTaskDef({ procDefId: this.processDefinitionInvalidId,
+          businessId: row.financeInvoiceInvalidDTO.id,
+          businessTable: 'jy_finance_invoice_invalid'}).then((data) => {
+            this.$router.push({
+              path: '/flowable/task/TaskForm',
+              query: {
+                ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title'),
+                procDefId: this.processDefinitionInvalidId,
+                procDefKey: this.procDefInvalidKey,
+                title: title,
+                formType: data.formType,
+                formUrl: data.formUrl,
+                formTitle: processTitle,
+                businessTable: 'jy_finance_invoice_invalid',
+                businessId: row.financeInvoiceInvalidDTO.id,
+                isShow: 'false',
+                status: status,
+                routePath: '/jy/finance/InvoiceList'
+              }
+            })
+          })
+      },
+      // 查看发票申请审批流程结果
+      invoiceDetail (row) {
+        if (row.status !== '0' && row.status !== '1') {
+          if (row.status === '6' || row.status === '7' || row.status === '8' || row.status === '9') {
+            this.invoiceInvalidDetail(row)
+          } else {
+            taskService.getTaskDef({
+              procInsId: row.procInsId,
+              procDefId: this.processDefinitionId
+            }).then((data) => {
+              this.$router.push({
+                path: '/flowable/task/TaskFormDetail',
+                query: {
+                  ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title'),
+                  isShow: 'false',
+                  readOnly: true,
+                  title: '嘉溢-发票申请' + '流程详情',
+                  formTitle: '嘉溢-发票申请' + '流程详情',
+                  businessId: row.id,
+                  status: 'reback'
+                }
+              })
+            })
+          }
+        }
+      },
+      // 查看发票作废审批流程结果
+      invoiceInvalidDetail (row) {
+        taskService.getTaskDef({
+          procInsId: row.financeInvoiceInvalidDTO.procInsId,
+          procDefId: this.processDefinitionInvalidId
+        }).then((data) => {
+          this.$router.push({
+            path: '/flowable/task/TaskFormDetail',
+            query: {
+              ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title'),
+              isShow: 'false',
+              readOnly: true,
+              title: '发票作废' + '流程详情',
+              formTitle: '发票作废' + '流程详情',
+              businessId: row.financeInvoiceInvalidDTO.id,
+              status: 'reback'
+            }
+          })
+        })
+      },
+      // 撤回发票申请审批
+      invoiceReback (row) {
+        this.$confirm(`确定要撤回该申请吗?`, '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(async () => {
+          await financeInvoiceService.queryById(row.id).then((data) => {
+            if (data.status !== '2') { // status的值不等于“审核中”,就弹出提示
+              this.$message.error('数据已发生改变或不存在,请刷新数据')
+              this.refreshList()
+            } else {
+              processService.revokeProcIns(row.procInsId).then(async (data) => {
+                let form = {status: '3', id: row.id}
+                await financeInvoiceService.updateStatusById(form)
+                this.$message.success(data)
+                this.refreshList()
+              })
+            }
+          })
+        })
+      },
+      invoiceInvalidReBack (row) {
+        this.$confirm(`确定要撤回该申请吗?`, '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(async () => {
+          await financeInvoiceService.queryById(row.id).then((data) => {
+            if (data.status !== '6') { // status的值不等于“审核中”,就弹出提示
+              this.$message.error('数据已发生改变或不存在,请刷新数据')
+              this.refreshList()
+            } else {
+              processService.revokeProcIns(row.financeInvoiceInvalidDTO.procInsId).then(async (data) => {
+                let form = {status: '5', id: row.id}
+                await financeInvoiceService.updateStatusById(form)
+                this.$message.success(data)
+                this.refreshList()
+              })
+            }
+          })
+        })
+      },
+      isReceivables (row) {
+        this.$confirm(`确定要确认收款吗?`, '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          let param = {id: row.id, receivablesStatus: '1'}
+          financeInvoiceService.isReceivables(param).then((data) => {
+            this.$message.success(data)
+            this.refreshList()
+          })
+        })
+      },
+      recallReceivables (row) {
+        this.$confirm(`确定要撤回收款吗?`, '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          let param = {id: row.id, receivablesStatus: '0'}
+          financeInvoiceService.isReceivables(param).then((data) => {
+            this.$message.success(data)
+            this.refreshList()
+          })
+        })
+      },
+      changeBillingDateList (event) {
+        if (this.commonJS.isNotEmpty(this.searchForm.billingDateList)) {
+          console.log('event', event)
+        }
+      },
+      openProgramPageForm () {
+        this.$refs.programPageForm.init('1', false)
+      },
+      getProgram (rows) {
+        if (this.commonJS.isNotEmpty(rows)) {
+          this.searchForm.programName = rows[0].name
+          this.searchForm.programId = rows[0].id
+        }
+      },
+	  getProgram1 (rowsType) {
+        if (this.commonJS.isNotEmpty(rowsType)) {
+          this.searchForm.rowsType = rows[0].rowsType
+        }
+      },
+      clearProgram () {
+        this.searchForm.programName = ''
+        this.searchForm.programId = ''
+      },
+	  clearProgram1 () {
+        this.searchForm.rowsType = ''
+      },
+      // 自定义服务端导出
+      exportMethod ({ options }) {
+        // 传给服务端的参数
+        const params = {
+          'current': this.tablePage.currentPage,
+          'size': this.tablePage.pageSize,
+          'orders': this.tablePage.orders,
+          ...this.searchForm,
+          filename: options.filename,
+          sheetName: options.sheetName,
+          isHeader: options.isHeader,
+          original: options.original,
+          mode: options.mode,
+          selectIds: options.mode === 'selected' ? options.map(item => item.id) : [],
+          exportFields: options.columns.map(column => column.property)
+        }
+        return financeInvoiceService.exportFile(params).then((res) => {
+          // 将二进制流文件写入excel表,以下为重要步骤
+          this.$utils.downloadExcel(res, options.filename+ ".xls")
+        }).catch(function (err) {
+          if (err.response) {
+            console.log(err.response)
+          }
+        })
+      },
+      // 驳回后调整
+      adjust (row) {
+        financeInvoiceService.queryById(row.id).then((data) => {
+			console.log('data1', data)
+          if (data.status !== '4') { // status的值不等于“驳回”,就弹出提示
+            this.$message.error('数据已发生改变或不存在,请刷新数据')
+            this.refreshList()
+          } else {
+            this.todo(row)
+          }
+        })
+      },
+      // 审核
+      examine (row) {
+        financeInvoiceService.queryById(row.id).then((data) => {
+          if (data.status !== '2') { // status的值不等于“审核中”,就弹出提示
+            this.$message.error('数据已发生改变或不存在,请刷新数据')
+            this.refreshList()
+          } else {
+            this.todo(row)
+          }
+        })
+      },
+      // 审核或重新调整跳转
+      todo (row) {
+		  console.log('row.taskId', row.taskId)
+        let cUser = false
+        taskService.getTaskDefInfo({
+          taskId: row.taskId
+        }).then((data) => {
+          this.$router.push({
+            path: '/flowable/task/TaskForm',
+            query: {
+              ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title', 'businessId'),
+              isShow: false,
+              formReadOnly: true,
+              formTitle: `${data.taskName}`,
+              cUser: cUser,
+              title: `审批【${data.taskName || ''}】`,
+              routePath: '/jy/finance/InvoiceList'   // 数据处理后需要跳转的页面路径
+            }
+          })
+        })
+      },
+      // 查询当前登录人是否是数据的审核人
+      checkIsAudit (row) {
+        let loginUserId = this.$store.state.user.id  // 获取当前登录用户id
+        if (this.commonJS.isNotEmpty(row.auditUserIds)) {
+          for (const userId of row.auditUserIds) {
+            if (userId === loginUserId) {  // 当数据的审核人中包含当前登录人id时,返回true
+              return true
+            }
+          }
+        }
+        return false
+      },
+      // 驳回后调整
+      adjustInvalid (row) {
+      	console.log('row',row)
+        financeInvoiceService.queryById(row.id).then((data) => {
+			console.log('data2', data)
+          if (data.status !== '8') { // status的值不等于“驳回”,就弹出提示
+            this.$message.error('数据已发生改变或不存在,请刷新数据')
+            this.refreshList()
+          } else {
+            this.todoInvalid(row)
+          }
+        })
+      },
+      // 审核
+      examineInvalid (row) {
+        financeInvoiceService.queryById(row.id).then((data) => {
+          if (data.status !== '6') { // status的值不等于“审核中”,就弹出提示
+            this.$message.error('数据已发生改变或不存在,请刷新数据')
+            this.refreshList()
+          } else {
+            this.todoInvalid(row)
+          }
+        })
+      },
+      // 审核或重新调整跳转
+      todoInvalid (row) {
+        let cUser = false
+        taskService.getTaskDefInfo({
+          taskId: row.financeInvoiceInvalidDTO.invalidTaskId
+        }).then((data) => {
+          this.$router.push({
+            path: '/flowable/task/TaskForm',
+            query: {
+              ...pick(data, 'formType', 'formUrl', 'procDefKey', 'taskDefKey', 'procInsId', 'procDefId', 'taskId', 'status', 'title', 'businessId'),
+              isShow: false,
+              formReadOnly: true,
+              formTitle: `${data.taskName}`,
+              cUser: cUser,
+              title: `审批【${data.taskName || ''}】`,
+              routePath: '/jy/finance/InvoiceList'   // 数据处理后需要跳转的页面路径
+            }
+          })
+        })
+      },
+      // 查询当前登录人是否是数据的审核人
+      checkIsAuditInvalid (row) {
+        let loginUserId = this.$store.state.user.id  // 获取当前登录用户id
+        if (this.commonJS.isNotEmpty(row.auditUserIdsInvalid)) {
+          for (const userId of row.auditUserIdsInvalid) {
+            if (userId === loginUserId) {  // 当数据的审核人中包含当前登录人id时,返回true
+              return true
+            }
+          }
+        }
+        return false
+      },
+
+
+
+    }
+  }
+</script>
+<style scoped>
+  /deep/ .el-input-number .el-input__inner {
+    text-align: left;
+  }
+</style>

Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 1621 - 0
src/views/jy/finance/InvoiceUpdateForm.vue


+ 657 - 0
src/views/jy/finance/ProgramForm.vue

@@ -0,0 +1,657 @@
+<template xmlns:v-slot="http://www.w3.org/1999/XSL/Transform">
+  <div>
+    <el-dialog
+      :title="title"
+      :close-on-click-modal="false"
+	  draggable
+      width="1300px"
+      @close="close"
+      append-to-body
+      @keyup.enter.native="doSubmit"
+      v-model="visible">
+      <el-form :model="inputForm" ref="inputForm" v-loading="loading" :class="method==='view'?'readonly':''"
+               label-width="160px" @submit.native.prevent>
+        <el-row  :gutter="15" v-if="baseFlag !== true">
+          <el-col :span="24">
+			  <vxe-table
+				  border
+				  show-overflow
+				  show-footer
+				  ref="baseTable"
+				  class="vxe-table-element"
+				  :data="inputForm.financeInvoiceBaseDTOList"
+				  style="margin-left: 5em"
+				  highlight-current-row
+				  :edit-config="{trigger: 'click', mode: 'cell', showStatus: true, autoClear: true}"
+			  >
+				  <vxe-table-column field="programName" align="center" title="项目名称">
+					  <template #default="scope">
+						  <el-link type="primary" :underline="false" @click="openProjectForm(scope.row.programId)" >{{scope.row.programName}}</el-link>
+					  </template>
+				  </vxe-table-column>
+				  <vxe-table-column field="contractName" align="center" title="合同名称"></vxe-table-column>
+				  <vxe-table-column field="account" align="center" title="开票金额"></vxe-table-column>
+				  <vxe-table-column field="reportType" align="center" title="报备类型"></vxe-table-column>
+				  <vxe-table-column field="programNo" align="center" title="项目编号"></vxe-table-column>
+				  <!--            <vxe-table-column field="clientName" align="center" title="委托方"></vxe-table-column>-->
+				  <!--            <vxe-table-column field="reportNo" title="报告号" :edit-render="{}">-->
+				  <!--              <template v-slot:edit="scope">-->
+				  <!--                <el-input v-model="scope.row.reportNo" placeholder="请填写报告号"/>-->
+				  <!--              </template>-->
+				  <!--            </vxe-table-column>-->
+				  <!--            <vxe-table-column title="操作" width="100">-->
+				  <!--              <template v-slot="scope">-->
+				  <!--                <el-button size="mini" type="danger" @click="removeEvent(scope.row,scope.$rowIndex,'base')">删除</el-button>-->
+				  <!--              </template>-->
+				  <!--            </vxe-table-column>-->
+			  </vxe-table>
+		  </el-col>
+        </el-row>
+        <el-row :gutter="15" v-if="baseFlag === true">
+          <el-form-item label="开票详情" prop="">
+          <el-input :readonly="true" type="textarea" maxlength="500" v-model="programName"></el-input>
+          </el-form-item>
+        </el-row>
+      </el-form>
+		<template #footer>
+			<span slot="footer" class="dialog-footer">
+			  <el-button @click="close()" icon="el-icon-circle-close">关闭</el-button>
+						<!--      <el-button size="small" type="primary" v-if="method != 'view'||receivablesFlag!==true" @click="doSubmit()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>-->
+						<!--      <el-button size="small" type="primary" v-if="receivablesFlag===true" @click="doSubmit()" icon="el-icon-circle-check" v-noMoreClick>保留</el-button>-->
+			</span>
+		</template>
+
+    </el-dialog>
+    <ProgramPageForm ref="programPageForm" @getProgram="getProgram"></ProgramPageForm>
+    <ContractForm  ref="contractForm" @getContract="getContract"></ContractForm>
+    <WorkClientForm  ref="workClientForm" @getWorkClient="getWorkClient"></WorkClientForm>
+    <ProjectForm ref="projectForm"></ProjectForm>
+  </div>
+</template>
+
+<script>
+  import financeInvoiceService from '@/api/cw/invoice/CwFinanceInvoiceService'
+  import workClientService from '@/api/cw/workClientInfo/WorkClientService'
+  import ProjectForm from '@/views/cw/projectRecords/ProjectRecordsForm'
+  import ProgramPageForm from '@/views/cw/invoice/ProgramPageForm'
+  import UpLoadComponent from '@/views/common/UpLoadComponent'
+  import ContractForm from '@/views/cw/invoice/ContractForm'
+  import WorkClientForm from '@/views/cw/invoice/WorkClientForm'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visible: false,
+        loading: false,
+        inputForm: {
+          id: '',
+          financeInvoiceBaseDTOList: [],
+          programName: '',
+          contractName: '',
+          programNo: '',
+          clientName: '',
+          reportNo: '',
+          type: '1',
+          no: '',
+          billingType: '1',
+          billingWorkplaceReal: '',
+          billingWorkplaceRealId: '',
+          taxpayerIdentificationNo: '',
+          address: '',
+          telPhone: '',
+          openBank: '',
+          bankAccount: '',
+          receivablesType: '2',
+          billingContent: '',
+          account: '',
+          billingContentTerms: '',
+          billingPeople: this.$store.state.user.name,
+          billingPeopleId: this.$store.state.user.id,
+          billingDate: '',
+          collectDate: '',
+          billingPeopleReal: this.$store.state.user.id,
+          reconciliationPeople: '',
+          reconciliationArea: '',
+          remarks: '',
+          name: '',
+          status: '',
+          procInsId: '',
+          processDefinitionId: '',
+          workAttachmentDtoList: [],
+          financeInvoiceDetailDTOList: [],
+          financeInvoiceReceivablesDTOList: [],
+          financeInvoiceInvalidDTO: {},
+		  reportType:''
+        },
+        programRow: '',
+        bankList: [],
+        err: '',
+        receivablesFlag: '', // true为收款,false为非收款
+        detailFlag: '', // true为修改发票明细
+        importVisible: false,
+        baseFlag: false,
+        programName: ''
+      }
+    },
+    created () {
+    },
+    components: {
+      ProgramPageForm,
+      ContractForm,
+      WorkClientForm,
+      UpLoadComponent,
+      ProjectForm
+    },
+    methods: {
+      init (id) {
+        this.method = 'view'
+        this.title = '查看项目详情信息'
+        this.inputForm = {
+          id: '',
+          financeInvoiceBaseDTOList: [],
+          programName: '',
+          contractName: '',
+          programNo: '',
+          clientName: '',
+          reportNo: '',
+          type: '1',
+          no: '',
+          billingType: '1',
+          billingWorkplaceReal: '',
+          billingWorkplaceRealId: '',
+          taxpayerIdentificationNo: '',
+          address: '',
+          telPhone: '',
+          openBank: '',
+          bankAccount: '',
+          receivablesType: '2',
+          billingContent: '',
+          account: '',
+          billingContentTerms: '',
+          billingPeople: this.$store.state.user.name,
+          billingPeopleId: this.$store.state.user.id,
+          billingDate: '',
+          collectDate: '',
+          billingPeopleReal: this.$store.state.user.id,
+          reconciliationPeople: '',
+          reconciliationArea: '',
+          remarks: '',
+          name: '',
+          status: '',
+          procInsId: '',
+          processDefinitionId: '',
+          workAttachmentDtoList: [],
+          financeInvoiceDetailDTOList: [],
+          financeInvoiceReceivablesDTOList: [],
+          financeInvoiceInvalidDTO: {
+            id: '',
+            invalidStatus: '',
+            invoiceId: '',
+            remarks: ''
+          },
+		  reportType:''
+        }
+        this.baseFlag = false
+        this.inputForm.id = id
+        this.visible = true
+        this.loading = false
+        this.$nextTick(() => {
+          this.$refs.inputForm.resetFields()
+          this.loading = true
+          financeInvoiceService.queryById(this.inputForm.id).then((data) => {
+            this.inputForm = this.recover(this.inputForm, data)
+            this.inputForm = JSON.parse(JSON.stringify(this.inputForm))
+            if (!this.commonJS.isEmpty(this.inputForm.billingWorkplaceRealId)) {
+              workClientService.queryById(this.inputForm.billingWorkplaceRealId).then((data) => {
+                this.bankList = data.workClientBank
+              })
+            }
+            if (this.commonJS.isEmpty(this.inputForm.financeInvoiceReceivablesDTOList) || this.inputForm.financeInvoiceReceivablesDTOList.length === 0) {
+              this.inputForm.financeInvoiceReceivablesDTOList = []
+            }
+            if (this.commonJS.isEmpty(this.inputForm.workAttachmentDtoList)) {
+              this.inputForm.workAttachmentDtoList = []
+            }
+            if (this.commonJS.isNotEmpty(this.inputForm.financeInvoiceBaseDTOList)) {
+              if (this.inputForm.financeInvoiceBaseDTOList.length === 1 && this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programId)) {
+                this.baseFlag = true
+                this.programName = this.inputForm.financeInvoiceBaseDTOList[0].programName
+              }
+            }
+            this.loading = false
+          })
+        })
+      },
+      openProjectForm (id) {
+        this.$refs.projectForm.init('view', id)
+      },
+      // 表单提交
+      async doSubmit () {
+        if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList)) {
+          this.$message.error('至少新增一条基本信息')
+          return
+        } else {
+          if (this.inputForm.financeInvoiceBaseDTOList.length === 0) {
+            this.$message.error('至少新增一条基本信息')
+            return
+          }
+        }
+        let acc = 0
+        this.inputForm.financeInvoiceDetailDTOList.forEach((item, index) => {
+          if (this.commonJS.isEmpty(item.number)) {
+            this.$message.warning('发票明细中第 ' + (index + 1) + ' 条数据的 “发票号” 为空')
+            throw new Error()
+          }
+          if (this.commonJS.isEmpty(item.account)) {
+            this.$message.warning('发票明细中第 ' + (index + 1) + ' 条数据的 “开票金额” 为空')
+            throw new Error()
+          }
+          acc = (acc + parseFloat(parseFloat(item.account).toFixed(2)))
+        })
+        if (acc !== this.inputForm.account) {
+          this.$message.warning('发票明细中 “开票金额”总和 与发票详情中 “发票金额” 不等')
+          return
+        }
+        this.inputForm.financeInvoiceDetailDTOList.forEach((item, index) => {
+          this.inputForm.financeInvoiceDetailDTOList.forEach((item2, index2) => {
+            if (index !== index2) {
+              if (item.number === item2.number) {
+                this.$message.warning('发票明细中第 ' + (index + 1) + ' 条数据的 “发票号” 存在重复')
+                throw new Error()
+              }
+            }
+          })
+        })
+        for await (let [index, item] of this.inputForm.financeInvoiceDetailDTOList.entries()) {
+          if (this.commonJS.isEmpty(item.number)) {
+            this.$message.warning('发票明细中第 ' + (index + 1) + ' 条数据的 “发票号” 为空')
+            this.err = true
+          }
+          await financeInvoiceService.queryByNumber(item.number, item.id).then((data) => {
+            if (data === true) {
+              this.$message.warning('发票明细中第 ' + (index + 1) + ' 条数据的 “发票号” 存在重复')
+              this.err = data
+            }
+          })
+        }
+        if (this.err === true) {
+          this.err = ''
+          return
+        }
+        if (this.receivablesFlag === true) {
+          this.inputForm.financeInvoiceReceivablesDTOList.forEach((item, index) => {
+            if (this.commonJS.isEmpty(item.remittanceUnit)) {
+              this.$message.warning('收款明细中第 ' + (index + 1) + ' 条数据的 “汇款单位” 为空,请重新输入')
+              throw new Error()
+            }
+            if (this.commonJS.isEmpty(item.remittanceAmount) || item.remittanceAmount === 0 || item.remittanceAmount === '0') {
+              this.$message.warning('收款明细中第 ' + (index + 1) + ' 条数据的 “汇款金额” 为空,请重新输入')
+              throw new Error()
+            }
+            if (this.commonJS.isEmpty(item.remittanceDate)) {
+              this.$message.warning('收款明细中第 ' + (index + 1) + ' 条数据的 “汇款时间” 为空,请重新输入')
+              throw new Error()
+            }
+          })
+        }
+        this.$refs['inputForm'].validate((valid) => {
+          if (valid) {
+            this.loading = true
+            if (this.$refs.uploadComponent.checkProgress()) {
+              this.loading = false
+              return
+            }
+            this.inputForm.workAttachmentDtoList = this.$refs.uploadComponent.getDataList()
+            financeInvoiceService.save(this.inputForm).then((data) => {
+              this.close()
+              this.$message.success(data)
+              this.$emit('refreshDataList')
+              this.loading = false
+            }).catch(() => {
+              this.loading = false
+            })
+          }
+        })
+      },
+      close () {
+        this.$refs.inputForm.resetFields()
+        this.inputForm = {
+          id: '',
+          financeInvoiceBaseDTOList: [],
+          programName: '',
+          contractName: '',
+          programNo: '',
+          clientName: '',
+          reportNo: '',
+          type: '1',
+          no: '',
+          billingType: '1',
+          billingWorkplaceReal: '',
+          billingWorkplaceRealId: '',
+          taxpayerIdentificationNo: '',
+          address: '',
+          telPhone: '',
+          openBank: '',
+          bankAccount: '',
+          receivablesType: '2',
+          billingContent: '',
+          account: '',
+          billingContentTerms: '',
+          billingPeople: '',
+          billingPeopleId: '',
+          billingDate: '',
+          collectDate: '',
+          billingPeopleReal: '',
+          reconciliationPeople: '',
+          reconciliationArea: '',
+          remarks: '',
+          name: '',
+          workAttachmentDtoList: [],
+          financeInvoiceDetailDTOList: [],
+          financeInvoiceReceivablesDTOList: [],
+          financeInvoiceInvalidDTO: {},
+			reportType:''
+        }
+        this.bankList = []
+        this.detailFlag = false
+        this.visible = false
+      },
+      insertEvent (type) {
+        if (type === 'base') {
+          if (this.inputForm.financeInvoiceBaseDTOList.length >= 1) {
+            if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programId)) {
+              this.$message.warning('非项目,只能有一条非项目数据')
+              return
+            }
+          }
+          this.$refs.baseTable.insert().then((data) => {
+            this.inputForm.financeInvoiceBaseDTOList.push(data)
+          })
+        }
+        if (type === 'detail') {
+          this.$refs.detailTable.insert().then((data) => {
+            this.inputForm.financeInvoiceDetailDTOList.push(data)
+          })
+        }
+        if (type === 'receivables') {
+          this.$refs.receivablesTable.insert().then((data) => {
+            this.inputForm.financeInvoiceReceivablesDTOList.push(data)
+          })
+        }
+      },
+      // 删除
+      removeEvent (row, rowIndex, type) {
+        if (type === 'base') {
+          this.$refs.baseTable.remove(row)
+          this.inputForm.financeInvoiceBaseDTOList.splice(rowIndex, 1)
+        }
+        if (type === 'detail') {
+          this.$refs.detailTable.remove(row)
+          this.inputForm.financeInvoiceDetailDTOList.splice(rowIndex, 1)
+        }
+        if (type === 'receivables') {
+          this.$refs.receivablesTable.remove(row)
+          this.inputForm.financeInvoiceReceivablesDTOList.splice(rowIndex, 1)
+        }
+      },
+      openProgramPageForm (rowIndex) {
+        if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programName) || this.inputForm.financeInvoiceBaseDTOList.length === 1) {
+          this.$refs.programPageForm.init()
+        } else {
+          if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programId)) {
+            this.$refs.programPageForm.init('s')
+          } else {
+            this.$refs.programPageForm.init(false)
+          }
+        }
+        this.programRow = rowIndex
+      },
+      getProgram (rows) {
+        rows.forEach((item, index) => {
+          if (index === 0) {
+            let r = this.inputForm.financeInvoiceBaseDTOList[this.programRow]
+            r.programName = item.name
+            r.contractName = item.contractName
+            r.programNo = item.no
+            r.clientName = item.clientName
+            r.client = item.client
+            r.programId = item.id
+            r.location = item.location // 项目所在地
+            this.inputForm.financeInvoiceBaseDTOList[this.programRow] = r
+          } else {
+            let r = {
+              programName: item.name,
+              contractName: item.contractName,
+              programNo: item.no,
+              clientName: item.clientName,
+              client: item.client,
+              programId: item.id,
+              location: item.location // 项目所在地
+            }
+            this.inputForm.financeInvoiceBaseDTOList.push(r)
+          }
+        })
+        this.$forceUpdate()
+        this.programRow = ''
+        this.inputForm.reconciliationArea = this.inputForm.financeInvoiceBaseDTOList[0].location
+      },
+      openContractForm () {
+        if (!this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0])) {
+          if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programId) && this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programName)) {
+            this.$message.warning('请先选择项目')
+          } else if (this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programId) && !this.commonJS.isEmpty(this.inputForm.financeInvoiceBaseDTOList[0].programName)) {
+            this.$refs.contractForm.init()
+          } else {
+            this.$message.warning('只有非项目开票可选择合同信息')
+          }
+        } else {
+          this.$message.warning('请选择项目信息')
+        }
+      },
+      getContract (row) {
+        this.inputForm.financeInvoiceBaseDTOList[0].contractName = row.name // 合同名称
+        this.inputForm.financeInvoiceBaseDTOList[0].client = row.clientId // 委托方
+        this.inputForm.financeInvoiceBaseDTOList[0].clientName = row.clientName // 委托方名称
+        this.$forceUpdate()
+      },
+      changeRadio () {
+        this.inputForm.address = ''
+        this.inputForm.telPhone = ''
+        this.inputForm.billingWorkplaceReal = ''
+        this.inputForm.billingWorkplaceRealId = ''
+        this.inputForm.taxpayerIdentificationNo = ''
+        this.bankList = []
+        this.inputForm.bankAccount = ''
+        this.inputForm.openBank = ''
+        this.inputForm.name = ''
+        this.$forceUpdate()
+      },
+      openWorkClientForm () {
+        this.$refs.workClientForm.init(null, '')
+      },
+      getWorkClient (row) {
+        this.inputForm.billingWorkplaceReal = row.name // 实际开票单位姓名
+        this.inputForm.billingWorkplaceRealId = row.id // 实际开票单位id ‘客户id’
+        this.inputForm.taxpayerIdentificationNo = row.uscCode // 纳税人识别号 ‘统一社会信用代码’
+        this.inputForm.address = row.registerAddress // 地址 ‘注册地址’
+        this.inputForm.telPhone = row.telephone // 电话
+        this.bankList = row.backs
+        this.inputForm.bankAccount = ''
+        this.inputForm.openBank = ''
+        this.$forceUpdate()
+      },
+      changeBank (value) {
+        this.bankList.forEach(item => {
+          if (item.id === value) {
+            this.inputForm.bankAccount = item.bankNumber
+          }
+        })
+      },
+      checkNumber (row, rowIndex) {
+        if (!this.commonJS.isEmpty(row.number)) {
+          if (parseInt(row.number) > 99999999) {
+            this.$message.warning('“发票号” 不可以大于 8 位,请重新输入')
+            row.number = undefined
+            return
+          }
+          this.inputForm.financeInvoiceDetailDTOList.forEach((item, index) => {
+            if (rowIndex !== index) {
+              if (row.number === item.number) {
+                row.number = ''
+                this.$message.warning('“发票号” 已存在,请重新输入')
+                throw new Error()
+              }
+            }
+          })
+          financeInvoiceService.queryByNumber(row.number, row.id).then((data) => {
+            if (data === true) {
+              row.number = ''
+              this.$message.warning('“发票号” 已存在,请重新输入')
+            }
+          })
+        }
+      },
+      checkAccount (row, rowIndex) {
+        if (this.commonJS.isEmpty(row.account)) {
+          row.account = undefined
+        }
+        this.getAmount(row)
+        this.getTax(row)
+      },
+      checkRate (row, rowIndex) {
+        if (!this.commonJS.isEmpty(row.rate)) {
+          if (parseFloat(row.rate) < 1 || parseFloat(row.rate) > 100) {
+            this.$message.warning('“税率” 请填写 1 到 100 之间的数字,请重新输入')
+            row.rate = undefined
+          }
+        }
+        this.getAmount(row)
+        this.getTax(row)
+      },
+      // 根据开票金额和税率计算出金额: 开票金额-税率*开票金额
+      getAmount (row) {
+        if (!this.commonJS.isEmpty(row.account) && !this.commonJS.isEmpty(row.rate)) {
+          row.amount = parseFloat((parseFloat(row.account) - parseFloat((parseFloat(row.account) * parseFloat((parseFloat(row.rate) / 100).toFixed(4))).toFixed(4))).toFixed(2))
+        } else {
+          row.amount = undefined
+        }
+      },
+      // 根据开票金额和税率计算出税额: 税率*开票金额
+      getTax (row) {
+        if (!this.commonJS.isEmpty(row.account) && !this.commonJS.isEmpty(row.rate)) {
+          row.tax = parseFloat((parseFloat(row.account) * parseFloat((parseFloat(row.rate) / 100).toFixed(4))).toFixed(2))
+        } else {
+          row.tax = undefined
+        }
+      },
+      // 下载模板
+      downloadTpl () {
+        this.loading = true
+        financeInvoiceService.exportTemplate().then((res) => {
+          // 将二进制流文件写入excel表,以下为重要步骤
+          this.$utils.downloadExcel(res, '发票明细导入模板')
+          this.loading = false
+        }).catch(function (err) {
+          this.loading = false
+          if (err.response) {
+            console.log(err.response)
+          }
+        })
+      },
+      async detailPush (data) {
+        if (this.commonJS.isNotEmpty(data)) {
+          await data.forEach(item => {
+            this.getAmount(item)
+            this.getTax(item)
+            this.inputForm.financeInvoiceDetailDTOList.push(item)
+          })
+        }
+        this.$message.success('导入完成')
+      },
+      beforeUploadDetail (file) {
+        const formBody = new FormData()
+        formBody.append('file', file.raw)
+        this.loading = true
+        financeInvoiceService.importDetail(formBody).then(async (result) => {
+          if (this.commonJS.isEmpty(result)) {
+            this.importVisible = false
+            this.loading = false
+            throw new Error()
+          }
+          for await (let item of result) {
+            this.inputForm.financeInvoiceDetailDTOList.forEach(detail => {
+              if (item.number === detail.number) {
+                this.$message.error('上传的文件中存在与页面重复的发票号,请重新填写后上传')
+                this.importVisible = false
+                this.loading = false
+                throw new Error()
+              }
+            })
+          }
+          await this.detailPush(result)
+          this.importVisible = false
+          this.loading = false
+        }).catch(() => {
+          this.importVisible = false
+          this.loading = false
+        })
+      },
+      checkIdentificationNo () {
+        if (this.commonJS.isEmpty(this.inputForm.taxpayerIdentificationNo)) {
+          this.$message.error('当前纳税人识别号为空,导入失败')
+          throw new Error()
+        }
+      },
+      async beforeUploadDetailCode (file) {
+        console.log('110', this.inputForm.taxpayerIdentificationNo)
+        await this.checkIdentificationNo()
+        const formBody = new FormData()
+        formBody.append('file', file.raw)
+        this.loading = true
+        financeInvoiceService.importDetail(formBody).then(async result => {
+          if (this.commonJS.isEmpty(result)) {
+            this.importVisible = false
+            this.loading = false
+            throw new Error()
+          }
+          for await (let item of result) {
+            await this.inputForm.financeInvoiceDetailDTOList.forEach(detail => {
+              if (item.number === detail.number) {
+                this.$message.error('上传的文件中存在与页面重复的发票号,请重新填写后上传')
+                this.importVisible = false
+                this.loading = false
+                throw new Error()
+              }
+            })
+          }
+          this.detailPushCode(result)
+          this.importVisible = false
+          this.loading = false
+        }).catch(() => {
+          this.importVisible = false
+          this.loading = false
+        })
+      },
+      detailPushCode (data) {
+        if (this.commonJS.isNotEmpty(data)) {
+          data.forEach(item => {
+            if (this.commonJS.isNotEmpty(item.taxpayerIdentificationNo)) {
+              if (item.taxpayerIdentificationNo === this.inputForm.taxpayerIdentificationNo) {
+                this.getAmount(item)
+                this.getTax(item)
+                this.inputForm.financeInvoiceDetailDTOList.push(item)
+              }
+            }
+          })
+        }
+        this.$message.success('导入完成')
+      }
+    }
+  }
+</script>
+<style scoped>
+  /deep/ .el-input-number .el-input__inner {
+    text-align: left;
+  }
+</style>

+ 364 - 0
src/views/jy/finance/ProgramPageForm.vue

@@ -0,0 +1,364 @@
+<template>
+  <div>
+    <el-dialog
+      :title="title"
+      :close-on-click-modal="false"
+	  draggable
+      width="1100px"
+      height="500px"
+      @close="close"
+      append-to-body
+      v-model="visible">
+      <div v-if="isShow">
+        <el-radio v-model="checkType" label="1" style="margin-right: 20px">项目</el-radio>
+<!--        <el-radio v-model="checkType" label="2" style="margin-right: 20px">报告</el-radio>-->
+	    <el-radio v-model="checkType" label="3" style="margin-right: 20px">其他</el-radio>
+      </div>
+		<!--报告        -->
+		<div v-if="checkType === '2'">
+			<el-form size="large" :inline="true" class="query-form" ref="searchForm" :model="searchForm"
+					 @submit.native.prevent>
+				<!-- 搜索框-->
+				<el-form-item label="项目名称" prop="projectName">
+					<el-input size="large" v-model="searchForm.projectName" placeholder="请输入项目名称" clearable></el-input>
+				</el-form-item>
+				<el-form-item label="报告号" prop="reportNo">
+					<el-input size="large" v-model="searchForm.reportNo" placeholder="请输入报告号" clearable></el-input>
+				</el-form-item>
+				<el-form-item label="报告创建时间" prop="createDates">
+					<el-date-picker
+						placement="bottom-start"
+						format="YYYY-MM-DD HH:mm:ss"
+						value-format="YYYY-MM-DD HH:mm:ss"
+						v-model="searchForm.createDates"
+						type="datetimerange"
+						range-separator="至"
+						start-placeholder="开始日期"
+						end-placeholder="结束日期">
+					</el-date-picker>
+				</el-form-item>
+
+				<el-form-item>
+					<el-button type="primary" @click="list1()" size="large" icon="el-icon-search">查询</el-button>
+					<el-button @click="resetSearch1()" size="large" icon="el-icon-refresh-right">重置</el-button>
+				</el-form-item>
+			</el-form>
+
+			<vxe-table
+				border="inner"
+				auto-resize
+				resizable
+				height="550px"
+				:loading="loading"
+				size="large"
+				ref="projectTable1"
+				show-header-overflow
+				show-overflow
+				highlight-hover-row
+				:menu-config="{}"
+				:print-config="{}"
+				@sort-change=""
+				:sort-config="{remote:true}"
+				:data="dataList1"
+				:row-config="{isCurrent: true}"
+				:checkbox-config="{trigger: 'row'}"
+			>
+				<vxe-column type="seq" width="60" title="序号"></vxe-column>
+				<vxe-column type="checkbox" width="60px"></vxe-column>
+				<vxe-column min-width="230" align="center" title="项目名称" field="projectName" show-overflow="title"></vxe-column>
+				<vxe-column min-width="230" align="center" title="项目编号" field="projectNumber"></vxe-column>
+				<vxe-column min-width="230" align="center" title="报告文号" field="reportNo"></vxe-column>
+				<vxe-column min-width="160" align="center" title="合同名称" field="contractName"></vxe-column>
+				<vxe-column min-width="160" align="center" title="报告创建人" field="userName"></vxe-column>
+				<vxe-column min-width="160" align="center" title="报告创建时间" field="createTime"></vxe-column>
+
+			</vxe-table>
+			<vxe-pager
+				background
+				size="large"
+				:current-page="tablePage1.currentPage"
+				:page-size="tablePage1.pageSize"
+				:total="tablePage1.total"
+				:page-sizes="[10, 20, 100, 1000, {label: '全量数据', value: 1000000}]"
+				:layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
+				@page-change="currentChangeHandle1">
+			</vxe-pager>
+		</div>
+      <div v-if="checkType === '1'" >
+          <el-form :inline="true" class="query-form" ref="searchForm" :model="searchForm" @submit.native.prevent>
+            <!-- 搜索框-->
+            <el-form-item label="项目名称" prop="projectName">
+              <el-input v-model="searchForm.projectName" placeholder="请输入项目名称" clearable></el-input>
+            </el-form-item>
+            <el-form-item label="项目编号" prop="projectNumber">
+              <el-input v-model="searchForm.projectNumber" placeholder="请输入项目编号" clearable></el-input>
+            </el-form-item>
+            <el-form-item label="创建时间" prop="createDates">
+              <el-date-picker
+                placement="bottom-start"
+                format="YYYY-MM-DD HH:mm:ss"
+                value-format="YYYY-MM-DD HH:mm:ss"
+                v-model="searchForm.createDates"
+                type="datetimerange"
+                range-separator="至"
+                start-placeholder="开始日期"
+                end-placeholder="结束日期">
+              </el-date-picker>
+            </el-form-item>
+
+            <el-form-item>
+              <el-button type="primary" @click="list()"  icon="el-icon-search">查询</el-button>
+              <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
+            </el-form-item>
+          </el-form>
+
+          <vxe-table
+            border="inner"
+            auto-resize
+            resizable
+            height="550px"
+            :loading="loading"
+            ref="projectTable"
+            show-header-overflow
+            show-overflow
+            highlight-hover-row
+            :menu-config="{}"
+            :print-config="{}"
+            :sort-config="{remote:true}"
+            :data="dataList"
+            :row-config="{isCurrent: true}"
+            :checkbox-config="{trigger: 'row'}"
+          >
+            <vxe-column type="seq" width="60" title="序号"></vxe-column>
+            <vxe-column type="checkbox" width="60px"></vxe-column>
+			  <vxe-column min-width="160" align="center" title="项目名称" field="name" show-overflow="title"></vxe-column>
+			  <vxe-column min-width="160" align="center" title="项目编号" field="no"></vxe-column>
+			  <vxe-column min-width="160" align="center" title="合同名称" field="contractName"></vxe-column>
+			  <vxe-column min-width="160" align="center" title="创建人" field="createById"></vxe-column>
+			  <vxe-column min-width="160" align="center" title="创建时间" field="createTime"></vxe-column>
+
+          </vxe-table>
+          <vxe-pager
+            background
+            :current-page="tablePage.currentPage"
+            :page-size="tablePage.pageSize"
+            :total="tablePage.total"
+            :page-sizes="[10, 20, 100, 1000, {label: '全量数据', value: 1000000}]"
+            :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
+            @page-change="currentChangeHandle">
+          </vxe-pager>
+        </div>
+      <div style="height: 500px;" v-if="checkType === '3'">
+        <el-form  label-width="80px" class="query-form" ref="searchForm" :model="searchForm" @keyup.enter.native="refreshList()" @submit.native.prevent>
+			<el-row  :gutter="15">
+            <el-col :span="21">
+              <el-form-item label="详情" prop="detail">
+                <el-input style="width: 100%" type="textarea" maxlength="500" v-model="detail" placeholder="请输入详情" show-word-limit></el-input>
+              </el-form-item>
+            </el-col>
+          </el-row>
+        </el-form>
+      </div>
+		<template #footer>
+			<span class="dialog-footer">
+			  <el-button @click="close()" icon="el-icon-circle-close">关闭</el-button>
+			  <el-button type="primary" v-if="method != 'view'" @click="getProgram()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>
+			</span>
+		</template>
+
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+	import ProjectInfoService from '@/api/jy/ProjectInfoService'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visible: false,
+        loading: false,
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+	    tablePage1: {
+		  total: 0,
+		  currentPage: 1,
+		  pageSize: 10,
+		  orders: []
+	    },
+        dataList: [],
+        dataList1: [],
+        searchForm: {
+          name: '',
+          no: '',
+          createBy: '',
+          projectMasterName: '',
+          projectNumber: '',
+          projectName: '',
+          createDates: [],
+		  reportNo: '',
+          status: ''
+        },
+        checkType: '',
+        detail: '',
+        isShow: true,
+        num: true,// num为true是多选,false是单选
+		reportType:''
+      }
+    },
+	  ProjectInfoService:null,
+    created () {
+		this.projectInfoService=new ProjectInfoService()
+    },
+    components: {
+    },
+    methods: {
+      /**
+       * @param isShow
+       *      isShow为空,则可以选择“项目”或填写“其他”
+       *      isShow为false,则只可以选择“项目”,并且弹出提示
+       *      isShow为‘1’,则只可以选择“项目”,不弹出提示
+       *      isShow为其他任何值,则只可以填写“其他”
+       * @param num
+       *      num为空或者true,则允许多选
+       *      num为其他任何值,则只可以单选
+       */
+      init (isShow, num) {
+        if (this.commonJS.isEmpty(isShow)) {
+          this.isShow = true
+          this.checkType = '1'
+        } else {
+			if (isShow === false || isShow === 'false') {
+				if (this.checkType === '1') {
+					this.isShow = false
+					this.checkType = '1'
+					this.$message({message: '第一条为项目后面新增只能选择项目', type: 'warning', customClass: 'messageZindex'})
+				} else if (this.checkType === '2') {
+					this.isShow = false
+					this.checkType = '2'
+					this.$message({message: '第一条为报告后面新增只能选择报告', type: 'warning', customClass: 'messageZindex'})
+				}
+			} else if (isShow === '1') {
+				this.isShow = false
+				this.checkType = '1'
+			}else if (isShow === '2') {
+				this.isShow = false
+				this.checkType = '2'
+			} else {
+				this.isShow = false
+				this.checkType = '3'
+			}
+        }
+        if (this.commonJS.isEmpty(num) || num === true) {
+          this.num = true // num为true是多选,false是单选
+        } else {
+          this.num = false
+        }
+        this.visible = true
+        this.list()
+	    // this.list1()
+      },
+      // 表单提交
+      getProgram () {
+        let rows
+	    let rowsType
+        if (this.checkType === '1') {
+          if (this.commonJS.isEmpty(this.$refs.projectTable.getCheckboxRecords())) {
+            this.$message.error('请至少选择一条数据')
+            return
+          }
+          if (this.num === false) {
+            if (this.$refs.projectTable.getCheckboxRecords().length > 1) {
+              this.$message.error('最多选择一条数据')
+              return
+            }
+          }
+          rows = this.$refs.projectTable.getCheckboxRecords()
+        } else if (this.checkType === '2') {
+			if (this.commonJS.isEmpty(this.$refs.projectTable1.getCheckboxRecords())) {
+				this.$message.error('请至少选择一条数据')
+				return
+			}
+			if (this.num === false) {
+				if (this.$refs.projectTable1.getCheckboxRecords().length > 1) {
+					this.$message.error('最多选择一条数据')
+					return
+				}
+			}
+			rows = this.$refs.projectTable1.getCheckboxRecords()
+		} else {
+          if (this.commonJS.isEmpty(this.detail)) {
+            this.$message.error('请填写开票详情')
+            return
+          }
+          rows = [{name: this.detail}]
+		  rows.bj1 = 'bj1'
+        }
+
+        this.close()
+        this.$emit('getProgram', rows)
+      },
+      list () {
+        this.loading = true
+        this.searchForm.status = '5'
+		  this.projectInfoService.listByCreateId({
+          'current': this.tablePage.currentPage,
+          'size': this.tablePage.pageSize,
+          'orders': this.tablePage.orders,
+          ...this.searchForm
+        }).then((data) => {
+          this.dataList = data.records
+          this.tablePage.total = data.total
+          this.loading = false
+        })
+      },
+	  // list1 () {
+		//   this.loading = true
+		//   this.searchForm.status = '5'
+		//   projectRecordsService.list1({
+		// 	'current': this.tablePage1.currentPage,
+		// 	'size': this.tablePage1.pageSize,
+		// 	'orders': this.tablePage1.orders,
+		// 	...this.searchForm
+		//   }).then((data) => {
+		// 	this.dataList1 = data.records
+		// 	this.tablePage1.total = data.total
+		// 	this.loading = false
+		//   })
+	  // },
+      // 当前页
+      currentChangeHandle ({currentPage, pageSize}) {
+        this.tablePage.currentPage = currentPage
+        this.tablePage.pageSize = pageSize
+        this.list()
+      },
+      resetSearch () {
+        this.$refs.searchForm.resetFields()
+        this.list()
+      },
+	  currentChangeHandle1 ({currentPage, pageSize}) {
+		this.tablePage1.currentPage = currentPage
+		this.tablePage1.pageSize = pageSize
+		this.list1()
+	  },
+	  resetSearch1 () {
+		this.$refs.searchForm.resetFields()
+		this.list1()
+	  },
+      close () {
+        this.detail = ''
+        this.visible = false
+      }
+    }
+  }
+</script>
+<style>
+  .messageZindex {
+    z-index:9999 !important;
+  }
+</style>

+ 148 - 0
src/views/jy/finance/WorkClientBillingChooseRadio.vue

@@ -0,0 +1,148 @@
+<template>
+  <div>
+    <el-dialog
+      :title="title"
+      :close-on-click-modal="false"
+      draggable
+      width="1000px"
+      append-to-body
+      height="500px"
+      @close="close"
+      @keyup.enter.native="getBilling"
+      v-model="visibleChoose">
+      <div style="height: calc(100%);">
+        <el-form :inline="true" class="query-form" ref="searchForm" :model="searchForm" @submit.native.prevent>
+          <!-- 搜索框-->
+          <el-form-item label="公司名称" prop="name">
+            <el-input v-model="searchForm.name" placeholder="公司名称" clearable></el-input>
+          </el-form-item>
+
+          <el-form-item>
+            <el-button type="primary" @click="list()" icon="el-icon-search">查询</el-button>
+            <el-button @click="resetSearch()" icon="el-icon-refresh-right">重置</el-button>
+          </el-form-item>
+        </el-form>
+
+        <vxe-table
+          border="inner"
+          auto-resize
+          resizable
+          height="auto"
+          max-height="400"
+          :loading="loading"
+          ref="billingTable"
+          show-header-overflow
+          show-overflow
+          highlight-hover-row
+          :menu-config="{}"
+          :print-config="{}"
+          :sort-config="{remote:true}"
+          :data="dataList"
+          :row-config="{isCurrent: true}"
+          :radio-config="{trigger: 'row'}">
+          <vxe-column type="seq" width="40"></vxe-column>
+          <vxe-column type="radio" width="40px"></vxe-column>
+          <vxe-column min-width="150" title="公司名称" align="center" field="name" tree-node></vxe-column>
+<!--          <vxe-column min-width="150" title="是否有纳税人识别号" align="center" field="isTaxpayerIdentificationNo">-->
+<!--            <template slot-scope="scope">-->
+<!--              {{$dictUtils.getDictLabel('yes_no', scope.row.isTaxpayerIdentificationNo, '-')}}-->
+<!--            </template>-->
+<!--          </vxe-column>-->
+<!--          <vxe-column min-width="150" title="纳税人识别号" align="center" field="taxpayerIdentificationNo"></vxe-column>-->
+          <vxe-column min-width="150" title="开户行" align="center" field="ourBank"></vxe-column>
+          <vxe-column min-width="150" title="银行账号" align="center" field="bankNumber"></vxe-column>
+          <vxe-column min-width="150" title="电话" align="center" field="telephone"></vxe-column>
+          <vxe-column min-width="150" title="地址" align="center" field="address"></vxe-column>
+        </vxe-table>
+      </div>
+		<template #footer>
+			<span class="dialog-footer">
+			  <el-button @click="close()" icon="el-icon-circle-close">关闭</el-button>
+			  <el-button type="primary" v-if="method != 'view'" @click="getBilling()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>
+			</span>
+		</template>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+	import WorkClientService from '@/api/jy/WorkClientService'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visibleChoose: false,
+        loading: false,
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+        dataList: [],
+        searchForm: {
+          id: '',
+          name: '',
+        },
+        clientId: ''
+      }
+    },
+	  workClientService: null,
+    created () {
+		this.workClientService = new WorkClientService()
+    },
+    components: {
+    },
+    methods: {
+      init (id) {
+        this.title = '开票信息选择'
+        this.visibleChoose = true
+        this.clientId = id
+        this.list()
+      },
+      // 表单提交
+      getBilling () {
+        let row = this.$refs.billingTable.getRadioRecord()
+        if (this.commonJS.isEmpty(row)) {
+          this.$message.error('请至少选择一条数据')
+        } else {
+          this.close()
+          this.$emit('getBilling', row)
+        }
+      },
+      list () {
+        this.dataList = []
+        this.loading = true
+        this.searchForm.id = this.clientId
+		  this.workClientService.getBillingListByClientId(this.searchForm).then((data) => {
+		  	console.log('data',data)
+          this.dataList = data
+          this.loading = false
+        })
+      },
+      // 当前页
+      currentChangeHandle ({currentPage, pageSize}) {
+        this.tablePage.currentPage = currentPage
+        this.tablePage.pageSize = pageSize
+        this.list()
+      },
+      resetSearch () {
+        this.$refs.searchForm.resetFields()
+        this.list()
+      },
+      close () {
+        this.$refs.searchForm.resetFields()
+        this.visibleChoose = false
+      }
+    }
+  }
+</script>
+<style scoped>
+  /deep/ .el-dialog__body {
+    padding-top: 0;
+  }
+  /deep/ .el-form-item--mini.el-form-item, .el-form-item--small.el-form-item {
+    margin-bottom: 0px;
+  }
+</style>

+ 219 - 0
src/views/jy/finance/WorkClientForm.vue

@@ -0,0 +1,219 @@
+<template>
+  <div>
+    <el-dialog
+      :title="title"
+      :close-on-click-modal="false"
+	  draggable
+      width="1100px"
+      height="500px"
+      @close="close"
+      append-to-body
+      v-model="visible">
+      <div style="height: calc(100% - 80px);">
+        <el-form :inline="true" class="query-form" ref="searchForm" :model="searchForm" @keyup.enter.native="list()" @submit.native.prevent>
+          <!-- 搜索框-->
+          <el-form-item label="客户名称" prop="name">
+            <el-input v-model="searchForm.name" placeholder="请输入客户名称" clearable></el-input>
+          </el-form-item>
+
+          <el-form-item label="创建时间" prop="createDates">
+            <el-date-picker
+              placement="bottom-start"
+              v-model="searchForm.createDates"
+              type="datetimerange"
+              range-separator="至"
+              start-placeholder="开始日期"
+              end-placeholder="结束日期">
+            </el-date-picker>
+          </el-form-item>
+
+          <el-form-item label="客户性质" prop="companyType">
+            <el-select v-model="searchForm.companyType" placeholder="请选择" style="width:100%;">
+              <el-option
+                v-for="item in $dictUtils.getDictList('customer_nature')"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value">
+              </el-option>
+            </el-select>
+          </el-form-item>
+
+          <el-form-item label="客户行业" prop="companyIndustry">
+            <el-select v-model="searchForm.companyIndustry" placeholder="请选择" style="width:100%;">
+              <el-option
+                v-for="item in $dictUtils.getDictList('industry')"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value">
+              </el-option>
+            </el-select>
+          </el-form-item>
+
+          <el-form-item label="统一社会信用代码" prop="uscCode">
+            <el-input v-model="searchForm.uscCode" placeholder="请输入统一社会信用代码" clearable></el-input>
+          </el-form-item>
+
+          <el-form-item label="创建人" prop="createBy">
+            <SelectUserTree
+              ref="companyTree"
+              :props="{
+                  value: 'id',             // ID字段名
+                  label: 'name',         // 显示名称
+                  children: 'children'    // 子级字段名
+                }"
+              :url="`/system-server/sys/user/treeUserDataAllOffice?type=2`"
+              :value="searchForm.createBy"
+              :clearable="true"
+              :accordion="true"
+              @getValue="(value) => {searchForm.createBy=value}"/>
+          </el-form-item>
+
+          <el-form-item>
+            <el-button type="primary" @click="list()" icon="el-icon-search">查询</el-button>
+            <el-button @click="resetSearch()"  icon="el-icon-refresh-right">重置</el-button>
+          </el-form-item>
+        </el-form>
+
+        <vxe-table
+          border="inner"
+          auto-resize
+          resizable
+          height="400px"
+          :loading="loading"
+          ref="workClientTable"
+          show-header-overflow
+          show-overflow
+          highlight-hover-row
+          :menu-config="{}"
+          :print-config="{}"
+          :sort-config="{remote:true}"
+          :data="dataList"
+          :checkbox-config="{}">
+          <vxe-column type="seq" width="60" title="序号"></vxe-column>
+          <vxe-column type="radio" width="40px"></vxe-column>
+
+          <vxe-column width="300px"  title="客户名称" field="name">
+          </vxe-column>
+<!--          <vxe-column width="200px"  title="代表方" field="deputy" ></vxe-column>-->
+          <vxe-column width="100px"  title="客户性质" field="companyType" >
+            <template #default="scope">
+              {{ $dictUtils.getDictLabel("customer_nature", scope.row.companyType, '-') }}
+            </template>
+          </vxe-column>
+          <vxe-column width="100px"  title="客户行业" field="companyIndustry" >
+            <template #default="scope">
+              {{ $dictUtils.getDictLabel("industry", scope.row.companyIndustry, '-') }}
+            </template>
+          </vxe-column>
+          <vxe-column width="200px" title="统一社会信用代码" field="uscCode" > </vxe-column>
+          <vxe-column width="100px" title="创建人" field="createBy" > </vxe-column>
+          <vxe-column width="150px" title="创建时间" field="createDate" > </vxe-column>
+        </vxe-table>
+
+        <vxe-pager
+          background
+          :current-page="tablePage.currentPage"
+          :page-size="tablePage.pageSize"
+          :total="tablePage.total"
+          :page-sizes="[10, 20, 100, 1000, {label: '全量数据', value: 1000000}]"
+          :layouts="['PrevPage', 'JumpNumber', 'NextPage', 'FullJump', 'Sizes', 'Total']"
+          @page-change="currentChangeHandle">
+        </vxe-pager>
+      </div>
+		<template #footer>
+			<span slot="footer" class="dialog-footer">
+			  <el-button @click="close()" icon="el-icon-circle-close">关闭</el-button>
+			  <el-button type="primary" v-if="method != 'view'" @click="getWorkClient()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>
+			</span>
+		</template>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+  import WorkClientService from '@/api/sys/WorkClientService'
+  import SelectUserTree from '@/views/utils/treeUserSelect'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visible: false,
+        loading: false,
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+        dataList: [],
+        searchForm: {
+          name: '',
+          areaId: '',
+          createDates: [],
+          companyType: '',
+          companyIndustry: '',
+          clientType: '',
+          uscCode: '',
+          createBy: '',
+          deputy: ''
+        },
+        rowId: '',
+        deputy: ''
+      }
+    },
+    workClientService: null,
+    created () {
+      this.workClientService = new WorkClientService()
+    },
+    components: {
+      SelectUserTree
+    },
+    methods: {
+      init (id, deputy) {
+        // if (!this.commonJS.isEmpty(id)) {
+        //   this.$refs.workContractTable.setCurrentRow(id)
+        // }
+        this.deputy = deputy
+        this.visible = true
+        this.list()
+      },
+      // 表单提交
+      getWorkClient () {
+        let row = this.$refs.workClientTable.getRadioRecord()
+        if (this.commonJS.isEmpty(row)) {
+          this.$message.error('请选择一条数据')
+          return
+        }
+        this.close()
+        this.$emit('getWorkClient', row, this.deputy)
+      },
+      list () {
+        this.loading = true
+        this.workClientService.list({
+          'current': this.tablePage.currentPage,
+          'size': this.tablePage.pageSize,
+          'orders': this.tablePage.orders,
+          ...this.searchForm
+        }).then((data) => {
+          this.dataList = data.records
+          this.tablePage.total = data.total
+          this.loading = false
+        })
+      },
+      // 当前页
+      currentChangeHandle ({currentPage, pageSize}) {
+        this.tablePage.currentPage = currentPage
+        this.tablePage.pageSize = pageSize
+        this.list()
+      },
+      resetSearch () {
+        this.$refs.searchForm.resetFields()
+        this.list()
+      },
+      close () {
+        this.visible = false
+      }
+    }
+  }
+</script>