فهرست منبع

Merge remote-tracking branch 'origin/master'

user5 9 ماه پیش
والد
کامیت
d4dc351d55

+ 7 - 0
src/api/finance/invoice/FinanceInvoiceService.js

@@ -94,4 +94,11 @@ export default class FinanceInvoiceService {
       responseType: 'blob'
     })
   }
+  redList(params) {
+  	return request({
+		url: prefix + "/finance/invoice/redList",
+		method: "get",
+		params: params,
+	});
+  }
 }

+ 2 - 0
src/views/cw/invoice/ProgramPageForm.vue

@@ -69,6 +69,8 @@
 				<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="230" align="center" title="审定金额(含税/元)" field="approvedIncludingTax"></vxe-column>
+				<vxe-column min-width="230" align="center" title="审定金额(不含税/元)" field="approvedNoIncludingTax"></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>

+ 12 - 2
src/views/cw/projectReportArchive/ProjectReportArchiveList.vue

@@ -538,7 +538,12 @@
       push (row) {
         // 读取流程表单
         let title = `发起流程[会计-项目报告归档]`
-        let processTitle = `${this.$store.state.user.name} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了 ${row.reportNo} - ${row.projectName} [会计-项目报告归档]`
+		  let processTitle = ''
+		  if (this.commonJS.isEmpty(row.reportNo)){
+			  processTitle = `${this.$store.state.user.name} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了无报告号 - ${row.projectName} [会计-项目报告归档]`
+		  }else {
+			  processTitle = `${this.$store.state.user.name} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了 ${row.reportNo} - ${row.projectName} [会计-项目报告归档]`
+		  }
         let status = 'startAndHold'
         if (row.status === '3' || row.status === '4') {
           status = 'startAndClose'
@@ -629,7 +634,12 @@
 				if (!this.commonJS.isEmpty(data.id)) {
 					// console.log('data', data)
 					// 读取流程表单
-					let tabTitle = ' ' + row.reportNo + ' - ' + row.cwProjectRecordsDTO.projectName
+					let tabTitle = ''
+					if(this.commonJS.isEmpty(row.reportNo)){
+						tabTitle = '无报告号报告' + ' - ' + row.cwProjectRecordsDTO.projectName
+					}else {
+						tabTitle = ' ' + row.reportNo + ' - ' + row.cwProjectRecordsDTO.projectName
+					}
 					let processTitle = `${this.userName} 在 ${this.moment(new Date()).format('YYYY-MM-DD HH:mm')} 发起了 ` + tabTitle + '[会计-报告借用]'
 					taskService.getTaskDef({ procDefId: data.id,
 						businessId: row.id,

+ 3 - 0
src/views/cw/reportManagement/ReportManagementForm.vue

@@ -1275,6 +1275,9 @@
             // this.$refs.uploadComponent.clearUpload()
             this.inputForm = this.recover(this.inputForm, data)
             this.inputForm = JSON.parse(JSON.stringify(this.inputForm))
+			  if (data.takeNumberType == '2'){
+			  	this.inputForm.reportNo = '无报告号报告'
+			  }
             // console.log('this.inputForm.cwWorkClientContactDTOList', data.cwWorkClientContactDTOList)
             if (this.commonJS.isEmpty(this.inputForm.createDate)) {
               this.inputForm.createDate = this.moment(new Date()).format('YYYY-MM-DD HH:mm:ss')

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 7 - 7
src/views/cw/reportManagement/ReportManagementList.vue


+ 1 - 1
src/views/cw/reportManagement/ReportReviewTakeNumberForm.vue

@@ -1436,7 +1436,7 @@
 				console.log("takeNumberTypeChange",this.inputForm.takeNumberType)
 				if(this.inputForm.takeNumberType === '1'){
 					this.reimbursementTypeFlag = true;
-				}else if (this.inputForm.takeNumberType === '0'){
+				}else if (this.inputForm.takeNumberType === '0' || this.inputForm.takeNumberType === '2'){
 					this.reimbursementTypeFlag = false;
 				}
 

+ 4 - 2
src/views/cw/reportManagement/reportReviewNew/ReportReviewFormNew.vue

@@ -908,7 +908,8 @@
 			status2:'',
 			status3:'',
 			approvedIncludingTax:'',
-			approvedNoIncludingTax:''
+			approvedNoIncludingTax:'',
+			takeNumberType:''
         },
         keyWatch: '',
         activeName: 'enclosure',
@@ -1065,7 +1066,8 @@
 			status2:'',
 			status3:'',
 			approvedIncludingTax:'',
-			approvedNoIncludingTax:''
+			approvedNoIncludingTax:'',
+			takeNumberType:'',
         },
         this.inputForm.id = id
         this.loading = false

+ 39 - 2
src/views/finance/invoice/InvoiceForm.vue

@@ -266,6 +266,35 @@
               </el-input-number>
             </el-form-item>
           </el-col>
+
+			<el-col :span="12">
+				<el-form-item label="是否红字发票" prop="redInvoiceFlag"
+							  :rules="[
+                        {required: true, message:'是否红字发票不能为空', trigger:'blur'}
+               ]">
+					<el-radio v-model="inputForm.redInvoiceFlag" v-for="item in $dictUtils.getDictList('yes_no')" :label="item.value" style="margin-right: 20px">
+						{{item.label}}</el-radio>
+				</el-form-item>
+			</el-col>
+
+			<el-col v-if="inputForm.redInvoiceFlag === '1'" :span="12">
+				<el-form-item label="关联红字发票" prop="redInvoiceRelevancyNumber"
+							  :rules="[
+                        {required: true, message:'关联红字发票不能为空', trigger:'blur'},{required: true, message:'关联红字发票不能为空', trigger:'change'}
+               ]">
+					<el-input :readonly="true" placeholder="请关联红字发票" v-model="inputForm.redInvoiceRelevancyNumber" @focus="openWorkInvoiceForm()" clearable></el-input>
+				</el-form-item>
+			</el-col>
+
+			<el-col v-if="inputForm.redInvoiceFlag === '1'" :span="12">
+				<el-form-item label="关联发票号" prop="invoiceNumberStr"
+							  :rules="[
+             ]">
+					<el-input :disabled="true" placeholder="关联发票号" v-model="inputForm.invoiceNumberStr" clearable></el-input>
+				</el-form-item>
+			</el-col>
+
+
           <el-col :span="12">
             <el-form-item label="是否多张开票" prop="isMultiple"
                           :rules="[
@@ -689,7 +718,11 @@
           receivablesDate: '',
           receivablesStatus: '',
           isReceivables: '',
-          isMultiple: ''
+          isMultiple: '',
+			redInvoiceFlag: '0',	//是否红字发票
+			redInvoiceRelevancyNumber: '',	//红字发票编号
+			invoiceNumberStr: '',	//红字发票号
+			redInvoiceRelevancyId: '',	//红字发票id
         },
         programRow: '',
         bankList: [],
@@ -784,7 +817,11 @@
           receivablesDate: '',
           receivablesStatus: '',
           isReceivables: '',
-          isMultiple: ''
+          isMultiple: '',
+			redInvoiceFlag: '0',	//是否红字发票
+			redInvoiceRelevancyNumber: '',	//红字发票编号
+			invoiceNumberStr: '',	//红字发票号
+			redInvoiceRelevancyId: '',	//红字发票id
         }
         this.inputForm.id = id
         this.visible = true

+ 73 - 3
src/views/finance/invoice/InvoiceFormTask.vue

@@ -266,6 +266,34 @@
 <!--            </el-input-number>-->
           </el-form-item>
         </el-col>
+
+		  <el-col :span="12">
+			  <el-form-item label="是否红字发票" prop="redInvoiceFlag"
+							:rules="[
+                        {required: true, message:'是否红字发票不能为空', trigger:'blur'}
+               ]">
+				  <el-radio v-model="inputForm.redInvoiceFlag" v-for="item in $dictUtils.getDictList('yes_no')" :label="item.value" style="margin-right: 20px">
+					  {{item.label}}</el-radio>
+			  </el-form-item>
+		  </el-col>
+
+		  <el-col v-if="inputForm.redInvoiceFlag === '1'" :span="12">
+			  <el-form-item label="关联红字发票" prop="redInvoiceRelevancyNumber"
+							:rules="[
+                        {required: true, message:'关联红字发票不能为空', trigger:'blur'},{required: true, message:'关联红字发票不能为空', trigger:'change'}
+               ]">
+				  <el-input :readonly="true" placeholder="请关联红字发票" v-model="inputForm.redInvoiceRelevancyNumber" @focus="openWorkInvoiceForm()" clearable></el-input>
+			  </el-form-item>
+		  </el-col>
+
+		  <el-col v-if="inputForm.redInvoiceFlag === '1'" :span="12">
+			  <el-form-item label="关联发票号" prop="invoiceNumberStr"
+							:rules="[
+             ]">
+				  <el-input :disabled="true" placeholder="关联发票号" v-model="inputForm.invoiceNumberStr" clearable></el-input>
+			  </el-form-item>
+		  </el-col>
+
         <el-col :span="12">
           <el-form-item label="是否多张开票" prop="isMultiple"
                         :rules="[
@@ -647,6 +675,8 @@
     <WorkClientForm  ref="workClientForm" @getWorkClient="getWorkClient"></WorkClientForm>
 	  <user-select1 ref="userSelect1" @doSubmit="selectUser1"></user-select1>
 	  <user-select2 ref="userSelect2" @doSubmit="selectUser2"></user-select2>
+	  <WorkInvoiceForm  ref="workInvoiceForm" @getWorkInvoiceRadioChoose="getWorkInvoice"></WorkInvoiceForm>
+
 	  <!--		邮箱弹窗-->
 	  <el-dialog v-model="dialogFormVisible" style="width: 50%" title="邮箱修改">
 		  <el-form :model="form" label-width="160px">
@@ -696,6 +726,7 @@
   import userService from "../../../api/sys/userService";
   import UserSelect1 from '@/views/utils/UserTreeSelect'
   import UserSelect2 from '@/views/utils/UserTreeSelect'
+  import WorkInvoiceForm from './WorkInvoiceChooseRadio'
   export default {
     props: {
       businessId: {
@@ -759,7 +790,11 @@
           financeInvoiceReceivablesDTOList: [],
           financeInvoiceInvalidDTO: {},
           isMultiple: '',
-			actualDrawerEmailAddress: ''
+			actualDrawerEmailAddress: '',
+			redInvoiceFlag: '0',	//是否红字发票
+			redInvoiceRelevancyNumber: '',	//红字发票编号
+			invoiceNumberStr: '',	//红字发票号
+			redInvoiceRelevancyId: '',	//红字发票id
         },
         programRow: '',
         bankList: [],
@@ -791,7 +826,8 @@
       SelectTree,
       UpLoadComponent,
 		UserSelect1,
-		UserSelect2
+		UserSelect2,
+		WorkInvoiceForm
     },
     computed: {
       bus: {
@@ -876,7 +912,11 @@
             remarks: ''
           },
           isMultiple: '',
-			actualDrawerEmailAddress: ''
+			actualDrawerEmailAddress: '',
+			redInvoiceFlag: '0',	//是否红字发票
+			redInvoiceRelevancyNumber: '',	//红字发票编号
+			invoiceNumberStr: '',	//红字发票号
+			redInvoiceRelevancyId: '',	//红字发票id
         }
         // if (method === 'add') {
         //   this.title = `新建发票`
@@ -916,6 +956,9 @@
             if (this.commonJS.isEmpty(this.inputForm.workAttachmentDtoList) || this.inputForm.workAttachmentDtoList.length === 0) {
               this.inputForm.workAttachmentDtoList = []
             }
+			  if (this.commonJS.isEmpty(this.inputForm.redInvoiceFlag)) {
+				  this.inputForm.redInvoiceFlag = '0'
+			  }
             if (this.commonJS.isEmpty(this.inputForm.financeInvoiceReceivablesDTOList) || this.inputForm.financeInvoiceReceivablesDTOList.length === 0) {
               this.inputForm.financeInvoiceReceivablesDTOList = []
             }
@@ -965,6 +1008,7 @@
                 allAmount: ''
               })
             }
+            console.log('data',this.inputForm)
             this.$refs.uploadComponent.newUpload(method, this.inputForm.workAttachmentDtoList, 'invoice')
             this.loading = false
           })
@@ -1054,6 +1098,17 @@
 				}
 			}
 		}
+        //判断是否是红字发票
+		  if (this.inputForm.account > 0 && this.inputForm.redInvoiceFlag == '1'){
+			  this.loading = false
+			  this.$message.error("发票金额为正数,不可为红字发票,请将是否红字发票请选择否")
+			  throw new Error()
+		  }
+		  if (this.inputForm.account < 0 && this.inputForm.redInvoiceFlag == '0'){
+			  this.loading = false
+			  this.$message.error("发票金额为负数,请将是否红字发票请选择是,并选择关联的发票信息")
+			  throw new Error()
+		  }
         if (this.commonJS.isNotEmpty(this.inputForm.financeInvoiceBaseDTOList)) {
           let i = this.inputForm.financeInvoiceBaseDTOList.length
           for (let j = 0; j < i; j++) {
@@ -1562,6 +1617,11 @@
           var result = this.inputForm.account.replace(reg, regStrs[i][1])
           this.inputForm.account = result
         }
+		  if(this.inputForm.account<0){
+			  this.inputForm.redInvoiceFlag = "1"
+		  }else{
+			  this.inputForm.redInvoiceFlag = "0"
+		  }
       },
 		//点开邮箱
 		openDia() {
@@ -1602,6 +1662,16 @@
 			this.inputForm.reconciliationPeopleName=user[0].name
 			this.inputForm.reconciliationPeople=user[0].id
 		},
+		openWorkInvoiceForm() {
+			this.$refs.workInvoiceForm.init()
+		},
+		getWorkInvoice(row) {
+			console.log("getWorkInvoice",row)
+			this.inputForm.redInvoiceRelevancyNumber = row.no
+			this.inputForm.invoiceNumberStr = row.number
+			this.inputForm.redInvoiceRelevancyId = row.id
+			this.$forceUpdate()
+		},
     }
   }
 </script>

+ 173 - 0
src/views/finance/invoice/WorkInvoiceChooseRadio.vue

@@ -0,0 +1,173 @@
+<template>
+  <div>
+    <el-dialog
+      :title="title"
+      :close-on-click-modal="false"
+	  draggable
+      width="1400px"
+      append-to-body
+      height="500px"
+      @close="close"
+      @keyup.enter.native="getWorkInvoice"
+	  v-model="visibleChoose">
+      <div style="height: calc(100%);">
+		<el-form size="large" :inline="true" class="query-form m-b-10" ref="searchForm" :model="searchForm" @submit.native.prevent>
+          <!-- 搜索框-->
+          <el-form-item label="发票申请编号" prop="no">
+            <el-input size="large" v-model="searchForm.no" placeholder="发票申请编号" clearable></el-input>
+          </el-form-item>
+          <el-form-item label="发票号" prop="number">
+            <el-input size="large" v-model="searchForm.number" placeholder="发票号" clearable></el-input>
+          </el-form-item>
+          <el-form-item label="开票内容" prop="billingContent">
+            <el-select v-model="searchForm.billingContent" placeholder="请选择" style="width:100%" 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>
+            <el-button type="primary" @click="list()" size="large" icon="el-icon-search">查询</el-button>
+            <el-button @click="resetSearch()" size="large" icon="el-icon-refresh-right">重置</el-button>
+          </el-form-item>
+        </el-form>
+
+        <vxe-table
+          border="inner"
+          height="480px"
+          :loading="loading"
+          size="small"
+          ref="invoiceTable"
+          show-header-overflow
+          show-overflow
+          highlight-hover-row
+          :menu-config="{}"
+          :print-config="{}"
+          :sort-config="{remote:true}"
+          :data="dataList"
+          :row-config="{isCurrent: true}"
+          :tree-config="{transform: true, rowField: 'id', parentField: 'oneUpCompany'}"
+          :radio-config="{trigger: 'row'}">
+          <vxe-column type="seq" width="40"></vxe-column>
+          <vxe-column type="radio" width="60px"></vxe-column>
+          <vxe-column width="230px" title="发票申请编号" align="center" field="no"></vxe-column>
+          <vxe-column width="200px" title="发票号" align="center" field="number"></vxe-column>
+          <vxe-column width="200px" title="开票内容" align="center" field="billingContent">
+            <template #default="scope">
+              {{$dictUtils.getDictLabel('invoice_billing_content', scope.row.billingContent, '-')}}
+            </template>
+          </vxe-column>
+			<vxe-column width="200px" title="项目名称" align="center" field="programName"></vxe-column>
+			<vxe-column width="200px" title="经办人" align="center" field="operator"></vxe-column>
+          <vxe-column width="200px" title="开票总金额" align="center" field="account"></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="getWorkInvoice()" icon="el-icon-circle-check" v-noMoreClick>确定</el-button>
+			</span>
+		</template>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+  import FinanceInvoiceService from '@/api/finance/invoice/FinanceInvoiceService'
+  export default {
+    data () {
+      return {
+        title: '',
+        method: '',
+        visibleChoose: false,
+        loading: false,
+        tablePage: {
+          total: 0,
+          currentPage: 1,
+          pageSize: 10,
+          orders: []
+        },
+        dataList: [],
+        searchForm: {
+          number: '',
+          no: '',
+		  billingContent: ''
+        }
+      }
+    },
+	  financeInvoiceService: null,
+    created () {
+		this.financeInvoiceService = new FinanceInvoiceService()
+    },
+    components: {
+    },
+    methods: {
+      init () {
+        this.title = '发票选择'
+        this.visibleChoose = true
+        this.list()
+      },
+      // 表单提交
+		getWorkInvoice () {
+        let row = this.$refs.invoiceTable.getRadioRecord()
+        if (this.commonJS.isEmpty(row)) {
+          this.$message.error('请至少选择一条数据')
+        } else {
+          this.close()
+          this.$emit('getWorkInvoiceRadioChoose', row)
+        }
+      },
+      list () {
+        this.dataList = []
+        this.loading = true
+        this.searchForm.isTrue = '1'
+		  this.financeInvoiceService.redList({
+          '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.$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>