Ver Fonte

fix:修改升级模块的逻辑代码。首页增加banner轮播

liuzl há 2 anos atrás
pai
commit
9a65522483
43 ficheiros alterados com 919 adições e 541 exclusões
  1. 36 2
      App.vue
  2. 7 4
      api/project/index.js
  3. 10 2
      api/task/index.js
  4. 1 1
      pages/contract/components/contractDetail.vue
  5. 1 1
      pages/contract/components/contractDynamics.vue
  6. 1 1
      pages/contract/detail.vue
  7. 4 6
      pages/contract/index.vue
  8. 3 3
      pages/contract/invoice.vue
  9. 3 3
      pages/customer/add.vue
  10. 1 1
      pages/customer/components/contacts.vue
  11. 3 3
      pages/customer/components/customerDetail.vue
  12. 1 1
      pages/customer/components/followRecords.vue
  13. 1 1
      pages/customer/components/moveInOpenSea.vue
  14. 3 3
      pages/customer/details.vue
  15. 8 8
      pages/customer/index.vue
  16. 5 5
      pages/customer/transfer.vue
  17. 1 1
      pages/distributor/components/followRecords.vue
  18. 3 3
      pages/distributor/details.vue
  19. 1 1
      pages/distributor/index.vue
  20. 3 3
      pages/home/checkIn.vue
  21. 120 113
      pages/home/index.vue
  22. 2 2
      pages/my/index.vue
  23. 1 1
      pages/openSeaCustomer/components/collectionCustomer.vue
  24. 8 8
      pages/openSeaCustomer/index.vue
  25. 7 7
      pages/project/components/projectDetail.vue
  26. 9 22
      pages/project/create.vue
  27. 1 1
      pages/project/details.vue
  28. 2 2
      pages/project/downgrade.vue
  29. 2 2
      pages/project/index.vue
  30. 176 78
      pages/project/upgrade.vue
  31. 70 45
      pages/publicPages/follow.vue
  32. 2 6
      pages/schedule/index.vue
  33. 3 1
      pages/schedule/manage.vue
  34. 262 0
      pages/schedule/supervise/components/progress.vue
  35. 0 131
      pages/schedule/supervise/components/taskDetails.vue
  36. 147 64
      pages/schedule/supervise/details.vue
  37. 3 5
      pages/schedule/supervise/index.vue
  38. BIN
      static/images/home1.png
  39. BIN
      static/images/swiper/banner1.png
  40. BIN
      static/images/swiper/banner2.png
  41. BIN
      static/images/swiper/banner3.png
  42. BIN
      static/images/user.jpg
  43. 8 0
      style/common.scss

+ 36 - 2
App.vue

@@ -16,13 +16,47 @@
   export default {
     onLaunch: function () {
       console.log('App Launch')
+      const updateManager = uni.getUpdateManager()
+      updateManager.onCheckForUpdate(function (res) {
+        // 请求完新版本信息的回调
+        if (res.hasUpdate) {
+          updateManager.onUpdateReady(function (res2) {
+            uni.showModal({
+              title: '更新提示',
+              content: '发现新版本,是否重启应用?',
+              cancelColor: '#eeeeee',
+              confirmColor: '#FF0000',
+              success(res2) {
+                if (res2.confirm) {
+                  // 新的版本已经下载好,调用 applyUpdate 应用新版本并重启
+                  updateManager.applyUpdate()
+                }
+              },
+            })
+          })
+        }
+      })
+
+      updateManager.onUpdateFailed(function (res) {
+        // 新的版本下载失败
+        uni.showModal({
+          title: '提示',
+          content: '检查到有新版本,但下载失败,请检查网络设置',
+          success(res) {
+            if (res.confirm) {
+              // 新的版本已经下载好,调用 applyUpdate 应用新版本并重启
+              updateManager.applyUpdate()
+            }
+          },
+        })
+      })
     },
     onShow: function () {
       store.dispatch('getUserInfo')
-      console.log('App Show')
+      // console.log('App Show')
     },
     onHide: function () {
-      console.log('App Hide')
+      // console.log('App Hide')
     },
   }
 </script>

+ 7 - 4
api/project/index.js

@@ -35,8 +35,11 @@ export default {
   downgrade(query) {
     return micro_request.postRequest(basePath, 'Business', 'BusinessDowngrade', query)
   },
-    // 项目升级
-   upgrade(query) {
-      return micro_request.postRequest(basePath, 'Business', 'BusinessUpgrade', query)
-    },
+  // 项目升级
+  upgrade(query) {
+    return micro_request.postRequest(basePath, 'Business', 'BusinessUpgrade', query)
+  },
+  businessUpgradeA(query) {
+    return micro_request.postFormDataRequest(basePath, 'BusinessHandler', 'BusinessUpgradeA', query)
+  },
 }

+ 10 - 2
api/task/index.js

@@ -2,9 +2,9 @@
  * @Author: liuzhenlin 461480418@qq.ocm
  * @Date: 2023-01-29 09:43:06
  * @LastEditors: liuzhenlin
- * @LastEditTime: 2023-01-29 09:43:36
+ * @LastEditTime: 2023-03-07 17:52:47
  * @Description: file content
- * @FilePath: \crm\api\schedule\index.js
+ * @FilePath: \oms\api\task\index.js
  */
 import micro_request from '../../utils/micro_request'
 const basePath = process.uniEnv.VUE_APP_ParentPath
@@ -13,4 +13,12 @@ export default {
   getList(query) {
     return micro_request.postRequest(basePath, 'Task', 'GetList', query)
   },
+  // 督办处理
+  handleTask(query) {
+    return micro_request.postRequest(basePath, 'Task', 'Handle', query)
+  },
+  // 督办进展列表
+  getTaskProgressList(query) {
+    return micro_request.postRequest(basePath, 'TaskProgress', 'GetList', query)
+  },
 }

+ 1 - 1
pages/contract/components/contractDetail.vue

@@ -161,7 +161,7 @@
     },
 
     mounted() {
-      console.log(this.abstract)
+      // console.log(this.abstract)
     },
 
     methods: {},

+ 1 - 1
pages/contract/components/contractDynamics.vue

@@ -54,7 +54,7 @@
 
     mounted() {
       this.fetchData()
-      console.log('contractId', this.contractId)
+      // console.log('contractId', this.contractId)
     },
 
     methods: {

+ 1 - 1
pages/contract/detail.vue

@@ -26,7 +26,7 @@
               <image class="img" src="../../static/images/menu1.png" mode="scaleToFill" />
               <text>{{ detail.contractName }}</text>
             </view>
-            <view class="date">{{ parseTime(detail.createdTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="date">{{ parseTime(detail.createdTime, '{y}-{m}-{d}') }}</view>
           </view>
           <view class="info">
             <view class="info-item">

+ 4 - 6
pages/contract/index.vue

@@ -167,12 +167,10 @@
       },
       // 筛选下的单选
       radioClick(item, target) {
-        console.log(item.key, target)
         this[target] = item.key
       },
       // 选择日期
       async pickDate(e) {
-        console.log(e)
         this.followUpDate = e.fulldate
       },
       // 重置
@@ -188,9 +186,9 @@
       },
       // 上拉滚动
       lower() {
-        console.log(this.list.length)
-        console.log(this.customerDataTotal)
-        console.log(this.loadStatus)
+        // console.log(this.list.length)
+        // console.log(this.customerDataTotal)
+        // console.log(this.loadStatus)
         if (this.list.length < this.customerDataTotal && this.loadStatus != 'loading') {
           this.$u.throttle(this.fetchData(), 2000, false)
         }
@@ -223,7 +221,7 @@
           }
           this.customerDataTotal = res.data.total
           this.loadStatus = this.list.length == this.customerDataTotal ? 'nomore' : 'loadmore'
-          console.log(this.loadStatus)
+          // console.log(this.loadStatus)
         } else {
           this.loadStatus = 'nomore'
         }

+ 3 - 3
pages/contract/invoice.vue

@@ -32,7 +32,7 @@
             <view class="label-tag"></view>
             开票日期
           </view>
-          <u--input v-model="form.invoiceDate" disabled disabledColor="#ffffff" placeholder="请选择开票日期"></u--input>
+          <u-input v-model="form.invoiceDate" disabled disabledColor="#ffffff" placeholder="请选择开票日期"></u-input>
         </u-form-item>
         <u-form-item prop="invoiceType" @click="showPicker = true">
           <view class="form-label flex_l">
@@ -110,7 +110,7 @@
       this.getOptions()
     },
     onLoad(option) {
-      console.log(option.id) //打印出上个页面传递的参数。
+      // console.log(option.id) //打印出上个页面传递的参数。
       this.form.contractId = parseInt(option.id)
       this.form.contractCode = option.code
     },
@@ -143,7 +143,7 @@
         params.invoiceAmount = parseInt(params.invoiceAmount)
         this.$refs.form.validate().then(async valid => {
           if (valid) {
-            console.log(valid);
+            // console.log(valid);
             const [err, res] = await to(api.addInvoice(params))
             if (err) return
             this.$refs.uToast.show({

+ 3 - 3
pages/customer/add.vue

@@ -315,7 +315,7 @@
                 })
                 picker.setColumnValues(1, shi)
               } else {
-                console.log(item)
+                // console.log(item)
                 picker.setColumnValues(1, [])
                 picker.setColumnValues(2, [])
               }
@@ -363,7 +363,7 @@
               remark: this.addForm.remark,
               custDistCode: this.selectLocation.value[0].id,
             }
-            console.log(params)
+            // console.log(params)
             const [err, res] = await to(customerApi.createCustomer(params))
             if (err) return
             if (res && res.code == 200) {
@@ -377,7 +377,7 @@
             }
           })
           .catch((err) => {
-            console.log(err)
+            // console.log(err)
             this.$refs.uNotify.show({
               top: this.height + this.paddingTop + 10,
               type: 'warning',

+ 1 - 1
pages/customer/components/contacts.vue

@@ -74,7 +74,7 @@
 
     mounted() {
       this.getContacts()
-      console.log('customerId', this.customerId)
+      // console.log('customerId', this.customerId)
     },
 
     methods: {

+ 3 - 3
pages/customer/components/customerDetail.vue

@@ -23,7 +23,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">创建时间:</view>
-            <view class="desc">{{ detail.createdTime }}</view>
+            <view class="desc">{{ parseTime(detail.createdTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -33,7 +33,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">下次联系时间:</view>
-            <view class="desc">{{ detail.followUpDate }}</view>
+            <view class="desc">{{ parseTime(detail.followUpDate, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -155,7 +155,7 @@
     },
 
     mounted() {
-      console.log(this.abstract)
+      // console.log(this.abstract)
     },
 
     methods: {},

+ 1 - 1
pages/customer/components/followRecords.vue

@@ -54,7 +54,7 @@
 
     mounted() {
       this.getRecords()
-      console.log('customerId', this.customerId)
+      // console.log('customerId', this.customerId)
     },
 
     methods: {

+ 1 - 1
pages/customer/components/moveInOpenSea.vue

@@ -49,7 +49,7 @@
         let params = this.openSeaObj
         const [err, res] = await to(customerApi.moveInOpenSea(params))
         if (err) return this.closeMoveInModel()
-        console.log(res.code)
+        // console.log(res.code)
         if (res.code == 200) {
           this.$refs.uToast.show({
             type: 'loading',

+ 3 - 3
pages/customer/details.vue

@@ -26,7 +26,7 @@
               <image class="img" src="../../static/images/menu1.png" mode="scaleToFill" />
               <text>{{ customerData.custName }}</text>
             </view>
-            <view class="date">{{ parseTime(customerData.createdTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="date">{{ parseTime(customerData.createdTime, '{y}-{m}-{d}') }}</view>
           </view>
           <view class="info">
             <view class="info-item">
@@ -168,7 +168,7 @@
         const [err, res] = await to(customerApi.getDetail({ ids: [this.customerId] }))
         if (err) return
         if (res && res.code == 200) {
-          console.log(res)
+          // console.log(res)
           this.customerData = res.data.list[0]
         }
       },
@@ -182,7 +182,7 @@
       },
       // 改变tab
       changeTabs(data) {
-        console.log(data)
+        // console.log(data)
         this.curTabIndex = data.index
       },
       // 打开转移

+ 8 - 8
pages/customer/index.vue

@@ -90,7 +90,7 @@
                 </view>
                 <view class="info-row flex_l">
                   <text class="info-label">最后跟进时间:</text>
-                  <u-text color="#323232" size="24rpx" :text="v.followUpDate || '-'"></u-text>
+                  <u-text color="#323232" size="24rpx" :text="parseTime(v.followUpDate,'{y}-{m}-{d}') || '-'"></u-text>
                 </view>
                 <view class="flex_l">
                   <view class="transfer-btn mr20" @click.stop="linkToTransfer(v.id)">
@@ -172,12 +172,12 @@
       },
       // 筛选下的单选
       radioClick(item, target) {
-        console.log(item.key, target)
+        // console.log(item.key, target)
         this[target] = item.key
       },
       // 选择日期
       async pickDate(e) {
-        console.log(e)
+        // console.log(e)
         this.followUpDate = e.fulldate
       },
       // 重置
@@ -193,9 +193,9 @@
       },
       // 上拉滚动
       lower() {
-        console.log(this.customerData.length)
-        console.log(this.customerDataTotal)
-        console.log(this.loadStatus)
+        // console.log(this.customerData.length)
+        // console.log(this.customerDataTotal)
+        // console.log(this.loadStatus)
         if (this.customerData.length < this.customerDataTotal && this.loadStatus != 'loading') {
           this.$u.throttle(this.getCustomerData(), 2000, false)
         }
@@ -229,7 +229,7 @@
           }
           this.customerDataTotal = res.data.total
           this.loadStatus = this.customerData.length == this.customerDataTotal ? 'nomore' : 'loadmore'
-          console.log(this.loadStatus)
+          // console.log(this.loadStatus)
         } else {
           this.loadStatus = 'nomore'
         }
@@ -244,7 +244,7 @@
       },
       // 移入公海
       moveInOpenSea(item) {
-        console.log(item)
+        // console.log(item)
         this.openSeaObj.ids = [item.id]
         this.showMoveInModel = true
       },

+ 5 - 5
pages/customer/transfer.vue

@@ -103,7 +103,7 @@
       this.paddingTop = navData.top + 'px'
     },
     onLoad(option) {
-      console.log(option.id) //打印出上个页面传递的参数。
+      // console.log(option.id) //打印出上个页面传递的参数。
       this.transferObj.ids = [parseInt(option.id)]
     },
     onShow() {},
@@ -112,9 +112,9 @@
         this.$refs.addForm
           .validate()
           .then(async () => {
-            console.log(1111)
+            // console.log(1111)
             let params = this.transferObj
-            console.log(params)
+            // console.log(params)
             const [err, res] = await to(customerApi.transfer(params))
             if (err) return
             if (res && res.code == 200) {
@@ -128,7 +128,7 @@
             }
           })
           .catch((err) => {
-            console.log(err)
+            // console.log(err)
             this.$refs.uNotify.show({
               top: this.height + this.paddingTop + 10,
               type: 'warning',
@@ -139,7 +139,7 @@
       },
       closeUser(user) {
         if (user) {
-          console.log(user)
+          // console.log(user)
           this.transferObj.salesId = user.id
           this.transferObj.salesName = user.label
         }

+ 1 - 1
pages/distributor/components/followRecords.vue

@@ -54,7 +54,7 @@
 
     mounted() {
       this.getRecords()
-      console.log('customerId', this.customerId)
+      // console.log('customerId', this.customerId)
     },
 
     methods: {

+ 3 - 3
pages/distributor/details.vue

@@ -26,7 +26,7 @@
               <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 class="date">{{ parseTime(distrInfo.createdTime, '{y}-{m}-{d}') }}</view>
           </view>
           <view class="info">
             <view class="info-item">
@@ -132,13 +132,13 @@
         const [err, res] = await to(distrApi.getEntity({ id: this.distrId }))
         if (err) return
         if (res && res.code == 200) {
-          console.log(res)
+          // console.log(res)
           this.distrInfo = res.data.list
         }
       },
       // 改变tab
       changeTabs(data) {
-        console.log(data)
+        // console.log(data)
         this.curTabIndex = data.index
       },
       goBack() {

+ 1 - 1
pages/distributor/index.vue

@@ -140,7 +140,7 @@
           }
           this.customerDataTotal = res.data.total
           this.loadStatus = this.customerData.length == this.customerDataTotal ? 'nomore' : 'loadmore'
-          console.log(this.loadStatus)
+          // console.log(this.loadStatus)
         } else {
           this.loadStatus = 'nomore'
         }

+ 3 - 3
pages/home/checkIn.vue

@@ -134,19 +134,19 @@
             message: '定位失败,请重试',
           })
         }
-        console.log(this.$refs.upload);
+        // console.log(this.$refs.upload);
         // this.$refs.upload.choose()
         const [err, res] = await uni.chooseImage({
           count: 1, //默认9
           sizeType: ['original'], //可以指定是原图还是压缩图,默认二者都有
           sourceType:['camera']
         })
-        console.log(res, 'rs');
+        // console.log(res, 'rs');
         if (err) return
         this.select(res)
         res.tempFiles[0].name = (new Date()).getTime() + ''
         res.tempFiles[0].type = ''
-        console.log(res.tempFiles[0], typeof res.tempFiles[0])
+        // console.log(res.tempFiles[0], typeof res.tempFiles[0])
       },
       // // 选择上传触发函数
       select(e) {

+ 120 - 113
pages/home/index.vue

@@ -24,131 +24,135 @@
       </view>
       <view class="h-right"></view> -->
       </view>
-      <view class="msg-box">
-        <view class="tab-date-wrap">
-          <text class="tab-date-item" @click="getReport('week')" :class="{ dateActive: tabDate == 'week' }">本周</text>
-          <text class="tab-date-item" @click="getReport('month')" :class="{ dateActive: tabDate == 'month' }">
-            本月
-          </text>
+      <view class="content">
+        <view class="msg-box">
+          <view class="tab-date-wrap">
+            <text class="tab-date-item" @click="getReport('week')" :class="{ dateActive: tabDate == 'week' }">
+              本周
+            </text>
+            <text class="tab-date-item" @click="getReport('month')" :class="{ dateActive: tabDate == 'month' }">
+              本月
+            </text>
+          </view>
+          <view class="date-msg">
+            <u-row justify="space-between">
+              <u-col span="4">
+                <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" @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" @click="handleHomeLink('/pages/schedule/index?type=1', 2)">
+                  <view class="num">{{ newTask }}</view>
+                  <view class="txt">督办事项</view>
+                </view>
+              </u-col>
+            </u-row>
+          </view>
         </view>
-        <view class="date-msg">
-          <u-row justify="space-between">
-            <u-col span="4">
-              <view class="center flex-column" @click="handleHomeLink('/pages/openSeaCustomer/index')">
-                <view class="num">{{ newCustomer }}</view>
-                <view class="txt">新增客户</view>
+        <view class="menu-wrap">
+          <u-row justify="space-between" gutter="14">
+            <u-col span="6">
+              <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/openSeaCustomer/index')">
+                <view class="menu-img-box">
+                  <image class="menu-img" src="../../static/images/menu5.png" mode="scaleToFill" />
+                </view>
+                <view class="menu-info flex flex-column">
+                  <view class="tit1">公海客户</view>
+                  <view class="tit2">公海客户管理</view>
+                </view>
               </view>
             </u-col>
-            <u-col span="4">
-              <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" @click="handleHomeLink('/pages/schedule/index?type=1', 2)">
-                <view class="num">{{ newTask }}</view>
-                <view class="txt">督办事项</view>
+            <u-col span="6">
+              <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/customer/index')">
+                <view class="menu-img-box">
+                  <image class="menu-img" src="../../static/images/menu1.png" mode="scaleToFill" />
+                </view>
+                <view class="menu-info flex flex-column">
+                  <view class="tit1">客户管理</view>
+                  <view class="tit2">客户信息管理</view>
+                </view>
               </view>
             </u-col>
           </u-row>
-        </view>
-      </view>
-      <view class="menu-wrap">
-        <u-row justify="space-between" gutter="14">
-          <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/openSeaCustomer/index')">
-              <view class="menu-img-box">
-                <image class="menu-img" src="../../static/images/menu5.png" mode="scaleToFill" />
-              </view>
-              <view class="menu-info flex flex-column">
-                <view class="tit1">公海客户</view>
-                <view class="tit2">公海客户管理</view>
-              </view>
-            </view>
-          </u-col>
-          <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/customer/index')">
-              <view class="menu-img-box">
-                <image class="menu-img" src="../../static/images/menu1.png" mode="scaleToFill" />
-              </view>
-              <view class="menu-info flex flex-column">
-                <view class="tit1">客户管理</view>
-                <view class="tit2">客户信息管理</view>
-              </view>
-            </view>
-          </u-col>
-        </u-row>
-        <u-row justify="space-between" gutter="14">
-          <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/project/index')">
-              <view class="menu-img-box">
-                <image class="menu-img" src="../../static/images/menu2.png" mode="scaleToFill" />
+          <u-row justify="space-between" gutter="14">
+            <u-col span="6">
+              <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/project/index')">
+                <view class="menu-img-box">
+                  <image class="menu-img" src="../../static/images/menu2.png" mode="scaleToFill" />
+                </view>
+                <view class="menu-info flex flex-column">
+                  <view class="tit1">项目管理</view>
+                  <view class="tit2">项目进展查询</view>
+                </view>
               </view>
-              <view class="menu-info flex flex-column">
-                <view class="tit1">项目管理</view>
-                <view class="tit2">项目进展查询</view>
-              </view>
-            </view>
-          </u-col>
-          <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/contract/index')">
-              <view class="menu-img-box">
-                <image class="menu-img" src="../../static/images/menu3.png" mode="scaleToFill" />
-              </view>
-              <view class="menu-info flex flex-column">
-                <view class="tit1">合同管理</view>
-                <view class="tit2">合同信息查阅</view>
+            </u-col>
+            <u-col span="6">
+              <view class="menu-item flex_l flex-colunm" @click="handleHomeLink('/pages/contract/index')">
+                <view class="menu-img-box">
+                  <image class="menu-img" src="../../static/images/menu3.png" mode="scaleToFill" />
+                </view>
+                <view class="menu-info flex flex-column">
+                  <view class="tit1">合同管理</view>
+                  <view class="tit2">合同信息查阅</view>
+                </view>
               </view>
-            </view>
-          </u-col>
-        </u-row>
-        <u-row justify="space-between" gutter="14">
-          <u-col span="6">
-            <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" />
+            </u-col>
+          </u-row>
+          <u-row justify="space-between" gutter="14">
+            <u-col span="6">
+              <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>
               </view>
-              <view class="menu-info flex flex-column">
-                <view class="tit1">合作伙伴</view>
-                <view class="tit2">合作伙伴展示</view>
+            </u-col>
+            <u-col span="6">
+              <view class="menu-item flex_l flex-colunm" @click="handleHomeLink()">
+                <view class="menu-img-box">
+                  <image class="menu-img" src="../../static/images/menu6.png" mode="scaleToFill" />
+                </view>
+                <view class="menu-info flex flex-column">
+                  <view class="tit1">工单管理</view>
+                  <view class="tit2">工单进度查询</view>
+                </view>
               </view>
-            </view>
-          </u-col>
-          <u-col span="6">
-            <view class="menu-item flex_l flex-colunm" @click="handleHomeLink()">
-              <view class="menu-img-box">
-                <image class="menu-img" src="../../static/images/menu6.png" mode="scaleToFill" />
+            </u-col>
+          </u-row>
+        </view>
+
+        <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 class="menu-info flex flex-column">
-                <view class="tit1">工单管理</view>
-                <view class="tit2">工单进度查询</view>
+              <view>
+                <u-text lines="1" :text="v.report_name"></u-text>
               </view>
             </view>
-          </u-col>
-        </u-row>
-      </view>
-
-      <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>
-          <view class="chart">
-            <l-echart :ref="item.id + ''" @finished="init(item.id)"></l-echart>
+        <view class="data-container">
+          <h4>个人报表</h4>
+          <view class="echarts" v-for="item in echarts" :key="item.id">
+            <h4>{{ item.report_name }}</h4>
+            <view class="chart">
+              <l-echart :ref="item.id + ''" @finished="init(item.id)"></l-echart>
+            </view>
           </view>
         </view>
       </view>
@@ -327,10 +331,10 @@
           })
         })
         this.privateBoard = privateBoardData.splice(0, 6)
-        console.log(this.privateBoard)
+        // console.log(this.privateBoard)
       },
       async init(id) {
-        console.log(id, 'id')
+        // console.log(id, 'id')
         const [err, res] = await to(
           indexApi.getHomeDataReportData({
             id,
@@ -376,7 +380,7 @@
             },
           ],
         }
-        console.log('option', option)
+        // console.log('option', option)
         this.$refs[id][0].init(echarts, (chart) => {
           chart.setOption(option)
         })
@@ -432,10 +436,13 @@
 
     .main {
       box-sizing: border-box;
-      padding: 0 32rpx 46rpx;
+      padding: 0 0 46rpx;
       position: absolute;
       width: 100%;
       height: calc(100vh - 200rpx);
+      .content {
+        padding: 0 32rpx;
+      }
       // overflow: hidden;
       .msg-box {
         width: 100%;

+ 2 - 2
pages/my/index.vue

@@ -85,12 +85,12 @@
     },
     created() {
       const navData = uni.getMenuButtonBoundingClientRect()
-      console.log(navData)
+      // console.log(navData)
       this.height = navData.height + 'px'
       this.paddingTop = navData.top + 'px'
     },
     mounted() {
-      console.log(this.nickName, this.avatar)
+      // console.log(this.nickName, this.avatar)
     },
     methods: {
       async logOut() {

+ 1 - 1
pages/openSeaCustomer/components/collectionCustomer.vue

@@ -53,7 +53,7 @@
         let params = this.openSeaObj
         const [err, res] = await to(customerApi.collection(params))
         if (err) return this.closeMoveInModel()
-        console.log(res.code)
+        // console.log(res.code)
         if (res.code == 200) {
           this.$refs.uToast.show({
             type: 'loading',

+ 8 - 8
pages/openSeaCustomer/index.vue

@@ -103,7 +103,7 @@
                 </view>
                 <view class="info-row flex_l">
                   <text class="info-label">最后跟进时间:</text>
-                  <u-text color="#323232" size="24rpx" :text="v.followUpDate || '-'"></u-text>
+                  <u-text color="#323232" size="24rpx" :text="parseTime(v.followUpDate, '{y}-{m}-{d}') || '-'"></u-text>
                 </view>
                 <view class="flex_l">
                   <view class="transfer-btn mr20" @click.stop="$refs.collection.open(v.id)">
@@ -182,12 +182,12 @@
       },
       // 筛选下的单选
       radioClick(item, target) {
-        console.log(item.key, target)
+        // console.log(item.key, target)
         this[target] = item.key
       },
       // 选择日期
       async pickDate(e) {
-        console.log(e)
+        // console.log(e)
         this.followUpDate = e.fulldate
       },
       // 重置
@@ -203,9 +203,9 @@
       },
       // 上拉滚动
       lower: function (e) {
-        console.log(this.customerData.length)
-        console.log(this.customerDataTotal)
-        console.log(this.loadStatus)
+        // console.log(this.customerData.length)
+        // console.log(this.customerDataTotal)
+        // console.log(this.loadStatus)
         if (this.customerData.length < this.customerDataTotal && this.loadStatus != 'loading') {
           this.$u.throttle(this.getCustomerData(), 2000, false)
         }
@@ -239,7 +239,7 @@
           }
           this.customerDataTotal = res.data.total
           this.loadStatus = this.customerData.length == this.customerDataTotal ? 'nomore' : 'loadmore'
-          console.log(this.loadStatus)
+          // console.log(this.loadStatus)
         } else {
           this.loadStatus = 'nomore'
         }
@@ -254,7 +254,7 @@
       },
       // 移入公海
       moveInOpenSea(item) {
-        console.log(item)
+        // console.log(item)
         this.openSeaObj.ids = [item.id]
         this.showMoveInModel = true
       },

+ 7 - 7
pages/project/components/projectDetail.vue

@@ -93,7 +93,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">下次联系时间:</view>
-            <view class="desc">{{ parseTime(detail.nextFollowTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="desc">{{ parseTime(detail.nextFollowTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -103,7 +103,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">最新跟进时间:</view>
-            <view class="desc">{{ parseTime(detail.finalFollowTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="desc">{{ parseTime(detail.finalFollowTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -163,7 +163,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">技术支持时间:</view>
-            <view class="desc">{{ parseTime(detail.technicalSupportTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="desc">{{ parseTime(detail.technicalSupportTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -203,7 +203,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">项目预算期限:</view>
-            <view class="desc">{{ parseTime(detail.nboBudgetTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="desc">{{ parseTime(detail.nboBudgetTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -243,7 +243,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">采购时间:</view>
-            <view class="desc">{{ parseTime(detail.purchasingTime, '{y}-{m}-{d} {h}:{i}') }}</view>
+            <view class="desc">{{ parseTime(detail.purchasingTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -313,7 +313,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">创建时间:</view>
-            <view class="desc">{{ detail.createdTime }}</view>
+            <view class="desc">{{ parseTime(detail.createdTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>
@@ -323,7 +323,7 @@
         <u-col span="12">
           <view class="flex_l">
             <view class="label">更新时间:</view>
-            <view class="desc">{{ detail.updatedTime }}</view>
+            <view class="desc">{{ parseTime(detail.updatedTime, '{y}-{m}-{d}') }}</view>
           </view>
         </u-col>
       </u-row>

+ 9 - 22
pages/project/create.vue

@@ -361,7 +361,7 @@
     <u-datetime-picker
       v-if="showEstTransDate"
       :show="showEstTransDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.estTransTime"
       @cancel="showEstTransDate = false"
       @confirm="pickEstTransDate"></u-datetime-picker>
@@ -369,7 +369,7 @@
     <u-datetime-picker
       v-if="showPlanDate"
       :show="showPlanDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.planPurchaseTime"
       @cancel="showPlanDate = false"
       @confirm="pickPlanDate"></u-datetime-picker>
@@ -377,7 +377,7 @@
     <u-datetime-picker
       v-if="showFollowDate"
       :show="showFollowDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.followTime"
       @cancel="showFollowDate = false"
       @confirm="pickFollowDate"></u-datetime-picker>
@@ -490,14 +490,14 @@
           nboBudget: '', //项目预算
           isBig: '', //是否是大项目
           isBigVal: '', //是否是大项目文字
-          estTransTime: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //预计成交时间
-          planPurchaseTime: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //计划采购时间
+          estTransTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //预计成交时间
+          planPurchaseTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //计划采购时间
           riskProfile: '', //风险情况
           difficulty: '', //困难点
           competitor: '', //竞争公司
           intervention: '', //介入情况
           remark: '', //备注
-          // followTime: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //跟进时间
+          // followTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //跟进时间
           // followUserId: '', //跟进用户id
           // followUserName: '', //跟进用户id
           // followContent: '', //跟进内容
@@ -525,7 +525,6 @@
       ...mapGetters(['userId', 'username']),
     },
     onLoad(option) {
-      console.log(option.id) //打印出上个页面传递的参数。
       this.addForm.custId = parseInt(option.id)
     },
     created() {
@@ -557,7 +556,6 @@
         const [err, res] = await to(customerApi.getDetail({ ids: [this.addForm.custId] }))
         if (err) return
         if (res && res.code == 200) {
-          console.log(res)
           this.addForm.custName = res.data.list[0].custName
           this.addForm.nboName = this.addForm.custName
         }
@@ -578,7 +576,6 @@
       // 关闭选择客户
       closeCust(user) {
         if (user) {
-          console.log(user)
           this.addForm.custId = user.id
           this.addForm.custName = user.name
         }
@@ -586,7 +583,6 @@
       // 经销商
       closeDealer(dealer) {
         if (dealer) {
-          console.log(dealer)
           this.addForm.distributorId = dealer.id
           this.addForm.distributorName = dealer.name
         }
@@ -594,7 +590,6 @@
       // 关闭选择客户联系人
       closeContact(user) {
         if (user) {
-          console.log(user)
           this.addForm.contactId = user.id
           this.addForm.contactName = user.label
           this.addForm.contactPostion = user.postion
@@ -604,7 +599,6 @@
       // 关闭选择销售
       closeUser(user) {
         if (user) {
-          console.log(user)
           this.addForm.saleId = user.id
           this.addForm.saleName = user.label
         }
@@ -612,7 +606,6 @@
       // 全部用户
       closeAllUser(user) {
         if (user) {
-          console.log(user)
           this.addForm.followUserId = user.id
           this.addForm.followUserName = user.label
         }
@@ -620,7 +613,6 @@
       closeProduct(product) {
         let data = [...this.productList, ...product]
         this.productList = data
-        console.log(this.productList)
       },
       // 选择来源
       pickSource(e) {
@@ -650,25 +642,22 @@
       async pickEstTransDate(e) {
         this.showEstTransDate = false
         const timeFormat = uni.$u.timeFormat
-        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
+        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd')
         this.addForm.estTransTime = timeValue
-        console.log(timeValue)
       },
       // 计划采购时间
       async pickPlanDate(e) {
         this.showPlanDate = false
         const timeFormat = uni.$u.timeFormat
-        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
+        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd')
         this.addForm.planPurchaseTime = timeValue
-        console.log(timeValue)
       },
       // 跟进时间
       async pickFollowDate(e) {
         this.showFollowDate = false
         const timeFormat = uni.$u.timeFormat
-        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
+        let timeValue = await timeFormat(e.value, 'yyyy-mm-dd')
         this.addForm.followTime = timeValue
-        console.log(timeValue)
       },
       nextStep() {
         if (this.step == 1) {
@@ -678,7 +667,6 @@
               this.step++
             })
             .catch((err) => {
-              console.log(err)
               this.$refs.uNotify.show({
                 top: this.height + this.paddingTop + 10,
                 type: 'warning',
@@ -708,7 +696,6 @@
         this.$refs.addForm
           .validate()
           .then(async () => {
-            console.log(this.addForm)
             let params = this.addForm
             params.nboBudget = Number(params.nboBudget)
             params.saleName = this.username

+ 1 - 1
pages/project/details.vue

@@ -26,7 +26,7 @@
               <image class="img" src="../../static/images/menu2.png" mode="scaleToFill" />
               <text>{{ projectData.nboName }}</text>
             </view>
-            <view class="date">{{ parseTime(projectData.createdTime, '{y}-{m}-{d} {h}:{i}') || '-' }}</view>
+            <view class="date">{{ parseTime(projectData.createdTime, '{y}-{m}-{d}') || '-' }}</view>
           </view>
           <view class="info">
             <view class="info-item">

+ 2 - 2
pages/project/downgrade.vue

@@ -95,7 +95,7 @@
     <u-datetime-picker
       v-if="showSupportDate"
       :show="showSupportDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.technicalSupportTime"
       @cancel="showSupportDate = false"
       @confirm="pickSupportDate"></u-datetime-picker>
@@ -173,7 +173,7 @@
           this.addForm.nboType = ''
           this.addForm.technicalSupportName = ''
           this.addForm.technicalSupportContent = ''
-          this.addForm.technicalSupportTime = this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}')
+          this.addForm.technicalSupportTime = this.parseTime(new Date(), '{y}-{m}-{d}')
           this.addForm.remark = ''
         }
       },

+ 2 - 2
pages/project/index.vue

@@ -90,8 +90,8 @@
                     :text="selectDictLabel(productLineOptions, v.productLine) || '-'"></u-text>
                 </view>
                 <view class="info-row flex_l">
-                  <text class="info-label">项目预算(万元):</text>
-                  <u-text color="#323232" size="24rpx" mode="price" :text="v.nboBudget"></u-text>
+                  <text class="info-label">项目预算:</text>
+                  <u-text color="#323232" size="24rpx" :text="formatPrice(v.nboBudget)"></u-text>
                 </view>
                 <view class="flex_l">
                   <view class="transfer-btn mr20" @click.stop="linkToTransfer(v.id)">

+ 176 - 78
pages/project/upgrade.vue

@@ -2,9 +2,9 @@
  * @Author: liuzhenlin 461480418@qq.ocm
  * @Date: 2023-01-12 11:57:48
  * @LastEditors: liuzhenlin
- * @LastEditTime: 2023-02-21 17:47:39
+ * @LastEditTime: 2023-03-08 15:15:33
  * @Description: file content
- * @FilePath: \frontend_mobile\pages\project\upgrade.vue
+ * @FilePath: \oms\pages\project\upgrade.vue
 -->
 <template>
   <view class="home">
@@ -64,10 +64,7 @@
             borderBottom
             customStyle="padding:40rpx 0 30rpx"
             @click="$refs.dealer.open()">
-            <view class="form-label flex_l">
-              <view class="label-tag"></view>
-              经销商/代理商
-            </view>
+            <view class="form-label flex_l">经销商/代理商</view>
             <u-input
               :readonly="true"
               placeholder="请选择经销商/代理商"
@@ -79,9 +76,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </u-form-item>
           <u-form-item prop="parentReceiver" 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.parentReceiver"
@@ -91,10 +86,8 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </u-form-item>
         </view>
-        <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
-          <view class="form-label flex_l">
-            技术支持人员
-          </view>
+        <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" v-if="addForm.nboType !== '30'">
+          <view class="form-label flex_l">技术支持人员</view>
           <u-input
             placeholder="输入技术支持人员"
             v-model="addForm.technicalSupportName"
@@ -103,7 +96,11 @@
             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
+          prop="technicalSupportContent"
+          borderBottom
+          customStyle="padding:40rpx 0 30rpx"
+          v-if="addForm.nboType !== '30'">
           <view class="form-label flex_l">
             <view class="label-tag"></view>
             技术支持内容
@@ -116,10 +113,12 @@
             clearable
             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>
+        <u-form-item
+          borderBottom
+          customStyle="padding:40rpx 0 30rpx"
+          @click="showSupportDate = true"
+          v-if="addForm.nboType !== '30'">
+          <view class="form-label flex_l">技术支持时间</view>
           <u-input
             :readonly="true"
             placeholder="请选择技术支持时间"
@@ -132,9 +131,7 @@
         </u-form-item>
         <view v-if="addForm.nboType !== '30'">
           <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showBudgetDate = true">
-            <view class="form-label flex_l">
-              项目预算期限
-            </view>
+            <view class="form-label flex_l">项目预算期限</view>
             <u-input
               :readonly="true"
               placeholder="请选择项目预算期限"
@@ -146,9 +143,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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.capitalSource"
@@ -158,9 +153,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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.productSatisfaction"
@@ -171,8 +164,13 @@
           </u-form-item>
         </view>
         <view v-if="addForm.nboType === '10'">
-          <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showChasingWay = true">
+          <u-form-item
+            prop="purchasingWayVal"
+            borderBottom
+            customStyle="padding:40rpx 0 30rpx"
+            @click="showChasingWay = true">
             <view class="form-label flex_l">
+              <view class="label-tag"></view>
               采购方式
             </view>
             <u-input
@@ -185,8 +183,13 @@
               clearable
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </u-form-item>
-          <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showPurchasingDate = true">
+          <u-form-item
+            prop="technicalSupportTime"
+            borderBottom
+            customStyle="padding:40rpx 0 30rpx"
+            @click="showPurchasingDate = true">
             <view class="form-label flex_l">
+              <view class="label-tag"></view>
               采购时间
             </view>
             <u-input
@@ -200,9 +203,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </u-form-item>
           <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="selectContact()">
-            <view class="form-label flex_l">
-              决策人员
-            </view>
+            <view class="form-label flex_l">决策人员</view>
             <u-input
               :readonly="true"
               placeholder="输入决策人员"
@@ -213,9 +214,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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
               :readonly="true"
               placeholder="输入决策部门"
@@ -226,9 +225,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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.historicalTransactionInfo"
@@ -238,9 +235,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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.dealerSalesName"
@@ -250,9 +245,7 @@
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </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.accendant"
@@ -261,37 +254,66 @@
               clearable
               customStyle="padding: 0 30rpx 0 12rpx"></u-input>
           </u-form-item>
-          <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
+          <u-form-item prop="isAdoptDashoo" borderBottom customStyle="padding:40rpx 0 30rpx">
             <view class="form-label flex_l">
+              <view class="label-tag"></view>
               是否采纳大数技术参数
             </view>
-            <u-radio-group v-model="addForm.isAdoptDashoo" placement="row">
+            <u-radio-group v-model="addForm.isAdoptDashoo" placement="row" @change="chooseRadio">
               <u-radio customStyle="margin-right:40rpx" label="是" name="10"></u-radio>
               <u-radio customStyle="margin-right:40rpx" label="否" name="20"></u-radio>
             </u-radio-group>
           </u-form-item>
+          <u-form-item
+            prop="file"
+            borderBottom
+            customStyle="padding:40rpx 0 30rpx"
+            v-if="addForm.isAdoptDashoo == '10'">
+            <view class="form-label flex_l">
+              <view class="label-tag"></view>
+              文件
+            </view>
+            <uni-file-picker file-mediatype="all" mode="grid" @select="chooseFile($event)" ref="upload" limit="1">
+              <view class="upload-btn">
+                <u-icon name="plus-circle-fill" color="blue" size="28"></u-icon>
+              </view>
+            </uni-file-picker>
+          </u-form-item>
         </view>
-        <u-form-item prop="remark" customStyle="padding:40rpx 0 30rpx">
+        <u-form-item
+          prop="projConversionReason"
+          customStyle="padding:40rpx 0 30rpx"
+          v-if="addForm.isAdoptDashoo != '30'">
+          <view class="form-label flex_l">升级原因</view>
+          <u-textarea
+            fontSize="26rpx"
+            v-model="addForm.projConversionReason"
+            placeholder="请输入升级原因"
+            height="180"
+            :count="true"
+            maxlength="300"></u-textarea>
+        </u-form-item>
+        <u-form-item prop="remark" customStyle="padding:40rpx 0 30rpx" v-else>
           <view class="form-label flex_l">
             <view class="label-tag"></view>
-            备注原因
+            转化原因
           </view>
           <u-textarea
             fontSize="26rpx"
             v-model="addForm.remark"
-            placeholder="请输入备注原因"
+            placeholder="请输入转化原因"
             height="180"
             :count="true"
             maxlength="300"></u-textarea>
         </u-form-item>
       </u-form>
-      <view class="save" @click="handleDowngrade">提交</view>
+      <view class="save" @click="handleUpgrade">提交</view>
     </view>
     <!-- 技术支持时间 -->
     <u-datetime-picker
       v-if="showSupportDate"
       :show="showSupportDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.technicalSupportTime"
       @cancel="showSupportDate = false"
       @confirm="pickSupportDate"></u-datetime-picker>
@@ -299,7 +321,7 @@
     <u-datetime-picker
       v-if="showBudgetDate"
       :show="showBudgetDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.nboBudgetTime"
       @cancel="showBudgetDate = false"
       @confirm="pickBudgetDate"></u-datetime-picker>
@@ -307,7 +329,7 @@
     <u-datetime-picker
       v-if="showPurchasingDate"
       :show="showPurchasingDate"
-      mode="datetime"
+      mode="date"
       v-model="addForm.purchasingTime"
       @cancel="showPurchasingDate = false"
       @confirm="pickPurchasingDate"></u-datetime-picker>
@@ -329,7 +351,7 @@
       content="确认进行项目升级?"
       :showCancelButton="true"
       @cancel="this.showModal = false"
-      @confirm="this.handleDownApi()"></u-modal>
+      @confirm="this.handleUpgradeApi()"></u-modal>
   </view>
 </template>
 <script>
@@ -358,21 +380,24 @@
           technicalSupportName: '', //技术支持人员
           technicalSupportContent: null, //技术支持内容
           technicalSupportTime: '', //技术支持时间
-          nboBudgetTime: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //项目预算时间
+          nboBudgetTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //项目预算时间
           capitalSource: '', //资金来源
           productSatisfaction: '', //产品方案满足情况
           purchasingWay: '', //采购方式id
           purchasingWayVal: '', //采购方式
-          purchasingTime: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //采购时间
+          purchasingTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //采购时间
           makerId: '', //决策人
           makerName: '', //决策人
           makerDept: '', //决策部门
           historicalTransactionInfo: '', //输入经销商与客户历史成交信息
           dealerSalesName: '', //经销商销售人员
           accendant: '', //维护部门及人员
-          isAdoptDashoo: '', //是否是大项目选择
-          remark: '', //备注
+          isAdoptDashoo: '', //是否采纳大数技术参数
+          remark: '', //转化原因
+          projConversionReason: '', //升级原因
           id: 0, //项目id
+          file: '',
+          tempFilePaths: '',
         },
         showModal: false,
         projectDetails: {},
@@ -395,16 +420,34 @@
             message: '请输入项目预算',
             trigger: ['blur'],
           },
-          distributorName: {
+          purchasingWayVal: {
+            type: 'string',
+            required: true,
+            message: '请输入采购方式',
+            trigger: ['blur'],
+          },
+          technicalSupportTime: {
+            type: 'string',
+            required: true,
+            message: '请输入采购时间',
+            trigger: ['blur'],
+          },
+          isAdoptDashoo: {
             type: 'string',
             required: true,
-            message: '请选择经销商',
+            message: '请选择是否采纳大数技术参数',
             trigger: ['blur'],
           },
+          file: {
+            type: 'object',
+            required: true,
+            message: '请上传文件',
+            trigger: ['change'],
+          },
           remark: {
             type: 'string',
             required: true,
-            message: '请输入备注内容',
+            message: '请输入转化',
             trigger: ['blur'],
           },
         },
@@ -419,7 +462,7 @@
       console.log(option.id) //打印出上个页面传递的参数。
       this.addForm.id = parseInt(option.id)
     },
-    onShow() {
+    mounted() {
       this.getDetails()
       this.getOptions()
     },
@@ -440,8 +483,9 @@
           this.addForm.nboType = ''
           this.addForm.technicalSupportName = ''
           this.addForm.technicalSupportContent = ''
-          this.addForm.technicalSupportTime = this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}')
-          this.addForm.nboBudgetTime = this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}')
+          this.addForm.technicalSupportTime = this.parseTime(new Date(), '{y}-{m}-{d}')
+          this.addForm.nboBudgetTime = this.parseTime(new Date(), '{y}-{m}-{d}')
+          this.addForm.projConversionReason = ''
           this.addForm.remark = ''
         }
       },
@@ -506,7 +550,57 @@
         this.addForm.purchasingTime = timeValue
         console.log(timeValue)
       },
-      handleDowngrade() {
+      // 选择是否采用大数参数
+      chooseRadio(e) {
+        console.log(e)
+        if (e == '20') {
+          this.addForm.file = ''
+        }
+      },
+      // // 选择上传触发函数
+      chooseFile(e) {
+        this.addForm.file = e.tempFiles[0].file
+        this.addForm.tempFilePaths = e.tempFilePaths[0]
+      },
+      // 上传函数
+      async upgradeA(data) {
+        const basePath = process.uniEnv.VUE_APP_MicroSrvProxy_API + process.uniEnv.VUE_APP_ParentPath
+        uni.uploadFile({
+          url: basePath,
+          filePath: data.tempFilePaths,
+          name: 'file',
+          formData: data,
+          header: {
+            Tenant: process.uniEnv.VUE_APP_TENANT,
+            Authorization: 'Bearer ' + uni.getStorageSync('opms_token') || '',
+            'X-RPCX-SerializeType': '1',
+            'X-RPCX-ServicePath': 'BusinessHandler',
+            'X-RPCX-ServiceMethod': 'BusinessUpgradeA',
+            SrvEnv: 'dev',
+          },
+          success: (res) => {
+            console.log('success', res)
+            this.$refs.uToast.show({
+              type: 'success',
+              message: '提交成功',
+              complete: () => {
+                this.goBack()
+              },
+            })
+          },
+          fail: (err) => {
+            this.$refs.uToast.show({
+              type: 'success',
+              message: '提交失败',
+            })
+            console.log('error', err)
+          },
+          complete: () => {
+            this.showModal = false
+          },
+        })
+      },
+      handleUpgrade() {
         this.$refs.addForm
           .validate()
           .then(async () => {
@@ -522,20 +616,24 @@
             })
           })
       },
-      async handleDownApi() {
+      async handleUpgradeApi() {
         let params = this.addForm
         params.nboBudget = Number(params.nboBudget)
-        const [err, res] = await to(projectApi.upgrade(params))
-        this.showModal = false
-        if (err) return
-        if (res && res.code == 200) {
-          this.$refs.uToast.show({
-            type: 'success',
-            message: '提交成功',
-            complete: () => {
-              this.goBack()
-            },
-          })
+        if (this.addForm.nboType === '10' && this.addForm.isAdoptDashoo == '10') {
+          this.upgradeA(params)
+        } else {
+          const [err, res] = await to(projectApi.upgrade(params))
+          this.showModal = false
+          if (err) return
+          if (res && res.code == 200) {
+            this.$refs.uToast.show({
+              type: 'success',
+              message: '提交成功',
+              complete: () => {
+                this.goBack()
+              },
+            })
+          }
         }
       },
       closeUser(user) {
@@ -605,7 +703,7 @@
         .label-tag {
           width: 15rpx;
           height: 15rpx;
-          background:  #ff4d4f;
+          background: #ff4d4f;
           border-radius: 50%;
           margin-right: 10rpx;
         }

+ 70 - 45
pages/publicPages/follow.vue

@@ -22,7 +22,12 @@
       <u-form :model="addForm" :rules="rules" ref="addForm" label-width="0">
         <u-form-item prop="content" customStyle="padding:40rpx 0 34rpx">
           <view class="form-label flex_l">跟进内容</view>
-          <u-textarea v-model="addForm.content" placeholder="请输入跟进内容" maxlength="800" height="190rpx" count
+          <u-textarea
+            v-model="addForm.content"
+            placeholder="请输入跟进内容"
+            maxlength="800"
+            height="190rpx"
+            count
             customStyle="border-radius:16rpx"></u-textarea>
         </u-form-item>
         <u-form-item prop="date" borderBottom customStyle="padding:40rpx 0 30rpx" @click="showDate = true">
@@ -30,31 +35,50 @@
             <view class="label-tag"></view>
             跟进时间
           </view>
-          <u-input :readonly="true" placeholder="请选择跟进时间" v-model="addForm.date" border="none" suffixIcon="arrow-down"
-            suffixIconStyle="color:#CDCDCD" clearable customStyle="padding: 0 30rpx 0 12rpx"></u-input>
+          <u-input
+            :readonly="true"
+            placeholder="请选择跟进时间"
+            v-model="addForm.date"
+            border="none"
+            suffixIcon="arrow-down"
+            suffixIconStyle="color:#CDCDCD"
+            clearable
+            customStyle="padding: 0 30rpx 0 12rpx"></u-input>
         </u-form-item>
         <u-form-item prop="mode" borderBottom customStyle="padding:40rpx 0 30rpx" @click="showMode = true">
           <view class="form-label flex_l">
             <view class="label-tag"></view>
             跟进方式
           </view>
-          <u-input :readonly="true" placeholder="请选择跟进方式" v-model="addForm.mode" border="none" suffixIcon="arrow-down"
-            suffixIconStyle="color:#CDCDCD" clearable customStyle="padding: 0 30rpx 0 12rpx"></u-input>
+          <u-input
+            :readonly="true"
+            placeholder="请选择跟进方式"
+            v-model="addForm.mode"
+            border="none"
+            suffixIcon="arrow-down"
+            suffixIconStyle="color:#CDCDCD"
+            clearable
+            customStyle="padding: 0 30rpx 0 12rpx"></u-input>
         </u-form-item>
         <u-form-item prop="contactsName" borderBottom customStyle="padding:40rpx 0 30rpx" @click="open">
           <view class="form-label flex_l">
             <view class="label-tag"></view>
             联系人
           </view>
-          <u-input :readonly="true" placeholder="请选择客户联系人" v-model="addForm.contactsName" border="none"
-            suffixIcon="arrow-down" suffixIconStyle="color:#CDCDCD" clearable customStyle="padding: 0 30rpx 0 12rpx">
-          </u-input>
+          <u-input
+            :readonly="true"
+            placeholder="请选择客户联系人"
+            v-model="addForm.contactsName"
+            border="none"
+            suffixIcon="arrow-down"
+            suffixIconStyle="color:#CDCDCD"
+            clearable
+            customStyle="padding: 0 30rpx 0 12rpx"></u-input>
         </u-form-item>
       </u-form>
       <view class="upload-file-box">
         <view class="form-label flex_l">附件</view>
-        <uni-file-picker file-mediatype="all" v-model="imageValue" mode="grid" @select="select" @progress="progress"
-          @success="success" @fail="fail" ref="upload" limit="1">
+        <uni-file-picker file-mediatype="all" v-model="imageValue" mode="grid" @select="select" ref="upload" limit="1">
           <view class="upload-btn">
             <u-icon name="plus-circle-fill" color="blue" size="28"></u-icon>
           </view>
@@ -62,11 +86,20 @@
       </view>
       <view class="save" @click="handleAdd">保存</view>
       <!-- 选择跟进方式 -->
-      <u-picker :show="showMode" :columns="modeColumns" keyName="label" @cancel="showMode = false" @confirm="pickMode">
-      </u-picker>
+      <u-picker
+        :show="showMode"
+        :columns="modeColumns"
+        keyName="label"
+        @cancel="showMode = false"
+        @confirm="pickMode"></u-picker>
       <!-- 选择下次时间 -->
-      <u-datetime-picker v-if="showDate" :show="showDate" mode="datetime" v-model="addForm.date"
-        @cancel="showDate = false" @confirm="pickDate"></u-datetime-picker>
+      <u-datetime-picker
+        v-if="showDate"
+        :show="showDate"
+        mode="datetime"
+        v-model="addForm.date"
+        @cancel="showDate = false"
+        @confirm="pickDate"></u-datetime-picker>
     </view>
     <u-notify ref="uNotify"></u-notify>
     <u-toast ref="uToast"></u-toast>
@@ -77,9 +110,7 @@
   </view>
 </template>
 <script>
-  import {
-    mapGetters
-  } from 'vuex'
+  import { mapGetters } from 'vuex'
   import to from 'await-to-js'
   import followApi from '../../api/follow'
   import custApi from '../../api/customer'
@@ -90,7 +121,7 @@
     name: 'omsIndex',
     components: {
       CustomerContact,
-      ProjectContact
+      ProjectContact,
     },
     data() {
       return {
@@ -100,7 +131,8 @@
         showMode: false, //选择行业
         showDate: false,
         modeColumns: [
-          [{
+          [
+            {
               label: '电话',
               id: '10',
             },
@@ -116,7 +148,7 @@
         ],
         addForm: {
           files: [],
-          date: this.parseTime(new Date(), '{y}-{m}-{d} {h}:{i}'), //时间
+          date: this.parseTime(new Date(), '{y}-{m}-{d}'), //时间
           content: '', //客户姓名
           mode: '', //跟进方式
           modeId: 0,
@@ -177,18 +209,22 @@
       async initData() {
         if (this.targetType == '10') {
           //客户
-          const [err, res] = await to(custApi.getDetail({
-            ids: [this.curId]
-          }))
+          const [err, res] = await to(
+            custApi.getDetail({
+              ids: [this.curId],
+            })
+          )
           if (err) return
           if (res && res.code == 200) {
             this.details = res.data.list[0]
           }
         } else if (this.targetType == '20') {
           //项目
-          const [err, res] = await to(prodApi.getDetail({
-            id: this.curId
-          }))
+          const [err, res] = await to(
+            prodApi.getDetail({
+              id: this.curId,
+            })
+          )
           if (err) return
           if (res && res.code == 200) {
             this.details = res.data
@@ -247,7 +283,8 @@
                 targetName: this.details.nboName,
               }
             }
-            let params = Object.assign({
+            let params = Object.assign(
+              {
                 contactsId: this.addForm.contactsId,
                 contactsName: this.addForm.contactsName,
                 followContent: this.addForm.content,
@@ -309,28 +346,16 @@
               type: 'success',
               message: '附件上传成功',
             })
-            this.addForm.files = [{
-              fileName: e.tempFiles[0].file.name,
-              fileUrl: action
-            }]
+            this.addForm.files = [
+              {
+                fileName: e.tempFiles[0].file.name,
+                fileUrl: action,
+              },
+            ]
           },
           fail: (err) => {},
         })
       },
-      // 获取上传进度
-      progress(e) {
-        console.log('上传进度:', e)
-      },
-
-      // 上传成功
-      success(e) {
-        console.log('上传成功')
-      },
-
-      // 上传失败
-      fail(e) {
-        console.log('上传失败:', e)
-      },
       goBack() {
         uni.navigateBack({
           //关闭当前页面,返回上一页面或多级页面。

+ 2 - 6
pages/schedule/index.vue

@@ -39,8 +39,8 @@
       </view>
       <view class="content">
         <manage v-if="curTabIndex === 0" ref="manage" @setBackVisible="initBack()" />
-        <supervise v-if="curTabIndex === 1" ref="supervise" />
-        <log v-if="curTabIndex === 2" ref="log" />
+        <supervise v-else-if="curTabIndex === 1" ref="supervise" />
+        <log v-else-if="curTabIndex === 2" ref="log" />
       </view>
     </view>
   </view>
@@ -76,7 +76,6 @@
       }
     },
     onLoad(option) {
-      console.log(option.type) //打印出上个页面传递的参数。
       if (option && option.type) {
         this.curTabIndex = parseInt(option.type)
       }
@@ -89,9 +88,6 @@
       this.height = navData.height + 'px'
       this.paddingTop = navData.top + 'px'
     },
-    mounted(option) {
-      console.log(option)
-    },
     methods: {
       // 显示返回
       initBack(visible) {

+ 3 - 1
pages/schedule/manage.vue

@@ -111,7 +111,7 @@
         }
       },
     },
-    async mounted() {
+    mounted() {
       this.getWeek()
       this.getTodoData()
     },
@@ -145,8 +145,10 @@
             String(date.getDate()).padStart(2, '0')
           )
         })
+        console.log(daysOfThisWeek)
         // 当前周的全部日期
         this.calendarList = daysOfThisWeek
+        console.log('calendarList', this.calendarList)
         //   当前日期
         this.currentDay = daysOfThisWeek[dayOfToday]
       },

+ 262 - 0
pages/schedule/supervise/components/progress.vue

@@ -0,0 +1,262 @@
+<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>
+            <u-icon
+              name="plus-circle"
+              color="#2979ff"
+              size="28"
+              @click="addProgress()"
+              v-if="details.taskStatus === '20' && details.step === 20 && type == 1"></u-icon>
+          </view>
+        </u-col>
+      </u-row>
+    </view>
+    <!-- 进展列表 -->
+    <view class="evolve-wrap" v-if="details.taskStatus === '20' && details.step === 20 && type == 1">
+      <view class="evolve-item" v-for="(v, i) in progressList" :key="i">
+        <view class="evolve-row split-line">
+          <view class="no mb12">{{ i + 1 }}</view>
+          <u-row justify="space-between" gutter="10">
+            <u-col span="3">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="时间"></u-text>
+            </u-col>
+            <u-col span="9" @click="openCalendar(i)">
+              <!-- <u-text :bold="true" customStyle="margin-bottom:12rpx" text="2022-11-11"></u-text> -->
+              <u-input :readonly="true" v-model="v.progDate"></u-input>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="进展描述"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <!-- <view class="desc mb12">2022-11-11</view> -->
+              <u-input v-model="v.progDesc"></u-input>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="附件"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <uni-file-picker file-mediatype="all" mode="grid" @select="select($event, i)" ref="upload" limit="1">
+                <view class="upload-btn">
+                  <u-icon name="plus-circle-fill" color="blue" size="28"></u-icon>
+                </view>
+              </uni-file-picker>
+              <!-- <view class="file mb12">测试啥.ppt</view> -->
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="备注"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <!-- <view class="file">备注备注备注备注备注备注备注</view> -->
+              <u-input v-model="v.remark"></u-input>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row" @click="handleDel()">
+          <u-text color="#2979ff" text="删除"></u-text>
+        </view>
+      </view>
+    </view>
+    <view class="evolve-wrap" v-else>
+      <view class="evolve-item" v-for="(v, i) in progressList" :key="i">
+        <view class="evolve-row split-line">
+          <view class="no mb12">{{ i + 1 }}</view>
+          <u-row justify="space-between" gutter="10">
+            <u-col span="3">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="时间"></u-text>
+            </u-col>
+            <u-col span="9">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" :text="v.progDate"></u-text>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="进展描述"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <view class="desc mb12">{{ v.progDesc }}</view>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="附件"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <view class="file mb12">{{ v.progFile }}</view>
+            </u-col>
+          </u-row>
+        </view>
+        <view class="evolve-row split-line">
+          <u-row gutter="10">
+            <u-col span="12">
+              <u-text :bold="true" customStyle="margin-bottom:12rpx" text="备注"></u-text>
+            </u-col>
+          </u-row>
+          <u-row>
+            <u-col span="12">
+              <view class="file">{{ v.remark }}</view>
+            </u-col>
+          </u-row>
+        </view>
+      </view>
+    </view>
+    <!-- 提示 -->
+    <u-toast ref="uToast"></u-toast>
+    <!-- 日历 -->
+    <u-calendar :show="showCalendar" @confirm="confirmCalendar" @close="showCalendar = false"></u-calendar>
+  </view>
+</template>
+
+<script>
+  import taskApi from '@/api/task'
+  export default {
+    props: {
+      details: {
+        type: Object,
+        default: {},
+      },
+      type: {
+        type: Number,
+        default: 0,
+      },
+    },
+    data() {
+      return {
+        curCalendarIndex: 0,
+        progressList: [],
+        showCalendar: false,
+      }
+    },
+    mounted() {
+      this.getProgressList()
+      console.log(this.details)
+    },
+    methods: {
+      // 获取进展信息
+      getProgressList() {
+        this.progressList = []
+        taskApi
+          .getTaskProgressList({ taskId: this.details.id + '' })
+          .then((res) => {
+            if (res.data.list) {
+              this.progressList = res.data.list
+            }
+          })
+          .catch((err) => {
+            console.error(err)
+          })
+      },
+      // 添加进展
+      addProgress() {
+        this.progressList.push({ progDesc: '', progDate: '', progFile: '', remark: '' })
+      },
+      // 删除进展
+      handleDel(index) {
+        this.progressList.splice(index, 1)
+      },
+      openCalendar(index) {
+        this.showCalendar = true
+        this.curCalendarIndex = index
+      },
+      confirmCalendar(val) {
+        this.progressList[this.curCalendarIndex].progDate = val[0]
+        this.showCalendar = false
+      },
+      // // 选择上传触发函数
+      select(e, index) {
+        console.log(e, index)
+        let url = process.uniEnv.VUE_APP_UPLOAD_WEED
+        uni.request({
+          url, //仅为示例,并非真实接口地址。
+          success: (res) => {
+            this.uploadFiles(e, res.data, index)
+          },
+        })
+      },
+      // 上传函数
+      async uploadFiles(e, res, index) {
+        let action = process.uniEnv.VUE_APP_PROTOCOL + res.publicUrl + '/' + res.fid
+        uni.uploadFile({
+          url: action,
+          filePath: e.tempFilePaths[0],
+          name: 'file',
+          formData: {
+            file: e.tempFiles[0].file,
+          },
+          success: (res) => {
+            this.$refs.uToast.show({
+              type: 'success',
+              message: '附件上传成功',
+            })
+            this.progressList[index].progFile = action
+          },
+        })
+      },
+    },
+  }
+</script>
+
+<style lang="scss" scoped>
+  .info-item {
+    padding: 20rpx;
+    .label {
+      color: #646464;
+      font-size: 26rpx;
+    }
+    .desc {
+      font-size: 26rpx;
+      text-indent: 20rpx;
+    }
+  }
+  .evolve-wrap {
+    .evolve-item {
+      margin-bottom: 20rpx;
+      .evolve-row {
+        padding: 20rpx;
+      }
+      .split-line {
+        border-bottom: 1px solid #e6e6e6;
+      }
+      border: 1px solid #e6e6e6;
+      border-radius: 10px;
+      .no {
+        width: 50rpx;
+        height: 50rpx;
+        background: #78b0ed;
+        border-radius: 50%;
+        text-align: center;
+        line-height: 50rpx;
+        color: #fff;
+      }
+    }
+  }
+</style>

+ 0 - 131
pages/schedule/supervise/components/taskDetails.vue

@@ -1,131 +0,0 @@
-<!--
- * @Author: liuzhenlin 461480418@qq.ocm
- * @Date: 2023-02-15 16:25:58
- * @LastEditors: liuzhenlin
- * @LastEditTime: 2023-03-06 16:12:12
- * @Description: file content
- * @FilePath: \oms\pages\schedule\supervise\components\taskDetails.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.taskDesc }}</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">{{ parseTime(detail.taskEndDate, '{y}-{m}-{d}') }}</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">{{ selectDictLabel(userList, detail.mainUserId) }}</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">{{ generateOwnerUser(detail.ownerUserId) }}</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">{{ selectDictLabel(userList, detail.watchUserId) }}</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">{{ selectDictLabel(userList, detail.supervisorUserId) }}</view>
-          </view>
-        </u-col>
-      </u-row>
-    </view>
-  </view>
-</template>
-
-<script>
-  export default {
-    props: {
-      detail: {
-        type: [Object],
-        default: {},
-      },
-      taskTypeOption: {
-        type: [Array],
-        default: [],
-      },
-      sourceOption: {
-        type: [Array],
-        default: [],
-      },
-      userList: {
-        type: [Array],
-        default: [],
-      },
-    },
-    data() {
-      return {}
-    },
-
-    mounted() {},
-
-    methods: {
-      // 协办人
-      generateOwnerUser(ids = null) {
-        let nameArr = []
-        if (ids) {
-          let idList = ids.split(',')
-          console.log(idList)
-          idList.forEach((item) => {
-            let findUser = this.userList.find((user) => user.key == item)
-            console.log(findUser)
-            if (findUser.value) nameArr.push(findUser.value)
-          })
-        }
-        return nameArr.join(',')
-      },
-    },
-  }
-</script>
-
-<style lang="scss" scoped>
-  .info-item {
-    padding: 20rpx;
-    .label {
-      color: #646464;
-      font-size: 26rpx;
-    }
-    .desc {
-      font-size: 26rpx;
-      text-indent: 20rpx;
-    }
-  }
-</style>

+ 147 - 64
pages/schedule/supervise/details.vue

@@ -2,7 +2,7 @@
  * @Author: liuzhenlin 461480418@qq.ocm
  * @Date: 2023-01-12 11:57:48
  * @LastEditors: liuzhenlin
- * @LastEditTime: 2023-03-06 15:57:46
+ * @LastEditTime: 2023-03-07 17:17:24
  * @Description: file content
  * @FilePath: \oms\pages\schedule\supervise\details.vue
 -->
@@ -26,7 +26,7 @@
               <image class="img" src="@/static/images/menu2.png" mode="scaleToFill" />
               <text>{{ details.taskTitle }}</text>
             </view>
-            <view class="date">{{ parseTime(details.taskStartDate, '{y}-{m}-{d} {h}:{i}') || '-' }}</view>
+            <view class="date">{{ parseTime(details.taskStartDate, '{y}-{m}-{d}') || '-' }}</view>
           </view>
           <view class="info">
             <view class="info-item">
@@ -65,7 +65,7 @@
             </view>
           </view>
         </view>
-        <view class="tabs">
+        <!-- <view class="tabs">
           <u-tabs
             @change="changeTabs"
             :current="curTabIndex"
@@ -78,39 +78,106 @@
             :inactiveStyle="{
               color: '#969696',
             }"></u-tabs>
-        </view>
+        </view> -->
       </view>
       <view class="data-list">
-        <task-details
-          v-if="curTabIndex == 0"
-          :detail="details"
-          :taskTypeOption="taskTypeOption"
-          :sourceOption="sourceOption"
-          :userList="userList"></task-details>
+        <view class="detail-wrap">
+          <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">{{ details.taskDesc }}</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">{{ parseTime(details.taskEndDate, '{y}-{m}-{d}') }}</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">{{ selectDictLabel(userList, details.mainUserId) }}</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">{{ generateOwnerUser(details.ownerUserId) }}</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">{{ selectDictLabel(userList, details.watchUserId) }}</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">{{ selectDictLabel(userList, details.supervisorUserId) }}</view>
+                </view>
+              </u-col>
+            </u-row>
+          </view>
+          <o-progress ref="progress" :details="details" :type="type"></o-progress>
+        </view>
       </view>
     </view>
     <!-- 新增按钮 -->
-    <view class="fixed-btn-group" :style="{ width: openBtnWidth ? '480rpx' : '90rpx' }">
-      <view class="flex1" v-if="openBtnWidth">
-        <view class="btn center" @click="linkToLevel(1)">升</view>
-      </view>
-      <view class="btn center" @click="openBtnWidth = !openBtnWidth">
-        <u-icon name="plus" color="#fff" size="20"></u-icon>
+    <view class="fixed-btn-group">
+      <view class="btn center" v-show="details.taskStatus === '10' && type == 1" @click="changeStatus(10)">接</view>
+      <view
+        class="btn center"
+        v-show="details.taskStatus === '20' && details.step === 20 && type == 1"
+        @click="changeStatus(20)">
+        提
       </view>
     </view>
+    <!-- 确认接收 -->
+    <u-modal
+      :show="modalVisible"
+      @confirm="confirmChangeStatus"
+      ref="uModal"
+      :asyncClose="true"
+      :showCancelButton="true"
+      :content="content"></u-modal>
+    <!-- 提示 -->
+    <u-toast ref="uToast"></u-toast>
   </view>
 </template>
 <script>
   import taskApi from '@/api/task'
   import userApi from '@/api/system/user'
   import to from 'await-to-js'
-  import TaskDetails from './components/taskDetails'
+  import OProgress from './components/progress'
   export default {
     name: 'omsIndex',
-    components: { TaskDetails },
+    components: { OProgress },
     data() {
       return {
-        openBtnWidth: false,
         height: '',
         paddingTop: '',
         curTabIndex: 0,
@@ -123,10 +190,6 @@
             name: '进展情况',
             index: 1,
           },
-          {
-            name: '联系人',
-            index: 2,
-          },
         ],
         taskId: 0, //项目id
         details: {}, //督办列表
@@ -155,10 +218,16 @@
             value: '撤销',
           },
         ], //督办状态
+        type: 0, //是否为我的待办
+        modalVisible: false,
+        progressVisible: false,
+        content: '',
+        step: '',
       }
     },
     onLoad(option) {
       this.taskId = option.id
+      this.type = option.type
       this.getOptions()
     },
     created() {
@@ -166,9 +235,6 @@
       this.height = navData.height + 'px'
       this.paddingTop = navData.top + 'px'
     },
-    onShow() {
-      this.getOptions()
-    },
     methods: {
       // 改变tab
       changeTabs(data) {
@@ -197,13 +263,14 @@
           idList.forEach((item) => {
             let findUser = this.userList.find((user) => user.key == item)
             console.log(findUser)
-            if (findUser.value) nameArr.push(findUser.value)
+            if (findUser && findUser.value) nameArr.push(findUser.value)
           })
         }
         return nameArr.join(',')
       },
       async getDetails() {
         let params = {
+          operateType: this.type,
           taskId: this.taskId,
         }
         const [err, res] = await to(taskApi.getList(params))
@@ -212,12 +279,40 @@
         }
         if (res && res.code == 200) {
           this.details = res.data.list[0] || {}
+          console.log(this.details)
+        }
+      },
+      // 接收待办
+      changeStatus(step) {
+        this.modalVisible = true
+        this.step = step
+        if (step == 10) this.content = '确认接收督办?'
+        else if (step == 20) this.content = '确认提交督办?'
+      },
+      async confirmChangeStatus() {
+        let params = {
+          taskId: parseInt(this.taskId),
+          step: this.step,
+          handleStatus: '' + this.step,
+          handleDesc: '',
+          progressList: this.$refs.progress.progressList,
+        }
+        const [err, res] = await to(taskApi.handleTask(params))
+        if (err) return
+        if (res && res.code == 200) {
+          this.modalVisible = false
+          this.$refs.uToast.show({
+            type: 'success',
+            message: '提交成功',
+            complete: () => {
+              this.goBack()
+            },
+          })
         }
       },
       goBack() {
-        uni.navigateBack({
-          //关闭当前页面,返回上一页面或多级页面。
-          delta: 1,
+        uni.reLaunch({
+          url: '/pages/schedule/index?type=1',
         })
       },
     },
@@ -311,24 +406,21 @@
       .data-list {
         margin-top: 16rpx;
         width: 100%;
-        height: calc(100vh - 532rpx);
+        height: calc(100vh - 446rpx);
         background: #ffffff;
         padding: 32rpx;
         overflow: auto;
-        padding-bottom: 145rpx;
-      }
-      .details-wrap {
-        background: #f6f7fb;
-        border: 1px solid #ceccca;
-        border-radius: 20rpx;
-        margin-bottom: 32rpx;
-        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12), 0 0 6px rgba(0, 0, 0, 0.04);
-        .header {
-          padding: 30rpx 30rpx 15rpx;
-          border-bottom: 2rpx solid #ceccca;
-        }
-        .content {
-          padding: 15rpx 30rpx 30rpx;
+        // padding-bottom: 145rpx;
+        .info-item {
+          padding: 20rpx;
+          .label {
+            color: #646464;
+            font-size: 26rpx;
+          }
+          .desc {
+            font-size: 26rpx;
+            text-indent: 20rpx;
+          }
         }
       }
     }
@@ -337,27 +429,18 @@
       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;
-      .red {
-        background: #ff4d4f !important;
-      }
-      .btn {
-        width: 60rpx;
-        height: 60rpx;
-        background: #3e7ef8;
-        border-radius: 50%;
-        margin: 10rpx;
-        font-size: 26rpx;
-        font-weight: bold;
-        color: #ffffff;
-      }
+    }
+    .btn {
+      width: 90rpx;
+      height: 90rpx;
+      border-radius: 50%;
+      background: #3e7ef8;
+      color: #ffffff;
+    }
+    .mb12 {
+      margin-bottom: 12rpx;
     }
   }
 </style>

+ 3 - 5
pages/schedule/supervise/index.vue

@@ -110,7 +110,7 @@
 
     data() {
       return {
-        curTabIndex: 2, //tabs状态
+        curTabIndex: 1, //tabs状态
         loadStatus: '', //加载状态
         list: [
           {
@@ -182,11 +182,9 @@
         let nameArr = []
         if (ids) {
           let idList = ids.split(',')
-          console.log(idList)
           idList.forEach((item) => {
             let findUser = this.userList.find((user) => user.key == item)
-            console.log(findUser)
-            if (findUser.value) nameArr.push(findUser.value)
+            if (findUser && findUser.value) nameArr.push(findUser.value)
           })
         }
         return nameArr.join(',')
@@ -200,7 +198,7 @@
       linkToDetail(v) {
         uni.navigateTo({
           //保留当前页面,跳转到应用内的某个页面
-          url: '/pages/schedule/supervise/details?id=' + v.id,
+          url: '/pages/schedule/supervise/details?id=' + v.id + '&type=' + this.curTabIndex,
         })
       },
       searchList() {

BIN
static/images/home1.png


BIN
static/images/swiper/banner1.png


BIN
static/images/swiper/banner2.png


BIN
static/images/swiper/banner3.png


BIN
static/images/user.jpg


+ 8 - 0
style/common.scss

@@ -186,4 +186,12 @@ view {
         background: $u-primary;
         color: #ffffff;
     }
+}
+
+.data-list {
+    .info-item {
+        .label {
+            min-width: 130rpx;
+        }
+    }
 }