From 7a81f2a5e0f4dfa02920d0b1f0c050e2104721b8 Mon Sep 17 00:00:00 2001
From: cyf009 <591388323@qq.com>
Date: Wed, 8 Jan 2025 17:07:27 +0800
Subject: [PATCH] 1

---
 .../dto/request/BatchEntryQueryRequest.java   |   5 +-
 .../web/dto/result/BatchEntryResult.java      |   2 +
 .../business/dao/xml/IncomeMapper.xml         |   7 +-
 .../business/dao/xml/IncomeTypeMapper.xml     |   3 +
 .../business/service/ClaimServiceImpl.java    |   3 +
 WebSite/src/api/Entry.js                      |  12 +
 WebSite/src/views/batchaccounting/index.vue   | 323 ++++++++++++------
 WebSite/src/views/common/organize.vue         |   2 +-
 .../src/views/srincomeallocation/index.vue    |   9 +-
 9 files changed, 250 insertions(+), 116 deletions(-)
 create mode 100644 WebSite/src/api/Entry.js

diff --git a/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/request/BatchEntryQueryRequest.java b/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/request/BatchEntryQueryRequest.java
index 00ead30..66f1473 100644
--- a/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/request/BatchEntryQueryRequest.java
+++ b/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/request/BatchEntryQueryRequest.java
@@ -22,7 +22,10 @@ public class BatchEntryQueryRequest {
     private String billNo;
     @JsonFormat(pattern = "yyyy-MM-dd")
     @ApiModelProperty(value = "浠樻鏃ユ湡/涓氬姟鏃堕棿")
-    private Date incomeDate;
+    private Date beginIncomeDate;
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @ApiModelProperty(value = "浠樻鏃ユ湡/涓氬姟鏃堕棿")
+    private Date endIncomeDate;
     @ApiModelProperty(value = "浠樻閲戦start")
     private BigDecimal incomeAmountStart;
     @ApiModelProperty(value = "浠樻閲戦end")
diff --git a/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/result/BatchEntryResult.java b/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/result/BatchEntryResult.java
index 392d8ea..ee1324f 100644
--- a/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/result/BatchEntryResult.java
+++ b/ServiceSiteCommon/facade/src/main/java/com/seasky/template/web/dto/result/BatchEntryResult.java
@@ -30,6 +30,8 @@ public class BatchEntryResult {
      private String incomeAccount;
      @ApiModelProperty(value = "浠樻璐﹀彿")
      private String paymentAccount;
+     @ApiModelProperty(value = "浠樻浜�/鍗曚綅")
+     private String paymentName;
      @ApiModelProperty(value = "鏀舵閲戦")
      private String incomeAmount;
      @ApiModelProperty(value = "鎽樿")
diff --git a/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeMapper.xml b/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeMapper.xml
index c3257d5..f73ae9c 100644
--- a/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeMapper.xml
+++ b/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeMapper.xml
@@ -283,8 +283,11 @@
         <if test="qry.incomeAccount!=null and qry.incomeAccount!=''">
             and a.income_account = #{qry.incomeAccount}
         </if>
-        <if test="qry.incomeDate!=null">
-            and a.income_date = #{qry.incomeDate}
+        <if test="qry.beginIncomeDate!=null">
+            and a.income_date = #{qry.beginIncomeDate}
+        </if>
+        <if test="qry.endIncomeDate!=null">
+            and a.income_date <![CDATA[<=]]> #{qry.endIncomeDate}
         </if>
         <if test="qry.billNo!=null and qry.billNo!=''">
             and a.bill_no = #{qry.billNo}
diff --git a/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeTypeMapper.xml b/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeTypeMapper.xml
index 0ac2ff3..be3b16e 100644
--- a/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeTypeMapper.xml
+++ b/ServiceSiteCommon/src/main/java/com/seasky/template/business/dao/xml/IncomeTypeMapper.xml
@@ -35,6 +35,9 @@
             t_income_claim d ON d.income_id = b.id AND d.available = 'YES'
         WHERE
             a.income_type_class = #{param}
+        <if test="param=='鐩存帴鍏ヨ处'">
+            and a.entry_mode='鎵归噺鍏ヨ处'
+        </if>
           AND d.id IS NULL  -- 纭繚娌℃湁鍖归厤鐨� t_income_claim 璁板綍
         GROUP BY
             a.id, a.income_type_code, a.income_type_name, a.entry_mode
diff --git a/ServiceSiteCommon/src/main/java/com/seasky/template/business/service/ClaimServiceImpl.java b/ServiceSiteCommon/src/main/java/com/seasky/template/business/service/ClaimServiceImpl.java
index d54293a..8126618 100644
--- a/ServiceSiteCommon/src/main/java/com/seasky/template/business/service/ClaimServiceImpl.java
+++ b/ServiceSiteCommon/src/main/java/com/seasky/template/business/service/ClaimServiceImpl.java
@@ -58,6 +58,9 @@ public class ClaimServiceImpl implements ClaimService {
         if(request.getMenuName().equals("鍩硅缁撶畻")){
             param = "鍩硅";
         }
+        if(request.getMenuName().equals("鎵归噺鍏ヨ处")){
+            param = "鐩存帴鍏ヨ处";
+        }
         List<OutSideIncomeTypeResult> resultList = incomeTypeMapper.findIncomeType(param);
         return resultList;
     }
diff --git a/WebSite/src/api/Entry.js b/WebSite/src/api/Entry.js
new file mode 100644
index 0000000..0eb3d85
--- /dev/null
+++ b/WebSite/src/api/Entry.js
@@ -0,0 +1,12 @@
+import request from '@/core/base/request';
+class Entry {
+    static async batchEntryPage(data) {
+        return await request({
+          url: 'entry/batchEntryPage',
+          method: 'post',
+          data
+        });
+      }
+
+}
+export default Entry;
\ No newline at end of file
diff --git a/WebSite/src/views/batchaccounting/index.vue b/WebSite/src/views/batchaccounting/index.vue
index 437ecad..63021a7 100644
--- a/WebSite/src/views/batchaccounting/index.vue
+++ b/WebSite/src/views/batchaccounting/index.vue
@@ -1,97 +1,181 @@
 <template>
-<div class="app-container" style="height:100% !important;">
-
-  <el-row :gutter="30" >
-    <el-col :span="5"> 
-      <income-type :incomeTypePara="incomeTypePara"></income-type>
+  <div class="app-container" style="height: 100% !important">
+    <el-row :gutter="30">
+      <el-col :span="5">
+        <income-type :incomeTypePara="incomeTypePara"></income-type>
       </el-col>
-    <el-col :span="1" > <el-divider direction="vertical"  style="height: 100%;"/></el-col>
-    <el-col  :span="18" style="padding-left: 0;">
-      <el-form :inline="true" label-width="90px" class="demo-form-inline">
-        <el-form-item label="鏀舵璐︽埛">
-          <el-select clearable placeholder="璇烽€夋嫨" style="width: 85%;"
-          v-model="queryMod.paymentAccount"
-          > 
-          <el-option
-              v-for="item in bankAccountNumberList"
-              :key="item.bankNumber"
-              :label="item.bankName"
-              :value="item.bankNumber"
-            />
-          </el-select>
-        </el-form-item>
-        <el-form-item label="涓氬姟鏃堕棿">
-          <el-date-picker
-            clearable v-model="queryMod.beginIncomeDate"
-            type="date"
-            style="width: 120px"
-            value-format="yyyy-MM-dd"
-            placeholder="寮€濮嬫棩鏈�"
-          ></el-date-picker>
-          ~
-          <el-date-picker
-            type="date"
-            clearable  v-model="queryMod.endIncomeDate"
-            style="width: 120px"
-            value-format="yyyy-MM-dd"
-            placeholder="缁撴潫鏃ユ湡"
+      <el-col :span="1">
+        <el-divider direction="vertical" style="height: 100%"
+      /></el-col>
+      <el-col :span="18" style="padding-left: 0">
+        <el-form :inline="true" label-width="90px" class="demo-form-inline">
+          <el-form-item label="鏀舵璐︽埛">
+            <el-select
+              clearable
+              placeholder="璇烽€夋嫨"
+              style="width: 85%"
+              v-model="queryMod.paymentAccount"
+            >
+              <el-option
+                v-for="item in bankAccountNumberList"
+                :key="item.bankNumber"
+                :label="item.bankName"
+                :value="item.bankNumber"
+              />
+            </el-select>
+          </el-form-item>
+          <el-form-item label="涓氬姟鏃堕棿">
+            <el-date-picker
+              clearable
+              v-model="queryMod.beginIncomeDate"
+              type="date"
+              style="width: 120px"
+              value-format="yyyy-MM-dd"
+              placeholder="寮€濮嬫棩鏈�"
+            ></el-date-picker>
+            ~
+            <el-date-picker
+              type="date"
+              clearable
+              v-model="queryMod.endIncomeDate"
+              style="width: 120px"
+              value-format="yyyy-MM-dd"
+              placeholder="缁撴潫鏃ユ湡"
+            >
+            </el-date-picker>
+          </el-form-item>
+          <el-form-item label="浠樻璐﹀彿">
+            <el-input
+              style="width: 90%"
+              v-model="queryMod.incomeSummary"
+              clearable
+              placeholder="浠樻璐﹀彿"
+            ></el-input>
+          </el-form-item>
+          <el-form-item label="涓氬姟鍗曞彿">
+            <el-input
+              style="width: 90%"
+              clearable
+              v-model="queryMod.billNo"
+              placeholder="涓氬姟鍗曞彿"
+            ></el-input>
+          </el-form-item>
+          <el-form-item label="閲戦">
+            <el-input
+              clearable
+              v-model="queryMod.incomeAmountStart"
+              style="width: 120px"
+              placeholder="寮€濮�"
+            ></el-input>
+            ~
+            <el-input
+              clearable
+              v-model="queryMod.incomeAmountEnd"
+              placeholder="缁撴潫"
+              style="width: 120px"
+            ></el-input>
+          </el-form-item>
+
+          <el-form-item label="浠樻浜�/鍗曚綅">
+            <el-input
+              style="width: 90%"
+              v-model="queryMod.incomeSummary"
+              clearable
+              placeholder="浠樻浜�/鍗曚綅"
+            ></el-input>
+          </el-form-item>
+        </el-form>
+        <el-form :inline="true" label-width="90px" class="demo-form-inline">
+          <el-form-item>
+            <el-button type="primary" @click="queryBatchEntry">鏌ヨ</el-button
+            ><el-button type="primary" @click="resetCondition">閲嶇疆</el-button>
+            <el-button type="primary" @click="resetCondition"
+              >鎵归噺鍏ヨ处</el-button
+            >
+          </el-form-item>
+        </el-form>
+
+        <el-table
+          :border="true"
+          stripe
+          :data="batchEntryResultList"
+          style="width: 100%"
+          :height="maxHeight"
+          highlight-current-row
+        >
+        <el-table-column type="selection" show-overflow-tooltip label="鍏ㄩ€�">
+        </el-table-column>
+          <el-table-column label="鍗曞彿"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.billNo }}</span>
+            </template></el-table-column
+          >
+          <el-table-column label="涓氬姟鏃堕棿"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.incomeDate }}</span>
+            </template></el-table-column
+          >
+          <el-table-column label="鏀舵閾惰璐︽埛"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.incomeAccount }}</span>
+            </template></el-table-column
+          >
+          <el-table-column label="浠樻璐︽埛"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.paymentAccount }}</span>
+            </template></el-table-column
+          >
+
+          <el-table-column label="浠樻浜�/鍗曚綅"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.paymentName }}</span>
+            </template></el-table-column
+          >
+          <el-table-column label="浠樻閲戦"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.incomeAmount }}</span>
+            </template></el-table-column
           >
-          </el-date-picker>
-        </el-form-item>
-        <el-form-item label="浠樻璐﹀彿">
-          <el-input style="width: 90%" v-model="queryMod.incomeSummary" clearable placeholder="浠樻璐﹀彿"></el-input>
-        </el-form-item>
-        <el-form-item label="涓氬姟鍗曞彿">
-          <el-input
-            style="width: 90%"
-            clearable v-model="queryMod.billNo"
-            placeholder="涓氬姟鍗曞彿"
-          ></el-input>
-        </el-form-item>
-        <el-form-item label="閲戦">
-          <el-input
-            clearable v-model="queryMod.beginAmount" 
-            style="width: 120px"
-            placeholder="寮€濮�"
-          ></el-input>
-          ~
-          <el-input
-            clearable v-model="queryMod.endAmount" 
-            placeholder="缁撴潫"
-            style="width: 120px"
-          ></el-input>
-        </el-form-item>
-       
-        <el-form-item label="浠樻浜�/鍗曚綅">
-          <el-input style="width: 90%" v-model="queryMod.incomeSummary" clearable placeholder="浠樻浜�/鍗曚綅"></el-input>
-        </el-form-item>
-      </el-form>
-      <el-form :inline="true" label-width="90px" class="demo-form-inline">
-        <el-form-item >
-          <el-button type="primary" @click="queryIncome">鏌ヨ</el-button
-          ><el-button type="primary" @click="resetCondition"
-            >閲嶇疆</el-button
+          <el-table-column label="鎽樿"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.incomeSummary }}</span>
+            </template></el-table-column
           >
-          <el-button type="primary" @click="resetCondition"
-            >鎵归噺鍏ヨ处</el-button
+          <el-table-column label="闄勮█"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.incomePostscript }}</span>
+            </template></el-table-column
           >
-        </el-form-item>
-      </el-form>
-    </el-col>
-  </el-row>
- 
+          <el-table-column label="鐘舵€�"
+            ><template v-slot="slot">
+              <span class="ellipsisclass">{{ slot.row.state }}</span>
+            </template></el-table-column
+          >
+        </el-table>
+        <Pagination
+        v-show="dataCount > 0"
+        :total="parseInt(dataCount)"
+        v-model:page="queryMod.pageIndex"
+        v-model:limit="queryMod.pageSize"
+        @pagination="queryBatchEntry()"
+      />
+      </el-col>
+    </el-row>
   </div>
 </template>
 
 <script>
 import { onMounted, reactive, toRefs } from 'vue';
-import IncomeType from '@/views/common/incometype.vue'
+import IncomeType from '@/views/common/incometype.vue';
 import BankAccountNumber from '@/api/BankAccountNumber';
+import Entry from '@/api/Entry';
+import { ElNotification } from 'element-plus';
+import Pagination from '@/components/Pagination';
 export default {
-name:"batchaccounting",
-components:{IncomeType},
-setup(){
-    const data=reactive({
+  name: 'batchaccounting',
+  components: { IncomeType,Pagination },
+  setup() {
+    const data = reactive({
       queryMod: {
         incomeAccount: '',
         paymentAccount: '',
@@ -99,42 +183,59 @@ setup(){
         billNo: '',
         beginIncomeDate: '',
         endIncomeDate: '',
-        beginAmount: '',
-        endAmount: '',
-        pageIndex:0,
-        pageSize:50
+        incomeAmountStart: '',
+        incomeAmountEnd: '',
+        pageIndex: 0,
+        pageSize: 50,
       },
-     incomeTypePara:{
-      menuName:'鎵归噺鍏ヨ处'
-     },
-     bankAccountNumberList:[]
-    })
-    const resetCondition=()=>{
-    data.queryMod.incomeAccount='';
-    data.queryMod.paymentAccount='';
-    data.beginAmount='';
-    data.endAmount='';
-    data.billNo='';
-    data.beginIncomeDate='';
-    data.endIncomeDate='';
-    data.pageIndex=1;
-    data.pageSize=50;
-    data.paymentName='';
-    }
-    onMounted(async()=>{
+      incomeTypePara: {
+        menuName: '鎵归噺鍏ヨ处',
+      },
+      bankAccountNumberList: [],
+      batchEntryResultList: [],
+      maxHeight: window.innerHeight - 265,
+      dataCount:0
+    });
+    const resetCondition = () => {
+      data.queryMod.incomeAccount = '';
+      data.queryMod.paymentAccount = '';
+      data.beginAmount = '';
+      data.endAmount = '';
+      data.billNo = '';
+      data.beginIncomeDate = '';
+      data.endIncomeDate = '';
+      data.pageIndex = 1;
+      data.pageSize = 50;
+      data.paymentName = '';
+    };
+    onMounted(async () => {
       const res = await BankAccountNumber.getBankAccountNumberList();
       if (res.code != '00000') {
         return ElNotification.warning(res.description);
       } else data.bankAccountNumberList = res.data;
-    })
-    return{
-        ...toRefs(data),
-        resetCondition
+    });
+    const queryBatchEntry=async()=>{
+   const res=await Entry.batchEntryPage(data.queryMod);
+   if (res.code != '00000') {
+            return ElNotification.warning(res.description);
+          } else {
+            data.batchEntryResultList = res.data;
+            data.dataCount = res.total;
+          }
     }
-}
-}
+    return {
+      ...toRefs(data),
+      resetCondition,
+      queryBatchEntry
+    };
+  },
+};
 </script>
 
 <style>
-
+.ellipsisclass {
+  text-overflow: ellipsis;
+  overflow: hidden;
+  white-space: nowrap;
+}
 </style>
\ No newline at end of file
diff --git a/WebSite/src/views/common/organize.vue b/WebSite/src/views/common/organize.vue
index 396506b..b6e6e59 100644
--- a/WebSite/src/views/common/organize.vue
+++ b/WebSite/src/views/common/organize.vue
@@ -80,7 +80,7 @@
 
 <script>
 import { onMounted, reactive, toRefs } from 'vue';
-import Pagination from 'element-plus/lib/el-pagination';
+import Pagination from '@/components/Pagination';
 import Common from '@/api/Common';
 import { ElMessage, ElNotification,ElMessageBox } from 'element-plus';
 export default {
diff --git a/WebSite/src/views/srincomeallocation/index.vue b/WebSite/src/views/srincomeallocation/index.vue
index 20d3946..1673b21 100644
--- a/WebSite/src/views/srincomeallocation/index.vue
+++ b/WebSite/src/views/srincomeallocation/index.vue
@@ -244,7 +244,7 @@
 </template>
 
 <script>
-import { ElNotification } from 'element-plus';
+import { ElMessage, ElNotification } from 'element-plus';
 import { onMounted, reactive, toRefs, getCurrentInstance } from 'vue';
 import Common from '@/api/Common';
 import IncomeType from '@/api/IncomeType';
@@ -368,6 +368,13 @@ export default {
           data.relatedVoucherPara.visible = true;
           data.relatedVoucherPara.id = row.id;
         }
+        if (row.entryMode == '閮ㄩ棬璁ら' || row.entryMode=='璐熻矗浜鸿棰�') {
+        
+        }
+        if(row.entryMode=='鎵归噺鍏ヨ处')
+        {
+          return ElMessage.success("宸蹭繚瀛樻敹鍏ョ被鍨嬶紝寰呮壒閲忓叆璐﹀鐞嗐€�");
+        }
     };
     return {
       ...toRefs(data),
-- 
GitLab