wenningning 2 лет назад
Родитель
Сommit
1642c4e9cc

+ 13 - 11
app.js

@@ -78,21 +78,23 @@ App({
     todayOrderNum:0,
     /** 今日订单金额 */
     todayOrderTotal:0,
+    /** 待处理售后订单 */
+    saleOrderTotal: 0,
     /** api 模式 */
     api_mode: 'prod',
     /** api域名 */
-	api_domain:{
-		api_base: 'http://192.168.1.199:7000/',//''https://dev.base.wdklian.com/',//,
-		api_buyer: 'http://192.168.1.199:7002/',//'https://api.buyer.wdklian.com/',//
-		api_seller: 'http://192.168.1.199:7003/',//'https://api.seller.wdklian.com/',//
-		api_admin: 'http://192.168.1.199:7004/',//'https://api.admin.wdklian.com/', //
-  }
-  // api_domain:{
-  //   api_base: 'https://api.base.wdklian.com/',//,'https://api.base.wdklian.com/',//''https://dev.base.wdklian.com/',//,
-	// 	api_buyer: 'https://api.buyer.wdklian.com/',//'http://192.168.1.199:7002/',//'https://api.buyer.wdklian.com/',///'https://api.buyer.wdklian.com/',//
-	// 	api_seller: 'https://api.seller.wdklian.com/',//'http://192.168.1.199:7003/',//'https://api.seller.wdklian.com/',//
-	// 	api_admin: 'https://api.admin.wdklian.com/', //'http://192.168.1.199:7004/',//'https://api.admin.wdklian.com/', //
+	// api_domain:{
+	// 	api_base: 'http://192.168.1.199:7000/',//''https://dev.base.wdklian.com/',//,
+	// 	api_buyer: 'http://192.168.1.199:7002/',//'https://api.buyer.wdklian.com/',//
+	// 	api_seller: 'http://192.168.1.199:7003/',//'https://api.seller.wdklian.com/',//
+	// 	api_admin: 'http://192.168.1.199:7004/',//'https://api.admin.wdklian.com/', //
   // }
+  api_domain:{
+    api_base: 'https://api.base.wdklian.com/',//,'https://api.base.wdklian.com/',//''https://dev.base.wdklian.com/',//,
+		api_buyer: 'https://api.buyer.wdklian.com/',//'http://192.168.1.199:7002/',//'https://api.buyer.wdklian.com/',///'https://api.buyer.wdklian.com/',//
+		api_seller: 'https://api.seller.wdklian.com/',//'http://192.168.1.199:7003/',//'https://api.seller.wdklian.com/',//
+		api_admin: 'https://api.admin.wdklian.com/', //'http://192.168.1.199:7004/',//'https://api.admin.wdklian.com/', //
+  }
 
   }
 

+ 1 - 1
custom-tab-bar/index.js

@@ -16,7 +16,7 @@ Component({
     list: [
       {
         icon: 'todo-list-o',
-        text: '订单处理',
+        text: '订单发货',
         url: '/pages/index/index'
       },
       {

+ 12 - 23
pages/aftersale/index.js

@@ -146,31 +146,20 @@ Page({
           refund_price: price
         }
         API_Refund.refundAuth(sn, _params).then((res) => {
-          if (res.agree) {
-            $wuxToptips().success({
-              hidden: false,
-              text: '操作成功',
-              duration: 3000,
-              success: () => {
-                that.setData({
-                  ['pageParam.page_no']: 1,
-                  finished: false,
-                  orderList: []
-                })
-                that.getRefundList()
-              }
-            })
-          } else {
-            $wuxToptips().error({
-              icon: 'cancel',
-              hidden: false,
-              text: res.message,
-              duration: 3000
-            })
-          }
+          that.setData({
+            ['pageParam.page_no']: 1,
+            finished: false,
+            orderList: []
+          })
+          that.getRefundList()
+          $wuxToptips().success({
+            hidden: false,
+            text: '操作成功',
+            duration: 3000
+          })
         })
       },
       onCancel(e){}
     })
   }
-})
+})

+ 1 - 1
pages/aftersale/index.wxml

@@ -72,7 +72,7 @@
 </wux-cell-group>
 <view class="btns">
 <van-button type="primary" wx:if="{{item.refund.after_sale_operate_allowable.allow_seller_approval}}" data-sn="{{item.refund.sn}}" data-agree="1" data-price="{{item.refund.refund_price}}" size="small" bindtap="handleRefundAuth">同意</van-button>
-<van-button type="danger" wx:if="{{item.refund.after_sale_operate_allowable.allow_seller_approval}}" data-sn="{{item.sn}}" data-agree="0" size="small" class="wux-ml--15" bindtap="handleRefundAuth">拒绝</van-button>
+<van-button type="danger" wx:if="{{item.refund.after_sale_operate_allowable.allow_seller_approval}}" data-sn="{{item.refund.sn}}" data-agree="0" data-price="{{item.refund.refund_price}}" size="small" class="wux-ml--15" bindtap="handleRefundAuth">拒绝</van-button>
 </view>
 </view>
 </view>

+ 1 - 1
pages/index/index.wxml

@@ -1,4 +1,4 @@
-<!--订单处理-->
+<!--订单发货-->
 <view wx:if="{{!loading}}">
 <wxs module="dateUtil" src="../../utils/dateTime.wxs"></wxs>
 <view class="order-panel cu-card article" wx:if="{{orderList.length>0}}">

+ 2 - 0
pages/store/index.js

@@ -18,6 +18,7 @@ Page({
     shops: [],
     todayOrderNum: 0,
     todayOrderTotal: 0,
+    saleOrderTotal: 0,
     boolOnline: false,
     loaded:false,
       shopAdminMemberId: null,
@@ -257,6 +258,7 @@ Page({
 	      loaded:true,
 		  todayOrderNum: app.globalData.todayOrderNum,
 		  todayOrderTotal: app.globalData.todayOrderTotal,
+          saleOrderTotal: app.globalData.saleOrderTotal
 		  })
 
 		  let i = 0;

+ 7 - 1
pages/store/index.wxml

@@ -71,7 +71,13 @@
     <wux-icon type="ios-search" color="#11c1f3"  slot="header" />
     </wux-grid>
     <wux-grid  label="售后订单" data-name="aftersale" bind:click="gridClick" >
-    <wux-icon type="ios-refresh" color="#11c1f3"  slot="header" />
+        <view class="ribbon1">
+          <text wx:if="{{saleOrderTotal > 99}}">99+</text>
+          <text wx:else>{{saleOrderTotal}}</text>
+<!--          {{saleOrderTotal}}-->
+        </view>
+        <wux-icon type="ios-refresh" color="#11c1f3"  slot="header" />
+
     </wux-grid>
 
 <!--    <wux-grid label="结算管理" data-name="bill" bind:click="gridClick" >-->

+ 18 - 3
pages/store/index.wxss

@@ -32,7 +32,7 @@ page{
   color: #fff;
   display: flex;
   justify-items: right;
-  margin-top: 50rpx;  
+  margin-top: 50rpx;
 }
 
   .today-count{text-align: center;margin:20rpx;}
@@ -45,7 +45,7 @@ page{
     text-align: center;
   }
   .store-menu-item image{
-   
+
   }
   .authorization{
   z-index: 10000;
@@ -53,4 +53,19 @@ page{
 }
 .btn-area{
   padding:35rpx;
-}
+}
+.ribbon1 {
+  line-height: 18rpx;
+  text-align: center;
+  /*transform: rotate(-45deg);*/
+  position: absolute;
+  padding: 8rpx;
+  right: 45rpx;
+  top: 35rpx;
+  /*width: 50rpx;*/
+  height: 35rpx;
+  background: red;
+  color: white;
+  letter-spacing: 1rpx;
+  border-radius: 80%
+}

+ 1 - 1
project.config.json

@@ -35,7 +35,7 @@
     "compileType": "miniprogram",
     "libVersion": "2.8.1",
     "appid": "wxe95ca6dc3c58aed4",
-    "projectname": "B2b2cSeller",
+    "projectname": "mp_seller",
     "simulatorType": "wechat",
     "simulatorPluginLibVersion": {},
     "condition": {

+ 1 - 1
project.private.config.json

@@ -1,6 +1,6 @@
 {
     "description": "项目私有配置文件。此文件中的内容将覆盖 project.config.json 中的相同字段。项目的改动优先同步到此文件中。详见文档:https://developers.weixin.qq.com/miniprogram/dev/devtools/projectconfig.html",
-    "projectname": "B2b2cSeller",
+    "projectname": "mp-seller",
     "setting": {
         "compileHotReLoad": true
     }

+ 1 - 0
utils/common.js

@@ -162,6 +162,7 @@ export function getCurrentShopData(){
             .then(res => {
                 app.globalData.sellerShop = res[0]
                 wx.setStorageSync('sellerShop', res[0])
+                app.globalData.saleOrderTotal = res[1].after_sale_order_num
                 app.globalData.orderNum = res[1].wait_ship_order_num
                 app.globalData.todayOrderNum = res[1].today_order_num
                 app.globalData.todayOrderTotal=res[1].today_order_total