Jelajahi Sumber

新增预警待办功能菜单页面

shipeng 2 bulan lalu
induk
melakukan
9dadb7a8e6

+ 18 - 0
src/api/team/teamMr.js

@@ -112,4 +112,22 @@ export const searchCompanysApi = (data) => {
     method: 'post',
     data: data
   })
+}
+
+// 预警待办分页查询   
+export const waitRepaymentList = (query) => {
+  return request({
+    url: '/member/marketTeamCreditAccount/waitRepaymentList',
+    method: 'get',
+    params: query
+  })
+}
+
+// 预警待办数量
+export const WaitRepaymentTotal = (query) => {
+  return request({
+    url: '/member/marketTeamCreditAccount/waitRepaymentTotal',
+    method: 'get',
+    params: query
+  })
 }

File diff ditekan karena terlalu besar
+ 0 - 0
src/assets/icons/svg/bell.svg


+ 44 - 0
src/components/RuoYi/Bell/index.vue

@@ -0,0 +1,44 @@
+<template>
+  <div v-hasPermi="['team:earlyWarning:isShow']">
+    <el-badge :value="total" class="item">
+      <svg-icon icon-class="bell" @click="goTo" />
+    </el-badge>
+    
+  </div>
+</template>
+
+<script>
+import { 
+  WaitRepaymentTotal
+} from '@/api/team/teamMr'
+export default {
+  name: 'RuoYiBell',
+  data() {
+    return {
+      total: 0,// 预警待办数
+    }
+  },
+  created() {
+    this.getNumTotal();
+  },
+  methods: {
+    getNumTotal() {
+      WaitRepaymentTotal(this.queryParams).then(response => {
+          this.total = response.data.total
+      }).catch(()=>{
+      })
+    },
+    goTo() {
+      this.$router.push('/team/earlyWarning');
+    }
+  }
+}
+</script>
+<style lang="css" scoped>
+::v-deep .el-badge__content.is-fixed {
+    position: absolute;
+    top: 10px;
+    right: 15px;
+  }
+
+</style>

+ 8 - 1
src/layout/components/Navbar.vue

@@ -7,6 +7,11 @@
 
     <div class="right-menu">
       <template v-if="device!=='mobile'">
+        
+        <el-tooltip content="预警待办" effect="dark" placement="bottom">
+            <ruo-yi-bell id="ruoyi-bell" class="right-menu-item hover-effect" />
+        </el-tooltip>
+
         <search id="header-search" class="right-menu-item" />
         
         <el-tooltip content="源码地址" effect="dark" placement="bottom">
@@ -56,6 +61,7 @@ import SizeSelect from '@/components/SizeSelect'
 import Search from '@/components/HeaderSearch'
 import RuoYiGit from '@/components/RuoYi/Git'
 import RuoYiDoc from '@/components/RuoYi/Doc'
+import RuoYiBell from '@/components/RuoYi/Bell'
 
 export default {
   components: {
@@ -66,7 +72,8 @@ export default {
     SizeSelect,
     Search,
     RuoYiGit,
-    RuoYiDoc
+    RuoYiDoc,
+    RuoYiBell
   },
   computed: {
     ...mapGetters([

+ 111 - 0
src/views/team/earlyWarning/index.vue

@@ -0,0 +1,111 @@
+<template>
+  <div class="app-container withdrawalApp-table" :style="{'--q-height':qHeight}">
+    
+    <div class="app-container-table-box">
+      <div class="textInfo">截止目前,您有{{ total }}条待办未处理:</div>
+      
+      <div class="app-container-table-info">
+        <el-table ref="tables" v-loading="loading" height="100%" :data="dataList" border>
+          <el-table-column label="序号" align="center" type="index" width="50"></el-table-column>
+          <el-table-column label="订单号" align="center" prop="orderId"  width="170" />
+          <el-table-column label="团队名称" align="center" prop="teamName" />
+          <el-table-column label="支付方式" align="center" prop="payWay" >
+            <template slot-scope="scope">
+              <dict-tag :options="dict.type.pay_way_type" :value="scope.row.payWay"/>
+            </template>
+          </el-table-column>
+          <el-table-column label="销售员" align="center" prop="salerPerson" />
+          <el-table-column label="预警还款时间" align="center" prop="repaymentTime" width="150" />
+          <el-table-column label="交易金额" align="center" prop="orderPrice" />
+          <el-table-column label="预警通知时间" align="center" prop="warnTime" width="160" />
+        </el-table>
+        <pagination
+          v-show="total>0"
+          :total="total"
+          :page.sync="queryParams.pageNum"
+          :limit.sync="queryParams.pageSize"
+          @pagination="getList"
+        />
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+
+import { 
+  waitRepaymentList
+} from '@/api/team/teamMr'
+
+export default {
+  name: "EarlyWarning",
+  dicts: ['pay_way_type'],
+  components: {  },
+  data() {
+    return {
+      qHeight: '0px',
+      resizeObserver: null,
+      loading: true,
+      total: 0,
+      dataList: null,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+      },
+      
+    };
+  },
+  created() {
+    this.getList();
+  },
+  mounted() {
+    this.resizeObserver = new ResizeObserver(entries => {
+      for (let entry of entries) {
+        const { width, height } = entry.contentRect;
+        this.qHeight = height + 'px'
+      }
+    });
+    this.resizeObserver.observe(this.$refs.queryFormBox);
+  },
+  methods: {
+    /** 查询列表 */
+    getList() {
+      this.dataList = [];
+      this.loading = true;
+      waitRepaymentList(this.queryParams).then(response => {
+          let list = response.data.rows
+          this.dataList = list
+          this.total = response.data.total;
+          this.loading = false;
+        }
+      ).catch(()=>{
+        this.dataList = []
+        this.loading = false;
+      })
+    },
+    
+  },
+  beforeDestroy() {
+    this.resizeObserver.unobserve(this.$refs.queryFormBox);
+    this.resizeObserver.disconnect();
+  },
+};
+</script>
+<style lang="scss" scoped>
+.app-container {
+  height: calc( 100vh - 110px );
+  box-sizing: border-box;
+}
+.app-container-table-box {
+  height: calc( 100% - var(--q-height) );
+  .app-container-table-info {
+    height: calc( 100% - 100px );
+  }
+}
+.textInfo {
+  font-size: 16px;
+  color: red;
+  margin: 10px 0;
+}
+</style>

Beberapa file tidak ditampilkan karena terlalu banyak file yang berubah dalam diff ini