Sfoglia il codice sorgente

新增财务管理-费用核对-支付页面

lihongxiao 3 anni fa
parent
commit
83d3700ef6

+ 28 - 8
src/components/TemplateTable/index.vue

@@ -12,16 +12,27 @@
       <el-form-item v-for="f in formList" :key="f.prop" :label="f.label" :prop="f.prop">
         <template>
           <template v-if="f.type === 'input'">
-            <el-input clearable v-model.trim="searchDataClone[f.prop]" size="small"></el-input>
+            <el-input clearable v-model.trim="searchDataClone[f.prop]" size="small" :placeholder="'请输入'+f.label"></el-input>
           </template>
           <template v-else-if="f.type === 'select'">
-            <el-select size="small" v-model="searchDataClone[f.prop]" placeholder="请选择">
+            <el-select size="small" clearable  v-model="searchDataClone[f.prop]" :placeholder="'请输入'+f.label">
               <el-option label="不限" value v-if="f.selectAuto"></el-option>
               <el-option
-                v-for="(s, i) in f.selectList"
+                v-for="(s, i) in f.options"
                 :key="i"
-                :label="s[f.optionLabel]"
-                :value="s[f.optionValue]"
+                :label="s.label"
+                :value="s.value"
+              ></el-option>
+            </el-select>
+          </template>
+          <template v-else-if="f.type === 'company'">
+            <el-select size="small" clearable  v-model="searchDataClone[f.prop]" :placeholder="'请输入'+f.label">
+              <el-option label="不限" value v-if="f.selectAuto"></el-option>
+              <el-option
+                v-for="(s, i) in InsCompanyList"
+                :key="i"
+                :label="s.name"
+                :value="s.id"
               ></el-option>
             </el-select>
           </template>
@@ -106,12 +117,12 @@
                 <!-- 自定义内容 -->
                 <slot v-if="item.type ==='slot'" show-overflow-tooltip :name="item.name"></slot>
                 <!-- 常规文本内容 -->
-                <el-table-column v-else :align="'center'"  :width="item.width || ''"  :fixed="item.fixed" show-overflow-tooltip :label="item.label"  :key="item.prop"  :prop="item.prop"></el-table-column>
+                <el-table-column v-else :align="'center'"  :width="item.width || ''"  :fixed="item.fixed"  :label="item.label"  :key="item.prop"  :prop="item.prop"></el-table-column>
 
             </template>
             <!-- <slot name="operate" :row="scope.row"></slot> -->
             <!-- 自定义操作栏 -->
-            <el-table-column v-if="tableConfig.operateShow" label="操作" align="center" :min-width="tableConfig.operationWidth || '100'"  fixed="right">
+            <el-table-column v-if="tableConfig.operateShow " label="操作" align="center" :min-width="tableConfig.operationWidth || '100'"  fixed="right">
                 <template slot-scope="scope">
                 <slot name="operate" :row="scope.row"></slot>
                 </template>
@@ -130,7 +141,7 @@
             <el-table-column v-if="tableConfig.optBtns" :min-width="tableConfig.operationWidth || '100'" label="操作" fixed="right"   header-align="center" align="center" >
                 <template slot-scope="scope">
                     <span v-for="(btn, index) in tableConfig.optBtns" :key="index">
-                        <el-button style="margin:0 10px"  v-permission="btn.perm"  v-if="btn.hide(scope.row)"  @click="btn.click(scope.row, index)" :type="btn.type" :icon="btn.icon" size="small">{{ btn.label }} </el-button>                   
+                        <el-button style="margin:0 10px"  v-permission="btn.perm"    @click="btn.click(scope.row, index)" :type="btn.type ||'primary'" :icon="btn.icon" size="small">{{ btn.label }} </el-button>                   
                    </span>
                 </template>
               </el-table-column>
@@ -200,9 +211,11 @@ export default {
   },
   data() {
     return {
+      InsCompanyList:[]
     };
   },
   created() {
+    this.companyFun()
   },
   filters: {
         formateDate(val) {
@@ -210,6 +223,13 @@ export default {
         }
     },
   methods: {
+    companyFun(){
+       this.$api.cost.gainTopList().then(res => {
+          if (res.data) {
+              this.InsCompanyList = res.data;
+          }
+      });
+        },
     selectDictLabel(dicts, value) {
         if (value === undefined) {
             return '';

+ 7 - 0
src/http/moudules/cost.js

@@ -102,3 +102,10 @@ export const getChannelMatchingIns= (data) => {
         data
     })
 }
+// 渠道确定领取接口
+export const receiveBatchNum= (id) => {
+    return axios({
+        url: "/api/inv/channelsExternalBillsDetails/receive/"+id,
+        method: "get",
+    })
+}

+ 4 - 2
src/utils/btnPermission.js

@@ -11,10 +11,12 @@ const permission = {
         // sessionStorage.setItem('ButtonPermissions',JSON.stringify(['role:add']))
         // 自定义指令的执行函数,,取到登录缓存的按钮权限数组,赋值给全局对象userMsg
         global.ButtonPermissions = store.state.user.perms
+
         // global.ButtonPermissions = JSON.parse(sessionStorage.getItem('ButtonPermissions'))
-        if (global.ButtonPermissions && global.ButtonPermissions.indexOf(value) < 0) {
-            el.style.display = 'none'
+        if (!global.ButtonPermissions && global.ButtonPermissions.indexOf(value) < 0) {
+            el.style.display = 'block'
         }
+       
     }
 }
 // 全局注册自定义指令

+ 12 - 1
src/views/FinancialManagement/CostVerification/Channel.vue

@@ -362,7 +362,7 @@
       ></el-pagination>
     </div>
       <span slot="footer" class="dialog-footer">
-        <el-button type="primary" size="small" :disabled='isDisabled' @click="dialogMateVisible=false">确定领取</el-button>
+        <el-button type="primary" size="small" :disabled='isDisabled' @click="confirmReceipt()">确定领取</el-button>
       </span>
     </el-dialog>
     <el-dialog
@@ -688,6 +688,17 @@ export default {
         }
       });
     },
+    confirmReceipt(){
+      this.$api.cost.receiveBatchNum(this.batchNumDetailId).then(res => {
+        if (res.code == 200) {
+          this.dialogMateVisible=false
+          this.$message({
+              message: "领取成功",
+              type: "success"
+            });
+        }
+      });
+    },
     handleTableDetail() {
       this.dialogBVatchVisible = true;
     },

+ 314 - 0
src/views/FinancialManagement/CostVerification/Payment.vue

@@ -0,0 +1,314 @@
+<template>
+    <!--布局容器-->
+    <div class="container" style="width: 99%; margin-top: 0px">
+        <templateTable :formList="formList" :searchData.sync="searchData" :tableConfig="tableConfig" :btnGroup="btnGroup"
+            :data="tableData" @getList="getList" @handleSearchList="handleSearchList" :pagination="queryFrom">
+            <el-table-column slot="batchNum" label="批次号" align="center">
+                <template slot-scope="scope">
+                    <span class="batchStyle" @click="redirectDetail(scope.row)">{{ scope.row.batchNum }}</span>
+                </template>
+            </el-table-column>
+        </templateTable>
+        <el-dialog v-dialogDrag title="批次详情" :visible.sync="dialogBVatchVisible" width="80%"
+            @close="closeBVatchVisibleVisible">
+            <div class="detailStyle">
+                <el-row>
+                    <el-col :span="4">交强险保费:{{ formDetailData.mlifta }}</el-col>
+                    <el-col :span="4">手续费:</el-col>
+                    <el-col :span="4">商业险保费:{{ formDetailData.cip }}</el-col>
+                    <el-col :span="4">手续费:</el-col>
+                </el-row>
+                <el-row style="margin:20px 0">
+                    <el-col :span="4">车船税:{{ formDetailData.vavt }}</el-col>
+                    <el-col :span="4">手续费:</el-col>
+                    <el-col :span="4">其他保费:{{ formDetailData.other }}</el-col>
+                    <el-col :span="4">手续费:</el-col>
+                </el-row>
+                <el-row>
+                    <el-col :span="16" style="text-align: center;">合计手续费:</el-col>
+                </el-row>
+            </div>
+            <el-table size="small" :data="batchData" border highlight-current-row stripe ref="expandTable"
+                :header-cell-style="{ background: '#F2F7FC', fontWeight: '700', color: '#606266' }">
+                <template v-for="(item, index) in columns">
+                    <el-table-column :prop="item.prop" :label="item.label" :key="index"></el-table-column>
+                </template>
+                <el-table-column label="操作" align="center" min-width="60">
+                    <template slot-scope="scope">
+                        <el-button size="mini" type="primary" @click="detailBatchFun(scope.row)">详情</el-button>
+                    </template>
+                </el-table-column>
+            </el-table>
+            <div class="block">
+                <el-pagination @size-change="tablePageBatchChange" @current-change="tableCurrentBatchChange"
+                    :current-page="queryBatchFrom.pageNum" :page-size="queryBatchFrom.pageSize"
+                    :page-sizes="[10, 20, 50, 100]" layout="total, sizes, prev, pager, next, jumper"
+                    :total="queryBatchFrom.totalSize"></el-pagination>
+            </div>
+        </el-dialog>
+        <el-dialog v-dialogDrag title="详情" :visible.sync="dialogBVatch" width="60%" @close="closdialogBVatceVisible">
+            <el-row style="margin-bottom:20px">
+                <el-col :span="8">批次号:{{ formBatchDetailData.batchNum }}</el-col>
+                <el-col :span="4">保险公司:中煤保险</el-col>
+                <el-col :span="8">保单号:{{ formBatchDetailData.policyNum }}</el-col>
+                <el-col :span="4">车牌号:{{ formBatchDetailData.plateNum }}</el-col>
+            </el-row>
+            <el-row>
+                <el-col :span="8">被保险人:{{ formBatchDetailData.insured }}</el-col>
+                <el-col :span="4">险种:{{ formBatchDetailData.insKindName }}</el-col>
+                <el-col :span="8">付款日期:{{ formBatchDetailData.payDate }}</el-col>
+            </el-row>
+            <el-row style="margin:40px 0 20px 0">
+                <el-col :span="8">交强险保费:{{ formBatchDetailData.mlifta }}</el-col>
+                <el-col :span="4">手续费:{{ formBatchDetailData.other }}</el-col>
+                <el-col :span="8">商业险保费:{{ formBatchDetailData.cip }}</el-col>
+                <el-col :span="4">手续费:{{ formBatchDetailData.other }}</el-col>
+            </el-row>
+            <el-row>
+                <el-col :span="8">车船税:{{ formBatchDetailData.vavt }}</el-col>
+                <el-col :span="4">手续费:{{ formBatchDetailData.other }}</el-col>
+                <el-col :span="8">其他保费:{{ formBatchDetailData.other }}</el-col>
+                <el-col :span="4">手续费:{{ formBatchDetailData.other }}</el-col>
+            </el-row>
+        </el-dialog>
+    </div>
+</template>
+  
+<script>
+import templateTable from '../../../components/TemplateTable/index.vue'
+import { mapState } from 'vuex'
+
+export default {
+    name: "payment",
+    components: { templateTable },
+    created() {
+        this.getList();
+    },
+    computed: {
+        ...mapState({
+            perms: state => state.user.perms
+        })
+    },
+    data() {
+        return {
+            InsCompanyList: [],
+            searchData: {},
+            formList: [
+                {
+                    label: "保险公司",
+                    prop: "insCompanyId",
+                    type: "company",
+                },
+                {
+                    label: "业务渠道",
+                    prop: "业务渠道",
+                    type: 'input'
+                },
+                {
+                    label: "车牌号",
+                    prop: "plateNum",
+                    type: 'input'
+                },
+                {
+                    label: "批次号",
+                    prop: "batchNum",
+                    type: 'input'
+                },
+                {
+                    label: "支付状态",
+                    prop: "status",
+                    type: 'select',
+                    options: [
+                        {
+                            label: '已支付',
+                            value: '1'
+                        }, {
+                            label: '未支付',
+                            value: '0'
+                        },
+                    ]
+                },
+            ],
+            tableConfig: {
+                columns: [
+                    {
+                        type: 'slot',
+                        name: 'batchNum',
+                    },
+                    {
+                        prop: 'insCompany', label: '保险公司',
+                    },
+                    {
+                        prop: 'plateNum', label: '车牌号',
+                    },
+                    {
+                        prop: 'mlifta', label: '交强险保费',
+                    },
+                    {
+                        prop: 'vavt', label: '车船税',
+                    }, {
+                        prop: 'other', label: '其他保费',
+                    }, {
+                        prop: 'status', label: '状态',
+                    }, {
+                        prop: '应付', label: '应付',
+                    }, {
+                        prop: '操作人', label: '操作人',
+                    }, {
+                        prop: 'payDate', label: '支付日期',
+                    }
+                ],
+
+                isCheckBox: true,
+                loading: true,
+                isPaginationShow: true,
+                optBtns: [
+                    {
+                        label: '支付',
+                        click: (row, index) => { return this.payFun(row) },
+                    }
+                ]
+            },
+            btnGroup: [{
+                name: '批量支付',
+                click: "changs",
+            }],
+            columns: [
+                {
+                    prop: "batchNum",
+                    label: "批次号"
+                },
+                {
+                    prop: "policyNum",
+                    label: "保单号"
+                },
+                {
+                    prop: "plateNum",
+                    label: "车牌号"
+                },
+                {
+                    prop: "insured",
+                    label: "被保险人"
+                },
+                {
+                    prop: "insKindName",
+                    label: "险种"
+                },
+                {
+                    prop: "mlifta",
+                    label: "交强险保费"
+                },
+                {
+                    prop: "vavt",
+                    label: "车船税"
+                },
+                {
+                    prop: "cip",
+                    label: "商业保险费"
+                },
+                {
+                    prop: "other",
+                    label: "其他保费"
+                },
+                {
+                    prop: "payDate",
+                    label: "付款日期"
+                }
+            ],
+            queryFrom: {
+                pageNum: 1,
+                pageSize: 10,
+                totalSize: 0
+            },
+            tableData: [],
+            queryBatchFrom: {
+                pageNum: 1,
+                pageSize: 10,
+                totalSize: 0
+            },
+            batchData: [],
+            formDetailData: {},
+            formBatchDetailData: {},
+            dialogBVatch: false,
+            dialogBVatchVisible: false
+        }
+    },
+    methods: {
+        //列表数据
+        getList(data) {
+            this.tableConfig.loading = true;
+            this.$api.cost.getchanneQueryPageDetails({ ...this.queryFrom, ...data }).then(res => {
+                if (res.data) {
+                    this.tableData = res.data.content;
+                    this.queryFrom.pageNum = res.data.pageNum;
+                    this.queryFrom.pageSize = res.data.pageSize;
+                    this.queryFrom.totalSize = res.data.totalSize;
+                    this.tableConfig.loading = false;
+                } else {
+                    this.tableConfig.loading = false;
+                }
+            });
+        },
+
+        handleSearchList(data) {
+            this.getList(data)
+        },
+        payFun(row) {
+            console.log(row, 1111111)
+        },
+        getBachList(batchNum) {
+            this.$api.cost
+                .getQueryPageDetails({
+                    batchNum,
+                    ...this.queryBatchFrom,
+                })
+                .then(res => {
+                    this.batchData = res.data.content;
+                    this.queryBatchFrom.pageNum = res.data.pageNum;
+                    this.queryBatchFrom.pageSize = res.data.pageSize;
+                    this.queryBatchFrom.totalSize = res.data.totalSize;
+                });
+        },
+        // 批次详情列表
+        redirectDetail(row) {
+            this.dialogBVatchVisible = true;
+            this.formDetailData = row;
+            this.getBachList(row.id);
+        },
+        tablePageBatchChange(val) {
+            this.queryBatchFrom.pageSize = val;
+            this.getBachList();
+        },
+        tableCurrentBatchChange(val) {
+            this.queryBatchFrom.pageNum = val;
+            this.getBachList();
+        },
+        // 批次详情查看接口
+        detailBatchFun(row) {
+            let id = row.id;
+            this.dialogBVatch = true;
+            this.$api.cost.detailsById(id).then(res => {
+                if (res.code == 200) {
+                    this.formBatchDetailData = res.data;
+                }
+            });
+        },
+        closeBVatchVisibleVisible() {
+            this.dialogBVatchVisible = false;
+        },
+        closdialogBVatceVisible() {
+            this.dialogBVatch = false;
+        },
+    }
+}
+</script>
+<style scoped>
+.batchStyle {
+    cursor: pointer;
+}
+
+.batchStyle:hover {
+    color: #8b0000;
+    text-decoration: underline;
+}
+</style>

+ 1 - 1
src/views/Task/Calculate - 副本.vue

@@ -674,7 +674,7 @@
 								  <el-col :span="8" class="u-f-ajc">{{insureItem.coveragePremium}}</el-col>
 								</el-row>
 								<el-row v-if="item.quoteCode=='200'" class="u-f-je" style="margin-top: 15px;">
-									<el-button type="primary" @click="showIframe(global.baseUrl.split(':80')[0]+':8091/#/pages/carInsure/quoteDetail?orderno='+item.result.orderno)">报价详情</el-button>
+									<el-button type="primary" @click="showIframe(process.env.BASE_URL.split(':80')[0]+':8091/#/pages/carInsure/quoteDetail?orderno='+item.result.orderno)">报价详情</el-button>
 								</el-row>
 							</el-row>
 						</template>

+ 3 - 2
src/views/Task/Calculate.vue

@@ -512,6 +512,7 @@
 		
 		<el-row class="u-f-ajc" style="margin: 20px 0;" v-if="isNewOrder">
 			<el-button type="primary" @click="quote">计算保费</el-button>
+			
 			<!-- <el-button @click="showIframe(global.baseUrl.split(':80')[0]+':8091/#/pages/carInsure/quoteDetail?orderno=1410512434299760640')" type="primary" style="margin-left: 16px;">
 			  点我打开
 			</el-button> -->
@@ -573,7 +574,7 @@
 								  <el-col :span="8" class="u-f-ajc">{{insureItem.coveragePremium}}</el-col>
 								</el-row>
 								<el-row v-if="item.quoteCode=='200'" class="u-f-je" style="margin-top: 15px;">
-									<el-button type="primary" @click="showIframe(global.baseUrl.split(':80')[0]+':8091/#/pages/carInsure/quoteDetail?orderno='+item.result.orderno)">报价详情</el-button>
+									<el-button type="primary" @click="showIframe(process.env.BASE_URL.split(':80')[0]+':8091/#/pages/carInsure/quoteDetail?orderno='+item.result.orderno)">报价详情</el-button>
 								</el-row>
 							</el-row>
 						</template>
@@ -821,7 +822,7 @@
 		</el-card>
 		
 		<el-row class="u-f-ajc" style="margin: 20px 0;" v-if="orderStatus=='5'">
-			<el-button type="primary" @click="showIframe(global.baseUrl.split(':80')[0]+':8091/#/pages/carInsure/payCode?orderno='+orderId)">生成缴费二维码</el-button>
+			<el-button type="primary" @click="showIframe(process.env.BASE_URL.split(':80')[0]+':8091/#/pages/carInsure/payCode?orderno='+orderId)">生成缴费二维码</el-button>
 		</el-row>
 		
 		<el-card id="demo10" v-if="orderStatus>6">