瀏覽代碼

前端代码合并提交

Administrator 2 年之前
父節點
當前提交
4c827e9997
共有 4 個文件被更改,包括 373 次插入10 次删除
  1. 5 1
      src/router/index.js
  2. 9 1
      src/views/Home.vue
  3. 45 8
      src/views/customer/customerEtcChangeInfo.vue
  4. 314 0
      src/views/selfCar/selfCarApply.vue

+ 5 - 1
src/router/index.js

@@ -20,6 +20,8 @@ const CustomerRecharge = () => import('@/views/customer/customerRecharge');
 const custRecTime = () => import('@/views/customer/custRecTime');
 const custRecMoney = () => import('@/views/customer/custRecMoney');
 
+const customerEtcChangeInfo = () => import('@/views/customer/customerEtcChangeInfo');
+
 // 系统管理部分
 const User = () => import('@/views/sys/user');
 
@@ -39,7 +41,7 @@ const selfCarTrade = () => import('@/views/selfCar/selfCarTrade.vue');
 const selfInvoice = () => import('@/views/selfCar/invoice.vue');
 const selfCarTradeException = () => import('@/views/selfCar/selfCarTradeException.vue');
 const SelfCalculateInfo = () => import('@/views/selfCar/calculateInfo.vue');
-
+const selfCarApply = () => import('@/views/selfCar/selfCarApply');
 // 平台菜单部分
 
 // 发票管理部分(企业注册部分)
@@ -94,6 +96,8 @@ const router = new Router({
         { name: 'customerRecharge', path: '/CustomerRecharge', component: CustomerRecharge },
         { name: 'custRecTime', path: '/custRecTime', component: custRecTime },
         { name: 'custRecMoney', path: '/custRecMoney', component: custRecMoney },
+        { name: 'customerEtcChangeInfo', path: '/customerEtcChangeInfo', component: customerEtcChangeInfo },
+        { name: 'selfCarApply', path: '/selfCarApply', component: selfCarApply },
         // 系统管理部分
         { name: 'User', path: '/user', component: User },
         // 无车部分

+ 9 - 1
src/views/Home.vue

@@ -184,6 +184,10 @@ export default {
               id:4,
               path:"custRecMoney",
               authName:"余额预警查询"
+            },{
+              id:4,
+              path:"customerEtcChangeInfo",
+              authName:"客户换卡记录查询"
             }
           ]
          },
@@ -237,7 +241,11 @@ export default {
               id:4,
               path:"selfInvoice",
               authName:"发票查询"
-            }
+            },{
+              id:5,
+              path:"selfCarApply",
+              authName:"按申请发票查询"
+            } 
           ]
          },{
           id: 6,

+ 45 - 8
src/views/customer/customerEtcChangeInfo.vue

@@ -43,12 +43,16 @@
             label="原公司编号"
             show-overflow-tooltip>
           </el-table-column>
-
-            <el-table-column
+        <el-table-column
             prop="targetCompanyName"
             label="目标公司名称"
             show-overflow-tooltip>
           </el-table-column>
+            <el-table-column
+            prop="targetCompanyNum"
+            label="目标公司编码"
+            show-overflow-tooltip>
+          </el-table-column>
 
             <el-table-column
             prop="changeTime"
@@ -82,12 +86,35 @@
         @size-change="handleSizeChange"
         @current-change="handleCurrentChange"
         :current-page="current"
-        :page-sizes="[6, 8, 10, 20, 50, 100,300,500,1000,3000,5000,8000]"
+        :page-sizes="[500,1000,3000,5000,8000]"
         :page-size="pagesize"
         layout="total, sizes, prev, pager, next, jumper"
         :total="total">
         </el-pagination>
       </div>
+        <el-dialog
+        :visible.sync="flag"
+        style="font-size: 0px;">
+        <div class="tou">客户--换卡记录</div>
+        <div class="line"></div>
+<!-- 表格部分 -->
+       <template>
+        <el-table
+          v-loading="loading"
+          ref="multipleTable"
+          :data="customerChangeInfoTable"
+           height="370px"
+          border
+          tooltip-effect="dark">
+          <el-table-column
+            label="etc卡号"
+            prop="cardId"
+            show-overflow-tooltip>
+          </el-table-column>
+          
+        </el-table>
+      </template>
+      </el-dialog>
     </div>
 </template>
 <script type="text/javascript">
@@ -100,10 +127,12 @@ import XLSX from "xlsx";
               companyName:'',
               customerId:''
             },
+            flag:false,
             customerChangeListTable:[],
+            customerChangeInfoTable:[],
              hightt:'0px',
             current: 1,
-            pagesize: 50,
+            pagesize: 500,
             total:''
           }
         },
@@ -124,14 +153,22 @@ import XLSX from "xlsx";
             formData.append('size', this.pagesize);
             formData.append('companyName', this.formCondition.companyName);
             formData.append('customerId', this.formCondition.customerId);
-            const response = await this.$http.post(`customer/customerChangeListTable`, formData);
+            const response = await this.$http.post(`customer/customerChangeList`, formData);
             if (response.data.code === 0) {
-              this.customeRecTimeListTable = response.data.data.records;
+              this.customerChangeListTable = response.data.data.records;
               this.total = response.data.data.total;
             }
           },
-          showChangeInfo(recoder){
-
+          async showChangeInfo(recoder){
+             this.flag = true;
+              const formData = new FormData();
+             formData.append('applyId', recoder['applyId']);
+              const response = await this.$http.post(`customer/customerChangeInfo`, formData);
+            if (response.data.code === 0) {
+              this.customerChangeInfoTable = response.data.data;
+            }else{
+              this.customerChangeInfoTable = [];
+            }
           },
           // 分页方法
           handleSizeChange(val) {

+ 314 - 0
src/views/selfCar/selfCarApply.vue

@@ -0,0 +1,314 @@
+<template>
+    <div class="invoice_container">
+      <div class="title">
+        <el-row>
+          <el-col :span="24">
+            <div class="top">
+               <el-input  placeholder="企业编号" class="input-demo" v-model="formCondition.companyNum"></el-input>
+               <el-input  placeholder="申请Id" class="input-demo" v-model="formCondition.applId"></el-input>
+               <el-input  placeholder="etc卡号" class="input-demo" v-model="formCondition.etcNum"></el-input>
+               <el-button type="success" style="margin-left: 1%;" @click="loadData">查询</el-button>
+               <el-button type="primary" style="margin-left: 1%;" @click="exportExcel">导出报表</el-button>
+            </div>
+          </el-col>
+        </el-row>
+      </div>
+      <!-- 表格部分 -->
+        <template>
+        <el-table
+          class="table"
+          v-loading="loading"
+          ref="multipleTable"
+          :data="invoiceTable"
+          :height="heightt"
+          border
+          tooltip-effect="dark">
+          <el-table-column
+            prop="plateNum"
+            label="车牌号"
+            show-overflow-tooltip>
+          </el-table-column>
+           <el-table-column
+            prop="cardId"
+            label="ETC卡号"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="tradeId"
+            label="交易Id"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="sellerTaxpayerCode"
+            label="销方税号"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="sellerName"
+            label="销方名称"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="enStation"
+            label="入口收费站"
+            width="100"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="exStation"
+            label="出口收费站"
+            width="100"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="invoiceCode"
+            label="发票代码"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="invoiceNum"
+            label="发票号码"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="invoiceMakeTime"
+            label="开票时间"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="exTime"
+            label="交易时间"
+            show-overflow-tooltip>
+          </el-table-column>
+          <!-- <el-table-column
+            prop="enStation"
+            label="入口收费站"
+            width="100"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="exStation"
+            label="出口收费站"
+            width="100"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="sellerName"
+            label="销方名称"
+            show-overflow-tooltip>
+          </el-table-column>
+          <el-table-column
+            prop="sellerTaxpayerCode"
+            label="销方税号"
+            show-overflow-tooltip>
+          </el-table-column> -->
+           <el-table-column
+            prop="fee"
+            label="交易金额"
+            show-overflow-tooltip>
+             <template slot-scope="scope">
+               <span>{{scope.row.fee/100| rounding}}</span>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="totalAmount"
+            label="价税合计"
+            show-overflow-tooltip>
+             <template slot-scope="scope">
+               <span>{{scope.row.totalAmount/100| rounding}}</span>
+            </template>
+          </el-table-column>
+           <el-table-column
+            prop="totalTaxAmount"
+            label="税额"
+            show-overflow-tooltip>
+             <template slot-scope="scope">
+               <span>{{scope.row.totalTaxAmount/100| rounding}}</span>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="amount"
+            label="金额"
+            show-overflow-tooltip>
+            <template slot-scope="scope">
+               <span>{{scope.row.fee/100| rounding}}</span>
+            </template>
+          </el-table-column>
+           <el-table-column
+            prop="taxRate"
+            label="税率"
+            show-overflow-tooltip>
+            <template slot-scope="scope">
+               <span>{{scope.row.taxRate| rounding}}</span>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="invoiceHtmlUrl"
+            label="预览地址"
+            show-overflow-tooltip>
+            <template slot-scope="scope">
+               <a :href="scope.row.invoiceHtmlUrl" target="_blank">{{scope.row.invoiceHtmlUrl}}</a>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="invoiceUrl"
+            label="下载地址"
+            show-overflow-tooltip>
+            <template slot-scope="scope">
+               <a :href="scope.row.invoiceUrl" target="_blank">{{scope.row.invoiceUrl}}</a>
+            </template>
+          </el-table-column>
+           <el-table-column
+            prop="invoiceStatus"
+            label="状态"
+            show-overflow-tooltip>
+             <template slot-scope="scope">
+              <span v-if="scope.row.tradeStatus == 1" style="color: green">待开票</span>
+              <span v-else-if="scope.row.tradeStatus == 2" style="color: red">开票中</span>
+              <span v-else-if="scope.row.tradeStatus == 3" style="color: red">已开票</span>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="msg"
+            label="发票状态信息"
+            width="100"
+            show-overflow-tooltip>
+          </el-table-column>
+        </el-table>
+      </template>
+    </div>
+</template>
+<script type="text/javascript">
+import FileSaver from "file-saver";
+import XLSX from "xlsx";
+      export default {
+        data(){
+          return{
+            formCondition:{
+              etcNum:'',
+              applId:'',
+              companyNum:''
+            },
+        
+           invoiceTable:[],
+            hightt:'0px',
+          }
+        },
+        created() {
+          this.heightt = tableHeight-50;
+        },
+        filters: {
+            rounding (value) {
+              return value.toFixed(2)
+            }
+        },
+        methods:{
+           firstLoadData(){
+           
+          },
+          // 列表展示
+          async loadData() {
+            const formData = new FormData();
+            for(var i in this.formCondition){
+                formData.append(i,this.formCondition[i]);
+            }
+            const response = await this.$http.post('selfCarService/getSelfCarInvoicesByAppl', formData);
+            if (response.data.code === 0) {
+              this.invoiceTable = response.data.data;
+            }
+          },
+
+         exportExcel() {
+          const loading = this.$loading({
+                                lock: true,
+                                text: '系统正在努力接收中,过程大概需要几分钟的时间,请您耐心等待...',
+                                spinner: 'el-icon-loading',
+                                background: 'rgba(0, 0, 0, 0.7)'
+                              });
+          // 设置当前日期
+          let time = new Date();
+          let year = time.getFullYear();
+          let month = time.getMonth() + 1;
+          let day = time.getDate();
+          let name = "自有车发票查询列表_"+year + "" + month + "" + day;
+          /* generate workbook object from table */
+          //  .table要导出的是哪一个表格
+          var wb = XLSX.utils.table_to_book(document.querySelector(".table"),{ raw: true });
+          this.formartNum(wb);
+          /* get binary string as output */
+          var wbout = XLSX.write(wb, {
+            bookType: "xlsx",
+            bookSST: true,
+            type: "array"
+          });
+          try {
+            //  name+'.xlsx'表示导出的excel表格名字
+            FileSaver.saveAs(
+              new Blob([wbout], { type: "application/octet-stream" }),
+              name + ".xlsx"
+            );
+          } catch (e) {
+            if (typeof console !== "undefined") console.log(e, wbout);
+          }
+          loading.close();
+          return wbout;
+      },
+         
+        }
+      };
+</script>
+<style>
+.invoice_container {
+  border: 1px solid #d9d9d9;
+  border-radius: 10px;
+}
+.invoice_container .title {
+  font-size: 5px;
+  margin-bottom: 20px;
+}
+.invoice_container .top {
+  padding-top: 20px;
+  padding-left: 20px;
+}
+.invoice_container .text {
+  display: inline-block;
+  color: #000;
+  font-size: 16px ;
+  margin-left: 1%;
+}
+.invoice_container .input-demo {
+  display: inline-block;
+  width: 15%;
+  margin-left: 1%;
+}
+.invoice_container .block {
+  font-size: 5px;
+  text-align: center;
+  margin-top: 25px;
+  margin-bottom: 25px;
+}
+.invoice_container .el-dialog {
+  width: 60%;
+}
+.invoice_container .el-dialog__header, .el-dialog__body {
+  padding: 0 20px;
+}
+.invoice_container .tou {
+  font-size: 20px;
+  height: 30px;
+  line-height: 30px;
+  padding-top: 15px;
+}
+.invoice_container .line {
+  margin-top: 15px;
+  margin-bottom: 15px;
+  width: 100%;
+  height: 2px;
+  background-color: #d9d9d9;
+}
+.invoice_container .xinxi {
+  text-align: center;
+  margin: 15px auto;
+  font-size: 18px;
+}
+</style>