Explorar o código

商品管理规则修复

ltx529596 %!s(int64=4) %!d(string=hai) anos
pai
achega
86c049469c

+ 7 - 7
src/manifest.json

@@ -1,9 +1,9 @@
 {
     "name" : "休度游商家管理系统",
-    "appid" : "__UNI__69B5200",
+    "appid" : "__UNI__B6E0DB1",
     // 自行更换uniapp appid 可登录查看uniapp提供的用户统计 https://tongji.dcloud.net.cn/
     "description" : "休度游商家管理系统",
-    "versionName" : "1.0.0",
+    "versionName" : "1.0.1",
     "versionCode" : "100",
     "transformPx" : false,
     "app-plus" : {
@@ -58,13 +58,13 @@
             },
             "icons" : {
                 "android" : {
-                    "hdpi" : "unpackage/res/icons/72x72.png",
-                    "xhdpi" : "unpackage/res/icons/96x96.png",
-                    "xxhdpi" : "unpackage/res/icons/144x144.png",
-                    "xxxhdpi" : "unpackage/res/icons/192x192.png"
+                    "hdpi" : "src/static/img/96.png",
+                    "xhdpi" : "src/static/img/144.png",
+                    "xxhdpi" : "src/static/img/144-3.png",
+                    "xxxhdpi" : "src/static/img/192.png"
                 },
                 "ios" : {
-                    "appstore" : "unpackage/res/icons/1024x1024.png",
+                    "appstore" : "src/static/img/144-2.png",
                     "ipad" : {
                         "app" : "unpackage/res/icons/76x76.png",
                         "app@2x" : "unpackage/res/icons/152x152.png",

+ 1 - 3
src/pages/index/index.vue

@@ -500,7 +500,6 @@ export default {
         }
       })
     },
-
     // 关键指数
     async getExponentData() {
       if (this.shopID === 0) {
@@ -512,6 +511,7 @@ export default {
           shopId: this.shopID,
         })
         .then(async (res) => {
+          console.log(res);
           if (res.code === 200 && res.data) {
             // 销售总额
             this.dataDo(res.data.xsze, this.sellSun);
@@ -524,7 +524,6 @@ export default {
           }
         });
     },
-
     // 指数数据处理
     dataDo(data, itemEle) {
       let todaynum = 0;
@@ -586,7 +585,6 @@ export default {
       }
       return itemEle;
     },
-
     // 待处理事物
     async getPendingData() {
       if (this.shopID === 0) {

+ 28 - 3
src/pages/index/setting/cellme.vue

@@ -5,7 +5,7 @@
     <view style="height: 94upx;"></view> -->
     <view class="cellme-content">
       <view class="name">重庆鼎游科技有限公司:</view>
-      <view class="phone">023-67535762</view>
+      <view class="phone" @tap="call"> <image class="phoneicon" src="../../../static/images/t10.png"></image> <text> {{ phone }}</text></view>
     </view>
   </view>
 </template>
@@ -17,19 +17,37 @@ export default {
   components: {
     Header,
   },
-  data() {
+  data () {
     //这里存放数据
     return {
       title: '联系我们',
+      phone: '023-67535762'
     };
   },
   //方法集合
   methods: {
     // 返回上一页
-    navBack() {
+    navBack () {
       console.log(1);
       this.$mRouter.back();
     },
+    call () {
+      let _self = this
+      uni.showModal({
+        content: `是否拨打电话:${_self.phone}`,
+        success: confirmRes => {
+          console.log(confirmRes);
+          if (confirmRes.confirm) {
+            uni.makePhoneCall({
+              phoneNumber: _self.phone,
+              sucess: res => {}
+            })
+          }
+        }
+      })
+      return
+
+    }
   },
 };
 </script>
@@ -45,6 +63,13 @@ export default {
     margin-top: 20upx;
     font-size: 32upx;
     font-weight: 700;
+    display: flex;
+    align-items: center;
+    .phoneicon {
+      width: 50upx;
+      height: 50upx;
+      margin-right: 20upx;
+    }
   }
 }
 </style>

+ 27 - 2
src/pages/index/setting/editnotice.vue

@@ -1,8 +1,6 @@
 <!-- editniotice -->
 <template>
   <view class="editniotice">
-    <!-- <Header :title="title" /> -->
-    <!-- <view style="height: 94upx;"></view> -->
     <view class="content">
       <view class="content-warp">
         <view class="uni-list-cell">
@@ -48,6 +46,14 @@
 						<text class="per">{{progress}}%</text>
 					</view>
         </view>
+
+        <!-- <view class="edit" @tap='toedit'>
+          <view class="txt">编辑公告</view>
+          <view class="icon-warp">
+            <image src="../../../static/images/moreicon.png" class="iconRight"></image>
+          </view>
+        </view> -->
+
         <view class="noticeContent">
           <view class="container">
             <editor
@@ -207,6 +213,11 @@ export default {
       });
     },
 
+    // // 跳转富文本
+    // toedit () {
+    //   this.$mRouter.push({route: '/pages/index/setting/editpublic'})
+    // },
+
     // --------------------------
 
     // 图标上传
@@ -335,6 +346,20 @@ export default {
     border: 2px solid #f4f4f4;
     margin-top: 20upx;
   }
+  .edit {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    height: 80upx;
+    border-bottom: 2px solid #f4f4f4;
+    .icon-warp {
+      width: 19upx;
+      .iconRight {
+        width: 19upx;
+        height: 27upx;
+      }
+    }
+  }
   .btn-warp {
     margin-top: 80upx;
     display: flex;

+ 57 - 0
src/pages/index/setting/editpublic.vue

@@ -0,0 +1,57 @@
+<!-- editpublic -->
+<template>
+  <view class="editpublic">
+    <view class="container">
+      <editor
+        id="editor"
+        class="ql-container"
+        :placeholder="placeholder"
+        @ready="onEditorReady"
+      ></editor>
+      <editor-parse :contents="content"></editor-parse>
+    </view>
+  </view>
+</template>
+
+<script>
+
+export default {
+  name: 'editpublic',
+  components: {},
+  data () {
+    //这里存放数据
+    return {
+      placeholder: '开始输入...',
+      content: '赋值内容'
+    };
+  },
+  //监控data中的数据变化
+  watch: {},
+  //方法集合
+  methods: {
+    onEditorReady () {
+      uni.createSelectorQuery().select('#editor').context((res) => {
+        this.editorCtx = res.context
+      }).exec()
+    },
+    undo () {
+      this.editorCtx.undo()
+    }
+
+  },
+}
+</script>
+<style lang='scss' scoped>
+.editpublic {
+  padding: 20upx 33upx 0;
+  .container {
+    padding: 10px;
+  }
+
+  #editor {
+    width: 100%;
+    height: 300px;
+    background-color: #cccccc;
+  }
+}
+</style>

+ 0 - 4
src/pages/index/setting/notice.vue

@@ -1,7 +1,6 @@
 <!-- 公告管理 -->
 <template>
   <view class="notice">
-    <!-- <Header :title="title"></Header> -->
     <view class="btn-add">
       <image
         src="../../../static/images/addicon.png"
@@ -9,7 +8,6 @@
         @tap="topage('add')"
       ></image>
     </view>
-    <!-- <view style="height: 94upx;"></view> -->
     <view class="notice-content">
       <view class="item" v-for="item in noticeList" :key="item.id">
         <view class="notice-top">
@@ -135,8 +133,6 @@ export default {
                 _self.getNoticeList();
               }
             });
-          } else {
-            _self.$mHelper.toast('取消删除');
           }
         },
       });

+ 23 - 15
src/pages/order/order.vue

@@ -1,6 +1,7 @@
 <!-- order -->
 <template>
-  <view class="order">
+  <view class="order"  @touchstart="handstart($event)"
+      @touchend="handend($event)">
     <view class="header-warp">
       <view class="header-search">
         <view class="search">
@@ -89,8 +90,7 @@
       class="order-content"
       v-if="isactive === 0"
       :class="{ leaveRightToLeft: isactive === 0 && direction=== 'left', leaveLeftToRight: isactive === 0 && direction ==='right'}"
-      @touchstart="handstart($event)"
-      @touchend="handend($event)"
+     
     >
       <view
         class="order-list"
@@ -128,8 +128,7 @@
       class="order-content"
       v-if="isactive === 1"
       :class="{ leaveRightToLeft: isactive === 1 && direction=== 'left', leaveLeftToRight: isactive === 1 && direction ==='right'}"
-      @touchstart="handstart($event)"
-      @touchend="handend($event)"
+     
     >
       <view
         class="order-list"
@@ -167,8 +166,7 @@
       class="order-content"
       v-if="isactive === 2"
       :class="{ leaveRightToLeft: isactive === 2 && direction=== 'left', leaveLeftToRight: isactive === 2 && direction ==='right'}"
-      @touchstart="handstart($event)"
-      @touchend="handend($event)"
+    
     >
       <view
         class="order-list"
@@ -205,7 +203,7 @@
 
     <uni-load-more :status="more"> </uni-load-more>
     <rf-loading v-if="loading"></rf-loading>
-    <view style="height: 250upx;"></view>
+    <view style="height: 100upx;"></view>
   </view>
 </template>
 
@@ -317,22 +315,33 @@ export default {
       if (Math.abs(endX - this.startX) > 50) {
         //滑动方向
         this.direction = endX - this.startX > 0 ? 'right' : 'left';
-        console.log(this.direction);
         this.more = 'loading'
+        if (this.direction === 'right' && this.isactive === 0) {
+          this.direction = ''
+          this.more = 'noMore'
+          return
+        }
+        if (this.direction === 'left' && this.isactive === 2) {
+          this.direction = ''
+          this.more = 'noMore'
+          return
+        }
         if (this.direction === 'right') {
           this.isactive--;
-          this.params.orderFlag = this.flagList[this.isactive];
           if (this.isactive < 0) {
-            this.isactive = 0;
+            this.isactive = 0
+            this.more = 'noMore'
             return;
           }
+          this.params.orderFlag = this.flagList[this.isactive];
         } else if (this.direction === 'left') {
           this.isactive++;
-          this.params.orderFlag = this.flagList[this.isactive];
           if (this.isactive > 2) {
             this.isactive = 2;
+            this.more = 'noMore'
             return;
           }
+          this.params.orderFlag = this.flagList[this.isactive];
         }
         this.getOrderList();
       } else {
@@ -348,7 +357,6 @@ export default {
     },
     // 确认时间后
     confirm(e) {
-      console.log(e);
       this.more = 'loading';
 
       this.startdate = e.range.before;
@@ -393,10 +401,10 @@ export default {
     // tab
     changeTab(type, falg) {
       this.direction = ''  // 关闭动画
-      console.log(type);
       this.more = 'loading';
       this.params.pageNum = 1;
       this.isactive = type;
+      console.log(this.isactive);
       this.params.orderFlag = falg;
       this.getOrderList();
     },
@@ -421,7 +429,6 @@ export default {
       await this.$http
         .post('/orders/proList', this.params)
         .then(async (res) => {
-          console.log(res);
           if (res.data.list.length > 0) {
             this.orderList = res.data.list;
             if (res.data.nextPage === 0) {
@@ -456,6 +463,7 @@ export default {
 <style lang="scss" scoped>
 .order {
   background-color: #f4f4f4;
+  height: 100vh;
   .header-warp {
     width: 100%;
     background-color: #fff;

+ 5 - 3
src/pages/public/login.vue

@@ -90,6 +90,10 @@ export default {
   // 页面生命周期 监听页面加载是否加载完成
   onLoad() {   
     this.getCaptchaImage();
+    
+    // #ifdef MP-WEIXIN
+    uni.hideHomeButton()  // 会话过期更改页面跳转到登录页的跳转方式,并隐藏小房子
+    // #endif
   },
   methods: {  
     // 统一跳转路由
@@ -148,14 +152,12 @@ export default {
 };
 </script>
 <style lang="scss" scoped>
-page {
-  background: #fff;
-}
 
 .container {
   padding-top: 65px;
   position: relative;
   width: 100vw;
+  height: 100vh;
   overflow: hidden;
   background: #fff;
 }

+ 28 - 16
src/pages/shop/shopdetail.vue

@@ -385,7 +385,7 @@ export default {
 
       typeList: [{ name: '商品类型(请先选择所属店铺)', id: '' }],
       typeIndex: 0,
-      typeId: '1',
+      typeId: '',
       typeDisabled: true,
 
       shopList: [{ name: '商品名称(请先选择商品类型)', id: '' }],
@@ -409,9 +409,10 @@ export default {
 
       Icon: '',
       Imglist: [],
+      progressimgs: 0,
 
-      price: 0.0,
-      rateprice: 0.0,
+      price: 0.00,
+      rateprice: 0.00,
 
       // -------------- 编辑分界线 ------------------------------------
 
@@ -524,10 +525,10 @@ export default {
         if (rule) {
           this.astrictDate.data.saleDay = rule.data.saleDay
             ? rule.data.saleDay
-            : 0;
+            : 1;
           this.astrictDate.data.saleNum = rule.data.saleNum
             ? rule.data.saleNum
-            : 0;
+            : 1;
           // 有效期模式
           this.astrictDate.dateSetting = rule.data.dateSetting;
           this.patterIndex = +rule.data.dateSetting;
@@ -572,9 +573,6 @@ export default {
       this.getShopList()
     }
   },
-  // onPageScroll (option) {
-  //   console.log(option);
-  // },
   methods: {
     // 获取单个商品信息
     async getShopBuyId (id) {
@@ -661,7 +659,7 @@ export default {
             html: this.shopData.describ, //this.EditGoodsDetail.content为赋值内容。
           });
         })
-        .exec(-1000)
+        .exec()
     },
     // -----------------------------------------------------------------
     // 跳转到管理分类页面
@@ -786,14 +784,15 @@ export default {
                 this.shopList[0] = { name: this.shopData.name, id: '' };
                 this.shopIndex = 0
                 this.shopId = this.shopList[this.shopIndex].id;
-                if (this.shopList[0].name === this.shopList[1].name) {
-                  this.shopList.length = 1
+                if (this.shopList.length != 1) {
+                  if (this.shopList[0].name === this.shopList[1].name) {
+                    this.shopList.length = 1
+                  }
                 }
               } else {
                 // 自营商品直接赋值
                 this.shopname = this.shopData.name;
               }
-
               this.loading = false;
             }
           }
@@ -834,6 +833,7 @@ export default {
     },
     subtractUser () {
       if (this.astrictDate.data.saleDay <= 1) {
+        this.astrictDate.data.saleDay = 1
         this.$mHelper.toast('最少一天');
         return;
       } else {
@@ -845,6 +845,7 @@ export default {
     },
     subtractDate () {
       if (this.astrictDate.data.saleNum <= 1) {
+        this.astrictDate.data.saleNum = 1
         this.$mHelper.toast('最少一张票');
         return;
       } else {
@@ -876,7 +877,9 @@ export default {
                 _self.Icon = res.fileID;
               }
             },
-            fail: function (msg) { },
+            fail: function (msg) {
+              _self.$mHelper.toast('图标上传失败,请重新上传')
+            },
             onUploadProgress: function (progressEvent) {
               _self.progress = Math.round(
                 (progressEvent.loaded * 100) / progressEvent.total
@@ -919,7 +922,7 @@ export default {
                 },
                 success: (res) => {
                   _self.Imglist.push({url:res.fileID,uid:res.filePath})
-                },
+                }
               });
             }
           }
@@ -943,6 +946,11 @@ export default {
     submitMesage () {
       let _this = this;
 
+      if (this.progress > 0  && this.progress < 100) {
+        this.$mHelper.toast('您有图标正在上传,请在上传完成后提交内容!')
+        return
+      }
+
       // 判断是否限制账号购买
       if (this.showoperat) {
         this.showoperat = '1';
@@ -953,7 +961,11 @@ export default {
       }
       let name = '';
       if (this.typeProperty === 1) {
-        name = this.shopList[this.shopIndex].name;
+        if (this.SHOPID) {
+          name = this.shopList[this.shopIndex].name
+        } else {
+          name = this.shopList[this.shopIndex].id;
+        }
       } else if (this.typeProperty === 0) {
         name = this.shopname;
       }
@@ -983,7 +995,7 @@ export default {
           this.$mHelper.toast('请输入商品划线价!');
           return;
         }
-        if (!this.expirationDate) {
+        if (this.expirationDate === '请选择商品过期日期') {
           this.$mHelper.toast('请选择商品过期日期');
           return;
         }

BIN=BIN
src/static/images/t10.png


BIN=BIN
src/static/img/144-2.png


BIN=BIN
src/static/img/144-3.png


BIN=BIN
src/static/img/144.png


BIN=BIN
src/static/img/192.png


BIN=BIN
src/static/img/72.png


BIN=BIN
src/static/img/96.png


+ 1 - 1
src/utils/helper.js

@@ -44,7 +44,7 @@ export default {
 			content: '会话已过期,是否跳转登录页面?',
 			success: (confirmRes) => {
 				if (confirmRes.confirm) {
-					mRouter.push({ route: '/pages/public/login' });
+					mRouter.reLaunch({ route: '/pages/public/login' });
 				}
 			}
 		});