lsw 1 year ago
parent
commit
852cf4dbd9

+ 1 - 1
admin-ui/src/App.vue

@@ -21,7 +21,7 @@ export default {
 /**挂载iconfont字体图标*/
 @font-face {
   font-family: 'iconfont';
-  src: url('https://at.alicdn.com/t/c/font_4507607_0tetqlbmivz.ttf?t=1713889487310') format('truetype');
+  src: url('https://at.alicdn.com/t/c/font_4507607_k7tryf81fl.ttf?t=1716877178929') format('truetype');
   /* src: url('~@/static/font/iconfont.ttf') format('truetype'); */
 }
 .icon {

+ 41 - 0
admin-ui/src/components/platform.vue

@@ -0,0 +1,41 @@
+<template>
+  <div class="cards">
+    <div class="ctop">
+      <span class="icon">&#xe646;</span>
+      <span class="ctitle">{{ form.serviceCompany }}</span>
+      <span class="ckk" @click="op('info')">
+        <router-link to="/data/platform">
+          编辑
+        </router-link>
+      </span>
+    </div>
+    <div class="desc">账户余额(元)</div>
+    <div class="money" @click="op('record')">
+      <span>{{money }}</span>
+    </div>
+  </div>
+</template>
+
+<script>
+  export default {
+    props: {
+      money: {
+        type: Number,
+        default: 0
+      }
+    },
+    data() {
+      return {
+        form: {}
+      };
+    },
+    mounted() {
+      this.ajax({ url: '/work/platform/detail' }).then((response) => {
+        this.form = response.data;
+      });
+    },
+    methods: {
+      op(tag, row) {}
+    }
+  };
+</script>

+ 296 - 0
admin-ui/src/views/dashboard/arows.vue

@@ -0,0 +1,296 @@
+<template>
+  <div class="yrows">
+    <!--结算单-->
+    <div v-if="row == '结算单'">
+      <div class="yr">
+        <div class="rout" style="padding-left: 0px">
+          <div class="rint" style="background-color: #faf7fe">
+            <div class="icon" style="color: #8642df">&#xe611;</div>
+            <div class="rcon">
+              <div class="rtt omit" title="结算人数(人)">结算人数(人)</div>
+              <div class="rdesc">{{ cdata.peoples || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr">
+        <div class="rout">
+          <div class="rint" style="background-color: #fffcf7">
+            <div class="icon" style="color: #fab22e">&#xe818;</div>
+            <div class="rcon">
+              <div class="rtt omit" title="结算金额(元)">结算金额(元)</div>
+              <div class="rdesc">{{ cdata.money || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr">
+        <div class="rout">
+          <div class="rint" style="background-color: #f7fbff">
+            <div class="icon" style="color: #489afd">&#xe645;</div>
+            <div class="rcon">
+              <div class="rtt omit" title="发放业务费(元)">发放业务费(元)</div>
+              <div class="rdesc">{{ cdata.realMoney || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr">
+        <div class="rout" style="padding-right: 0px">
+          <div class="rint" style="background-color: #fff7f9">
+            <div class="icon" style="color: #fa5376">&#xe70f;</div>
+            <div class="rcon">
+              <div class="rtt omit" title="总服务费(元)">总服务费(元)</div>
+              <div class="rdesc">{{ cdata.serviceMoney || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+    <!--待办事项-->
+    <div v-if="row == '待办事项'">
+      <div class="yr" style="width: 33.333%">
+        <router-link to="/square/recharge?state=0">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" style="float: none; color: #2196f3">&#xe6b0;</span>
+              <span class="bages">{{cdata.recharge>100?'99+':cdata.recharge||0}}</span>
+              <div class="ctt">充值审核</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+      <div class="yr" style="width: 33.333%">
+        <router-link to="/square/out?state=0">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" style="float: none; color: #2196f3">&#xe6b0;</span>
+              <span class="bages">{{cdata.moneyOut>100?'99+':cdata.moneyOut||0}}</span>
+              <div class="ctt">提现审核</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+      <div class="yr" style="width: 33.333%">
+        <router-link to="/square/pay?give=1">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" style="float: none; color: #2196f3">&#xe6b0;</span>
+              <span class="bages">{{cdata.gives>100?'99+':cdata.gives||0}}</span>
+              <div class="ctt">发放审核</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+    </div>
+    <div v-if="row == '统计概览'">
+      <div class="yr" style="width: 50%">
+        <div class="rout">
+          <div class="rint" style="background-color: #f7fbff">
+            <div class="icon" style="color: #489afd">&#xe640;</div>
+            <div class="rcon">
+              <div class="rtt">企业总数</div>
+              <div class="rdesc">{{ cdata.companys || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr" style="width: 50%">
+        <div class="rout" style="padding-right: 0px">
+          <div class="rint" style="background-color: #fffcf7">
+            <div class="icon" style="color: #fab22e">&#xe60a;</div>
+            <div class="rcon">
+              <div class="rtt">使用人数</div>
+              <div class="rdesc">{{ cdata.users || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr" style="width: 50%">
+        <div class="rout">
+          <div class="rint" style="background-color: #faf7fe">
+            <div class="icon" style="color: #8642df">&#xe6ed;</div>
+            <div class="rcon">
+              <div class="rtt">签约总数</div>
+              <div class="rdesc">{{ cdata.contracts || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <div class="yr" style="width: 50%">
+        <div class="rout" style="padding-right: 0px">
+          <div class="rint" style="background-color: #fff7f9">
+            <div class="icon" style="color: #fa5376">&#xe604;</div>
+            <div class="rcon">
+              <div class="rtt">接包总数</div>
+              <div class="rdesc">{{ cdata.packages || 0 }}</div>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+    <div v-if="row == '快捷菜单'">
+      <div class="yr" style="width: 20%" v-for="(item, index) in menu" :key="item.id" v-hasPermi="[item.hasPermi]">
+        <router-link :to="item.url">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" :style="{ float: 'none', color: item.color }" v-html="item.icon">&#xe60d;</span>
+              <div class="ctt">{{ item.name }}</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+      <div class="yr" style="width: 20%">
+        <router-link to="/notice">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" style="float: none; color: #2196f3">&#xe6b0;</span>
+              <div class="ctt">通知公告</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+      <div class="yr" style="width: 20%">
+        <router-link to="/feedback">
+          <div class="rout">
+            <div class="rint" style="text-align: center; cursor: pointer">
+              <span class="icon" style="float: none; color: #ff5722">&#xe6d5;</span>
+              <div class="ctt">问题反馈</div>
+            </div>
+          </div>
+        </router-link>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+  export default {
+    props: {
+      row: {
+        type: String
+      },
+      cdata: {
+        type: Object
+      }
+    },
+    data() {
+      return {
+        menu: [{
+            icon: '&#xe611;',
+            color: '#fab22e',
+            name: 'APP用户',
+            url: '/users',
+            hasPermi: 'work:user:list'
+          },
+          {
+            icon: '&#xe640;',
+            color: '#1890ff',
+            name: '企业管理',
+            url: '/square/company',
+            hasPermi: 'work:company:list'
+          },
+          {
+            icon: '&#xe645;',
+            color: '#9C27B0',
+            name: '充值管理',
+            url: '/square/recharge',
+            hasPermi: 'work:recharge:list'
+          },
+          {
+            icon: '&#xe628;',
+            color: '#3F51B5',
+            name: '提现管理',
+            url: '/square/out',
+            hasPermi: 'work:out:list'
+          },
+          {
+            icon: '&#xe645;',
+            color: '#FF9800',
+            name: '发放业务',
+            url: '/square/pay',
+            hasPermi: 'work:statement:pay'
+          },
+          {
+            icon: '&#xe60d;',
+            color: '#1890ff',
+            name: '用户管理',
+            url: '/system/user',
+            hasPermi: 'system:user:list'
+          },
+          {
+            icon: '&#xe60b;',
+            color: '#FFC107',
+            name: '角色管理',
+            url: '/system/role',
+            hasPermi: 'system:role:list'
+          },
+          {
+            icon: '&#xe62c;',
+            color: '#9E9E9E',
+            name: '操作日志',
+            url: '/system/operlog',
+            hasPermi: 'monitor:operlog:list'
+          }
+        ]
+      };
+    },
+    methods: {}
+  };
+</script>
+
+<style lang="scss" scoped>
+  .yrows {
+    margin-top: 10px;
+    .yr {
+      float: left;
+      width: 25%;
+      .rout {
+        padding: 6px;
+        .rint {
+          padding: 10px;
+          border-radius: 5px;
+          overflow: hidden;
+          position: relative;
+          .icon {
+            float: left;
+            font-size: 30px;
+            background-color: white;
+            border-radius: 50%;
+            padding: 10px;
+            width: 50px;
+            height: 50px;
+            box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+          }
+          .bages {
+            position: absolute;
+            background-color: red;
+            color: white;
+            padding: 0px 5px 0px 5px;
+            border-radius: 40px;
+            text-align: center;
+            top: 2px
+          }
+          .rcon {
+            float: left;
+            padding-left: 12px;
+            width: calc(100% - 55px);
+            .rtt {
+              color: #8c8c8c;
+              font-size: 14px;
+            }
+            .rdesc {
+              font-weight: bold;
+              padding-top: 7px;
+            }
+          }
+          .ctt {
+            color: #8c8c8c;
+            font-size: 14px;
+            padding-top: 18px;
+          }
+        }
+      }
+    }
+  }
+</style>

+ 117 - 115
admin-ui/src/views/dashboard/yrows.vue

@@ -6,7 +6,7 @@
           <div class="rint" style="background-color: #faf7fe">
             <div class="icon" style="color: #8642df">&#xe611;</div>
             <div class="rcon">
-              <div class="rtt">结算人数(人)</div>
+              <div class="rtt omit" title="结算人数(人)">结算人数(人)</div>
               <div class="rdesc">{{ cdata.peoples || 0 }}</div>
             </div>
           </div>
@@ -17,7 +17,7 @@
           <div class="rint" style="background-color: #fffcf7">
             <div class="icon" style="color: #fab22e">&#xe818;</div>
             <div class="rcon">
-              <div class="rtt">总金额(元)</div>
+              <div class="rtt omit" title="结算金额(元)">结算金额(元)</div>
               <div class="rdesc">{{ cdata.money || 0 }}</div>
             </div>
           </div>
@@ -28,7 +28,7 @@
           <div class="rint" style="background-color: #f7fbff">
             <div class="icon" style="color: #489afd">&#xe645;</div>
             <div class="rcon">
-              <div class="rtt">发放业务费(元)</div>
+              <div class="rtt omit" title="发放业务费(元)">发放业务费(元)</div>
               <div class="rdesc">{{ cdata.realMoney || 0 }}</div>
             </div>
           </div>
@@ -39,7 +39,7 @@
           <div class="rint" style="background-color: #fff7f9">
             <div class="icon" style="color: #fa5376">&#xe70f;</div>
             <div class="rcon">
-              <div class="rtt">总服务费(元)</div>
+              <div class="rtt omit" title="总服务费(元)">总服务费(元)</div>
               <div class="rdesc">{{ cdata.serviceMoney || 0 }}</div>
             </div>
           </div>
@@ -128,127 +128,129 @@
 </template>
 
 <script>
-export default {
-  props: {
-    row: {
-      type: String
+  export default {
+    props: {
+      row: {
+        type: String
+      },
+      cdata: {
+        type: Object
+      }
     },
-    cdata: {
-      type: Object
-    }
-  },
-  data() {
-    return {
-      menu: [
-        {
-          icon: '&#xe818;',
-          color: '#fab22e',
-          name: '项目管理',
-          url: '/project',
-          hasPermi: 'work:project:list'
-        },
-        {
-          icon: '&#xe609;',
-          color: '#1890ff',
-          name: '制单管理',
-          url: '/statement/make',
-          hasPermi: 'work:statement:make'
-        },
-        {
-          icon: '&#xe627;',
-          color: '#9C27B0',
-          name: '结算单管理',
-          url: '/statement/manage',
-          hasPermi: 'work:statement:manage'
-        },
-        {
-          icon: '&#xe625;',
-          color: '#3F51B5',
-          name: '结算单审核',
-          url: '/statement/audit',
-          hasPermi: 'work:statement:audit'
-        },
-        {
-          icon: '&#xe645;',
-          color: '#FF9800',
-          name: '发放业务费',
-          url: '/statement/give',
-          hasPermi: 'work:statement:give'
-        },
-        {
-          icon: '&#xe623;',
-          color: '#607D8B',
-          name: '关联用户',
-          url: '/relate',
-          hasPermi: 'work:relate:list'
-        },
-        {
-          icon: '&#xe60d;',
-          color: '#1890ff',
-          name: '员工管理',
-          url: '/system/user',
-          hasPermi: 'system:user:list'
-        },
-        {
-          icon: '&#xe60b;',
-          color: '#FFC107',
-          name: '角色管理',
-          url: '/system/role',
-          hasPermi: 'system:role:list'
-        },
-        {
-          icon: '&#xe62c;',
-          color: '#9E9E9E',
-          name: '操作日志',
-          url: '/system/operlog',
-          hasPermi: 'monitor:operlog:list'
-        }
-      ]
-    };
-  },
-  methods: {}
-};
+    data() {
+      return {
+        menu: [{
+            icon: '&#xe818;',
+            color: '#fab22e',
+            name: '项目管理',
+            url: '/project',
+            hasPermi: 'work:project:list'
+          },
+          {
+            icon: '&#xe609;',
+            color: '#1890ff',
+            name: '制单管理',
+            url: '/statement/make',
+            hasPermi: 'work:statement:make'
+          },
+          {
+            icon: '&#xe627;',
+            color: '#9C27B0',
+            name: '结算单管理',
+            url: '/statement/manage',
+            hasPermi: 'work:statement:manage'
+          },
+          {
+            icon: '&#xe625;',
+            color: '#3F51B5',
+            name: '结算单审核',
+            url: '/statement/audit',
+            hasPermi: 'work:statement:audit'
+          },
+          {
+            icon: '&#xe645;',
+            color: '#FF9800',
+            name: '发放业务费',
+            url: '/statement/give',
+            hasPermi: 'work:statement:give'
+          },
+          {
+            icon: '&#xe623;',
+            color: '#607D8B',
+            name: '关联用户',
+            url: '/relate',
+            hasPermi: 'work:relate:list'
+          },
+          {
+            icon: '&#xe60d;',
+            color: '#1890ff',
+            name: '员工管理',
+            url: '/system/user',
+            hasPermi: 'system:user:list'
+          },
+          {
+            icon: '&#xe60b;',
+            color: '#FFC107',
+            name: '角色管理',
+            url: '/system/role',
+            hasPermi: 'system:role:list'
+          },
+          {
+            icon: '&#xe62c;',
+            color: '#9E9E9E',
+            name: '操作日志',
+            url: '/system/operlog',
+            hasPermi: 'monitor:operlog:list'
+          }
+        ]
+      };
+    },
+    methods: {}
+  };
 </script>
 
 <style lang="scss" scoped>
-.yrows {
-  margin-top: 10px;
-  .yr {
-    float: left;
-    width: 25%;
-    .rout {
-      padding: 6px;
-      .rint {
-        padding: 10px;
-        border-radius: 5px;
-        overflow: hidden;
-        .icon {
-          float: left;
-          font-size: 30px;
-          background-color: white;
-          border-radius: 50%;
+  .yrows {
+    margin-top: 10px;
+    .yr {
+      float: left;
+      width: 25%;
+      .rout {
+        padding: 6px;
+        .rint {
           padding: 10px;
-          box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
-        }
-        .rcon {
-          float: left;
-          padding-left: 12px;
-          .rtt {
+          border-radius: 5px;
+          overflow: hidden;
+          .icon {
+            float: left;
+            font-size: 30px;
+            background-color: white;
+            border-radius: 50%;
+            padding: 10px;
+            width: 50px;
+            height: 50px;
+            box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+          }
+          .rcon {
+            float: left;
+            padding-left: 12px;
+            width: calc(100% - 55px);
+            .rtt {
+              color: #8c8c8c;
+              font-size: 14px;
+            }
+            .rdesc {
+              font-weight: bold;
+              padding-top: 7px;
+            }
+          }
+          .ctt {
             color: #8c8c8c;
             font-size: 14px;
+            padding-top: 18px;
           }
-          .rdesc {
-            font-weight: bold;
-            padding-top: 7px;
-          }
-        }
-        .ctt {
-          color: #8c8c8c;
-          font-size: 14px;
-          padding-top: 18px;
         }
       }
     }
   }
-}
 </style>

+ 131 - 23
admin-ui/src/views/index_admin.vue

@@ -1,35 +1,143 @@
 <template>
   <div class="dashboard-editor-container">
     <top title="欢迎使用承揽时代管理端"></top>
+    <div class="chart-wrapper">
+      <div class="pop" style="width: 65%">
+        <div class="out">
+          <div class="int">
+            <div class="bos">
+              <div class="lab">
+                <div class="bsg"></div>
+                <div class="tit">平台信息</div>
+              </div>
+              <platform :money="data.currentMoney"></platform>
+              <arows :cdata="data" row="结算单"></arows>
+            </div>
+          </div>
+        </div>
+        <div class="out">
+          <div class="int">
+            <div class="bos">
+              <div class="lab">
+                <div class="bsg"></div>
+                <div class="tit">快捷菜单</div>
+              </div>
+              <arows :cdata="data" row="快捷菜单"></arows>
+            </div>
+          </div>
+        </div>
+        <div class="out">
+          <div class="int">
+            <div class="bos">
+              <div class="lab">
+                <div class="bsg"></div>
+                <div class="tit">企业交易金额统计</div>
+              </div>
+              <div class="years">
+                <el-date-picker class="dpicker" :clearable="false" v-model="year" type="year" value-format="yyyy" placeholder="请选择年份"></el-date-picker>
+                <div class="year" :class="{ active: current == index }" @click="current = index" v-for="(item, index) in type" :key="index">{{ item.name }}</div>
+              </div>
+              <BarChart :chartData="chartData" height="270px"></BarChart>
+            </div>
+          </div>
+        </div>
+      </div>
+      <!--待办事项-->
+      <div class="pop" style="width: 35%">
+        <div class="out mar0">
+          <div class="int">
+            <div class="bos">
+              <div class="lab">
+                <div class="bsg"></div>
+                <div class="tit">待办事项</div>
+              </div>
+              <arows :cdata="data" row="待办事项"></arows>
+            </div>
+          </div>
+        </div>
+        <div class="out mar0">
+          <div class="int">
+            <div class="bos">
+              <div class="lab">
+                <div class="bsg"></div>
+                <div class="tit">统计概览</div>
+              </div>
+              <arows :cdata="data" row="统计概览"></arows>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
   </div>
 </template>
 
 <script>
-import top from '@/views/dashboard/top';
-export default {
-  components: {
-    top
-  },
-  data() {
-    return {
-      user: this.$store.state.user
-    };
-  },
-  created() {
-    //this.getData();
-  },
-  methods: {
-    getData() {
-      this.ajax({ url: '/home/index', data: { deptId: this.deptId } }).then((response) => {
-        this.data = response.data;
-      });
+  import top from '@/views/dashboard/top';
+  import arows from '@/views/dashboard/arows';
+  import BarChart from './dashboard/BarChart';
+  import platform from '@/components/platform';
+  export default {
+    components: {
+      platform,
+      top,
+      arows,
+      BarChart
+    },
+    data() {
+      return {
+        user: this.$store.state.user,
+        noticeList: [],
+        data: {},
+        current: 0,
+        chartData: [],
+        year: this.util.getDate('year'),
+        type: [
+          { name: '充值金额', value: 0 },
+          { name: '提现金额', value: 1 },
+          { name: '发放金额', value: 2 }
+        ]
+      };
+    },
+    watch: {
+      current(val) {
+        this.getRecord();
+      },
+      year(val) {
+        this.getRecord();
+      }
+    },
+    created() {
+      this.getData();
+      this.getRecord();
+    },
+    methods: {
+      getData() {
+        this.ajax({ url: '/home/index' }).then((response) => {
+          this.data = response.data.count;
+          if (response.data.count.gives > 0 || response.data.count.recharge > 0 || response.data.count.moneyOut > 0) {
+            setTimeout(() => {
+              this.$notify({
+                title: '待办事项',
+                dangerouslyUseHTMLString: true,
+                message: '你有待处理事项,请及时处理',
+                type: 'error',
+                duration: 0
+              });
+            }, 1000);
+          }
+        });
+      },
+      getRecord() {
+        this.ajax({ url: '/work/company/statistics/chart', data: { year: this.year, type: this.current } }).then((response) => {
+          this.chartData = response.data;
+        });
+      }
     }
-  }
-};
+  };
 </script>
 
 <style lang="scss" scoped>
-.bos {
-  border: 0px;
-}
+  .bos {
+    border: 0px;
+  }
 </style>

+ 4 - 0
admin-ui/src/views/work/money/out/index.vue

@@ -84,6 +84,9 @@ export default {
     };
   },
   created() {
+    if (this.$route.query.state) {
+      this.queryParams.state = this.$route.query.state;
+    }
     this.getList();
   },
   methods: {
@@ -102,6 +105,7 @@ export default {
     },
     resetQuery() {
       this.resetForm('queryForm');
+      this.queryParams.state = null;
       this.dateRange = [];
       this.handleQuery();
     },

+ 68 - 64
admin-ui/src/views/work/money/recharge/index.vue

@@ -62,73 +62,77 @@
   </div>
 </template>
 <script>
-import audit from './audit';
-export default {
-  name: 'Recharge',
-  data() {
-    return {
-      ids: [],
-      showSearch: true,
-      response: {},
-      dateRange: [],
-      queryParams: {
-        pageNum: 1,
-        pageSize: 10,
-        companyName: null,
-        state: null,
-        nums: null,
-        orderByColumn: 'r.id',
-        isAsc: 'desc'
-      }
-    };
-  },
-  created() {
-    this.getList();
-  },
-  methods: {
-    getList() {
-      if (this.dateRange) {
-        this.queryParams.dateBegin = this.dateRange[0];
-        this.queryParams.dateEnd = this.dateRange[1];
-      }
-      this.ajax({ url: '/work/recharge/list', data: this.queryParams }).then((response) => {
-        this.response = response;
-      });
-    },
-    handleQuery() {
-      this.queryParams.pageNum = 1;
-      this.getList();
-    },
-    resetQuery() {
-      this.resetForm('queryForm');
-      this.dateRange = [];
-      this.handleQuery();
-    },
-    selects(rows) {
-      this.ids = rows.map((item) => item.id);
+  import audit from './audit';
+  export default {
+    name: 'Recharge',
+    data() {
+      return {
+        ids: [],
+        showSearch: true,
+        response: {},
+        dateRange: [],
+        queryParams: {
+          pageNum: 1,
+          pageSize: 10,
+          companyName: null,
+          state: null,
+          nums: null,
+          orderByColumn: 'r.id',
+          isAsc: 'desc'
+        }
+      };
     },
-    op(tag, row) {
-      if (tag == 'detail') {
-        const id = row.id || this.ids[0];
-        this.iframe({ obj: audit, param: { id: id, detail: true, companyName: row.companyName }, title: '充值详情', width: '40%', height: '70%' });
-      }
-      if (tag == 'edit') {
-        const id = row.id || this.ids[0];
-        this.iframe({ obj: audit, param: { id: id, companyName: row.companyName }, title: '充值确认', width: '40%', height: '70%' });
+    created() {
+      if (this.$route.query.state) {
+        this.queryParams.state = this.$route.query.state;
       }
+      this.getList();
     },
-    del(row) {
-      this.$confirm('是否确认删除选中数据?', '警告', { type: 'warning' }).then(() => {
-        this.get({ url: '/work/recharge/remove/' + (row.id || this.ids) }).then((response) => {
-          this.$modal.msgSuccess('删除成功');
-          this.getList();
+    methods: {
+      getList() {
+        if (this.dateRange) {
+          this.queryParams.dateBegin = this.dateRange[0];
+          this.queryParams.dateEnd = this.dateRange[1];
+        }
+        this.ajax({ url: '/work/recharge/list', data: this.queryParams }).then((response) => {
+          this.response = response;
         });
-      });
-    },
-    /** 导出按钮操作 */
-    handleExport() {
-      this.download('/work/recharge/export', { ...this.queryParams }, '充值明细.xlsx');
+      },
+      handleQuery() {
+        this.queryParams.pageNum = 1;
+        this.getList();
+      },
+      resetQuery() {
+        this.resetForm('queryForm');
+        this.queryParams.state = null;
+        this.dateRange = [];
+        this.handleQuery();
+      },
+      selects(rows) {
+        this.ids = rows.map((item) => item.id);
+      },
+      op(tag, row) {
+        if (tag == 'detail') {
+          const id = row.id || this.ids[0];
+          this.iframe({ obj: audit, param: { id: id, detail: true, companyName: row.companyName }, title: '充值详情', width: '40%', height: '70%' });
+        }
+        if (tag == 'edit') {
+          const id = row.id || this.ids[0];
+          this.iframe({ obj: audit, param: { id: id, companyName: row.companyName }, title: '充值确认', width: '40%', height: '70%' });
+        }
+      },
+      del(row) {
+        this.$confirm('是否确认删除选中数据?', '警告', { type: 'warning' }).then(() => {
+          this.get({ url: '/work/recharge/remove/' + (row.id || this.ids) }).then((response) => {
+            this.$modal.msgSuccess('删除成功');
+            this.getList();
+          });
+        });
+      },
+      /** 导出按钮操作 */
+      handleExport() {
+        this.download('/work/recharge/export', { ...this.queryParams }, '充值明细.xlsx');
+      }
     }
-  }
-};
+  };
 </script>

+ 4 - 0
admin-ui/src/views/work/statement/pay/index.vue

@@ -75,6 +75,9 @@
       };
     },
     created() {
+      if (this.$route.query.give) {
+        this.queryParams.give = this.$route.query.give;
+      }
       this.getList();
     },
     methods: {
@@ -93,6 +96,7 @@
       },
       resetQuery() {
         this.resetForm('queryForm');
+        this.queryParams.give = null;
         this.dateRange = [];
         this.handleQuery();
       },

+ 73 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/work/controller/FeedbackController.java

@@ -0,0 +1,73 @@
+package com.ruoyi.web.work.controller;
+
+import com.ruoyi.common.annotation.Log;
+import com.ruoyi.common.core.controller.BaseController;
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.common.core.page.TableDataInfo;
+import com.ruoyi.common.enums.BusinessType;
+import com.ruoyi.web.work.domain.Feedback;
+import com.ruoyi.web.work.service.IFeedbackService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import java.rmi.ServerException;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * 问题反馈
+ *
+ * @author lsw
+ * @date 2024-04-24
+ */
+@RestController
+@RequestMapping("/work/feedback")
+public class FeedbackController extends BaseController {
+    @Autowired
+    private IFeedbackService feedbackService;
+
+    @GetMapping("/list")
+    public TableDataInfo list(Feedback feedback) {
+        feedback.setCompanyId(getLoginUser().getUser().getCompanyId());
+        if (getLoginUser().getUser().getType() == 1) {
+            feedback.setUserId(getUserId());
+        }
+        startPage();
+        List<Feedback> list = feedbackService.selectList(feedback);
+        return getDataTable(list);
+    }
+
+    @GetMapping(value = "/detail/{id}")
+    public AjaxResult detail(@PathVariable("id") Long id) {
+        return AjaxResult.success(feedbackService.getById(id));
+    }
+
+    @Log(title = "提交问题反馈", businessType = BusinessType.INSERT)
+    @PostMapping("/add")
+    public AjaxResult add(@Validated @RequestBody Feedback feedback) throws ServerException {
+        return feedbackService.add(feedback);
+    }
+
+    @PreAuthorize("@ss.hasPermi('work:feedback:edit')")
+    @Log(title = "问题反馈", businessType = BusinessType.UPDATE)
+    @PostMapping("/edit")
+    public AjaxResult edit(@RequestBody Feedback feedback) {
+        feedback.setState(1);
+        return toAjax(feedbackService.updateById(feedback));
+    }
+
+    @PreAuthorize("@ss.hasPermi('work:feedback:remove')")
+    @Log(title = "删除问题反馈", businessType = BusinessType.DELETE)
+    @GetMapping("/remove/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids) {
+        return toAjax(feedbackService.removeByIds(Arrays.asList(ids)));
+    }
+
+    @Log(title = "删除问题反馈", businessType = BusinessType.DELETE)
+    @GetMapping("/delByUser/{id}")
+    public AjaxResult delByUser(@PathVariable Long id) {
+        return toAjax(feedbackService.delByUser(id));
+    }
+}

+ 27 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/work/controller/IndexController.java

@@ -0,0 +1,27 @@
+package com.ruoyi.web.work.controller;
+
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.web.work.mapper.CommonMapper;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ * 后台首页统计
+ */
+@RestController
+@RequestMapping("/home")
+public class IndexController {
+
+    @Autowired
+    private CommonMapper mapper;
+
+
+    @GetMapping("/index")
+    public AjaxResult index() {
+        AjaxResult result = new AjaxResult();
+        result.put("count", mapper.admin());
+        return AjaxResult.success(result);
+    }
+}

+ 8 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/work/mapper/CommonMapper.java

@@ -17,6 +17,14 @@ public interface CommonMapper {
      */
     Map<String, Object> company(@Param("companyId") Long companyId);
 
+
+    /**
+     * 后台管理员端首页统计
+     *
+     * @return
+     */
+    Map<String, Object> admin();
+
     /**
      * 后台企业端每月交易金额统计
      *

+ 18 - 1
ruoyi-admin/src/main/resources/mapper/work/CommonMapper.xml

@@ -16,6 +16,22 @@
                 ( SELECT SUM( service_money ) FROM tb_statement WHERE give = 2 AND company_id =#{companyId} ) AS serviceMoney,
                 ( SELECT SUM( peoples ) FROM tb_statement WHERE give = 2 AND company_id =#{companyId} ) AS peoples
     </select>
+    <!--后台管理员端首页统计-->
+    <select id="admin" resultType="java.util.Map">
+        SELECT
+                ( SELECT SUM( money ) FROM tb_company ) AS currentMoney,
+                ( SELECT COUNT( id ) FROM tb_company ) AS companys,
+                ( SELECT SUM( money ) FROM tb_statement WHERE give = 2 ) AS money,
+                ( SELECT SUM( peoples ) FROM tb_statement WHERE give = 2 ) AS peoples,
+                ( SELECT SUM( service_money ) FROM tb_statement WHERE give = 2 ) AS serviceMoney,
+                ( SELECT SUM( real_money ) FROM tb_statement WHERE give = 2 ) AS realMoney,
+                ( SELECT COUNT( user_id ) FROM sys_user WHERE type = 1 ) AS users,
+                ( SELECT COUNT( id ) FROM tb_recharge WHERE state = 0 ) AS recharge,
+                ( SELECT COUNT( id ) FROM tb_money_out WHERE state = 0 ) AS moneyOut,
+                ( SELECT COUNT( id ) FROM tb_statement WHERE audit = 2 AND give = 1 ) AS gives,
+                ( SELECT COUNT( id ) FROM tb_packages) AS packages,
+                ( SELECT COUNT( id ) FROM tb_user WHERE is_contract=1) AS contracts
+    </select>
     <!--后台企业端每月交易金额统计-->
     <select id="record" resultType="java.util.Map">
         SELECT
@@ -39,7 +55,8 @@
             LEFT JOIN
             tb_record ON
             MONTH(tb_record.create_time) = months.month AND YEAR(tb_record.create_time) =#{year}
-            AND tb_record.company_id=#{companyId} AND tb_record.type=#{type}
+            <if test="companyId != null ">AND tb_record.company_id=#{companyId}</if>
+            AND tb_record.type=#{type}
         GROUP BY
             months.month
         ORDER BY