Pārlūkot izejas kodu

fix:增加水印,echarts压缩包体积缩减、

liuzl 2 gadi atpakaļ
vecāks
revīzija
2663879fb8

+ 23 - 22
App.vue

@@ -1,27 +1,28 @@
 <style lang="scss">
-	/* 注意要写在第一行,同时给style标签加入lang="scss"属性 */
-	@import 'uview-ui/index.scss';
-	@import './style/common.scss';
-
-	image {
-		image-rendering: -moz-crisp-edges;
-		image-rendering: -o-crisp-edges;
-		image-rendering: -webkit-optimize-contrast;
-		image-rendering: crisp-edges;
-		-ms-interpolation-mode: nearest-neighbor;
-	}
+  /* 注意要写在第一行,同时给style标签加入lang="scss"属性 */
+  @import 'uview-ui/index.scss';
+  @import './style/common.scss';
 
+  image {
+    image-rendering: -moz-crisp-edges;
+    image-rendering: -o-crisp-edges;
+    image-rendering: -webkit-optimize-contrast;
+    image-rendering: crisp-edges;
+    -ms-interpolation-mode: nearest-neighbor;
+  }
 </style>
 <script>
-	export default {
-		onLaunch: function() {
-			console.log('App Launch')
-		},
-		onShow: function() {
-			console.log('App Show')
-		},
-		onHide: function() {
-			console.log('App Hide')
-		},
-	}
+  import store from './store'
+  export default {
+    onLaunch: function () {
+      console.log('App Launch')
+    },
+    onShow: function () {
+      store.dispatch('getUserInfo')
+      console.log('App Show')
+    },
+    onHide: function () {
+      console.log('App Hide')
+    },
+  }
 </script>

+ 4 - 0
api/system/index.js

@@ -26,4 +26,8 @@ export default {
   getCheckList(query) {
     return micro_request.postRequest(basePath, 'PunchRecords', 'GetList', query)
   },
+  // 数值指标
+  getHomeNumReportData(query) {
+    return micro_request.postRequest(basePath, 'Home', 'GetHomeNumReportData', query)
+  },
 }

+ 0 - 1
components/CustomerContact.vue

@@ -76,7 +76,6 @@
         }
       },
       open(id) {
-        console.log(id)
         this.queryForm.custId = id
         this.selectVisible = true
         this.getUserList()

+ 0 - 2
components/SelectProduct.vue

@@ -114,7 +114,6 @@
         } else {
           this.isallcheck = false // 反选
         }
-        console.log(' this.isallcheck', this.isallcheck)
       },
       // 全部
       checkboxChange() {
@@ -122,7 +121,6 @@
         this.checkboxList.forEach((el) => {
           el.ischeck = this.isallcheck
         })
-        console.log(this.checkboxList)
       },
     },
   }

+ 65 - 0
components/WaterMark/index.vue

@@ -0,0 +1,65 @@
+<!--
+ * @Author: liuzhenlin 461480418@qq.ocm
+ * @Date: 2023-02-24 17:28:55
+ * @LastEditors: liuzhenlin
+ * @LastEditTime: 2023-02-25 10:05:16
+ * @Description: file content
+ * @FilePath: \oms\components\WaterMark\index.vue
+-->
+<template>
+  <view class="make">
+    <view class="list">
+      <view class="item" v-for="i in 300" :key="i">
+        <text>{{ nickName }}{{ phone }}</text>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script>
+  import { mapGetters } from 'vuex'
+  export default {
+    name: 'watermark',
+    computed: {
+      ...mapGetters(['nickName', 'phone']),
+    },
+    data() {
+      return {}
+    },
+    mounted() {
+    },
+  }
+</script>
+
+<style lang="scss" scoped>
+  .make {
+    position: fixed;
+    width: 100%;
+    height: 100%;
+    top: 0;
+    left: 0;
+    z-index: 9999;
+    background: rgba(0, 0, 0, 0);
+    pointer-events: none;
+
+    .list {
+      width: 500%;
+      height: 400%;
+      position: absolute;
+      top: -50%;
+      left: -50%;
+      transform: rotate(-45deg);
+      display: flex;
+      flex-wrap: wrap;
+      justify-content: space-between;
+      pointer-events: none;
+
+      .item {
+        font-size: 32rpx;
+        color: rgba(220, 220, 220, 0.5);
+        padding: 30rpx;
+        pointer-events: none;
+      }
+    }
+  }
+</style>

+ 0 - 1
components/calendar.vue

@@ -112,7 +112,6 @@
         let month = d.getMonth() + 1
         let date = d.getDate()
         this.currentDate = `${year}-${month}-${date}`
-        console.log(this.currentDate)
         // 获取当前月第一天
         curMonthStartDay = new Date(this.formatDate(now.getFullYear(), now.getMonth() + 1, 1))
         // 当前月第一天是周几

+ 2 - 0
main.js

@@ -15,7 +15,9 @@ import store from './store'
 import uView from 'uview-ui'
 import { parseTime, translateDataToTree, formatPrice, selectDictLabel } from './utils'
 import dictApi from '@/api/system/dict'
+import WaterMark from '@/components/WaterMark/index.vue'
 
+Vue.component('WaterMark', WaterMark)
 Vue.prototype.parseTime = parseTime
 Vue.prototype.translateDataToTree = translateDataToTree
 Vue.prototype.formatPrice = formatPrice

+ 1 - 0
package.json

@@ -9,6 +9,7 @@
         "echarts": "^5.4.1",
         "qs": "^6.11.0",
         "uview-ui": "^2.0.31",
+        "vue-inset-loader": "^1.2.6",
         "vuex": "^4.1.0"
     },
     "scripts": {

+ 226 - 197
pages.json

@@ -1,199 +1,228 @@
 {
-    "easycom": {
-        "^u-(.*)": "uview-ui/components/u-$1/u-$1.vue"
-    },
-    "pages": [{
-            "path": "pages/login/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "登录"
-        },
-        {
-            "path": "pages/home/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "首页"
-        },
-        {
-            "path" : "pages/home/checkIn",
-            "style" :
-            {
-                 "navigationStyle": "custom"
-            },
-            "tit": "打卡"
-        },
-        {
-            "path": "pages/contract/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "合同管理"
-        },
-        {
-            "path": "pages/contract/detail",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "合同详情"
-        },
-        {
-            "path": "pages/contract/invoice",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "新建发票"
-        },
-        {
-            "path": "pages/contract/collection",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "新建回款"
-        },
-        {
-            "path": "pages/project/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "项目管理首页"
-        },
-        {
-            "path": "pages/project/transfer",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "转移项目"
-        },
-        {
-            "path": "pages/project/details",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "项目详情"
-        },
-        {
-            "path": "pages/customer/details",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "客户详情"
-        },
-        {
-            "path": "pages/customer/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "储备客户"
-        },
-        {
-            "path": "pages/openSeaCustomer/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "公海客户"
-        },
-        {
-            "path": "pages/publicPages/follow",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "填写跟进"
-        },
-        {
-            "path": "pages/customer/transfer",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "转移客户"
-        },
-        {
-            "path": "pages/customer/add",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "客户添加"
-        },
-        {
-            "path": "pages/project/create",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "创建项目"
-        },
-        {
-            "path": "pages/project/downgrade",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "项目降级"
-        },
-        {
-            "path": "pages/project/upgrade",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "项目升级"
-        },
-        {
-            "path": "pages/message/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "信息"
-        },
-        {
-            "path": "pages/my/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "我的"
-        },
-        {
-            "path": "pages/schedule/index",
-            "style": {
-                "navigationStyle": "custom"
-            },
-            "tit": "日程"
-        }
-    ],
-    "tabBar": {
-        "color": "#7A7E83",
-        "selectedColor": "#3E7EF8",
-        "borderStyle": "black",
-        "backgroundColor": "#ffffff",
-        "list": [{
-                "pagePath": "pages/home/index",
-                "iconPath": "static/images/tabBar/home.png",
-                "selectedIconPath": "static/images/tabBar/home-active.png",
-                "text": "首页"
-            },
-            {
-                "pagePath": "pages/schedule/index",
-                "iconPath": "static/images/tabBar/schedule.png",
-                "selectedIconPath": "static/images/tabBar/schedule-active.png",
-                "text": "日程"
-            },
-            {
-                "pagePath": "pages/message/index",
-                "iconPath": "static/images/tabBar/message.png",
-                "selectedIconPath": "static/images/tabBar/message-active.png",
-                "text": "消息"
-            },
-            {
-                "pagePath": "pages/my/index",
-                "iconPath": "static/images/tabBar/my.png",
-                "selectedIconPath": "static/images/tabBar/my-active.png",
-                "text": "我的"
-            }
-        ]
-    },
-    "globalStyle": {
-        "navigationBarTextStyle": "black",
-        "navigationBarTitleText": "oms",
-        "navigationBarBackgroundColor": "#F8F8F8",
-        "backgroundColor": "#F8F8F8"
-    },
-    "uniIdRouter": {}
+  //在pages.json文件中新加insetLoader属性
+  "insetLoader": {
+    //配置
+    "config": {
+      //将需要引入的组件名起了个confirm的名字在下面label中使用
+      //右侧"<test ref='confirm' />"为需要插入的组件标签
+      "WaterMark": "<WaterMark ref='WaterMark' />"
+    },
+    // 全局配置
+    //需要挂在的组件名
+    "label": ["WaterMark"],
+    //根元素的标签类型 也就是插入到页面哪个根元素下默认为div 但是uniapp中需要写为view
+    "rootEle": "view"
+  },
+  "easycom": {
+    "^u-(.*)": "uview-ui/components/u-$1/u-$1.vue"
+  },
+  "pages": [
+    {
+      "path": "pages/home/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "首页"
+    },
+    {
+      "path": "pages/login/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "登录"
+    },
+    {
+      "path": "pages/home/checkIn",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "打卡"
+    },
+    {
+      "path": "pages/contract/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "合同管理"
+    },
+    {
+      "path": "pages/contract/detail",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "合同详情"
+    },
+    {
+      "path": "pages/contract/invoice",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "新建发票"
+    },
+    {
+      "path": "pages/contract/collection",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "新建回款"
+    },
+    {
+      "path": "pages/project/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "项目管理首页"
+    },
+    {
+      "path": "pages/project/transfer",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "转移项目"
+    },
+    {
+      "path": "pages/project/details",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "项目详情"
+    },
+    {
+      "path": "pages/customer/details",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "客户详情"
+    },
+    {
+      "path": "pages/customer/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "储备客户"
+    },
+    {
+      "path": "pages/openSeaCustomer/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "公海客户"
+    },
+    {
+      "path": "pages/distributor/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "合作伙伴"
+    },
+    {
+      "path": "pages/distributor/details",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "经销商详情"
+    },
+    {
+      "path": "pages/publicPages/follow",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "填写跟进"
+    },
+    {
+      "path": "pages/customer/transfer",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "转移客户"
+    },
+    {
+      "path": "pages/customer/add",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "客户添加"
+    },
+    {
+      "path": "pages/project/create",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "创建项目"
+    },
+    {
+      "path": "pages/project/downgrade",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "项目降级"
+    },
+    {
+      "path": "pages/project/upgrade",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "项目升级"
+    },
+    {
+      "path": "pages/message/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "信息"
+    },
+    {
+      "path": "pages/my/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "我的"
+    },
+    {
+      "path": "pages/schedule/index",
+      "style": {
+        "navigationStyle": "custom"
+      },
+      "tit": "日程"
+    }
+  ],
+  "tabBar": {
+    "color": "#7A7E83",
+    "selectedColor": "#3E7EF8",
+    "borderStyle": "black",
+    "backgroundColor": "#ffffff",
+    "list": [
+      {
+        "pagePath": "pages/home/index",
+        "iconPath": "static/images/tabBar/home.png",
+        "selectedIconPath": "static/images/tabBar/home-active.png",
+        "text": "首页"
+      },
+      {
+        "pagePath": "pages/schedule/index",
+        "iconPath": "static/images/tabBar/schedule.png",
+        "selectedIconPath": "static/images/tabBar/schedule-active.png",
+        "text": "日程"
+      },
+      {
+        "pagePath": "pages/message/index",
+        "iconPath": "static/images/tabBar/message.png",
+        "selectedIconPath": "static/images/tabBar/message-active.png",
+        "text": "消息"
+      },
+      {
+        "pagePath": "pages/my/index",
+        "iconPath": "static/images/tabBar/my.png",
+        "selectedIconPath": "static/images/tabBar/my-active.png",
+        "text": "我的"
+      }
+    ]
+  },
+  "globalStyle": {
+    "navigationBarTextStyle": "black",
+    "navigationBarTitleText": "oms",
+    "navigationBarBackgroundColor": "#F8F8F8",
+    "backgroundColor": "#F8F8F8"
+  },
+  "uniIdRouter": {}
 }

+ 0 - 2
pages/contract/collection.vue

@@ -120,7 +120,6 @@
       this.getOptions()
     },
     onLoad(option) {
-      console.log(option.id) //打印出上个页面传递的参数。
       this.form.contractId = parseInt(option.id)
       this.form.contractCode = option.code
     },
@@ -153,7 +152,6 @@
           .validate()
           .then(async (valid) => {
             if (valid) {
-              console.log(valid)
               const [err, res] = await to(api.addCollection(params))
               if (err) return
               this.$refs.uToast.show({

+ 0 - 1
pages/contract/detail.vue

@@ -184,7 +184,6 @@
       },
       // 改变tab
       changeTabs(data) {
-        console.log(data)
         this.curTabIndex = data.index
       },
       // 打开转移

+ 2 - 7
pages/customer/details.vue

@@ -66,20 +66,16 @@
         <view class="tabs">
           <u-tabs
             @change="changeTabs"
-            lineWidth="8"
             :current="curTabIndex"
-            lineHeight="8"
             :scrollable="false"
             :list="list"
-            :lineColor="`url(${lineBg}) 100% 100%`"
             :activeStyle="{
               color: '#3E7EF8',
               fontWeight: 'bold',
             }"
             :inactiveStyle="{
               color: '#969696',
-            }"
-            itemStyle="height: 90rpx;"></u-tabs>
+            }"></u-tabs>
         </view>
       </view>
       <view class="data-list">
@@ -126,8 +122,7 @@
     data() {
       return {
         openBtnWidth: false,
-        lineBg: require('../../static/images/up.png'),
-        curTabIndex: 0,
+        curTabIndex: 1,
         fllowList: [], //跟进数据
         list: [
           {

+ 85 - 0
pages/distributor/components/distrDetail.vue

@@ -0,0 +1,85 @@
+<!--
+ * @Author: liuzhenlin 461480418@qq.ocm
+ * @Date: 2023-02-15 16:25:58
+ * @LastEditors: liuzhenlin
+ * @LastEditTime: 2023-02-16 11:17:12
+ * @Description: file content
+ * @FilePath: \oms\pages\customer\components\customerDetail.vue
+-->
+<template>
+  <view>
+    <view class="info-item">
+      <u-row justify="space-between" gutter="10">
+        <u-col span="12">
+          <view class="flex_l">
+            <view class="label">助记名::</view>
+            <view class="desc">{{ detail.abbrName }}</view>
+          </view>
+        </u-col>
+      </u-row>
+    </view>
+    <view class="info-item">
+      <u-row>
+        <u-col span="12">
+          <view class="flex_l">
+            <view class="label">负责人电话::</view>
+            <view class="desc">{{ detail.distBossPhone }}</view>
+          </view>
+        </u-col>
+      </u-row>
+    </view>
+    <view class="info-item">
+      <u-row>
+        <u-col span="12">
+          <view class="flex_l">
+            <view class="label">业务范围::</view>
+            <view class="desc">{{ detail.businessScope }}</view>
+          </view>
+        </u-col>
+      </u-row>
+    </view>
+    <view class="info-item">
+      <u-row justify="space-between" gutter="10">
+        <u-col span="12">
+          <view class="flex_l">
+            <view class="label">创建人::</view>
+            <view class="desc">{{ detail.createdName }}</view>
+          </view>
+        </u-col>
+      </u-row>
+    </view>
+  </view>
+</template>
+
+<script>
+  export default {
+    name: 'OmsCustomerDetail',
+    props: {
+      detail: {
+        type: [Object],
+        default: {},
+      },
+    },
+    data() {
+      return {}
+    },
+
+    mounted() {},
+
+    methods: {},
+  }
+</script>
+
+<style lang="scss" scoped>
+  .info-item {
+    padding: 20rpx;
+    .label {
+      color: #646464;
+      font-size: 26rpx;
+    }
+    .desc {
+      font-size: 26rpx;
+      text-indent: 20rpx;
+    }
+  }
+</style>

+ 118 - 0
pages/distributor/components/followRecords.vue

@@ -0,0 +1,118 @@
+<template>
+  <view class="todo-list">
+    <u-empty mode="list" text="暂无记录" v-if="followList.length == 0"></u-empty>
+    <view v-else v-for="(v, i) in followList" :key="i">
+      <view class="follow-date">
+        <u-text :bold="true" size="26rpx" :text="v.followDay"></u-text>
+      </view>
+      <view class="todo-item" v-for="item in v.followupList" :key="item.id">
+        <u-row>
+          <u-col span="12">
+            <view class="header">
+              <u-row>
+                <u-col span="12">
+                  <view class="flex_l">
+                    <text class="tit-txt text-ellipsis flex_1">
+                      {{ item.contactsName }} 跟进({{ formatType(item.followType) }})
+                    </text>
+                  </view>
+                </u-col>
+              </u-row>
+              <view class="content flex">
+                <text>{{ item.followContent }}</text>
+              </view>
+              <view class="content-footer flex1">
+                <text class="date">{{ item.followDate }}</text>
+                <view class="flex flex-middle">
+                  <text class="user-txt">联系人:{{ item.contactsName }}</text>
+                </view>
+              </view>
+            </view>
+          </u-col>
+        </u-row>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script>
+  import to from 'await-to-js'
+  import followApi from '../../../api/customer'
+  export default {
+    name: 'OmsCustomerDetail',
+    props: {
+      customerId: {
+        type: [String, Number],
+        default: '0',
+      },
+    },
+    data() {
+      return {
+        followList: [],
+      }
+    },
+
+    mounted() {
+      this.getRecords()
+      console.log('customerId', this.customerId)
+    },
+
+    methods: {
+      async getRecords() {
+        let params = {
+          custId: '' + this.customerId,
+          DaysBeforeToday: 9999,
+        }
+        const [err, res] = await to(followApi.getListByDay(params))
+        if (err) return
+        if (res.code == 200) this.followList = res.data.list || []
+      },
+      formatType(val) {
+        let str = ''
+        if (val == 10) str = '电话'
+        else if (val == 20) str = '邮件'
+        else if (val == 30) str = '拜访'
+        return str
+      },
+    },
+  }
+</script>
+
+<style lang="scss" scoped>
+  .todo-list {
+    height: 100%;
+    overflow: auto;
+    .follow-date {
+      padding: 20rpx 0 20rpx 20rpx;
+    }
+    .todo-item {
+      padding: 12rpx 40rpx 12rpx 46rpx;
+      background: #f2f3f5;
+      border-radius: 15rpx;
+      margin-bottom: 32rpx;
+      .tit-txt {
+        font-size: 28rpx;
+        font-weight: bold;
+        color: #323232;
+      }
+      .content {
+        padding: 10rpx 0;
+        font-size: 28rpx;
+        color: #646464;
+      }
+      .content-footer {
+        padding: 0 0 12rpx 0;
+        font-size: 24rpx;
+        .date {
+          color: #969696;
+        }
+        .user-img {
+          width: 46rpx;
+          height: 46rpx;
+          border-radius: 50%;
+          margin-right: 15rpx;
+        }
+      }
+    }
+  }
+</style>

+ 285 - 0
pages/distributor/details.vue

@@ -0,0 +1,285 @@
+<!--
+ * @Author: liuzhenlin 461480418@qq.ocm
+ * @Date: 2023-01-12 11:57:48
+ * @LastEditors: liuzhenlin
+ * @LastEditTime: 2023-02-28 10:21:59
+ * @Description: file content
+ * @FilePath: \oms\pages\distributor\details.vue
+-->
+<template>
+  <view class="home">
+    <view class="nav">
+      <view :style="{ paddingTop }">
+        <view class="title" :style="[{ height }, { lineHeight: height }]">
+          <view class="back" @click="goBack()">
+            <u-icon name="arrow-left" color="#ffffff" size="22"></u-icon>
+          </view>
+          <text>经销商详情</text>
+        </view>
+      </view>
+    </view>
+    <view class="main">
+      <view class="main-top">
+        <view class="customer-box">
+          <view class="header flex1">
+            <view class="name flex_l">
+              <image class="img" src="../../static/images/menu1.png" mode="scaleToFill" />
+              <text>{{ distrInfo.distName }}</text>
+            </view>
+            <view class="date">{{ parseTime(distrInfo.createdTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+          </view>
+          <view class="info">
+            <view class="info-item">
+              <u-row>
+                <u-col span="7">
+                  <view class="flex_l">
+                    <view class="info-label">客户编码:</view>
+                    <text class="info-txt">{{ distrInfo.distCode }}</text>
+                  </view>
+                </u-col>
+                <u-col span="5">
+                  <view class="flex_l">
+                    <view class="info-label">负责人:</view>
+                    <text class="info-txt">{{ distrInfo.distBoss }}</text>
+                  </view>
+                </u-col>
+              </u-row>
+            </view>
+            <view class="info-item">
+              <u-row justify="space-between">
+                <u-col span="7">
+                  <view class="flex_l">
+                    <view class="info-label">销售人:</view>
+                    <text class="info-txt">{{ distrInfo.belongSale }}</text>
+                  </view>
+                </u-col>
+                <u-col span="5">
+                  <view class="flex_l">
+                    <view class="info-label">归属省份:</view>
+                    <text class="info-txt">{{ distrInfo.provinceDesc }}</text>
+                  </view>
+                </u-col>
+              </u-row>
+            </view>
+          </view>
+        </view>
+        <view class="tabs">
+          <u-tabs
+            @change="changeTabs"
+            :current="curTabIndex"
+            :scrollable="false"
+            :list="list"
+            :activeStyle="{
+              color: '#3E7EF8',
+              fontWeight: 'bold',
+            }"
+            :inactiveStyle="{
+              color: '#969696',
+            }"></u-tabs>
+        </view>
+      </view>
+      <view class="data-list">
+        <!-- 跟进记录 -->
+        <follow-records v-if="curTabIndex == 0" ref="follow" :customerId="customerId"></follow-records>
+        <!-- 详情 -->
+        <distr-detail v-if="curTabIndex == 1" :detail="distrInfo"></distr-detail>
+      </view>
+    </view>
+  </view>
+</template>
+<script>
+  import distrApi from '../../api/base/distr'
+  import to from 'await-to-js'
+  import distrDetail from './components/distrDetail'
+  import followRecords from './components/followRecords'
+  export default {
+    name: 'omsIndex',
+    components: { distrDetail, followRecords },
+    data() {
+      return {
+        openBtnWidth: false,
+        curTabIndex: 0,
+        fllowList: [], //跟进数据
+        list: [
+          {
+            name: '活动记录',
+            index: 0,
+          },
+          {
+            name: '详细信息',
+            index: 1,
+          },
+        ],
+        height: '',
+        paddingTop: '',
+        distrInfo: {},
+        distrId: 0, //客户id
+      }
+    },
+    onLoad(option) {
+      this.distrId = parseInt(option.id)
+    },
+    created() {
+      const navData = uni.getMenuButtonBoundingClientRect()
+      this.height = navData.height + 'px'
+      this.paddingTop = navData.top + 'px'
+    },
+    onShow() {
+      this.getDistrDetail()
+    },
+    methods: {
+      async getDistrDetail() {
+        const [err, res] = await to(distrApi.getEntity({ id: this.distrId }))
+        if (err) return
+        if (res && res.code == 200) {
+          console.log(res)
+          this.distrInfo = res.data.list
+        }
+      },
+      // 改变tab
+      changeTabs(data) {
+        console.log(data)
+        this.curTabIndex = data.index
+      },
+      goBack() {
+        uni.navigateBack({
+          //关闭当前页面,返回上一页面或多级页面。
+          delta: 1,
+        })
+      },
+    },
+  }
+</script>
+<style>
+  page {
+    background: #f2f3f5;
+  }
+</style>
+<style lang="scss" scoped>
+  .home {
+    padding-top: 200rpx;
+
+    .nav {
+      position: absolute;
+      left: 0;
+      top: 0;
+      width: 100%;
+      height: 356rpx;
+      background: #3e7ef8;
+      border-radius: 0 0 31rpx 31rpx;
+      .title {
+        position: relative;
+        text-align: center;
+        font-size: 32rpx;
+        font-weight: bold;
+        color: #ffffff;
+        .back {
+          position: absolute;
+          top: 0;
+          bottom: 0;
+          margin: auto;
+          left: 70rpx;
+          display: flex;
+        }
+      }
+    }
+
+    .main {
+      position: absolute;
+      width: 100%;
+      height: calc(100vh - 200rpx);
+      overflow: hidden;
+      padding-bottom: 64rpx;
+      .main-top {
+        padding: 0 32rpx;
+      }
+      .customer-box {
+        width: 100%;
+        background: #ffffff;
+        box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);
+        border-radius: 32rpx;
+        padding: 22rpx 38rpx 68rpx 40rpx;
+        .header {
+          .name {
+            .img {
+              width: 46rpx;
+              height: 46rpx;
+              border-radius: 50%;
+              margin-right: 8rpx;
+            }
+            text {
+              font-size: 28rpx;
+              font-weight: bold;
+              color: #323232;
+            }
+          }
+          .date {
+            font-size: 24rpx;
+            color: #3e7ef8;
+          }
+        }
+        .info {
+          .info-item {
+            margin-top: 18rpx;
+            .info-label {
+              width: 116rpx;
+              text-align: left;
+              font-size: 24rpx;
+              color: #646464;
+            }
+            .info-txt {
+              flex: 1;
+              font-size: 24rpx;
+              color: #323232;
+            }
+          }
+        }
+      }
+      .data-list {
+        margin-top: 16rpx;
+        width: 100%;
+        height: calc(100vh - 532rpx);
+        background: #ffffff;
+        padding: 32rpx;
+        overflow: auto;
+        padding-bottom: 145rpx;
+        .status1 {
+          color: #4096fb;
+          background: rgba(64, 150, 251, 0.2);
+        }
+        .status2 {
+          background: rgba(255, 184, 60, 0.2);
+          color: #ffb83c;
+        }
+        .status3 {
+          color: #fe6936;
+          background: rgba(254, 105, 54, 0.2);
+        }
+      }
+    }
+    .fixed-btn-group {
+      position: fixed;
+      display: flex;
+      justify-content: space-around;
+      align-items: center;
+      width: 90rpx;
+      height: 90rpx;
+      bottom: 50rpx;
+      right: 50rpx;
+      box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
+      border-radius: 20px;
+      transition: all 0.2s;
+      background: #fff;
+      .btn {
+        width: 60rpx;
+        height: 60rpx;
+        background: #3e7ef8;
+        border-radius: 50%;
+        margin: 10rpx;
+        font-size: 26rpx;
+        font-weight: bold;
+        color: #ffffff;
+      }
+    }
+  }
+</style>

+ 334 - 0
pages/distributor/index.vue

@@ -0,0 +1,334 @@
+<!--
+ * @Author: liuzhenlin 461480418@qq.ocm
+ * @Date: 2023-01-12 11:57:48
+ * @LastEditors: liuzhenlin
+ * @LastEditTime: 2023-02-27 17:46:12
+ * @Description: file content
+ * @FilePath: \oms\pages\distributor\index.vue
+-->
+<template>
+  <view class="home">
+    <view class="nav">
+      <view :style="{ paddingTop }">
+        <view class="title" :style="[{ height }, { lineHeight: height }]">
+          <view class="back" @click="goBack()">
+            <u-icon name="arrow-left" color="#ffffff" size="22"></u-icon>
+          </view>
+          <text>合作伙伴</text>
+        </view>
+      </view>
+    </view>
+    <view class="main">
+      <view class="query-wrap">
+        <view class="search-container">
+          <view class="search-input">
+            <u-input
+              clearable
+              placeholderStyle="font-size:26rpx"
+              :customStyle="{ height: '66rpx' }"
+              v-model="distName"
+              prefixIcon="search"
+              prefixIconStyle="font-size: 22px;color: #909399"
+              placeholder="请输入经销商名称"
+              shape="circle"
+              border="surround"></u-input>
+          </view>
+          <view class="search-btn" @click="searchList">搜索</view>
+        </view>
+      </view>
+      <u-empty v-if="customerData.length == 0" mode="list" text="暂无数据"></u-empty>
+      <scroll-view :scroll-y="true" class="data-list" @scrolltolower="lower" v-else>
+        <view>
+          <view class="data-item" v-for="(v, i) in customerData" :key="i" @click="toDetails(v)">
+            <view class="customer-name flex">
+              <text class="name">{{ v.distName }}</text>
+            </view>
+            <view class="customer-info flex">
+              <view class="info-left flex_1">
+                <view class="info-row flex_l">
+                  <text class="info-label">所在省份:</text>
+                  <u-text color="#323232" size="24rpx" :text="v.provinceDesc || '-'"></u-text>
+                </view>
+                <view class="info-row flex_l">
+                  <text class="info-label">业务范围:</text>
+                  <u-text color="#323232" size="24rpx" :text="v.businessScope || '-'"></u-text>
+                </view>
+                <view class="info-row flex_l">
+                  <text class="info-label">归属销售:</text>
+                  <u-text color="#323232" size="24rpx" :text="v.belongSale || '-'"></u-text>
+                </view>
+              </view>
+            </view>
+          </view>
+          <u-loadmore :status="loadStatus" />
+        </view>
+      </scroll-view>
+    </view>
+    <!-- 消息提示 -->
+    <u-toast ref="uToast"></u-toast>
+  </view>
+</template>
+<script>
+  import distrApi from '../../api/base/distr'
+  import to from 'await-to-js'
+  export default {
+    name: 'omsIndex',
+    components: {},
+    data() {
+      return {
+        height: '',
+        paddingTop: '',
+        pageNum: 0,
+        pageSize: 10,
+        customerData: [], //客户列表
+        customerDataTotal: 0, //列表元素数量
+        loadStatus: '', //加载状态
+        distName: '', //经销商名称
+      }
+    },
+    created() {
+      const navData = uni.getMenuButtonBoundingClientRect()
+      this.height = navData.height + 'px'
+      this.paddingTop = navData.top + 'px'
+    },
+    onShow() {
+      this.getOptions()
+      this.searchList()
+    },
+    methods: {
+      getOptions() {
+        Promise.all([this.getDicts('cust_idy')])
+          .then(([industry]) => {
+            // this.levelOptions = level.data.values || []
+            this.industryOptions = industry.data.values || []
+          })
+          .catch((err) => console.log(err))
+      },
+      // 确认
+      confirmFilter() {
+        this.searchList()
+      },
+      // 上拉滚动
+      lower() {
+        if (this.customerData.length < this.customerDataTotal && this.loadStatus != 'loading') {
+          this.$u.throttle(this.getCustomerData(), 2000, false)
+        }
+      },
+      // 查询列表
+      searchList() {
+        this.pageNum = 0
+        this.getCustomerData(true)
+      },
+      async getCustomerData(reset) {
+        this.loadStatus = 'loading'
+        this.pageNum++
+        let params = {
+          distName: this.distName,
+          pageNum: this.pageNum,
+          pageSize: this.pageSize,
+        }
+        const [err, res] = await to(distrApi.getList(params))
+        if (err) {
+          this.loadStatus = 'nomore'
+          return
+        }
+        if (res && res.code == 200) {
+          if (reset) {
+            this.customerData = res.data.list || []
+          } else {
+            this.customerData = [...this.customerData, ...(res.data.list || [])]
+          }
+          this.customerDataTotal = res.data.total
+          this.loadStatus = this.customerData.length == this.customerDataTotal ? 'nomore' : 'loadmore'
+          console.log(this.loadStatus)
+        } else {
+          this.loadStatus = 'nomore'
+        }
+      },
+      goBack() {
+        uni.navigateBack({
+          //关闭当前页面,返回上一页面或多级页面。
+          delta: 1,
+        })
+      },
+      toDetails(v) {
+        uni.navigateTo({
+          //保留当前页面,跳转到应用内的某个页面
+          url: '/pages/distributor/details?id=' + v.id,
+        })
+      },
+    },
+  }
+</script>
+<style>
+  page {
+    background: #f2f3f5;
+  }
+</style>
+<style lang="scss" scoped>
+  .home {
+    padding-top: 188rpx;
+
+    .nav {
+      position: absolute;
+      left: 0;
+      top: 0;
+      width: 100%;
+      height: 284rpx;
+      background: #3e7ef8;
+      .title {
+        position: relative;
+        text-align: center;
+        font-size: 32rpx;
+        font-weight: bold;
+        color: #ffffff;
+        .back {
+          position: absolute;
+          top: 0;
+          bottom: 0;
+          margin: auto;
+          left: 70rpx;
+          display: flex;
+        }
+      }
+    }
+
+    .main {
+      position: absolute;
+      width: 100%;
+      height: calc(100vh - 188rpx);
+      background: #ffffff;
+      box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);
+      border-radius: 31rpx 31rpx 0 0;
+      padding: 0 32rpx;
+      overflow: auto;
+      padding-bottom: 64rpx;
+      .query-wrap {
+        padding-top: 20rpx;
+        .search-container {
+          display: flex;
+          align-items: center;
+          .search-input {
+            flex: 1;
+          }
+          .search-btn {
+            text-align: center;
+            line-height: 60rpx;
+            border-radius: 12rpx;
+            width: 100rpx;
+            height: 60rpx;
+            font-size: 26rpx;
+            margin: 0 0 0 12rpx;
+            background: $u-primary;
+            color: #ffffff;
+          }
+        }
+      }
+      .data-list {
+        width: 100%;
+        height: calc(100vh - 372rpx);
+        overflow: auto;
+        .data-item {
+          background: rgba(242, 243, 245, 0.5);
+          border-radius: 15rpx;
+          padding: 28rpx 40rpx 28rpx 38rpx;
+          margin-top: 32rpx;
+          .customer-name {
+            .name {
+              flex: 1;
+              color: #323232;
+              font-weight: bold;
+              font-size: 28rpx;
+              margin-right: 12rpx;
+            }
+            .user-code {
+              width: 180rpx;
+              height: 32rpx;
+              font-size: 24rpx;
+              color: #323232;
+              line-height: 32rpx;
+            }
+          }
+          .customer-info {
+            .info-left {
+              .transfer-btn {
+                margin-top: 20rpx;
+                width: 150rpx;
+              }
+              .info-row {
+                margin-top: 12rpx;
+                .info-label {
+                  color: #646464;
+                  font-size: 24rpx;
+                }
+              }
+            }
+            .info-right {
+              padding-top: 30rpx;
+              .user-img {
+                border-radius: 50%;
+                width: 46rpx;
+                height: 46rpx;
+              }
+            }
+          }
+        }
+      }
+    }
+
+    .filter-popup {
+      background: rgba(0, 0, 0, 0.8);
+      position: fixed;
+      width: 100%;
+      height: 100%;
+      left: 0;
+      z-index: 1;
+      .filter-wrap {
+        width: 100%;
+        padding: 20rpx;
+        background: #ffffff;
+        .filter-item {
+          padding-bottom: 30rpx;
+          .tit {
+            font-size: 26rpx;
+            color: #323232;
+            font-weight: bold;
+            padding-bottom: 20rpx;
+          }
+          .menu-list {
+            display: flex;
+            flex-wrap: wrap;
+            .menu-item {
+              margin-right: 40rpx;
+              margin-bottom: 20rpx;
+            }
+          }
+        }
+      }
+      .btn-box {
+        width: 698rpx;
+        height: 75px;
+        display: flex;
+        align-items: center;
+        justify-content: space-between;
+        > view {
+          width: 320rpx;
+          height: 40px;
+          border-radius: 40px;
+          border: solid 1rpx #ec652b;
+          align-items: center;
+          justify-content: center;
+          text-align: center;
+          line-height: 40px;
+        }
+        .reset {
+          color: #ec652b;
+        }
+        .submit {
+          color: #fff;
+          background-color: #ec652b;
+        }
+      }
+    }
+  }
+</style>

+ 2 - 2
pages/home/checkIn.vue

@@ -28,8 +28,8 @@
         <template v-if="!showList">
           <view class="btn" @click="checkIn">打卡</view>
           <view class="location">
-            <u--text @click="getLocation" :lines="1" :block="true" align="center" size="32rpx" :text="address">
-            </u--text>
+            <u-text @click="getLocation" :lines="1" :block="true" align="center" size="32rpx" :text="address">
+            </u-text>
             <u-loading-icon mode="circle" size="24rpx" :show="show"></u-loading-icon>
           </view>
         </template>

+ 71 - 17
pages/home/index.vue

@@ -2,12 +2,13 @@
  * @Author: liuzhenlin 461480418@qq.ocm
  * @Date: 2023-01-12 11:57:48
  * @LastEditors: liuzhenlin
- * @LastEditTime: 2023-02-23 18:05:16
+ * @LastEditTime: 2023-02-27 17:20:10
  * @Description: file content
  * @FilePath: \oms\pages\home\index.vue
 -->
 <template>
   <view class="home">
+    <!-- <WaterMark></WaterMark> -->
     <view class="nav">
       <view :style="{ paddingTop }">
         <view class="title" :style="[{ height }, { lineHeight: height }]">首页</view>
@@ -32,19 +33,19 @@
         <view class="date-msg">
           <u-row justify="space-between">
             <u-col span="4">
-              <view class="center flex-column">
+              <view class="center flex-column" @click="handleHomeLink('/pages/openSeaCustomer/index')">
                 <view class="num">{{ newCustomer }}</view>
                 <view class="txt">新增客户</view>
               </view>
             </u-col>
             <u-col span="4">
-              <view class="center flex-column">
+              <view class="center flex-column" @click="handleHomeLink('/pages/project/index')">
                 <view class="num">{{ newBusiness }}</view>
                 <view class="txt">新增项目</view>
               </view>
             </u-col>
             <u-col span="4">
-              <view class="center flex-column">
+              <view class="center flex-column" @click="handleHomeLink('/pages/schedule/index?type=1', 2)">
                 <view class="num">{{ newTask }}</view>
                 <view class="txt">督办事项</view>
               </view>
@@ -103,13 +104,13 @@
         </u-row>
         <u-row justify="space-between" gutter="14">
           <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink()">
+            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/distributor/index')">
               <view class="menu-img-box">
                 <image class="menu-img" src="../../static/images/menu4.png" mode="scaleToFill" />
               </view>
               <view class="menu-info flex flex-column">
-                <view class="tit1">回款管理</view>
-                <view class="tit2">回款数据展示</view>
+                <view class="tit1">合作伙伴</view>
+                <view class="tit2">合作伙伴展示</view>
               </view>
             </view>
           </u-col>
@@ -126,7 +127,22 @@
           </u-col>
         </u-row>
       </view>
-      <view class="echarts-container">
+
+      <view class="data-container">
+        <h4>个人看板</h4>
+        <view class="flex flex-wrap flex-around">
+          <view class="board-data" v-for="(v, i) in privateBoard" :key="i">
+            <view>
+              <u-text :bold="true" :text="v.report_data"></u-text>
+            </view>
+            <view>
+              <u-text lines="1" :text="v.report_name"></u-text>
+            </view>
+          </view>
+        </view>
+      </view>
+
+      <view class="data-container">
         <h4>个人报表</h4>
         <view class="echarts" v-for="item in echarts" :key="item.id">
           <h4>{{ item.report_name }}</h4>
@@ -197,6 +213,7 @@
     name: 'omsIndex',
     data() {
       return {
+        privateBoard: [], //个人看板数据
         height: '',
         paddingTop: '',
         tabDate: 'week',
@@ -234,7 +251,7 @@
       this.paddingTop = navData.top + 'px'
     },
     mounted() {
-      this.getEcharts()
+      this.getHomeConfig()
     },
     onShow() {
       this.getReport('week')
@@ -254,7 +271,7 @@
           this.newTask = res.data.newTask
         }
       },
-      handleHomeLink(url) {
+      handleHomeLink(url, linkType) {
         if (!url) {
           uni.showToast({
             title: '功能开发中~',
@@ -262,12 +279,19 @@
           })
           return
         }
-        uni.navigateTo({
-          //保留当前页面,跳转到应用内的某个页面
-          url,
-        })
+        if (linkType && linkType == '2') {
+          uni.reLaunch({
+            url,
+          })
+        } else {
+          uni.navigateTo({
+            //保留当前页面,跳转到应用内的某个页面
+            url,
+          })
+        }
       },
-      async getEcharts() {
+      // 获取首页配置
+      async getHomeConfig() {
         const [err, res] = await to(
           indexApi.getHomeReport({
             module_code: 'HomePage',
@@ -275,7 +299,29 @@
         )
         if (err) return
         const obj = JSON.parse(res.data.configInfo)
+        this.privateBoard = obj.num_report_config || []
         this.echarts = obj.data_report_config || []
+        this.getHomeNumReportData()
+      },
+      // 获取首页个人看板数据
+      async getHomeNumReportData() {
+        let ids = this.privateBoard.map((item) => {
+          return item.id
+        })
+        const {
+          data: { num_report_response },
+        } = await indexApi.getHomeNumReportData({ ids: ids })
+        let privateBoardData = []
+        this.privateBoard.forEach((item, index) => {
+          num_report_response.forEach((val) => {
+            if (item.id === val.id) {
+              this.privateBoard[index].report_data = val.data
+              privateBoardData.push(this.privateBoard[index])
+            }
+          })
+        })
+        this.privateBoard = privateBoardData.splice(0, 6)
+        console.log(this.privateBoard)
       },
       async init(id) {
         console.log(id, 'id')
@@ -324,6 +370,7 @@
             },
           ],
         }
+        console.log('option', option)
         this.$refs[id][0].init(echarts, (chart) => {
           chart.setOption(option)
         })
@@ -561,7 +608,7 @@
         }
       }
 
-      .echarts-container {
+      .data-container {
         background-color: #fff;
         box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);
         border-radius: 31rpx 31rpx 31rpx 31rpx;
@@ -576,7 +623,14 @@
           color: #323232;
           padding-left: 40rpx;
         }
-
+        .board-data {
+          width: 46%;
+          border-radius: 10rpx;
+          padding: 0 20rpx;
+          border: 1px solid #eee;
+          line-height: 50rpx;
+          margin-bottom: 20rpx;
+        }
         .echarts {
           height: 480rpx;
           box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);

+ 1 - 6
pages/project/details.vue

@@ -66,20 +66,16 @@
         <view class="tabs">
           <u-tabs
             @change="changeTabs"
-            lineWidth="8"
             :current="curTabIndex"
-            lineHeight="8"
             :scrollable="false"
             :list="list"
-            :lineColor="`url(${lineBg}) 100% 100%`"
             :activeStyle="{
               color: '#3E7EF8',
               fontWeight: 'bold',
             }"
             :inactiveStyle="{
               color: '#969696',
-            }"
-            itemStyle="height: 90rpx;"></u-tabs>
+            }"></u-tabs>
         </view>
       </view>
       <view class="data-list">
@@ -122,7 +118,6 @@
     data() {
       return {
         openBtnWidth: false,
-        lineBg: require('../../static/images/up.png'),
         curTabIndex: 0,
         fllowList: [], //跟进数据
         list: [

+ 10 - 14
pages/project/downgrade.vue

@@ -41,9 +41,7 @@
           </u-radio-group>
         </u-form-item>
         <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
-          <view class="form-label flex_l">
-            技术支持人员
-          </view>
+          <view class="form-label flex_l">技术支持人员</view>
           <u-input
             placeholder="输入技术支持人员"
             v-model="addForm.technicalSupportName"
@@ -52,7 +50,7 @@
             clearable
             customStyle="padding: 0 30rpx 0 12rpx"></u-input>
         </u-form-item>
-        <u-form-item prop="technicalSupportContent" borderBottom customStyle="padding:40rpx 0 30rpx">
+        <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
           <view class="form-label flex_l">
             <view class="label-tag"></view>
             技术支持内容
@@ -66,9 +64,7 @@
             customStyle="padding: 0 30rpx 0 12rpx"></u-input>
         </u-form-item>
         <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showSupportDate = true">
-          <view class="form-label flex_l">
-            技术支持时间
-          </view>
+          <view class="form-label flex_l">技术支持时间</view>
           <u-input
             :readonly="true"
             placeholder="请选择技术支持时间"
@@ -140,12 +136,12 @@
             message: '请选择项目级别',
             trigger: ['blur'],
           },
-          technicalSupportContent: {
-            type: 'string',
-            required: true,
-            message: '请输入技术支持内容',
-            trigger: ['blur'],
-          },
+          // technicalSupportContent: {
+          //   type: 'string',
+          //   required: true,
+          //   message: '请输入技术支持内容',
+          //   trigger: ['blur'],
+          // },
           remark: {
             type: 'string',
             required: true,
@@ -287,7 +283,7 @@
         .label-tag {
           width: 15rpx;
           height: 15rpx;
-          background:  #ff4d4f;
+          background: #ff4d4f;
           border-radius: 50%;
           margin-right: 10rpx;
         }

+ 1 - 1
pages/project/upgrade.vue

@@ -390,7 +390,7 @@
             trigger: ['blur'],
           },
           nboBudget: {
-            type: 'string',
+            type: 'number',
             required: true,
             message: '请输入项目预算',
             trigger: ['blur'],

+ 13 - 2
pages/schedule/index.vue

@@ -75,12 +75,23 @@
         ],
       }
     },
+    onLoad(option) {
+      console.log(option.type) //打印出上个页面传递的参数。
+      if (option && option.type) {
+        this.curTabIndex = parseInt(option.type)
+      }
+    },
+    onHide() {
+      this.curTabIndex = 0
+    },
     created() {
       const navData = uni.getMenuButtonBoundingClientRect()
       this.height = navData.height + 'px'
       this.paddingTop = navData.top + 'px'
     },
-    mounted() {},
+    mounted(option) {
+      console.log(option)
+    },
     methods: {
       // 显示返回
       initBack(visible) {
@@ -135,7 +146,7 @@
       box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);
       border-radius: 31rpx 31rpx 0 0;
       padding: 0 32rpx;
-      overflow: auto;
+      // overflow: auto;
       padding-bottom: 64rpx;
 
       .tabs {

+ 134 - 124
store/index.js

@@ -12,134 +12,144 @@ import userApi from '../api/system/user'
 import to from 'await-to-js'
 Vue.use(Vuex)
 const store = new Vuex.Store({
-    state: {
-        token: '', //用户token
-        userId: '',
-        username: '',
-        nickName: '',
-        postName:'',
-        avatar: '',
-        followPageDetail: {}, //跟进页面的客户/项目信息
+  state: {
+    token: '', //用户token
+    userId: '',
+    username: '',
+    nickName: '',
+    postName: '',
+    avatar: '',
+    followPageDetail: {}, //跟进页面的客户/项目信息
+    phone: '',
+  },
+  getters: {
+    followPageDetail: (state) => state.followPageDetail,
+    userId: (state) => state.userId,
+    token: (state) => state.token,
+    username: (state) => state.username,
+    nickName: (state) => state.nickName,
+    postName: (state) => state.postName,
+    avatar: (state) => state.avatar,
+    phone: (state) => state.phone,
+  },
+  //mutations定义同步操作的方法
+  mutations: {
+    /**
+     * @description 设置token
+     * @param {*} state
+     * @param {*} token
+     */
+    setDetails(state, info) {
+      state.followPageDetail = info
     },
-    getters: {
-        followPageDetail: (state) => state.followPageDetail,
-        userId: (state) => state.userId,
-        token: (state) => state.token,
-        username: (state) => state.username,
-        nickName: (state) => state.nickName,
-        postName:(state) => state.postName,
-        avatar: (state) => state.avatar,
+    /**
+     * @description 设置token
+     * @param {*} state
+     * @param {*} token
+     */
+    setToken(state, token) {
+      state.token = token
+      uni.setStorageSync('opms_token', token)
     },
-    //mutations定义同步操作的方法
-    mutations: {
-        /**
-         * @description 设置token
-         * @param {*} state
-         * @param {*} token
-         */
-        setDetails(state, info) {
-            state.followPageDetail = info
-        },
-        /**
-         * @description 设置token
-         * @param {*} state
-         * @param {*} token
-         */
-        setToken(state, token) {
-            state.token = token
-            uni.setStorageSync('opms_token', token)
-        },
-        /**
-         * @description 设置用户id
-         * @param {*} state
-         * @param {*} userId
-         */
-        setUserId(state, userId) {
-            state.userId = userId
-        },
-        /**
-         * @description 设置用户名字
-         * @param {*} state
-         * @param {*} username
-         */
-        setUsername(state, username) {
-            state.username = username
-        },
-        /**
-         * @description
-         * @param {*} state
-         * @param {*} nickName
-         */
-        setNickName(state, nickName) {
-            state.nickName = nickName
-        },
-        setPostName(state, postName) {
-            state.postName = postName
-        },
-        /**
-         * @description 设置用头像
-         * @param {*} state
-         * @param {*} avatar
-         */
-        setAvatar(state, avatar) {
-            state.avatar = avatar
-        },
+    /**
+     * @description 设置用户id
+     * @param {*} state
+     * @param {*} userId
+     */
+    setUserId(state, userId) {
+      state.userId = userId
     },
-    actions: {
-        /**
-         * @description 登录
-         * @param {*} { commit }
-         * @param {*} userInfo
-         */
-        async login({ commit, dispatch }, userInfo) {
-            const [err, res] = await to(userApi.login(userInfo))
-            if (err) return
-            uni.showToast({
-                title: '登录成功',
-                icon: 'none',
-                complete: async() => {
-                    commit('setToken', res.data.token)
-                    uni.reLaunch({
-                        url: '/pages/home/index',
-                    })
-                    await dispatch('getUserInfo')
-                },
-            })
-        },
-        /**
-         * @description 获取用户信息接口
-         * @param {*} { commit, dispatch, state }
-         * @returns
-         */
-        async getUserInfo({ commit }) {
-            const [err, res] = await to(userApi.getUserInfo())
-            if (err) return
-            const { id, userName, nickName, avatar, postName } = res.data.entity
-            if (id) commit('setUserId', id)
-            if (userName) commit('setUsername', userName)
-            if (nickName) commit('setNickName', nickName)
-            if (postName) commit('setPostName', nickName)
-            if (avatar) commit('setAvatar', avatar)
-        },
-        /**
-         * @description 退出登录
-         * @param {*} { dispatch }
-         */
-        async logout({ dispatch }) {
-            await userApi.logout()
-            await dispatch('resetAll')
-        },
-        /**
-         * @description 重置token、roles、permission、router、tabsBar等
-         * @param {*} { commit, dispatch }
-         */
-        async resetAll({ commit }) {
-            commit('setUsername', '游客')
-            commit('setAvatar', 'https://i.gtimg.cn/club/item/face/img/2/15922_100.gif')
-            commit('setToken', '')
-            uni.removeStorageSync('opms_token')
+    /**
+     * @description 设置用户名字
+     * @param {*} state
+     * @param {*} username
+     */
+    setUsername(state, username) {
+      state.username = username
+    },
+    /**
+     * @description
+     * @param {*} state
+     * @param {*} nickName
+     */
+    setNickName(state, nickName) {
+      state.nickName = nickName
+    },
+    setPostName(state, postName) {
+      state.postName = postName
+    },
+    /**
+     * @description 设置用头像
+     * @param {*} state
+     * @param {*} avatar
+     */
+    setAvatar(state, avatar) {
+      state.avatar = avatar
+    },
+    /**
+     * @description 手机号
+     * @param {*} state
+     * @param {*} phone
+     */
+    setPhone(state, phone) {
+      state.phone = phone
+    },
+  },
+  actions: {
+    /**
+     * @description 登录
+     * @param {*} { commit }
+     * @param {*} userInfo
+     */
+    async login({ commit, dispatch }, userInfo) {
+      const [err, res] = await to(userApi.login(userInfo))
+      if (err) return
+      uni.showToast({
+        title: '登录成功',
+        icon: 'none',
+        complete: async () => {
+          commit('setToken', res.data.token)
+          uni.reLaunch({
+            url: '/pages/home/index',
+          })
+          await dispatch('getUserInfo')
         },
+      })
+    },
+    /**
+     * @description 获取用户信息接口
+     * @param {*} { commit, dispatch, state }
+     * @returns
+     */
+    async getUserInfo({ commit }) {
+      const [err, res] = await to(userApi.getUserInfo())
+      if (err) return
+      const { id, userName, nickName, avatar, postName, phone } = res.data.entity
+      if (id) commit('setUserId', id)
+      if (userName) commit('setUsername', userName)
+      if (nickName) commit('setNickName', nickName)
+      if (postName) commit('setPostName', nickName)
+      if (avatar) commit('setAvatar', avatar)
+      if (phone) commit('setPhone', phone)
+    },
+    /**
+     * @description 退出登录
+     * @param {*} { dispatch }
+     */
+    async logout({ dispatch }) {
+      await userApi.logout()
+      await dispatch('resetAll')
+    },
+    /**
+     * @description 重置token、roles、permission、router、tabsBar等
+     * @param {*} { commit, dispatch }
+     */
+    async resetAll({ commit }) {
+      commit('setUsername', '游客')
+      commit('setAvatar', 'https://i.gtimg.cn/club/item/face/img/2/15922_100.gif')
+      commit('setToken', '')
+      uni.removeStorageSync('opms_token')
     },
+  },
 })
 export default store
-

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
uni_modules/lime-echart/static/echarts.min.js


+ 15 - 0
vue.config.js

@@ -0,0 +1,15 @@
+const path = require('path')
+
+module.exports = {
+	configureWebpack: {
+		module: {
+			rules: [{
+				test: /\.vue$/,
+				use: {
+					loader: path.resolve(__dirname, "./node_modules/vue-inset-loader")
+				},
+			}]
+		},
+	}
+}
+

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels