Forráskód Böngészése

feat:首页改版

钱新宇 4 napja
szülő
commit
33c5450746
46 módosított fájl, 2601 hozzáadás és 1451 törlés
  1. 10 4
      components/IconList/index.vue
  2. 95 0
      components/List/index.vue
  3. 6 23
      pages.json
  4. 6 6
      pages/activity/index.vue
  5. 1 1
      pages/activity/lottery.vue
  6. 63 63
      pages/addr/index.vue
  7. 252 253
      pages/article/detail.vue
  8. 239 165
      pages/balance/index.vue
  9. 12 12
      pages/bind/user.vue
  10. 47 45
      pages/car/index.vue
  11. 2 2
      pages/car/order.vue
  12. 26 26
      pages/coupon/active.vue
  13. 50 37
      pages/index/index.vue
  14. 43 43
      pages/login/index.vue
  15. 26 22
      pages/orders/index.vue
  16. 11 11
      pages/orders/lottery.vue
  17. 17 17
      pages/orders/receipt.vue
  18. 9 9
      pages/product/index.vue
  19. 28 6
      pages/product/list.vue
  20. 20 20
      pages/recruitment/index.vue
  21. 1 1
      pages/recruitment/lottery.vue
  22. 148 150
      pages/recruitment/record.vue
  23. 63 33
      pages/score/clockin.vue
  24. 17 17
      pages/score/index.vue
  25. 1 1
      pages/score/lottery.vue
  26. 42 42
      pages/score/product.vue
  27. 148 150
      pages/score/record.vue
  28. 228 77
      pages/user/index.vue
  29. 188 189
      pages/user/info.vue
  30. 22 22
      pages/user/withdraw.vue
  31. 420 4
      pages/wait/index.vue
  32. BIN
      static/icon/car.png
  33. BIN
      static/icon/car_active.png
  34. BIN
      static/icon/home.png
  35. BIN
      static/icon/home_active.png
  36. BIN
      static/icon/product.png
  37. BIN
      static/icon/product_active.png
  38. BIN
      static/icon/user.png
  39. BIN
      static/icon/user_active.png
  40. BIN
      static/icon/video.png
  41. BIN
      static/icon/video_active.png
  42. 12 0
      uni_modules/cc-myTabbar/changelog.md
  43. 42 0
      uni_modules/cc-myTabbar/components/cc-myTabbar/cc-myTabbar.scss
  44. 131 0
      uni_modules/cc-myTabbar/components/cc-myTabbar/cc-myTabbar.vue
  45. 86 0
      uni_modules/cc-myTabbar/package.json
  46. 89 0
      uni_modules/cc-myTabbar/readme.md

+ 10 - 4
components/IconList/index.vue

@@ -26,6 +26,10 @@ const props = defineProps({
     type: Number,
     default: 0,
   },
+  small: {
+    type: Boolean,
+    default: false,
+  },
 });
 
 const getColumnCount = () => {
@@ -72,6 +76,8 @@ const _handleClick = (url) => {
 const displayIcons = computed(() => {
   return props.icons.slice(0, getMaxItems());
 });
+
+const iconSize = computed(() => (props.small ? '31px' : '44px'));
 </script>
 
 <style lang="less" scoped>
@@ -88,7 +94,7 @@ const displayIcons = computed(() => {
   grid-template-columns: repeat(var(--columns), 1fr);
   gap: 16rpx;
   width: 100%;
-  padding: 16px;
+  padding: 16px 8px;
   box-sizing: border-box;
   background-color: #fff;
   border-radius: 8px;
@@ -100,8 +106,8 @@ const displayIcons = computed(() => {
     align-items: center;
 
     .icon-wrapper {
-      width: 44px;
-      height: 44px;
+      width: v-bind('iconSize');
+      height: v-bind('iconSize');
       overflow: hidden;
 
       image {
@@ -128,7 +134,7 @@ const displayIcons = computed(() => {
 }
 
 .row8 {
-  grid-template-rows: repeat(2, 1fr);
+  // grid-template-rows: repeat(2, 1fr);
 }
 
 .row5 {

+ 95 - 0
components/List/index.vue

@@ -0,0 +1,95 @@
+<template>
+  <view>
+    <view v-if="showTitle" style="padding: 6px 0 6px 0; color: #333; font-size: 16px; display: flex; align-items: center">
+      <view style="width: 4px; height: 20px; background: linear-gradient(to bottom, #f89c33, #f86834); margin-right: 4px" />
+      {{ title }}
+    </view>
+    <view class="list">
+      <view v-for="(item, index) in lists" :key="index" class="list-item" @click="_handleClick(item.url)">
+        <view class="content">
+          <image v-if="iconShow" class="icon" :src="item.image" :alt="item.image" />
+          <view class="title">{{ item.text }}</view>
+        </view>
+        <view>{{ '>' }}</view>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script setup>
+defineProps({
+  lists: {
+    type: Array,
+    default: () => [],
+  },
+  iconShow: {
+    type: Boolean,
+    default: true,
+  },
+  showTitle: {
+    type: Boolean,
+    default: true,
+  },
+  title: {
+    type: String,
+    default: '',
+  },
+});
+
+const _handleClick = (url) => {
+  if (url) {
+    uni.navigateTo({
+      url,
+      fail: (err) => {
+        uni.switchTab({
+          url,
+        });
+      },
+    });
+  }
+};
+</script>
+
+<style lang="less" scoped>
+.list {
+  width: 100%;
+  box-sizing: border-box;
+  border-radius: 8px;
+
+  .list-item {
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    padding: 16px;
+    background: #fff;
+    cursor: pointer;
+    border-bottom: 1px solid #f2f2f2;
+    &:first-child {
+      border-radius: 8px 8px 0 0;
+    }
+    &:last-child {
+      border-radius: 0 0 8px 8px;
+    }
+    .content {
+      display: flex;
+      align-items: center;
+
+      .icon {
+        width: 48rpx;
+        height: 48rpx;
+        margin-right: 12px;
+        border-radius: 8px;
+      }
+
+      .title {
+        font-size: 16px;
+        color: #333;
+      }
+    }
+
+    .arrow {
+      color: #999;
+    }
+  }
+}
+</style>

+ 6 - 23
pages.json

@@ -35,7 +35,8 @@
     {
       "path": "pages/user/index",
       "style": {
-        "navigationBarTitleText": "我的"
+        "navigationBarTitleText": "我的",
+        "navigationStyle": "custom"
       }
     },
     {
@@ -308,34 +309,16 @@
     "position": "bottom",
     "list": [
       {
-        "pagePath": "pages/index/index",
-        "iconPath": "static/icon/home.png",
-        "selectedIconPath": "static/icon/home_active.png",
-        "text": "首页"
-      },
-      {
-        "pagePath": "pages/score/index",
-        "iconPath": "static/tabbar/score.png",
-        "selectedIconPath": "static/tabbar/score_active.png",
-        "text": "积分"
+        "pagePath": "pages/index/index"
       },
       {
-        "pagePath": "pages/score/clockin",
-        "iconPath": "static/tabbar/clockin.png",
-        "selectedIconPath": "static/tabbar/clockin_active.png",
-        "text": "签到"
+        "pagePath": "pages/product/list"
       },
       {
-        "pagePath": "pages/car/index",
-        "iconPath": "static/icon/car.png",
-        "selectedIconPath": "static/icon/car_active.png",
-        "text": "购物车"
+        "pagePath": "pages/car/index"
       },
       {
-        "pagePath": "pages/user/index",
-        "iconPath": "static/icon/user.png",
-        "selectedIconPath": "static/icon/user_active.png",
-        "text": "我的"
+        "pagePath": "pages/user/index"
       }
     ]
   }

+ 6 - 6
pages/activity/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <view class="activity" style="background-image: none; background-color: #e03519; padding: 0 0 120rpx">
+  <view class="activity" style="background-image: none; background-color: #f89c33; padding: 0 0 120rpx">
     <!-- <view class="rule" @click="showRule">活动规则</view> -->
 
     <!-- logo与跑马灯 -->
@@ -15,7 +15,7 @@
       <view class="activity-info">
         <!-- <text class="title">{{ acticve_detail?.name }}</text> -->
         <view class="active-rule">
-          <rich-text :nodes="acticve_detail.active_rule" class="rich_text" ></rich-text>
+          <rich-text :nodes="acticve_detail.active_rule" class="rich_text"></rich-text>
         </view>
       </view>
       <view class="activity-btn" @click="_handleChangePage(1)">立即参与</view>
@@ -405,8 +405,8 @@ const _handleChangeRule = (type) => {
         height: 400rpx;
         overflow-y: auto;
         .rich_text {
-		 font-size: 28rpx;
-		 font-weight: bold;
+          font-size: 28rpx;
+          font-weight: bold;
           white-space: break-spaces;
         }
       }
@@ -441,7 +441,7 @@ const _handleChangeRule = (type) => {
       height: 300rpx;
       padding: 26rpx;
       overflow: auto;
-	  font-size: 28rpx;
+      font-size: 28rpx;
       border-radius: 6rpx;
       margin-bottom: 30rpx;
       background-color: #fff;
@@ -533,7 +533,7 @@ const _handleChangeRule = (type) => {
         box-sizing: border-box;
         background-color: #ffffff;
         .rich_text {
-			white-space: break-spaces;
+          white-space: break-spaces;
         }
       }
     }

+ 1 - 1
pages/activity/lottery.vue

@@ -703,7 +703,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 63 - 63
pages/addr/index.vue

@@ -19,7 +19,7 @@
               class="radio_icon"
               :src="item.is_default ? 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/radioed.png' : 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/radio.png'"
             ></image>
-            <text :class="item.is_default ? 'radioed_text' : ''">{{ item.is_default ? "已默认" : "设为默认" }}</text>
+            <text :class="item.is_default ? 'radioed_text' : ''">{{ item.is_default ? '已默认' : '设为默认' }}</text>
           </view>
           <view class="addr_right_btn" @click="removeAddr(index)">删除</view>
           <view class="addr_right_btn" @click="openForm(item)">编辑</view>
@@ -94,7 +94,7 @@
           <view class="form_group">
             <view class="group_title">设为默认</view>
             <view class="group_box">
-              <switch color="#E03519" style="transform: scale(0.6); float: right" @change="defaultSwitch" :checked="addrRequest.is_default ? true : false" />
+              <switch color="#F89C33" style="transform: scale(0.6); float: right" @change="defaultSwitch" :checked="addrRequest.is_default ? true : false" />
             </view>
           </view>
           <button class="submit_btn" @click="saveAddr">保存地址</button>
@@ -105,8 +105,8 @@
 </template>
 
 <script>
-import { getProvinces, getMyCity, getAreas, getProvincesIndex, getCityIndex, getAreaIndex } from "../../utils/city";
-import Empty from "@/components/Empty/Empty.vue";
+import { getProvinces, getMyCity, getAreas, getProvincesIndex, getCityIndex, getAreaIndex } from '../../utils/city';
+import Empty from '@/components/Empty/Empty.vue';
 
 // 防抖函数
 function debounce(func, wait) {
@@ -131,13 +131,13 @@ export default {
       // 保存地址
       addrRequest: {
         id: 0,
-        contact_name: "",
-        contact_phone: "",
-        contact_province: "",
-        contact_city: "",
-        contact_area: "",
-        contact_addr: "",
-        contact_shop: "",
+        contact_name: '',
+        contact_phone: '',
+        contact_province: '',
+        contact_city: '',
+        contact_area: '',
+        contact_addr: '',
+        contact_shop: '',
         is_default: 0,
         shop_type: 1,
       },
@@ -154,9 +154,9 @@ export default {
       AddrEmit: false,
       //终端类型
       terminalType: [
-        { key: 1, label: "单店" },
-        { key: 2, label: "连锁" },
-        { key: 3, label: "诊所、社康等" },
+        { key: 1, label: '单店' },
+        { key: 2, label: '连锁' },
+        { key: 3, label: '诊所、社康等' },
       ],
       //获取的默认地址
       defaultAddr: {},
@@ -165,8 +165,8 @@ export default {
     };
   },
   onLoad(param) {
-    this.AddrEmit = param.notify == "addr" ? true : false;
-    this.autoShowForm = param.type == "create" ? true : false;
+    this.AddrEmit = param.notify == 'addr' ? true : false;
+    this.autoShowForm = param.type == 'create' ? true : false;
     // 获取列表
     this.getList();
     this.get_remark_addr();
@@ -192,16 +192,16 @@ export default {
   },
   methods: {
     onSearchInput: debounce(function (inputVal, isSelect) {
-      console.log("搜索关键字:", this.addrRequest.contact_shop);
-      console.log("是否选择:", isSelect);
+      console.log('搜索关键字:', this.addrRequest.contact_shop);
+      console.log('是否选择:', isSelect);
       if (isSelect) return;
-      if (this.addrRequest.contact_shop.trim() === "" || this.addrRequest.contact_shop.length < 2) {
+      if (this.addrRequest.contact_shop.trim() === '' || this.addrRequest.contact_shop.length < 2) {
         this.searchResults = [];
         return;
       }
-      this.$http.request("api/custom_addr/get_guess_addr", { contact_shop: this.addrRequest.contact_shop }).then((callback) => {
+      this.$http.request('api/custom_addr/get_guess_addr', { contact_shop: this.addrRequest.contact_shop }).then((callback) => {
         // 获取成功
-        if (callback.code == "success") {
+        if (callback.code == 'success') {
           this.searchResults = callback.data.map((item, index) => ({
             text: item.contact_shop,
             value: index,
@@ -226,9 +226,9 @@ export default {
     },
     //获取get_remark_addr
     get_remark_addr() {
-      this.$http.request("api/custom_addr/get_remark_addr").then((callback) => {
+      this.$http.request('api/custom_addr/get_remark_addr').then((callback) => {
         // 获取成功
-        if (callback.code == "success") {
+        if (callback.code == 'success') {
           // 通知地址变更
           this.defaultAddr = callback.data;
         }
@@ -239,12 +239,12 @@ export default {
       // 登录提示
       if (!this.$checkAccess.alterLogin()) return;
       // 判断数据
-      this.$http.request("api/custom_addr/get_list").then((callback) => {
+      this.$http.request('api/custom_addr/get_list').then((callback) => {
         // 获取成功
-        if (callback.code == "success") {
+        if (callback.code == 'success') {
           this.addrList = callback.data;
           // 通知地址变更
-          if (this.AddrEmit) uni.$emit("addr_list_change", { list: this.addrList });
+          if (this.AddrEmit) uni.$emit('addr_list_change', { list: this.addrList });
         }
       });
     },
@@ -257,13 +257,13 @@ export default {
         this.addrRequest.contact_shop = this.defaultAddr.contact_shop;
         this.addrRequest.contact_addr = this.defaultAddr.contact_addr;
         this.addrRequest.is_default = 0;
-        this.addrRequest.shop_type = this.defaultAddr.shop_type == "" ? 1 : this.defaultAddr.shop_type;
+        this.addrRequest.shop_type = this.defaultAddr.shop_type == '' ? 1 : this.defaultAddr.shop_type;
         const { contact_province, contact_city, contact_area } = this.defaultAddr;
-        if (contact_province == "") {
+        if (contact_province == '') {
           this.cityValue = [0, 0, 0];
-          this.addrRequest.contact_province = "请选择";
-          this.addrRequest.contact_city = "请选择";
-          this.addrRequest.contact_area = "请选择";
+          this.addrRequest.contact_province = '请选择';
+          this.addrRequest.contact_city = '请选择';
+          this.addrRequest.contact_area = '请选择';
         } else {
           const provinces = getProvincesIndex(contact_province);
           const city = getCityIndex(contact_city, provinces.city, provinces.index);
@@ -274,8 +274,8 @@ export default {
           this.addrRequest.contact_province = contact_province;
           this.addrRequest.contact_area = contact_area;
           this.addrRequest.contact_city = contact_city;
-          if (contact_area == "") this.addrRequest.contact_area = "请选择";
-          if (contact_city == "") this.addrRequest.contact_city = "请选择";
+          if (contact_area == '') this.addrRequest.contact_area = '请选择';
+          if (contact_city == '') this.addrRequest.contact_city = '请选择';
         }
       } else {
         if (!item.shop_type) item.shop_type = 1;
@@ -289,7 +289,7 @@ export default {
         this.cityArray.splice(2, 1, city.area);
       }
       // 显示下单弹出层
-      this.$refs.addrForm.open("bottom");
+      this.$refs.addrForm.open('bottom');
     },
     // 默认开关
     defaultSwitch(e) {
@@ -302,7 +302,7 @@ export default {
     },
     // 城市修改
     cityChange(e) {
-		this.onFocus()
+      this.onFocus();
       // 替换三个选项
       this.cityValue.splice(e.detail.column, 1, e.detail.value);
       // 下一级设置为0
@@ -328,49 +328,49 @@ export default {
     saveAddr() {
       // 判断姓名
       if (!this.addrRequest.contact_name) {
-        uni.showToast({ icon: "none", title: "请填写收件人" });
+        uni.showToast({ icon: 'none', title: '请填写收件人' });
         return;
       }
       if (this.addrRequest.contact_name.length < 2) {
-        uni.showToast({ icon: "none", title: "请填写收件人完整姓名" });
+        uni.showToast({ icon: 'none', title: '请填写收件人完整姓名' });
         return;
       }
       if (!this.addrRequest.contact_shop) {
-        uni.showToast({ icon: "none", title: "请填写店铺名称" });
+        uni.showToast({ icon: 'none', title: '请填写店铺名称' });
         return;
       }
       if (!this.addrRequest.contact_phone) {
-        uni.showToast({ icon: "none", title: "请填写收件人手机号" });
+        uni.showToast({ icon: 'none', title: '请填写收件人手机号' });
         return;
       }
       if (!this.addrRequest.contact_addr) {
-        uni.showToast({ icon: "none", title: "请填写联系地址" });
+        uni.showToast({ icon: 'none', title: '请填写联系地址' });
         return;
       }
       if (this.addrRequest.contact_addr.length < 3) {
-        uni.showToast({ icon: "none", title: "请填写可用联系地址" });
+        uni.showToast({ icon: 'none', title: '请填写可用联系地址' });
         return;
       }
       const _clone = JSON.parse(JSON.stringify(this.addrRequest));
-      if (_clone.contact_province == "请选择" || _clone.contact_city == "请选择" || _clone.contact_area == "请选择") {
+      if (_clone.contact_province == '请选择' || _clone.contact_city == '请选择' || _clone.contact_area == '请选择') {
         uni.showToast({
-          icon: "none",
-          title: "请选择完整的省市区信息",
+          icon: 'none',
+          title: '请选择完整的省市区信息',
         });
         return;
       }
       // 请求状态
       uni.showLoading({ mask: true });
       // 请求路径
-      var url = this.addrRequest.id ? "api/custom_addr/edit" : "api/custom_addr/add";
+      var url = this.addrRequest.id ? 'api/custom_addr/edit' : 'api/custom_addr/add';
       // 授权成功以后,调用绑定
-      this.$http.request(url, this.addrRequest, "post").then((re) => {
+      this.$http.request(url, this.addrRequest, 'post').then((re) => {
         // 关闭
         uni.hideLoading();
         // 成功的话
-        if (re.code != "success") {
+        if (re.code != 'success') {
           // 跳转
-          uni.showToast({ title: re.msg, icon: "none" });
+          uni.showToast({ title: re.msg, icon: 'none' });
           return;
         }
         // 地址变动
@@ -382,19 +382,19 @@ export default {
     // 删除地址
     removeAddr(index) {
       // 授权成功以后,调用绑定
-      this.$http.request("api/custom_addr/del", { id: this.addrList[index].id }, "post").then((re) => {
+      this.$http.request('api/custom_addr/del', { id: this.addrList[index].id }, 'post').then((re) => {
         // 关闭
         uni.hideLoading();
         // 成功的话
-        if (re.code != "success") {
+        if (re.code != 'success') {
           // 跳转
-          uni.showToast({ title: re.msg, icon: "none" });
+          uni.showToast({ title: re.msg, icon: 'none' });
           return;
         }
         // 成功删除该项
         this.addrList.splice(index, 1);
         // 通知地址变更
-        if (this.AddrEmit) uni.$emit("addr_list_change", { list: this.addrList });
+        if (this.AddrEmit) uni.$emit('addr_list_change', { list: this.addrList });
       });
     },
     // 设置默认
@@ -402,13 +402,13 @@ export default {
       // 如果已经是默认状态
       if (this.addrList[index].is_default) return;
       // 授权成功以后,调用绑定
-      this.$http.request("api/custom_addr/set_default", { id: this.addrList[index].id }, "post").then((re) => {
+      this.$http.request('api/custom_addr/set_default', { id: this.addrList[index].id }, 'post').then((re) => {
         // 关闭
         uni.hideLoading();
         // 成功的话
-        if (re.code != "success") {
+        if (re.code != 'success') {
           // 跳转
-          uni.showToast({ title: re.msg, icon: "none" });
+          uni.showToast({ title: re.msg, icon: 'none' });
           return;
         }
         // 更新其他的默认项
@@ -418,16 +418,16 @@ export default {
         // 成功修改值
         this.addrList[index].is_default = 1;
         // 通知地址变更
-        if (this.AddrEmit) uni.$emit("addr_list_change", { list: this.addrList });
+        if (this.AddrEmit) uni.$emit('addr_list_change', { list: this.addrList });
       });
     },
     handleRadioChange(key) {
-		this.onFocus()
+      this.onFocus();
       this.addrRequest.shop_type = Number(key);
     },
-	onFocus(){
-		this.$refs.combox.close()
-	}
+    onFocus() {
+      this.$refs.combox.close();
+    },
   },
 };
 </script>
@@ -483,7 +483,7 @@ export default {
           vertical-align: middle;
         }
         .radioed_text {
-          color: #e03519;
+          color: #f89c33;
         }
       }
       .addr_right_btn {
@@ -516,7 +516,7 @@ export default {
     margin: 0rpx auto;
     margin-top: 20rpx;
     border-radius: 40rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
   }
 }
 .popup {
@@ -594,7 +594,7 @@ export default {
       margin: 20rpx auto;
       margin-top: 40rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 252 - 253
pages/article/detail.vue

@@ -1,261 +1,260 @@
 <template>
-	<view>
-		<view class="article_title">{{articleInfo.title}}</view>
-		<view class="article_time">{{articleInfo.insert_time}}</view>
-		<view class="rich_text">
-			<rich-text :nodes="articleInfo.content"></rich-text>
-		</view>
-		<view class="article_poster" v-if="articleInfo.poster" >
-			<image class="poster_img" show-menu-by-longpress @click="navigatoPage()" :src="articleInfo.poster" mode="widthFix"></image>
-		</view>
-		<view class="read_total">阅读:{{articleInfo.read_count}}</view>
-		<view>&nbsp;</view>
-		<view class="handle_box">
-			<view class="click_box" @click.stop="updateEvent(2)">
-				<uni-icons :type="articleInfo.is_hand?'hand-up-filled':'hand-up'" :color="articleInfo.is_hand?'#e03519':'#333333'" size="20"></uni-icons>
-				<text>{{articleInfo.hand_count}}</text>
-			</view>
-			<button class="click_box" open-type="share">
-				<uni-icons type="upload" size="20"></uni-icons>
-				<text>{{articleInfo.share_count}}</text>
-			</button>
-			<view class="click_box" @click.stop="updateEvent(4)" >
-				<uni-icons :type="articleInfo.is_like?'heart-filled':'heart'" :color="articleInfo.is_like?'#e03519':'#333333'"  size="20"></uni-icons>
-				<text>{{articleInfo.like_count}}</text>
-			</view>
-		</view>
-	</view>
+  <view>
+    <view class="article_title">{{ articleInfo.title }}</view>
+    <view class="article_time">{{ articleInfo.insert_time }}</view>
+    <view class="rich_text">
+      <rich-text :nodes="articleInfo.content"></rich-text>
+    </view>
+    <view class="article_poster" v-if="articleInfo.poster">
+      <image class="poster_img" show-menu-by-longpress @click="navigatoPage()" :src="articleInfo.poster" mode="widthFix"></image>
+    </view>
+    <view class="read_total">阅读:{{ articleInfo.read_count }}</view>
+    <view>&nbsp;</view>
+    <view class="handle_box">
+      <view class="click_box" @click.stop="updateEvent(2)">
+        <uni-icons :type="articleInfo.is_hand ? 'hand-up-filled' : 'hand-up'" :color="articleInfo.is_hand ? '#F89C33' : '#333333'" size="20"></uni-icons>
+        <text>{{ articleInfo.hand_count }}</text>
+      </view>
+      <button class="click_box" open-type="share">
+        <uni-icons type="upload" size="20"></uni-icons>
+        <text>{{ articleInfo.share_count }}</text>
+      </button>
+      <view class="click_box" @click.stop="updateEvent(4)">
+        <uni-icons :type="articleInfo.is_like ? 'heart-filled' : 'heart'" :color="articleInfo.is_like ? '#F89C33' : '#333333'" size="20"></uni-icons>
+        <text>{{ articleInfo.like_count }}</text>
+      </view>
+    </view>
+  </view>
 </template>
 
 <script>
-	export default {
-		data() {
-			return {
-				articleInfo:{
-					'id':0,
-					'title':'',
-					'poster':'',
-					'content':'',
-					'read_count':0,
-					'hand_count':0,
-					'like_count':0,
-					'share_count':0,
-					'is_hand':0,
-					'is_like':0,
-					'path':'',
-					'appid':'',
-					'insert_time':'',
-				},
-				// 请求参数
-				requestParam: {
-				  id: 0
-				},
-				isReqing:false,
-			}
-		},
-		onLoad(param) {
-			// 参数接收
-			this.requestParam.id = param.id;
-			// #ifdef MP-WEIXIN
-			//分享按钮
-			uni.showShareMenu({
-			  withShareTicket: true,
-			  menus: ["shareAppMessage", "shareTimeline"],
-			});
-			// #endif
-		},
-		onShareAppMessage(obj) {
-			this.updateEvent(3);
-			  return {
-				title: `999智控终端平台\n${this.articleInfo.title}`,
-				path: "/pages/article/detail?id=" + this.articleInfo.id,
-				promise: new Promise((resolve, reject) => {
-				  this.$http.request("api/share_message/get_item", { item_id: this.articleInfo.id, pages: "/pages/article/detail" }).then((callback) => {
-					console.log(callback, "api/share_message/get_item");
-					let obj = {
-					  title: callback.data?.title == "" ? `999智控终端平台\n${this.articleInfo.title}` : callback.data.title,
-					  path: "/pages/article/detail?id=" + this.articleInfo.id,
-					};
-					if (callback.data?.image_url !== "") {
-					  obj.imageUrl = callback.data.image_url;
-					}
-					resolve(obj);
-				  });
-				}),
-		  };
-		},
-		onShow() {
-			// 如果存在产品ID的话
-			if (this.requestParam.id > 0) {
-			  // 请求详情
-			  this.$http.request("api/article/get_detail", this.requestParam).then((re) => {
-			    // 成功渲染数据
-			    if (re.code == "success") {
-			      // 刷新数据
-			      this.articleInfo = re.data;
-			    } else {
-			      if (re.code != "no_login") {
-			        uni.showModal({
-			          content: re.msg,
-			          showCancel: false,
-			        });
-			      }
-			    }
-			  });
-			}
-		},
-		methods: {
-			updateEvent(typeId){
-				
-				if( this.isReqing )  return ;
-				
-				this.isReqing		= true;
-				// 如果存在产品ID的话
-				if ( this.articleInfo.id > 0 ) {
-				  // 请求详情
-				  this.$http.request("api/article/update_event", {type_id:typeId,article_id:this.articleInfo.id}).then((re) => {
-					this.isReqing = false;
-				    // 成功渲染数据
-				    if (re.code == "success") {
-					  // 如果是点赞
-					  if( typeId == 2 ) {
-						this.articleInfo.is_hand ? this.articleInfo.hand_count -= 1 : this.articleInfo.hand_count += 1;
-						this.articleInfo.is_hand = this.articleInfo.is_hand ? 0 : 1;
-					  }
-					  // 如果是点赞
-					  if( typeId == 3 ) {
-						this.articleInfo.is_hand ? this.articleInfo.share_count -= 1 : this.articleInfo.share_count += 1;
-					  }
-					  // 如果是喜欢
-					  if( typeId == 4 ) {
-						this.articleInfo.is_like ? this.articleInfo.like_count -= 1 : this.articleInfo.like_count += 1;
-						this.articleInfo.is_like = this.articleInfo.is_like ? 0 : 1;
-					  }
-				    } else {
-				      if (re.code != "no_login") {
-				        uni.showModal({
-				          content: re.msg,
-				          showCancel: false,
-				        });
-				      }
-				    }
-				  });
-				}
-			},
-			navigatoPage(){
-				// 没有跳转路径
-				if( !this.articleInfo.path ) return '';
-				// 如果路径有http
-				let url 	= this.articleInfo.path;
-				
-				console.log(url);
-				
-				// 判断是不是小程序链接
-				if ( url.includes("http") ) {
-				  // 转码
-				  let link_url = encodeURIComponent(url);
-				  // 跳转到webview
-				  uni.redirectTo({
-				    url: `/pages/webview/index?link_url=${link_url}`,
-				  });
-				} else {
-					console.log(this.articleInfo.appid);
-				  // 是否有appid
-				  this.articleInfo.appid ? uni.navigateToMiniProgram({appId:this.articleInfo.appid,path:url}) : uni.navigateTo({url:url});
-				}
-			}
-		}
-	}
+export default {
+  data() {
+    return {
+      articleInfo: {
+        id: 0,
+        title: '',
+        poster: '',
+        content: '',
+        read_count: 0,
+        hand_count: 0,
+        like_count: 0,
+        share_count: 0,
+        is_hand: 0,
+        is_like: 0,
+        path: '',
+        appid: '',
+        insert_time: '',
+      },
+      // 请求参数
+      requestParam: {
+        id: 0,
+      },
+      isReqing: false,
+    };
+  },
+  onLoad(param) {
+    // 参数接收
+    this.requestParam.id = param.id;
+    // #ifdef MP-WEIXIN
+    //分享按钮
+    uni.showShareMenu({
+      withShareTicket: true,
+      menus: ['shareAppMessage', 'shareTimeline'],
+    });
+    // #endif
+  },
+  onShareAppMessage(obj) {
+    this.updateEvent(3);
+    return {
+      title: `999智控终端平台\n${this.articleInfo.title}`,
+      path: '/pages/article/detail?id=' + this.articleInfo.id,
+      promise: new Promise((resolve, reject) => {
+        this.$http.request('api/share_message/get_item', { item_id: this.articleInfo.id, pages: '/pages/article/detail' }).then((callback) => {
+          console.log(callback, 'api/share_message/get_item');
+          let obj = {
+            title: callback.data?.title == '' ? `999智控终端平台\n${this.articleInfo.title}` : callback.data.title,
+            path: '/pages/article/detail?id=' + this.articleInfo.id,
+          };
+          if (callback.data?.image_url !== '') {
+            obj.imageUrl = callback.data.image_url;
+          }
+          resolve(obj);
+        });
+      }),
+    };
+  },
+  onShow() {
+    // 如果存在产品ID的话
+    if (this.requestParam.id > 0) {
+      // 请求详情
+      this.$http.request('api/article/get_detail', this.requestParam).then((re) => {
+        // 成功渲染数据
+        if (re.code == 'success') {
+          // 刷新数据
+          this.articleInfo = re.data;
+        } else {
+          if (re.code != 'no_login') {
+            uni.showModal({
+              content: re.msg,
+              showCancel: false,
+            });
+          }
+        }
+      });
+    }
+  },
+  methods: {
+    updateEvent(typeId) {
+      if (this.isReqing) return;
+
+      this.isReqing = true;
+      // 如果存在产品ID的话
+      if (this.articleInfo.id > 0) {
+        // 请求详情
+        this.$http.request('api/article/update_event', { type_id: typeId, article_id: this.articleInfo.id }).then((re) => {
+          this.isReqing = false;
+          // 成功渲染数据
+          if (re.code == 'success') {
+            // 如果是点赞
+            if (typeId == 2) {
+              this.articleInfo.is_hand ? (this.articleInfo.hand_count -= 1) : (this.articleInfo.hand_count += 1);
+              this.articleInfo.is_hand = this.articleInfo.is_hand ? 0 : 1;
+            }
+            // 如果是点赞
+            if (typeId == 3) {
+              this.articleInfo.is_hand ? (this.articleInfo.share_count -= 1) : (this.articleInfo.share_count += 1);
+            }
+            // 如果是喜欢
+            if (typeId == 4) {
+              this.articleInfo.is_like ? (this.articleInfo.like_count -= 1) : (this.articleInfo.like_count += 1);
+              this.articleInfo.is_like = this.articleInfo.is_like ? 0 : 1;
+            }
+          } else {
+            if (re.code != 'no_login') {
+              uni.showModal({
+                content: re.msg,
+                showCancel: false,
+              });
+            }
+          }
+        });
+      }
+    },
+    navigatoPage() {
+      // 没有跳转路径
+      if (!this.articleInfo.path) return '';
+      // 如果路径有http
+      let url = this.articleInfo.path;
+
+      console.log(url);
+
+      // 判断是不是小程序链接
+      if (url.includes('http')) {
+        // 转码
+        let link_url = encodeURIComponent(url);
+        // 跳转到webview
+        uni.redirectTo({
+          url: `/pages/webview/index?link_url=${link_url}`,
+        });
+      } else {
+        console.log(this.articleInfo.appid);
+        // 是否有appid
+        this.articleInfo.appid ? uni.navigateToMiniProgram({ appId: this.articleInfo.appid, path: url }) : uni.navigateTo({ url: url });
+      }
+    },
+  },
+};
 </script>
 
 <style lang="less">
-	.article_title{
-		width: 700rpx;
-		display: block;
-		font-size: 36rpx;
-		overflow: hidden;
-		font-weight: bold;
-		line-height: 60rpx;
-		padding: 0rpx 25rpx;
-		background-color: #FFFFFF;
-	}
-	.article_time{
-		width: 700rpx;
-		color: #999999;
-		display: block;
-		font-size: 26rpx;
-		overflow: hidden;
-		line-height: 40rpx;
-		padding: 0rpx 25rpx;
-		background-color: #FFFFFF;
-	}
-	.rich_text{
-		width: 700rpx;
-		display: block;
-		overflow: hidden;
-		font-size: 26rpx;
-		margin: 0rpx auto;
-		min-height: 50rpx;
-		line-height: 50rpx;
-		padding: 10rpx 25rpx;
-		background-color: #FFFFFF;
-		[alt] {
-		  //web_view图片
-		  max-width: 100%; // 避免图片超宽
-		  vertical-align: bottom; // 避免图片之间间隙
-		}
-	}
-	.article_poster{
-		width: 700rpx;
-		display: block;
-		overflow: hidden;
-		margin: 6rpx auto;
-		padding: 10rpx 25rpx;
-		background-color: #FFFFFF;
-		.poster_img{
-			width: 700rpx;
-			display: block;
-		}
-	}
-	.read_total{
-		width: 700rpx;
-		color: #999999;
-		display: block;
-		font-size: 26rpx;
-		overflow: hidden;
-		line-height: 60rpx;
-		padding: 0rpx 25rpx;
-		margin-bottom: 122rpx;
-		background-color: #FFFFFF;
-	}
-	.handle_box {
-	  left: 0rpx;
-	  width: 700rpx;
-	  height: 120rpx;
-	  display: block;
-	  position: fixed;
-	  overflow: hidden;
-	  padding: 20rpx 25rpx;
-	  background-color: #FFFFFF;
-	  bottom: var(--window-bottom);
-	  border-top: 2rpx solid #DDDDDD;
-	  .click_box{
-		  border: none;
-		  float: right;
-		  display: block;
-		  height: 120rpx;
-		  padding: 0rpx 0rpx;
-		  line-height: 120rpx;
-		  margin-right: 20rpx;
-		  font-size: 24rpx !important;
-		  background-color: transparent;
-		  .uni-icons{
-			  font-size: 36rpx !important;
-		  }
-	  }
-	  .click_box::after{
-		  border: none;
-		  background-color: transparent;
-	  }
-	}
+.article_title {
+  width: 700rpx;
+  display: block;
+  font-size: 36rpx;
+  overflow: hidden;
+  font-weight: bold;
+  line-height: 60rpx;
+  padding: 0rpx 25rpx;
+  background-color: #ffffff;
+}
+.article_time {
+  width: 700rpx;
+  color: #999999;
+  display: block;
+  font-size: 26rpx;
+  overflow: hidden;
+  line-height: 40rpx;
+  padding: 0rpx 25rpx;
+  background-color: #ffffff;
+}
+.rich_text {
+  width: 700rpx;
+  display: block;
+  overflow: hidden;
+  font-size: 26rpx;
+  margin: 0rpx auto;
+  min-height: 50rpx;
+  line-height: 50rpx;
+  padding: 10rpx 25rpx;
+  background-color: #ffffff;
+  [alt] {
+    //web_view图片
+    max-width: 100%; // 避免图片超宽
+    vertical-align: bottom; // 避免图片之间间隙
+  }
+}
+.article_poster {
+  width: 700rpx;
+  display: block;
+  overflow: hidden;
+  margin: 6rpx auto;
+  padding: 10rpx 25rpx;
+  background-color: #ffffff;
+  .poster_img {
+    width: 700rpx;
+    display: block;
+  }
+}
+.read_total {
+  width: 700rpx;
+  color: #999999;
+  display: block;
+  font-size: 26rpx;
+  overflow: hidden;
+  line-height: 60rpx;
+  padding: 0rpx 25rpx;
+  margin-bottom: 122rpx;
+  background-color: #ffffff;
+}
+.handle_box {
+  left: 0rpx;
+  width: 700rpx;
+  height: 120rpx;
+  display: block;
+  position: fixed;
+  overflow: hidden;
+  padding: 20rpx 25rpx;
+  background-color: #ffffff;
+  bottom: var(--window-bottom);
+  border-top: 2rpx solid #dddddd;
+  .click_box {
+    border: none;
+    float: right;
+    display: block;
+    height: 120rpx;
+    padding: 0rpx 0rpx;
+    line-height: 120rpx;
+    margin-right: 20rpx;
+    font-size: 24rpx !important;
+    background-color: transparent;
+    .uni-icons {
+      font-size: 36rpx !important;
+    }
+  }
+  .click_box::after {
+    border: none;
+    background-color: transparent;
+  }
+}
 </style>

+ 239 - 165
pages/balance/index.vue

@@ -1,176 +1,250 @@
 <template>
-	<view class="balance">
-		<!-- <view class="date_picker">
+  <view class="balance">
+    <!-- <view class="date_picker">
       <picker mode="date" :value="selectedDate" fields="month" @change="_bindDateChange">
         <view>{{ formattedDate }}</view>
       </picker>
     </view> -->
-		<view class="balance_list">
-			<!-- <view class="balance_date">2025年1月</view> -->
-			<view class="balance_item" @click="_goDetail(item.id)" v-for="(item, index) in balanceList" :key="item.id">
-				<view class="balance_item_fix">
-					<view class="balance_item_left">
-						<view style="margin-bottom: 10rpx">{{ item.type_state }}
-							<text v-if="item.state" style="font-size: 20rpx">
-								({{ item.state }})
-							</text>
-						</view>
-						<view>{{ item.insert_time }}</view>
-					</view>
-					<view class="balance_item_right">
-						<view class="price">{{ item.prefix == 1 ? "+" : "-" }}{{ item.amount }}</view>
-						<view>余额:{{ item.balance }}</view>
-					</view>
-				</view>
-				<view class="alter_info"v-if="item.buy_type == 2 && item.status == 1" >若提现不成功,将在24小时内返回您的余额,可重新提现</view>
-			</view>
-		</view>
-		<Empty v-if="balanceList.length == 0 && !isReqing" text="----- 还没有记录啦 -----" />
-		<view class="to_bottom" v-if="isLast && balanceList.length"> -----到底啦-----</view>
-	</view>
+    <view class="balance_content">
+      <view class="balance_content_main">
+        <view style="display: flex">
+          <view class="price_content" style="margin-right: 45rpx">
+            <text class="title">当前余额(元)</text> <text>{{ Number(userInfo.amount || 0).toFixed(2) }}</text></view
+          >
+          <view class="price_content">
+            <text class="title">已成功提现(元)</text> <text>{{ Number(userInfo.transfer_amount || 0).toFixed(2) }}</text></view
+          >
+        </view>
+        <view class="withdraw_btn" @click="_goWithdraw">兑现</view>
+      </view>
+    </view>
+    <view class="balance_list">
+      <!-- <view class="balance_date">2025年1月</view> -->
+      <view class="balance_item" @click="_goDetail(item.id)" v-for="(item, index) in balanceList" :key="item.id">
+        <view class="balance_item_fix">
+          <view class="balance_item_left">
+            <view style="margin-bottom: 10rpx"
+              >{{ item.type_state }}
+              <text v-if="item.state" style="font-size: 20rpx"> ({{ item.state }}) </text>
+            </view>
+            <view>{{ item.insert_time }}</view>
+          </view>
+          <view class="balance_item_right">
+            <view class="price">{{ item.prefix == 1 ? '+' : '-' }}{{ item.amount }}</view>
+            <view>余额:{{ item.balance }}</view>
+          </view>
+        </view>
+        <view class="alter_info" v-if="item.buy_type == 2 && item.status == 1">若提现不成功,将在24小时内返回您的余额,可重新提现</view>
+      </view>
+    </view>
+    <Empty v-if="balanceList.length == 0 && !isReqing" text="----- 还没有记录啦 -----" />
+    <view class="to_bottom" v-if="isLast && balanceList.length"> -----到底啦-----</view>
+  </view>
 </template>
 
 <script setup>
-	import {
-		ref,
-		computed,
-		onMounted
-	} from "vue";
-	import {
-		onReachBottom,
-		onPullDownRefresh
-	} from "@dcloudio/uni-app";
-	import Empty from "@/components/Empty/Empty.vue";
-	import http from "@/utils/request";
-
-	const selectedDate = ref("请选择日期");
-	const balanceList = ref([]);
-	const page = ref(1);
-	const pageSize = ref(15);
-	const isLast = ref(false);
-	const isReqing = ref(false);
-
-	const _bindDateChange = (e) => {
-		selectedDate.value = e.detail.value;
-	};
-
-	onMounted(() => {
-		_getBalacnelist();
-	});
-
-	const _goDetail = (record_id) => {
-		uni.navigateTo({
-			url: `/pages/balance/detail?record_id=${record_id}`,
-		});
-	};
-
-	const _getBalacnelist = async () => {
-		if (isReqing.value) return;
-		isReqing.value = true;
-
-		try {
-			const callback = await http.request("api/custom_amount/get_record_list", {
-				page: page.value,
-				limit: pageSize.value
-			});
-			if (callback.code == "success") {
-				if (callback.data.last_page <= page.value) isLast.value = true;
-				const balanceListData = callback.data.data || [];
-				balanceList.value = [...balanceList.value, ...balanceListData];
-			}
-		} finally {
-			isReqing.value = false;
-		}
-	};
-
-	onReachBottom(async () => {
-		console.log("上拉加载");
-		if (isLast.value || isReqing.value) return;
-		page.value += 1;
-		await _getBalacnelist();
-	});
-
-	onPullDownRefresh(async () => {
-		page.value = 1;
-		balanceList.value = [];
-		isLast.value = false;
-		await _getBalacnelist();
-		uni.stopPullDownRefresh();
-	});
-
-	const formattedDate = computed(() => {
-		if (selectedDate.value === "请选择日期") {
-			return selectedDate.value;
-		}
-		const [year, month] = selectedDate.value.split("-");
-		return `${year}年${parseInt(month)}月`;
-	});
+import { ref, computed, onMounted } from 'vue';
+import { onReachBottom, onPullDownRefresh } from '@dcloudio/uni-app';
+import Empty from '@/components/Empty/Empty.vue';
+import http from '@/utils/request';
+
+const selectedDate = ref('请选择日期');
+const balanceList = ref([]);
+const page = ref(1);
+const pageSize = ref(15);
+const isLast = ref(false);
+const isReqing = ref(false);
+const userInfo = ref({
+  amount: 0,
+  transfer_amount: 0,
+});
+
+const _bindDateChange = (e) => {
+  selectedDate.value = e.detail.value;
+};
+
+onMounted(() => {
+  _getBalacnelist();
+  _getUserInfo();
+});
+
+const _goDetail = (record_id) => {
+  uni.navigateTo({
+    url: `/pages/balance/detail?record_id=${record_id}`,
+  });
+};
+
+const _getBalacnelist = async () => {
+  if (isReqing.value) return;
+  isReqing.value = true;
+
+  try {
+    const callback = await http.request('api/custom_amount/get_record_list', {
+      page: page.value,
+      limit: pageSize.value,
+    });
+    if (callback.code == 'success') {
+      if (callback.data.last_page <= page.value) isLast.value = true;
+      const balanceListData = callback.data.data || [];
+      balanceList.value = [...balanceList.value, ...balanceListData];
+    }
+  } finally {
+    isReqing.value = false;
+  }
+};
+
+const _getUserInfo = async () => {
+  try {
+    const callback = await http.request('api/custom/get_info');
+    if (callback.code == 'success') {
+      // 赋值
+      userInfo.value = callback.data;
+      // 存储登录标识
+      uni.setStorageSync('userInfo', callback.data);
+    }
+  } catch (error) {
+    console.log(error);
+  }
+};
+
+onReachBottom(async () => {
+  console.log('上拉加载');
+  if (isLast.value || isReqing.value) return;
+  page.value += 1;
+  await _getBalacnelist();
+});
+
+onPullDownRefresh(async () => {
+  page.value = 1;
+  balanceList.value = [];
+  isLast.value = false;
+  await _getBalacnelist();
+  uni.stopPullDownRefresh();
+});
+
+const formattedDate = computed(() => {
+  if (selectedDate.value === '请选择日期') {
+    return selectedDate.value;
+  }
+  const [year, month] = selectedDate.value.split('-');
+  return `${year}年${parseInt(month)}月`;
+});
+
+const _goWithdraw = () => {
+  // #ifdef MP-WEIXIN
+  uni.navigateTo({
+    url: '/pages/user/withdraw',
+  });
+  // #endif
+  // #ifdef H5
+  uni.showModal({
+    title: '温馨提示',
+    content: '请前往小程序兑现',
+    showCancel: false,
+  });
+  // #endif
+};
 </script>
 
 <style scoped lang="less">
-	.balance {
-		padding: 36rpx;
-		box-sizing: border-box;
-		width: 100vw;
-
-		.date_picker {
-			padding: 0 16rpx;
-			border: 1px solid #e5e5e5;
-			width: 250rpx;
-			height: 60rpx;
-			line-height: 60rpx;
-			margin-bottom: 40rpx;
-		}
-
-		.balance_list {
-			.balance_date {
-				font-weight: bold;
-				padding-bottom: 20rpx;
-				border-bottom: 2rpx solid #ddd;
-			}
-			.balance_item {
-				border-bottom: 1px solid #ddd;
-				padding-bottom: 20rpx;
-				.balance_item_fix {
-					display: flex;
-					justify-content: space-between;
-					align-items: center;
-					.balance_item_left,
-					.balance_item_right {
-						display: flex;
-						flex-direction: column;
-						font-size: 26rpx;
-						padding-top: 20rpx;
-					}
-
-					.balance_item_right {
-						align-items: flex-end;
-
-						>.price {
-							font-weight: bold;
-							margin-bottom: 10rpx;
-
-							&.red {
-								color: #ff0000;
-							}
-
-							&.green {
-								color: #00ff00;
-							}
-						}
-					}
-				}
-			}
-
-			.alter_info {
-				display: block;
-				color: #e03519;
-				font-size: 20rpx;
-				overflow: hidden;
-				margin: 0rpx auto;
-				line-height: 40rpx;
-				padding: 5rpx 0rpx;
-			}
-		}
-	}
-</style>
+.balance {
+  padding: 36rpx;
+  box-sizing: border-box;
+  width: 100vw;
+  .balance_content {
+    margin-bottom: 20rpx;
+    padding: 35rpx;
+    background-color: #fff;
+    box-sizing: border-box;
+    border-radius: 20rpx;
+    position: sticky;
+    top: 0;
+    left: 0;
+    right: 0;
+    width: 100%;
+    box-sizing: border-box;
+    .balance_content_main {
+      display: flex;
+      justify-content: space-between;
+      align-items: center;
+
+      .price_content {
+        display: flex;
+        flex-direction: column;
+        > .title {
+          font-size: 24rpx;
+          margin-bottom: 15rpx;
+        }
+      }
+      .withdraw_btn {
+        color: #ffffff;
+        background-color: #f89c33;
+        border-radius: 60rpx;
+        padding: 10rpx 20rpx;
+        width: 90rpx;
+        text-align: center;
+        line-height: 40rpx;
+      }
+    }
+  }
+  .date_picker {
+    padding: 0 16rpx;
+    border: 1px solid #e5e5e5;
+    width: 250rpx;
+    height: 60rpx;
+    line-height: 60rpx;
+    margin-bottom: 40rpx;
+  }
+
+  .balance_list {
+    .balance_date {
+      font-weight: bold;
+      padding-bottom: 20rpx;
+      border-bottom: 2rpx solid #ddd;
+    }
+    .balance_item {
+      border-bottom: 1px solid #ddd;
+      padding-bottom: 20rpx;
+      .balance_item_fix {
+        display: flex;
+        justify-content: space-between;
+        align-items: center;
+        .balance_item_left,
+        .balance_item_right {
+          display: flex;
+          flex-direction: column;
+          font-size: 26rpx;
+          padding-top: 20rpx;
+        }
+
+        .balance_item_right {
+          align-items: flex-end;
+
+          > .price {
+            font-weight: bold;
+            margin-bottom: 10rpx;
+
+            &.red {
+              color: #ff0000;
+            }
+
+            &.green {
+              color: #00ff00;
+            }
+          }
+        }
+      }
+    }
+
+    .alter_info {
+      display: block;
+      color: #f89c33;
+      font-size: 20rpx;
+      overflow: hidden;
+      margin: 0rpx auto;
+      line-height: 40rpx;
+      padding: 5rpx 0rpx;
+    }
+  }
+}
+</style>

+ 12 - 12
pages/bind/user.vue

@@ -13,9 +13,9 @@ export default {
   data() {
     return {
       requestParam: {
-        code: "",
-        kailin_uid: "",
-        work_userid: "",
+        code: '',
+        kailin_uid: '',
+        work_userid: '',
       },
       alloRequest: false,
     };
@@ -36,27 +36,27 @@ export default {
   methods: {
     getPhonenumber(re) {
       // 如果授权失败的话
-      if (re.detail.errMsg != "getPhoneNumber:ok") {
+      if (re.detail.errMsg != 'getPhoneNumber:ok') {
         uni.showToast({
-          icon: "error",
-          title: "授权失败",
+          icon: 'error',
+          title: '授权失败',
         });
         return;
       }
       // 获取授权码
       this.requestParam.code = re.detail.code;
       // 授权成功以后,调用登录
-      this.$http.request("api/work_bind/custom", this.requestParam, "post").then((re) => {
+      this.$http.request('api/work_bind/custom', this.requestParam, 'post').then((re) => {
         // 成功的话
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 存储登录标识
-          uni.setStorageSync("userLogin", re.data);
+          uni.setStorageSync('userLogin', re.data);
           // 跳转到页面
-          uni.switchTab({ url: "/pages/user/index" });
+          uni.switchTab({ url: '/pages/user/index' });
         } else {
           uni.showToast({
             title: re.msg,
-            icon: "none",
+            icon: 'none',
           });
         }
       });
@@ -95,7 +95,7 @@ export default {
 }
 .alter_info {
   display: block;
-  color: #e03519;
+  color: #f89c33;
   font-size: 20rpx;
   overflow: hidden;
   margin: 20rpx auto;

+ 47 - 45
pages/car/index.vue

@@ -32,7 +32,7 @@
                   <navigator :url="'/pages/product/index?product_id=' + item.product_id">
                     <image class="car_image" :src="item.thumb" mode=""></image>
                     <view class="product_status" v-if="item.product_status !== 0">
-                      {{ item.stock == 0 ? "已售罄" : "已下架" }}
+                      {{ item.stock == 0 ? '已售罄' : '已下架' }}
                     </view>
                   </navigator>
                 </view>
@@ -56,7 +56,7 @@
                     </button>
                   </view>
                   <view class="pay_title">
-                    <text class="pay_title_text">{{ item.is_pay?'支付商品':'预约商品' }}</text>
+                    <text class="pay_title_text">{{ item.is_pay ? '支付商品' : '预约商品' }}</text>
                   </view>
                 </view>
               </view>
@@ -78,14 +78,15 @@
       <view class="price_box">
         合计:<text class="price_total">¥{{ priceTotal }}</text>
       </view>
-      <view class="to_order" @click="toOrder()">{{is_pay?'购买':'预约'}}</view>
+      <view class="to_order" @click="toOrder()">{{ is_pay ? '购买' : '预约' }}</view>
     </view>
+    <cc-myTabbar :tabBarShow="3"></cc-myTabbar>
   </view>
 </template>
 
 <script>
-import Empty from "@/components/Empty/Empty.vue";
-import SwipeAction from "@/components/SwipeAction/SwipeAction.vue";
+import Empty from '@/components/Empty/Empty.vue';
+import SwipeAction from '@/components/SwipeAction/SwipeAction.vue';
 export default {
   components: { Empty, SwipeAction },
   data() {
@@ -95,7 +96,7 @@ export default {
       // 是否全选
       checkedAll: false,
       // 总价
-      priceTotal: "0.00",
+      priceTotal: '0.00',
       // 是否请求中
       isReqing: false,
       //购物车列表
@@ -106,10 +107,11 @@ export default {
   },
   onLoad() {
     // #ifdef MP-WEIXIN
+    uni.hideTabBar();
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
     // #endif
   },
@@ -118,13 +120,13 @@ export default {
     let shareList = getApp().globalData.shareList;
     // 获取分享信息
     let shareObj = {
-      title: "999智控终端平台\n药优惠 得积分 兑豪礼",
-      path: "/pages/index/index",
-      imageUrl: "",
+      title: '999智控终端平台\n药优惠 得积分 兑豪礼',
+      path: '/pages/index/index',
+      imageUrl: '',
     };
     // 循环列表
     for (let i in shareList) {
-      if (shareList[i].pages == "pages/car/index") {
+      if (shareList[i].pages == 'pages/car/index') {
         shareObj.path = shareList[i].path ? shareList[i].path : shareObj.path;
         shareObj.title = shareList[i].title ? `999智控终端平台\n${shareList[i].title}` : shareObj.title;
         shareObj.imageUrl = shareList[i].image_url ? shareList[i].image_url : shareObj.imageUrl;
@@ -143,11 +145,11 @@ export default {
     // 非全选
     this.checkedAll = 0;
     // 请求列表
-    this.$http.request("api/shop_cart/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/shop_cart/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         // 赋值
 
         this.cartListByGroup = this.formatGroupedData(re.data);
@@ -162,8 +164,8 @@ export default {
     // 未登录不请求
     if (!this.$checkAccess.checkLogin()) return;
     // 请求列表
-    this.$http.request("api/shop_cart/get_list", this.requestParam).then((re) => {
-      if (re.code == "success") {
+    this.$http.request('api/shop_cart/get_list', this.requestParam).then((re) => {
+      if (re.code == 'success') {
         // 赋值
         this.cartListByGroup = this.formatGroupedData(re.data);
 
@@ -222,8 +224,8 @@ export default {
         this.cartListByGroup[pIndex].products[index].buy_num = this.cartListByGroup[pIndex].products[index].stock;
         // 提示
         uni.showToast({
-          title: "购买数量不能大于库存",
-          icon: "none",
+          title: '购买数量不能大于库存',
+          icon: 'none',
         });
         return;
       }
@@ -233,25 +235,25 @@ export default {
         this.cartListByGroup[pIndex].products[index].buy_num = 1;
         // 提示
         uni.showToast({
-          title: "数量不可小于1",
-          icon: "none",
+          title: '数量不可小于1',
+          icon: 'none',
         });
         return;
       }
       // 请求列表
       this.$http
-        .request("api/shop_cart/edit", {
+        .request('api/shop_cart/edit', {
           id: this.cartListByGroup[pIndex].products[index].id,
           buy_num: this.cartListByGroup[pIndex].products[index].buy_num,
         })
         .then((re) => {
-          if (re.code == "success") {
+          if (re.code == 'success') {
             // 计算价格
             this.priceHandler();
           } else {
             uni.showToast({
               title: re.msg,
-              icon: "none",
+              icon: 'none',
             });
           }
         });
@@ -259,17 +261,17 @@ export default {
     // 删除购物车
     deleteCar(pIndex, index) {
       uni.showModal({
-        title: "是否删除?",
+        title: '是否删除?',
         success: (re) => {
           if (re.confirm) {
             // 请求列表
             this.$http
-              .request("api/shop_cart/del", {
+              .request('api/shop_cart/del', {
                 id: this.cartListByGroup[pIndex].products[index].id,
               })
               .then((re) => {
                 // 如果删除成功的话
-                if (re.code == "success") {
+                if (re.code == 'success') {
                   this.cartListByGroup[pIndex].products.splice(index, 1);
                   // 计算价格
                   this.priceHandler();
@@ -345,24 +347,24 @@ export default {
           if (item.checked) {
             priceTotal = this.$decimal.add(priceTotal, this.$decimal.mul(item.price, item.buy_num));
             if (item.is_pay == 0) {
-              reservation_status    = true;
+              reservation_status = true;
             }
             if (item.is_pay == 1) {
-              pay_status            = true;
+              pay_status = true;
             }
           }
         });
       }
-      if (pay_status && reservation_status){
-        this.is_pay     = 2;
-      }else if(pay_status){
-        this.is_pay     = 1;
-      }else if(reservation_status){
-        this.is_pay     = 0;
-      }else {
-        this.is_pay     = 0;
+      if (pay_status && reservation_status) {
+        this.is_pay = 2;
+      } else if (pay_status) {
+        this.is_pay = 1;
+      } else if (reservation_status) {
+        this.is_pay = 0;
+      } else {
+        this.is_pay = 0;
       }
-      console.log(this.is_pay)
+      console.log(this.is_pay);
       // 小数点处理
       this.priceTotal = priceTotal.toFixed(2);
     },
@@ -370,7 +372,7 @@ export default {
       // 等待支付的信息
       let waitList = [];
       if (this.is_pay == 2) {
-        uni.showToast({ icon: "none", title: "混合商品,无法下单" });
+        uni.showToast({ icon: 'none', title: '混合商品,无法下单' });
         return;
       }
       // 循环处理
@@ -380,12 +382,12 @@ export default {
           if (this.cartListByGroup[index].products[key].checked) {
             // 如果库存不足
             if (this.cartListByGroup[index].products[key].buy_num < 1) {
-              uni.showToast({ icon: "none", title: "选择的产品至少需要1个" });
+              uni.showToast({ icon: 'none', title: '选择的产品至少需要1个' });
               return;
             }
             // 如果库存不足
             if (this.cartListByGroup[index].products[key].buy_num > this.cartListByGroup[index].products[key].stock) {
-              uni.showToast({ icon: "none", title: "产品库存不足" });
+              uni.showToast({ icon: 'none', title: '产品库存不足' });
               return;
             }
             waitList.push(this.cartListByGroup[index].products[key].id);
@@ -394,16 +396,16 @@ export default {
       }
       // 如果没有选择
       if (!waitList.length) {
-        uni.showToast({ icon: "none", title: "请选择需要结算的产品" });
+        uni.showToast({ icon: 'none', title: '请选择需要结算的产品' });
         return;
       }
       // 如果没有选择
       if (waitList.length > 99) {
-        uni.showToast({ icon: "none", title: "这么多产品一个预约单写不下哦" });
+        uni.showToast({ icon: 'none', title: '这么多产品一个预约单写不下哦' });
         return;
       }
       uni.navigateTo({
-        url: "/pages/car/order?cart_ids=" + waitList.join(","),
+        url: '/pages/car/order?cart_ids=' + waitList.join(','),
       });
     },
     clickItem(e) {
@@ -622,7 +624,7 @@ export default {
   overflow: hidden;
   background: #ffffff;
   padding: 0rpx 35rpx;
-  bottom: var(--window-bottom);
+  bottom: 140rpx;
   .check_all_label {
     float: left;
     width: 120rpx;
@@ -638,7 +640,7 @@ export default {
     .checkbox.active {
       border: 2rpx solid red;
       .checkbox_active {
-        background-color: #e03519;
+        background-color: #f89c33;
       }
     }
     .checkall {
@@ -675,7 +677,7 @@ export default {
     padding: 0rpx 0rpx;
     text-align: center;
     border-radius: 30rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
   }
 }
 </style>

+ 2 - 2
pages/car/order.vue

@@ -797,7 +797,7 @@ export default {
     padding: 0rpx 0rpx;
     text-align: center;
     border-radius: 40rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
   }
 }
 
@@ -1021,7 +1021,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 26 - 26
pages/coupon/active.vue

@@ -67,16 +67,16 @@ export default {
       // 活动信息
       activeInfo: {
         id: 0,
-        name: "",
-        banner_img: "",
-        active_rule: "",
+        name: '',
+        banner_img: '',
+        active_rule: '',
         status: 0,
         start_time: 0,
         end_time: 0,
-        city_ids: "",
+        city_ids: '',
         allow_join: 0,
-        start_date: "",
-        end_date: "",
+        start_date: '',
+        end_date: '',
         coupon_list: [],
         product_list: [],
       },
@@ -99,22 +99,22 @@ export default {
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
     // #endif
   },
   onShareAppMessage(obj) {
     return {
       title: `999智控终端平台\n${this.activeInfo.name}`,
-      path: "/pages/coupon/active?id=" + this.requestParam.id,
+      path: '/pages/coupon/active?id=' + this.requestParam.id,
       promise: new Promise((resolve, reject) => {
-        this.$http.request("api/share_message/get_item", { item_id: this.requestParam.id, pages: "/pages/coupon/active" }).then((callback) => {
-          console.log(callback, "api/share_message/get_item");
+        this.$http.request('api/share_message/get_item', { item_id: this.requestParam.id, pages: '/pages/coupon/active' }).then((callback) => {
+          console.log(callback, 'api/share_message/get_item');
           let obj = {
-            title: callback.data?.title == "" ? `999智控终端平台\n${this.activeInfo.name}` : callback.data.title,
-            path: "/pages/coupon/active?id=" + this.requestParam.id,
+            title: callback.data?.title == '' ? `999智控终端平台\n${this.activeInfo.name}` : callback.data.title,
+            path: '/pages/coupon/active?id=' + this.requestParam.id,
           };
-          if (callback.data?.image_url !== "") {
+          if (callback.data?.image_url !== '') {
             obj.imageUrl = callback.data.image_url;
           }
           resolve(obj);
@@ -128,15 +128,15 @@ export default {
     // 如果存在产品ID的话
     if (this.requestParam.id > 0) {
       // 请求详情
-      this.$http.request("api/coupon_active/get_detail", this.requestParam).then((re) => {
+      this.$http.request('api/coupon_active/get_detail', this.requestParam).then((re) => {
         // 成功渲染数据
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 刷新数据
           this.activeInfo = re.data;
           // 列表大于2.显示
           if (re.data.product_list.length <= 2) this.show_more_product = true;
         } else {
-          if (re.code != "no_login") {
+          if (re.code != 'no_login') {
             uni.showModal({
               content: re.msg,
               showCancel: false,
@@ -146,7 +146,7 @@ export default {
       });
     } else {
       uni.showModal({
-        content: "未知的活动ID",
+        content: '未知的活动ID',
         showCancel: false,
       });
     }
@@ -155,20 +155,20 @@ export default {
     toUse(item) {
       // 没有范围
       if (item.type_id == 2) {
-        uni.switchTab({ url: "/pages/index/index" });
+        uni.switchTab({ url: '/pages/index/index' });
         return;
       }
       // 只有一个商品,直接跳转到对应商品
       if (item.product_scope.length == 1) {
         uni.navigateTo({
-          url: "/pages/product/index?product_id=" + item.product_scope[0],
+          url: '/pages/product/index?product_id=' + item.product_scope[0],
         });
         return;
       }
       // 没有范围
       if (item.product_scope.length > 1) {
         uni.navigateTo({
-          url: "/pages/coupon/product?coupon_id=" + item.coupon_id,
+          url: '/pages/coupon/product?coupon_id=' + item.coupon_id,
         });
         return;
       }
@@ -179,7 +179,7 @@ export default {
       // 如果不能参与
       if (!this.activeInfo.allow_join) {
         uni.showModal({
-          content: "暂不可参与活动",
+          content: '暂不可参与活动',
           showCancel: false,
         });
         return;
@@ -187,9 +187,9 @@ export default {
       // 如果存在优惠券
       if (couponId > 0) {
         // 请求详情
-        this.$http.request("api/custom_coupon/get_coupon", { coupon_id: couponId }).then((re) => {
+        this.$http.request('api/custom_coupon/get_coupon', { coupon_id: couponId }).then((re) => {
           // 成功渲染数据
-          if (re.code == "success") {
+          if (re.code == 'success') {
             this.activeInfo.coupon_list[index].is_have = 1;
           } else {
             uni.showModal({
@@ -200,7 +200,7 @@ export default {
         });
       } else {
         uni.showModal({
-          content: "请选择要领取的优惠券",
+          content: '请选择要领取的优惠券',
           showCancel: false,
         });
       }
@@ -287,7 +287,7 @@ export default {
         height: 140rpx;
         display: block;
         .rebate {
-          color: #e03519;
+          color: #f89c33;
           height: 60rpx;
           overflow: hidden;
           font-size: 36rpx;
@@ -325,7 +325,7 @@ export default {
           text-align: center;
           padding: 0rpx 0rpx;
           border-radius: 10rpx;
-          background-color: #e03519;
+          background-color: #f89c33;
         }
       }
     }

+ 50 - 37
pages/index/index.vue

@@ -1,8 +1,7 @@
 <template>
-  <view>
+  <view class="index">
     <view class="page-title" />
     <!-- 轮播图 -->
-
     <view class="banner_box">
       <view class="banner_list" v-if="bannerList.length">
         <swiper class="banner_swiper" :autoplay="true">
@@ -15,9 +14,9 @@
     <view class="icon-list">
       <icon-list mode="row8" :icons="icons" :gap="0" />
     </view>
-    <view class="notice-list">
+    <!-- <view class="notice-list">
       <notice-list :noticeList="[{ text: '开邻智数新版本发布啦~' }, { text: '更多新功能敬请期待~' }]" gap="18" />
-    </view>
+    </view> -->
     <view class="header-title">
       <components-header title="专区导航" />
     </view>
@@ -78,6 +77,7 @@
     <uni-popup ref="addFollow" type="center" class="center_popup">
       <FollowPopup :closePopup="closePopup" />
     </uni-popup>
+    <cc-myTabbar :tabBarShow="0"></cc-myTabbar>
   </view>
 </template>
 
@@ -90,17 +90,17 @@ import ComponentsHeader from '@/components/ComponentsHeader';
 const Icons = [
   { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d3fed51fa2.ng', text: '全品', urlMap: { internal_url: '/pages/product/list' } },
   { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d3ffdea775.ng', text: '医保价', urlMap: { internal_url: '/pages/wait/index?id=1&name=医保价' } },
-  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d400fd5932.ng', text: '行业资讯', urlMap: { internal_url: '/pages/wait/index?id=2&name=行业资讯' } },
-  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d401d6a885.ng', text: '直播', urlMap: { internal_url: '/pages/wait/index?id=3&name=直播' } },
-  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d402ddaeb6.ng', text: '促销活动', urlMap: { internal_url: '/pages/wait/index?id=4&name=促销活动' } },
-  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d404366cf8.ng', text: '拼团包邮', urlMap: { internal_url: '/pages/wait/index?id=5&name=拼团包邮' } },
+  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d400fd5932.ng', text: '行业资讯', urlMap: { internal_url: '/pages/article/index' } },
+  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d401d6a885.ng', text: '直播', urlMap: { internal_url: '/pages/wait/index?id=101&name=直播' } },
+  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d402ddaeb6.ng', text: '促销活动', urlMap: { internal_url: '/pages/wait/index?id=2&name=促销活动' } },
+  { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d404366cf8.ng', text: '拼团包邮', urlMap: { internal_url: '/pages/wait/index?id=3&name=拼团包邮' } },
   { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d404c65d9f.ng', text: '积分商城', urlMap: { internal_url: '/pages/score/index' } },
   { image: 'https://openwork-oss.oss-cn-shenzhen.aliyuncs.com/uploads/c/1/s/92/up/20250521/682d40561a23b.ng', text: '领卷中心', urlMap: { internal_url: '/pages/coupon/index' } },
 ];
 const Banners = [
-  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/active.png', text: '区域活动', urlMap: { internal_url: '/pages/wait/index?id=8&name=区域活动' } },
-  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/b2b.png', text: 'B2B专供', urlMap: { internal_url: '/pages/wait/index?id=9&name=B2B专供' } },
-  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/exp.png', text: '近效期', urlMap: { internal_url: '/pages/wait/index?id=10&name=近效期' } },
+  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/active.png', text: '区域活动', urlMap: { internal_url: '/pages/wait/index?id=4&name=区域活动' } },
+  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/b2b.png', text: 'B2B专供', urlMap: { internal_url: '/pages/wait/index?id=5&name=B2B专供' } },
+  { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/exp.png', text: '近效期', urlMap: { internal_url: '/pages/wait/index?id=6&name=近效期' } },
   { image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/heath.png', text: '大健康', urlMap: { internal_url: '/pages/wait/index?id=11&name=大健康' } },
 ];
 export default {
@@ -115,6 +115,7 @@ export default {
       requestParam: {
         name: '',
         page: 1,
+        get_top: 1,
       },
       // 是否最后一页
       isLast: false,
@@ -134,6 +135,7 @@ export default {
   },
   onLoad() {
     // #ifdef MP-WEIXIN
+    uni.hideTabBar();
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
@@ -258,30 +260,30 @@ export default {
     });
     uni.stopPullDownRefresh();
   },
-  onReachBottom() {
-    // 如果页码是0,避免第一页重复
-    if (this.requestParam.page < 1) return;
-    // 最后一页不再请求
-    if (this.isLast) return;
-    // 请求中,不再请求
-    if (this.isReqing) return;
-    // 增加一页
-    this.requestParam.page = this.requestParam.page + 1;
-    // 设置请求中
-    this.isReqing = true;
-    // 请求列表
-    this.$http.request('api/product/get_list', this.requestParam).then((re) => {
-      // 设置非请求中
-      this.isReqing = false;
-      // 成功结果
-      if (re.code == 'success') {
-        // 最后一页
-        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
-        // 追加数据
-        this.productList.push(...re.data.data);
-      }
-    });
-  },
+  // onReachBottom() {
+  //   // 如果页码是0,避免第一页重复
+  //   if (this.requestParam.page < 1) return;
+  //   // 最后一页不再请求
+  //   if (this.isLast) return;
+  //   // 请求中,不再请求
+  //   if (this.isReqing) return;
+  //   // 增加一页
+  //   this.requestParam.page = this.requestParam.page + 1;
+  //   // 设置请求中
+  //   this.isReqing = true;
+  //   // 请求列表
+  //   this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+  //     // 设置非请求中
+  //     this.isReqing = false;
+  //     // 成功结果
+  //     if (re.code == 'success') {
+  //       // 最后一页
+  //       if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+  //       // 追加数据
+  //       this.productList.push(...re.data.data);
+  //     }
+  //   });
+  // },
   methods: {
     // 请求加载下一页
     getMore(callback) {
@@ -367,9 +369,17 @@ export default {
 </script>
 
 <style lang="less">
+.index {
+  // background-image: url(https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/index_header.png);
+  // background-position: 0% 0%;
+  // background-repeat: no-repeat;
+  // background-size: 750rpx 588rpx;
+}
 .page-title {
   //渐变加透明;
   // background: linear-gradient(to bottom, rgba(245, 52, 29, 1) 0%, rgba(255, 255, 255, 0) 100%);
+  // background: linear-gradient(180deg, #ea310f 0%, #f5f5f5 100%);
+  // background: url() no-repeat 100% 100%;
   position: absolute;
   top: 0;
   left: 0;
@@ -404,7 +414,7 @@ export default {
       text-overflow: ellipsis;
     }
     .city_name.uncheck {
-      color: #e03519;
+      color: #f89c33;
     }
     .search_input {
       z-index: 0;
@@ -418,6 +428,7 @@ export default {
       border-top-left-radius: 40rpx;
       border-bottom-left-radius: 40rpx;
       border: 2rpx solid #dddddd;
+      background-color: #ffffff;
     }
     .search_btn {
       top: 0rpx;
@@ -433,7 +444,7 @@ export default {
       padding: 0rpx 0rpx;
       line-height: 60rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }
@@ -469,6 +480,7 @@ export default {
   overflow: hidden;
   margin: -20rpx auto 20rpx;
   padding: 0rpx 35rpx;
+  padding-bottom: calc(env(safe-area-inset-bottom) + 100rpx);
   .product_list {
     display: block;
     overflow: hidden;
@@ -569,6 +581,7 @@ export default {
         color: 26rpx;
         text-align: center;
         line-height: 60rpx;
+        font-size: 24rpx;
       }
     }
     .product_item:nth-child(even) {

+ 43 - 43
pages/login/index.vue

@@ -11,19 +11,19 @@
       <button @click="toPhoneLogin" class="get_phone">授权登录</button>
       <!-- #endif -->
       <!-- #ifdef MP-TOUTIAO -->
-		<button open-type="getPhoneNumber" @getphonenumber="getPhonenumber" class="get_phone">抖音用户手机号授权登录</button>
-		<!-- <button class="get_phone" style="margin-top: 40rpx; background-color: #fff; color: #333">手机号验证登录</button> -->
-		<view class="policy_content">
-		  <image
-			class="checkbox"
-			@click="changeAgreePolicy"
-			:src="agreePolicy ? 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/checked.png' : 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/checkbox.png'"
-		  ></image>
-		  我已阅读并同意
-		  <navigator url="/pages/policy/index" style="color: #e03519">《服务协议》</navigator>
-		</view>
+      <button open-type="getPhoneNumber" @getphonenumber="getPhonenumber" class="get_phone">抖音用户手机号授权登录</button>
+      <!-- <button class="get_phone" style="margin-top: 40rpx; background-color: #fff; color: #333">手机号验证登录</button> -->
+      <view class="policy_content">
+        <image
+          class="checkbox"
+          @click="changeAgreePolicy"
+          :src="agreePolicy ? 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/checked.png' : 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/checkbox.png'"
+        ></image>
+        我已阅读并同意
+        <navigator url="/pages/policy/index" style="color: #f89c33">《服务协议》</navigator>
+      </view>
       <!-- #endif -->
-		<button  class="cancel_login" @click="cancelLogin()">取消登录</button>
+      <button class="cancel_login" @click="cancelLogin()">取消登录</button>
     </view>
   </view>
 </template>
@@ -47,53 +47,53 @@ export default {
     changeAgreePolicy() {
       this.agreePolicy = !this.agreePolicy;
     },
-	cancelLogin(){
-		// 返回上一页
-		uni.navigateBack();
-	},
+    cancelLogin() {
+      // 返回上一页
+      uni.navigateBack();
+    },
     getPhonenumber(re) {
       // // 如果授权失败的话
-      if (re.detail.errMsg != "getPhoneNumber:ok") {
+      if (re.detail.errMsg != 'getPhoneNumber:ok') {
         uni.showToast({
-          icon: "error",
-          title: "授权失败",
+          icon: 'error',
+          title: '授权失败',
         });
         return;
       }
       // 授权成功以后,调用登录
-      this.$http.request("api/wechat/phone_number", { code: re.detail.code }, "post").then((re) => {
+      this.$http.request('api/wechat/phone_number', { code: re.detail.code }, 'post').then((re) => {
         // 成功的话
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 存储登录标识
-          uni.setStorageSync("userLogin", re.data);
+          uni.setStorageSync('userLogin', re.data);
           // 跳转到页面
           if (this.redirect) {
             let url = this.redirect;
-            if (this.activity_id) url = url + "?id=" + this.activity_id;
-            if (this.id) url = url + "?id=" + this.id;
+            if (this.activity_id) url = url + '?id=' + this.activity_id;
+            if (this.id) url = url + '?id=' + this.id;
             uni.redirectTo({ url: url });
-          } else uni.switchTab({ url: "/pages/user/index" });
+          } else uni.switchTab({ url: '/pages/user/index' });
         } else {
           uni.showToast({
             title: re.msg,
-            icon: "none",
+            icon: 'none',
           });
         }
       });
     },
     toPhoneLogin(re) {
       // 登录效果
-      this.$http.request("api/wechat/phone_number", this.requestParam).then((re) => {
+      this.$http.request('api/wechat/phone_number', this.requestParam).then((re) => {
         // 成功的话
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 存储登录标识
-          uni.setStorageSync("userLogin", re.data);
+          uni.setStorageSync('userLogin', re.data);
           // 跳转到页面
-          uni.switchTab({ url: "/pages/user/index" });
+          uni.switchTab({ url: '/pages/user/index' });
         } else {
           uni.showToast({
             title: re.msg,
-            icon: "none",
+            icon: 'none',
           });
         }
       });
@@ -143,18 +143,18 @@ export default {
 .get_phone::after {
   border: 0rpx solid #dddddd;
 }
-.cancel_login{
-	display: block;
-	width: 100%;
-	height: 80rpx;
-	color: #666666;
-	font-size: 28rpx;
-	background: #dddddd;
-	margin: 0rpx auto;
-	line-height: 80rpx;
-	margin-top: 40rpx;
-	border-radius: 30rpx;
-	border: 0rpx solid #dddddd;
+.cancel_login {
+  display: block;
+  width: 100%;
+  height: 80rpx;
+  color: #666666;
+  font-size: 28rpx;
+  background: #dddddd;
+  margin: 0rpx auto;
+  line-height: 80rpx;
+  margin-top: 40rpx;
+  border-radius: 30rpx;
+  border: 0rpx solid #dddddd;
 }
 .cancel_login::after {
   border: 0rpx solid #dddddd;

+ 26 - 22
pages/orders/index.vue

@@ -56,7 +56,7 @@
 </template>
 
 <script>
-import Empty from "@/components/Empty/Empty.vue";
+import Empty from '@/components/Empty/Empty.vue';
 
 export default {
   components: {
@@ -77,7 +77,11 @@ export default {
       isReqing: false,
     };
   },
-  onLoad() {},
+  onLoad(param) {
+    if (param.status) {
+      this.requestParam.status = param.status;
+    }
+  },
   onShow() {
     // 登录提示
     if (!this.$checkAccess.alterLogin()) return;
@@ -90,11 +94,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/orders/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/orders/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         this.orderList = re.data.data;
       }
@@ -112,11 +116,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/orders/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/orders/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         this.orderList = re.data.data;
       }
@@ -137,11 +141,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/orders/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/orders/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         // 追加数据
         this.orderList.push(...re.data.data);
@@ -163,11 +167,11 @@ export default {
       // 设置请求中
       this.isReqing = true;
       // 请求列表
-      this.$http.request("api/orders/get_list", this.requestParam).then((re) => {
+      this.$http.request('api/orders/get_list', this.requestParam).then((re) => {
         // 设置非请求中
         this.isReqing = false;
         // 成功结果
-        if (re.code == "success") {
+        if (re.code == 'success') {
           if (re.data.last_page >= this.requestParam.page) this.isLast = true;
           this.orderList = re.data.data;
         }
@@ -179,12 +183,12 @@ export default {
     // 取消订单
     cancelOrder(index) {
       uni.showModal({
-        title: "确认取消该订单?",
+        title: '确认取消该订单?',
         success: (res) => {
           if (res.confirm) {
             // 请求列表
-            this.$http.request("api/orders/cancel", { id: this.orderList[index].id }).then((re) => {
-              this.orderList[index].state = "已取消";
+            this.$http.request('api/orders/cancel', { id: this.orderList[index].id }).then((re) => {
+              this.orderList[index].state = '已取消';
               this.orderList[index].status = 4;
             });
           }
@@ -213,12 +217,12 @@ export default {
     // 取消拼团
     cancelOrderRegiment(index) {
       uni.showModal({
-        title: "确认取消该订单?",
+        title: '确认取消该订单?',
         success: (res) => {
           if (res.confirm) {
             // 请求列表
-            this.$http.request("api/orders/cancel_regiment", { id: this.orderList[index].id }).then((re) => {
-              this.orderList[index].state = "已取消";
+            this.$http.request('api/orders/cancel_regiment', { id: this.orderList[index].id }).then((re) => {
+              this.orderList[index].state = '已取消';
               this.orderList[index].status = 4;
             });
           }
@@ -228,18 +232,18 @@ export default {
     navToProduct(id) {
       if (id) {
         uni.navigateTo({
-          url: "/pages/product/index?product_id=" + id,
+          url: '/pages/product/index?product_id=' + id,
         });
       }
     },
     toReceipt(item) {
       uni.navigateTo({
-        url: "/pages/orders/receipt?order_id=" + item.id,
+        url: '/pages/orders/receipt?order_id=' + item.id,
       });
     },
     goDetail(id) {
       uni.navigateTo({
-        url: "/pages/orders/detail?order_id=" + id,
+        url: '/pages/orders/detail?order_id=' + id,
       });
     },
   },
@@ -364,7 +368,7 @@ export default {
       .pay_total {
         float: right;
         height: 60rpx;
-        color: #e03519;
+        color: #f89c33;
         font-size: 28rpx;
         line-height: 60rpx;
       }
@@ -401,13 +405,13 @@ export default {
       .order_share {
         float: right;
         height: 50rpx;
-        color: #e03519;
+        color: #f89c33;
         font-size: 24rpx;
         padding: 0rpx 10rpx;
         line-height: 50rpx;
         margin-left: 10rpx;
         border-radius: 25rpx;
-        border: 2rpx solid #e03519;
+        border: 2rpx solid #f89c33;
         background-color: transparent;
       }
       .order_share::after {

+ 11 - 11
pages/orders/lottery.vue

@@ -110,7 +110,7 @@ export default {
         id: 0,
       },
       checkedAddr: {},
-	  isReqing:false,
+      isReqing: false,
     };
   },
   onLoad(param) {
@@ -197,8 +197,8 @@ export default {
       });
     },
     onClick() {
-	  // 没有数据的话,或者请求中,不允许刷新
-	  if (this.isReqing) return;
+      // 没有数据的话,或者请求中,不允许刷新
+      if (this.isReqing) return;
       // 活动是否开始
       if (!this.lotteryInfo.id) {
         uni.showToast({
@@ -231,8 +231,8 @@ export default {
         });
         return;
       }
-	  // 设置请求中
-	  this.isReqing = true;
+      // 设置请求中
+      this.isReqing = true;
       // 请求列表
       this.$http.request('/api/lottery_order/get_reward', { lottery_id: this.lotteryInfo.id }).then((re) => {
         // 设置非请求中
@@ -241,8 +241,8 @@ export default {
         if (re.code == 'success') {
           // 奖品列表更新
           this.prizeList = re.data.reward_list;
-		  // 次数操作
-		  this.lotteryInfo.join_num = this.lotteryInfo.join_num - 1;
+          // 次数操作
+          this.lotteryInfo.join_num = this.lotteryInfo.join_num - 1;
           // 奖品的索引
           return this.$refs.dialer.run(re.data.reward_index);
         } else {
@@ -262,11 +262,11 @@ export default {
     },
     showRecord() {
       // 没有数据的话,或者请求中,不允许刷新
-	  if (this.isReqing) return;
+      if (this.isReqing) return;
       // 活动是否开始
       if (this.lotteryInfo.id) {
-	    // 设置请求中
-		this.isReqing = true;
+        // 设置请求中
+        this.isReqing = true;
         // 请求列表
         this.$http.request('/api/lottery_order_record/get_list', { lottery_id: this.lotteryInfo.id }).then((re) => {
           // 设置非请求中
@@ -644,7 +644,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 17 - 17
pages/orders/receipt.vue

@@ -52,12 +52,12 @@ export default {
   data() {
     return {
       order_id: 0,
-      localImage: "",
+      localImage: '',
       orderInfo: {},
       shareInfo: {
-        title: "999智控终端平台\n我已经完成一笔订单,你也快来吧",
-        path: "/pages/index/index",
-        imageUrl: "",
+        title: '999智控终端平台\n我已经完成一笔订单,你也快来吧',
+        path: '/pages/index/index',
+        imageUrl: '',
       },
     };
   },
@@ -70,7 +70,7 @@ export default {
     // 判断订单ID
     if (this.order_id <= 0) {
       uni.showModal({
-        content: "未知的活动ID",
+        content: '未知的活动ID',
         showCancel: false,
       });
       return;
@@ -80,14 +80,14 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/orders/get_item", { id: this.order_id }).then((re) => {
+    this.$http.request('api/orders/get_item', { id: this.order_id }).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         this.orderInfo = re.data;
       } else {
-        if (re.code != "no_login") {
+        if (re.code != 'no_login') {
           uni.showModal({
             content: re.msg,
             showCancel: false,
@@ -103,8 +103,8 @@ export default {
     chooseImage() {
       uni.chooseImage({
         count: 1, // 默认9,设置图片的数量
-        sizeType: ["compressed"], // 可以指定是原图还是压缩图,默认二者都有
-        sourceType: ["album", "camera"], // 可以指定来源是相册还是相机,默认二者都有
+        sizeType: ['compressed'], // 可以指定是原图还是压缩图,默认二者都有
+        sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
         success: (chooseImageRes) => {
           let tempFilePaths = chooseImageRes.tempFilePaths;
           this.localImage = tempFilePaths[0];
@@ -115,7 +115,7 @@ export default {
       // 判断订单ID
       if (this.order_id <= 0) {
         uni.showModal({
-          content: "未知的活动ID",
+          content: '未知的活动ID',
           showCancel: false,
         });
         return;
@@ -123,7 +123,7 @@ export default {
       // 判断订单ID
       if (!this.localImage) {
         uni.showModal({
-          content: "请上传图片",
+          content: '请上传图片',
           showCancel: false,
         });
         return;
@@ -135,17 +135,17 @@ export default {
       // 设置请求中
       this.isReqing = true;
       // 请求列表
-      this.$http.fileupload("api/orders_receipt/apply", this.localImage, { order_id: this.order_id }).then((re) => {
+      this.$http.fileupload('api/orders_receipt/apply', this.localImage, { order_id: this.order_id }).then((re) => {
         // 设置非请求中
         uni.hideLoading();
         // 成功结果
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 赋值
           this.shareInfo = re.data.share_info;
           // 弹出提示
-          this.$refs.sharePopup.open("center");
+          this.$refs.sharePopup.open('center');
         } else {
-          if (re.code != "no_login") {
+          if (re.code != 'no_login') {
             // 设置请求中
             this.isReqing = false;
             // 允许请求
@@ -269,7 +269,7 @@ export default {
   }
 }
 .info_alter {
-  // color: #E03519;
+  // color: #F89C33;
   display: block;
   font-size: 26rpx;
   overflow: hidden;

+ 9 - 9
pages/product/index.vue

@@ -48,7 +48,7 @@
                 <view class="regiment_center_text">还差{{ item.surplus_number }}人成团</view>
                 <view class="regiment_center_time">
                   <view class="center_title">还剩</view>
-                  <uni-countdown color="#E03519" :show-day="false" :hour="remainder(item.end_time, 1)" :minute="remainder(item.end_time, 2)" :second="remainder(item.end_time, 3)"></uni-countdown>
+                  <uni-countdown color="#F89C33" :show-day="false" :hour="remainder(item.end_time, 1)" :minute="remainder(item.end_time, 2)" :second="remainder(item.end_time, 3)"></uni-countdown>
                 </view>
               </view>
             </view>
@@ -279,7 +279,7 @@
             <view class="regiment_center_text">还差{{ item.surplus_number }}人成团</view>
             <view class="regiment_center_time">
               <view class="center_title">还剩</view>
-              <uni-countdown color="#E03519" :show-day="false" :hour="remainder(item.end_time, 1)" :minute="remainder(item.end_time, 2)" :second="remainder(item.end_time, 3)"></uni-countdown>
+              <uni-countdown color="#F89C33" :show-day="false" :hour="remainder(item.end_time, 1)" :minute="remainder(item.end_time, 2)" :second="remainder(item.end_time, 3)"></uni-countdown>
             </view>
           </view>
         </view>
@@ -1387,7 +1387,7 @@ export default {
     padding: 0rpx 0rpx;
     text-align: center;
     margin-right: 35rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
     border-radius: 0rpx;
     border-top-right-radius: 20rpx;
     border-bottom-right-radius: 20rpx;
@@ -1404,7 +1404,7 @@ export default {
     padding: 0rpx 0rpx;
     text-align: center;
     margin-right: 35rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
     border-radius: 20rpx;
 
     .regiment_countdown {
@@ -1423,7 +1423,7 @@ export default {
     line-height: 80rpx;
     padding: 0rpx 0rpx;
     text-align: center;
-    background-color: #f59a23;
+    background-color: #e03519;
     border-radius: 0rpx;
     border-top-left-radius: 20rpx;
     border-bottom-left-radius: 20rpx;
@@ -1782,7 +1782,7 @@ export default {
         line-height: 80rpx;
         padding: 0rpx 0rpx;
         border-radius: 40rpx;
-        background-color: #e03519;
+        background-color: #f89c33;
         border: 0rpx solid transparent;
       }
 
@@ -1990,7 +1990,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 
@@ -2051,7 +2051,7 @@ export default {
 
         .regiment_but {
           font-size: 25rpx;
-          background-color: #e03519;
+          background-color: #f89c33;
           color: #f9f9f9;
         }
       }
@@ -2222,7 +2222,7 @@ export default {
 
           .regiment_but {
             font-size: 25rpx;
-            background-color: #e03519;
+            background-color: #f89c33;
             color: #f9f9f9;
           }
         }

+ 28 - 6
pages/product/list.vue

@@ -3,6 +3,11 @@
     <!-- 轮播图 -->
     <view class="search_fixed">
       <view class="search_box">
+        <view class="city_name" v-if="!toSelectedCity">
+          <navigator url="/pages/user/info" v-if="isManager">{{ cityName }}</navigator>
+          <text v-if="!isManager">{{ cityName }}</text>
+        </view>
+        <navigator url="/pages/user/info" v-if="toSelectedCity" class="city_name uncheck">选城市</navigator>
         <input class="search_input" type="text" v-model="requestParam.name" @input="searchChange" placeholder="请输入产品名称搜索" />
         <button class="search_btn" @click.stop="searchOpen()" data-eventsync="true">搜索</button>
       </view>
@@ -47,6 +52,7 @@
     <uni-popup ref="addFollow" type="center" class="center_popup">
       <FollowPopup :closePopup="closePopup" />
     </uni-popup>
+    <cc-myTabbar :tabBarShow="2"></cc-myTabbar>
   </view>
 </template>
 
@@ -79,6 +85,7 @@ export default {
   },
   onLoad() {
     // #ifdef MP-WEIXIN
+    uni.hideTabBar();
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
@@ -319,19 +326,32 @@ export default {
   display: block;
   position: fixed;
   margin: 0rpx auto;
-  padding: 20rpx 20rpx;
+  padding: 20rpx 0rpx;
   background-color: #ffffff;
-  box-sizing: border-box;
   .search_box {
     width: 750rpx;
     height: 60rpx;
     display: block;
     position: relative;
-
+    .city_name {
+      float: left;
+      width: 100rpx;
+      height: 60rpx;
+      display: block;
+      font-size: 30rpx;
+      overflow: hidden;
+      margin-left: 35rpx;
+      line-height: 60rpx;
+      white-space: nowrap;
+      text-overflow: ellipsis;
+    }
+    .city_name.uncheck {
+      color: #f89c33;
+    }
     .search_input {
       z-index: 0;
       float: left;
-      width: 600rpx;
+      width: 510rpx;
       height: 56rpx;
       display: block;
       font-size: 24rpx;
@@ -340,11 +360,12 @@ export default {
       border-top-left-radius: 40rpx;
       border-bottom-left-radius: 40rpx;
       border: 2rpx solid #dddddd;
+      background-color: #ffffff;
     }
     .search_btn {
       top: 0rpx;
       z-index: 9;
-      right: 40rpx;
+      left: 610rpx;
       color: #ffffff;
       position: absolute;
       display: block;
@@ -355,7 +376,7 @@ export default {
       padding: 0rpx 0rpx;
       line-height: 60rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }
@@ -464,6 +485,7 @@ export default {
         color: 26rpx;
         text-align: center;
         line-height: 60rpx;
+        font-size: 24rpx;
       }
     }
     .product_item:nth-child(even) {

+ 20 - 20
pages/recruitment/index.vue

@@ -42,42 +42,42 @@ export default {
       listKey: 0,
       listLength: 0,
       active_id: 0,
-      active_rule: "",
+      active_rule: '',
     };
   },
   onLoad(param) {
     // 存储分享标识
     if (param.share_uid) {
-      uni.setStorageSync("share_uid", param.share_uid);
-      console.log("share_uid", param.share_uid);
+      uni.setStorageSync('share_uid', param.share_uid);
+      console.log('share_uid', param.share_uid);
     }
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
   },
   onShareAppMessage(obj) {
     //获取当前用户信息
-    let userInfo = uni.getStorageSync("userInfo");
-    let param = "";
+    let userInfo = uni.getStorageSync('userInfo');
+    let param = '';
     if (userInfo.uid) {
-      param = "?share_uid=" + userInfo.uid;
+      param = '?share_uid=' + userInfo.uid;
     }
     console.log(222, param);
     // 返回分享信息
     return {
-      title: "999智控终端平台\n药优惠 得积分 兑豪礼",
-      path: "/pages/recruitment/index",
-      imageUrl: "",
+      title: '999智控终端平台\n药优惠 得积分 兑豪礼',
+      path: '/pages/recruitment/index',
+      imageUrl: '',
       promise: new Promise((resolve, reject) => {
-        this.$http.request("api/share_message/get_item", { item_id: this.action_info.id, pages: "/pages/recruitment/index" }).then((callback) => {
-          console.log(callback, "api/share_message/get_item");
+        this.$http.request('api/share_message/get_item', { item_id: this.action_info.id, pages: '/pages/recruitment/index' }).then((callback) => {
+          console.log(callback, 'api/share_message/get_item');
           let obj = {
-            title: callback.data?.title == "" ? "999智控终端平台\n药优惠 得积分 兑豪礼" : callback.data.title,
-            path: "/pages/recruitment/index",
+            title: callback.data?.title == '' ? '999智控终端平台\n药优惠 得积分 兑豪礼' : callback.data.title,
+            path: '/pages/recruitment/index',
           };
-          if (callback.data?.image_url !== "") {
+          if (callback.data?.image_url !== '') {
             obj.imageUrl = callback.data.image_url;
           }
           if (param) {
@@ -96,11 +96,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("/api/recruitment/get_info", this.requestParam).then((re) => {
+    this.$http.request('/api/recruitment/get_info', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         this.action_info = re.data;
         this.active_rule = this.action_info.active_rule;
         console.log(this.action_info?.length);
@@ -109,7 +109,7 @@ export default {
   },
   methods: {
     showRule() {
-      this.$refs.clockinRule.open("center");
+      this.$refs.clockinRule.open('center');
     },
     closeRule() {
       this.$refs.clockinRule.close();
@@ -310,7 +310,7 @@ page {
       }*/
       .clockin_item.acitve {
         color: #ffffff;
-        background-color: #e03519;
+        background-color: #f89c33;
       }
     }
 
@@ -321,7 +321,7 @@ page {
       margin-top: 20rpx;
       padding: 0rpx 0rpx;
       border-radius: 60rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
       border: 0rpx solid transparent;
     }
 

+ 1 - 1
pages/recruitment/lottery.vue

@@ -727,7 +727,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 148 - 150
pages/recruitment/record.vue

@@ -1,158 +1,156 @@
 <template>
-	<view>
-		<view class="record_box">
-			<view class="to_bottom" v-if="!recordList.length"> -----还没有拉新奖励啦-----</view>
-			<view class="record_list" >
-				<!-- Vue3 项目部分小程序端事件延迟或调用失败 在执行事件的元素上添加 data-eventsync="true" 属性以解决此问题 -->
-				<view class="record_item" v-for="(item,index) in recordList" :key="index" >
-					<view class="item_info">
-						<view class="pay_desc">{{item.username}}注册</view>
-						<view class="pay_time">{{item.insert_time}}</view>
-					</view>
-					<view class="score">
-						<view class="text_red" v-if="item.prize_type == 1">+{{item.prize}}</view>
-						<view class="text_red" v-if="item.prize_type == 2">赠送优惠卷</view>
-					</view>
-				</view>
-			</view>
-		</view>
-		<view class="to_bottom" v-if="isLast"> -----到底啦-----</view>
-	</view>
+  <view>
+    <view class="record_box">
+      <view class="to_bottom" v-if="!recordList.length"> -----还没有拉新奖励啦-----</view>
+      <view class="record_list">
+        <!-- Vue3 项目部分小程序端事件延迟或调用失败 在执行事件的元素上添加 data-eventsync="true" 属性以解决此问题 -->
+        <view class="record_item" v-for="(item, index) in recordList" :key="index">
+          <view class="item_info">
+            <view class="pay_desc">{{ item.username }}注册</view>
+            <view class="pay_time">{{ item.insert_time }}</view>
+          </view>
+          <view class="score">
+            <view class="text_red" v-if="item.prize_type == 1">+{{ item.prize }}</view>
+            <view class="text_red" v-if="item.prize_type == 2">赠送优惠卷</view>
+          </view>
+        </view>
+      </view>
+    </view>
+    <view class="to_bottom" v-if="isLast"> -----到底啦-----</view>
+  </view>
 </template>
 
 <script>
-	export default {
-		data() {
-			return {
-				// 列表
-				recordList:[],
-				// 请求参数
-				requestParam:{
-					page:1,
-				},
-				// 是否最后一页
-				isLast:false,
-				// 是否请求中
-				isReqing:false,
-			}
-		},
-		onShow() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return ;
-			// 没有数据的话,或者请求中,不允许刷新
-			if( this.isReqing )		return ;
-			// 请求参数
-			this.requestParam.page	= 1;
-			// 是否是最后一页
-			this.isLast			 	= false;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求
-			this.$http.request('api/recruitment/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					this.recordList = re.data.data;
-				}
-			});
-		},
-		onPullDownRefresh() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return uni.stopPullDownRefresh();
-			// 如果请求中,不允许请求,
-			if( this.isReqing )		return uni.stopPullDownRefresh();
-			// 初始化页码为1
-			this.requestParam.page	= 1;
-			// 是否是最后一页
-			this.isLast			 	= false;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求列表
-			this.$http.request('api/recruitment/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					this.recordList = re.data.data;
-				}
-			});
-			uni.stopPullDownRefresh();
-		},
-		onReachBottom() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return ;
-			// 如果页码是0,避免第一页重复
-			if( this.requestParam.page < 1 ) return;
-			// 最后一页不再请求
-			if( this.isLast ) 	return;
-			// 请求中,不再请求
-			if( this.isReqing ) return;
-			// 增加一页
-			this.requestParam.page = this.requestParam.page+1;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求列表
-			this.$http.request('api/recruitment/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					// 最后一页
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					// 追加数据
-					this.recordList.push(...re.data.data);
-				}
-			});
-		},
-		methods: {
-			
-		}
-	}
+export default {
+  data() {
+    return {
+      // 列表
+      recordList: [],
+      // 请求参数
+      requestParam: {
+        page: 1,
+      },
+      // 是否最后一页
+      isLast: false,
+      // 是否请求中
+      isReqing: false,
+    };
+  },
+  onShow() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return;
+    // 没有数据的话,或者请求中,不允许刷新
+    if (this.isReqing) return;
+    // 请求参数
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求
+    this.$http.request('api/recruitment/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        this.recordList = re.data.data;
+      }
+    });
+  },
+  onPullDownRefresh() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return uni.stopPullDownRefresh();
+    // 如果请求中,不允许请求,
+    if (this.isReqing) return uni.stopPullDownRefresh();
+    // 初始化页码为1
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/recruitment/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        this.recordList = re.data.data;
+      }
+    });
+    uni.stopPullDownRefresh();
+  },
+  onReachBottom() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return;
+    // 如果页码是0,避免第一页重复
+    if (this.requestParam.page < 1) return;
+    // 最后一页不再请求
+    if (this.isLast) return;
+    // 请求中,不再请求
+    if (this.isReqing) return;
+    // 增加一页
+    this.requestParam.page = this.requestParam.page + 1;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/recruitment/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        // 最后一页
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        // 追加数据
+        this.recordList.push(...re.data.data);
+      }
+    });
+  },
+  methods: {},
+};
 </script>
 
 <style lang="less">
-	.record_box{
-		display: block;
-		overflow: hidden;
-		margin: 10rpx auto;
-		.record_list{
-			display: block;
-			overflow: hidden;
-			.record_item{
-				display: block;
-				height: 100rpx;
-				margin: 10rpx auto;
-				background: #FFFFFF;
-				padding: 0rpx 35rpx;
-				.item_info{
-					float: left;
-					height: 100rpx;
-					.pay_desc{
-						height: 60rpx;
-						color: #666666;
-						font-size: 28rpx;
-						line-height: 60rpx;
-					}
-					.pay_time{
-						color: #999999;
-						height: 40rpx;
-						font-size: 24rpx;
-						line-height: 40rpx;
-					}
-				}
-				.score{
-					float: right;
-					height: 100rpx;
-					color: forestgreen;
-					line-height: 100rpx;
-					.text_red{
-						color: #E03519;
-					}
-				}
-			}
-		}
-	}
+.record_box {
+  display: block;
+  overflow: hidden;
+  margin: 10rpx auto;
+  .record_list {
+    display: block;
+    overflow: hidden;
+    .record_item {
+      display: block;
+      height: 100rpx;
+      margin: 10rpx auto;
+      background: #ffffff;
+      padding: 0rpx 35rpx;
+      .item_info {
+        float: left;
+        height: 100rpx;
+        .pay_desc {
+          height: 60rpx;
+          color: #666666;
+          font-size: 28rpx;
+          line-height: 60rpx;
+        }
+        .pay_time {
+          color: #999999;
+          height: 40rpx;
+          font-size: 24rpx;
+          line-height: 40rpx;
+        }
+      }
+      .score {
+        float: right;
+        height: 100rpx;
+        color: forestgreen;
+        line-height: 100rpx;
+        .text_red {
+          color: #f89c33;
+        }
+      }
+    }
+  }
+}
 </style>

+ 63 - 33
pages/score/clockin.vue

@@ -1,7 +1,11 @@
 <template>
   <view>
     <view class="main_view">
-      <view class="status_bar" :style="status_bar_style"><!-- 这里是状态栏 --></view>
+      <view class="status_bar" :style="status_bar_style">
+        <view v-if="hasPrePage" class="back-btn" @click="goBack">
+          <uni-icons type="left" size="20" color="#333"></uni-icons>
+        </view>
+      </view>
       <view class="info_box">
         <view class="left_box">
           <view class="score_info">
@@ -23,7 +27,7 @@
       <view class="clockin_box" v-if="clockinList.length > 0">
         <view class="box_title">
           <view class="left_icon" v-if="this.listKey > 0" @click="leftClockin()"><uni-icons type="left" size="20"></uni-icons></view>
-          {{ isMark.finish_day ? "已连续签到 " + isMark.finish_day + " 天" : "连续签到奖励更丰厚" }}
+          {{ isMark.finish_day ? '已连续签到 ' + isMark.finish_day + ' 天' : '连续签到奖励更丰厚' }}
           <view class="right_icon" v-if="this.listKey < this.listLength - 1" @click="rightClockin()"> <uni-icons type="right" size="20"></uni-icons></view>
         </view>
         <view class="clockin_list">
@@ -40,7 +44,7 @@
             <view class="give_score">+{{ item.reward }}</view>
           </view>
         </view>
-        <button class="clockin_btn" :class="isMark.is_clockin ? 'active' : ''" @click="toClockin()">{{ isMark.is_clockin ? "已签到" : "签到" }}</button>
+        <button class="clockin_btn" :class="isMark.is_clockin ? 'active' : ''" @click="toClockin()">{{ isMark.is_clockin ? '已签到' : '签到' }}</button>
         <navigator url="/pages/score/record" class="score_record">积分记录 &gt;</navigator>
         <button class="clockin_rule_btn" @click="showRule">活动规则 &gt;</button>
       </view>
@@ -68,6 +72,7 @@ export default {
   data() {
     return {
       status_bar_style: {},
+      hasPrePage: false,
       clockinList: [],
       isMark: {
         finish_day: 0,
@@ -82,23 +87,33 @@ export default {
       listKey: 0,
       listLength: 0,
       active_id: 0,
-      active_rule: "",
-	  show_lottery:0,
+      active_rule: '',
+      show_lottery: 0,
     };
   },
   onLoad() {
     // #ifdef MP-WEIXIN
     let menuButtonInfo = uni.getMenuButtonBoundingClientRect();
     this.status_bar_style = {
-      height: menuButtonInfo.height + "px",
-      "padding-top": menuButtonInfo.top + "px",
+      height: menuButtonInfo.height + 'px',
+      'padding-top': menuButtonInfo.top + 'px',
+      position: 'relative',
+      display: 'flex',
+      justifyContent: 'center',
+      alignItems: 'center',
+      zIndex: 1000,
     };
+
+    // 判断是否有上级页面
+    const pages = getCurrentPages();
+    this.hasPrePage = pages.length > 1;
     // #endif
     // #ifdef MP-WEIXIN
+
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
     // #endif
   },
@@ -107,13 +122,13 @@ export default {
     let shareList = getApp().globalData.shareList;
     // 获取分享信息
     let shareObj = {
-      title: "999智控终端平台\n药优惠 得积分 兑豪礼",
-      path: "/pages/score/clockin",
-      imageUrl: "",
+      title: '999智控终端平台\n药优惠 得积分 兑豪礼',
+      path: '/pages/score/clockin',
+      imageUrl: '',
     };
     // 循环列表
     for (let i in shareList) {
-      if (shareList[i].pages == "pages/score/clockin") {
+      if (shareList[i].pages == 'pages/score/clockin') {
         shareObj.path = shareList[i].path ? shareList[i].path : shareObj.path;
         shareObj.title = shareList[i].title ? `999智控终端平台\n${shareList[i].title}` : shareObj.title;
         shareObj.imageUrl = shareList[i].image_url ? shareList[i].image_url : shareObj.imageUrl;
@@ -132,25 +147,28 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("/api/custom_score/get_info", this.requestParam).then((re) => {
+    this.$http.request('/api/custom_score/get_info', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         this.scoreInfo = re.data;
       }
     });
-	// 请求
-	this.$http.request('api/lottery_score/get_detail').then((re) => {
-	  // 成功结果
-	  if (re.code == 'success') {
-	    this.show_lottery = 1;
-	  }
-	});
+    // 请求
+    this.$http.request('api/lottery_score/get_detail').then((re) => {
+      // 成功结果
+      if (re.code == 'success') {
+        this.show_lottery = 1;
+      }
+    });
   },
   methods: {
+    goBack() {
+      uni.navigateBack();
+    },
     showRule() {
-      this.$refs.clockinRule.open("center");
+      this.$refs.clockinRule.open('center');
     },
     closeRule() {
       this.$refs.clockinRule.close();
@@ -162,8 +180,8 @@ export default {
       if (!this.$checkAccess.alterLogin()) return;
       if (this.active_id === 0) {
         uni.showToast({
-          title: "暂无活动",
-          icon: "none",
+          title: '暂无活动',
+          icon: 'none',
         });
       }
       // 请求中,不允许刷新
@@ -173,17 +191,17 @@ export default {
       // 请求列表
       this.$http
         .request(
-          "api/score_clockin/finish",
+          'api/score_clockin/finish',
           {
             active_id: this.active_id,
           },
-          "post"
+          'post'
         )
         .then((re) => {
           // 设置非请求中
           this.isReqing = false;
           // 成功结果
-          if (re.code == "success") {
+          if (re.code == 'success') {
             // 赋值
             this.isMark = re.data;
             // 积分更新
@@ -195,17 +213,17 @@ export default {
             }
           } else {
             uni.showToast({
-              title: "打卡失败",
-              icon: "none",
+              title: '打卡失败',
+              icon: 'none',
             });
           }
         });
     },
     getClockinList() {
       // 请求列表
-      this.$http.request("api/score_clockin/get_list", this.requestParam).then((re) => {
+      this.$http.request('api/score_clockin/get_list', this.requestParam).then((re) => {
         // 成功结果
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 赋值
           this.clockinList = re.data.list;
           this.listLength = this.clockinList.length;
@@ -229,6 +247,18 @@ export default {
 </script>
 
 <style lang="less">
+.status_bar {
+  .back-btn {
+    position: absolute;
+    left: 16px;
+    bottom: 0;
+    padding: 6px;
+    display: flex;
+    align-items: center;
+    justify-content: center;
+    z-index: 1000;
+  }
+}
 page {
   background-color: #ffffff;
 }
@@ -487,7 +517,7 @@ page {
 				}*/
       .clockin_item.acitve {
         color: #ffffff;
-        background-color: #e03519;
+        background-color: #f89c33;
       }
     }
 
@@ -498,7 +528,7 @@ page {
       margin-top: 20rpx;
       padding: 0rpx 0rpx;
       border-radius: 60rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
       border: 0rpx solid transparent;
     }
 

+ 17 - 17
pages/score/index.vue

@@ -35,7 +35,7 @@ export default {
       productList: [],
       // 请求参数
       requestParam: {
-        name: "",
+        name: '',
         page: 1,
       },
       // 是否最后一页
@@ -49,7 +49,7 @@ export default {
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
     // #endif
   },
@@ -58,13 +58,13 @@ export default {
     let shareList = getApp().globalData.shareList;
     // 获取分享信息
     let shareObj = {
-      title: "999智控终端平台\n药优惠 得积分 兑豪礼",
-      path: "/pages/score/index",
-      imageUrl: "",
+      title: '999智控终端平台\n药优惠 得积分 兑豪礼',
+      path: '/pages/score/index',
+      imageUrl: '',
     };
     // 循环列表
     for (let i in shareList) {
-      if (shareList[i].pages == "pages/score/index") {
+      if (shareList[i].pages == 'pages/score/index') {
         shareObj.path = shareList[i].path ? shareList[i].path : shareObj.path;
         shareObj.title = shareList[i].title ? `999智控终端平台\n${shareList[i].title}` : shareObj.title;
         shareObj.imageUrl = shareList[i].image_url ? shareList[i].image_url : shareObj.imageUrl;
@@ -77,7 +77,7 @@ export default {
     // 没有数据的话,或者请求中,不允许刷新
     if (this.isReqing) return;
     // 请求参数
-    this.requestParam.name = "";
+    this.requestParam.name = '';
     // 请求参数
     this.requestParam.page = 1;
     // 是否是最后一页
@@ -85,11 +85,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求
-    this.$http.request("api/score_product/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/score_product/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         this.productList = re.data.data;
       }
@@ -105,11 +105,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/score_product/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/score_product/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         this.productList = re.data.data;
       }
@@ -128,11 +128,11 @@ export default {
     // 设置请求中
     this.isReqing = true;
     // 请求列表
-    this.$http.request("api/score_product/get_list", this.requestParam).then((re) => {
+    this.$http.request('api/score_product/get_list', this.requestParam).then((re) => {
       // 设置非请求中
       this.isReqing = false;
       // 成功结果
-      if (re.code == "success") {
+      if (re.code == 'success') {
         // 最后一页
         if (re.data.last_page <= this.requestParam.page) this.isLast = true;
         // 追加数据
@@ -157,11 +157,11 @@ export default {
       // 设置请求中
       this.isReqing = true;
       // 请求列表
-      this.$http.request("api/score_product/get_list", this.requestParam).then((re) => {
+      this.$http.request('api/score_product/get_list', this.requestParam).then((re) => {
         // 设置非请求中
         this.isReqing = false;
         // 成功结果
-        if (re.code == "success") {
+        if (re.code == 'success') {
           this.productList = re.data.data;
           if (re.data.data.length && re.data.last_page >= this.requestParam.page) this.isLast = true;
         }
@@ -169,7 +169,7 @@ export default {
     },
     toDetail(item) {
       uni.navigateTo({
-        url: "/pages/score/product?id=" + item.id,
+        url: '/pages/score/product?id=' + item.id,
       });
     },
   },
@@ -218,7 +218,7 @@ export default {
       padding: 0rpx 0rpx;
       line-height: 60rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 1 - 1
pages/score/lottery.vue

@@ -647,7 +647,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 42 - 42
pages/score/product.vue

@@ -1,5 +1,5 @@
 <template>
-	<page-meta :page-style="'overflow:' + (show ? 'hidden' : 'visible')"></page-meta>
+  <page-meta :page-style="'overflow:' + (show ? 'hidden' : 'visible')"></page-meta>
   <view>
     <view>
       <view class="product_image_box">
@@ -109,12 +109,12 @@ export default {
       show: false, // 使用Popup组件时,阻止禁止滚动穿透
       productInfo: {
         id: 0,
-        name: "",
+        name: '',
         score: 0,
-        spec: "",
+        spec: '',
         stock: 0,
-        thumb: "",
-        description: "",
+        thumb: '',
+        description: '',
       },
       requestParam: {
         id: 0,
@@ -122,7 +122,7 @@ export default {
       // 数量
       quantity: 1,
       // 总价
-      priceTotal: "0.00",
+      priceTotal: '0.00',
       // 规格选择按钮类型
       specBtnType: 1, // 1预约。2购物车
       // 地址列表
@@ -130,12 +130,12 @@ export default {
       // 已选地址
       checkedAddr: {
         id: 0,
-        contact_name: "",
-        contact_phone: "",
-        contact_province: "",
-        contact_city: "",
-        contact_area: "",
-        contact_addr: "",
+        contact_name: '',
+        contact_phone: '',
+        contact_province: '',
+        contact_city: '',
+        contact_area: '',
+        contact_addr: '',
         is_default: 0,
       },
     };
@@ -145,7 +145,7 @@ export default {
     this.requestParam.id = param.id;
     var that = this;
     // 监听地址变动
-    uni.$on("addr_list_change", function (data) {
+    uni.$on('addr_list_change', function (data) {
       // 地址列表
       that.addrList = data.list;
     });
@@ -153,22 +153,22 @@ export default {
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
-      menus: ["shareAppMessage", "shareTimeline"],
+      menus: ['shareAppMessage', 'shareTimeline'],
     });
     // #endif
   },
   onShareAppMessage(obj) {
     return {
       title: `999智控终端平台\n${this.productInfo.name}`,
-      path: "/pages/score/product?id=" + this.productInfo.id,
+      path: '/pages/score/product?id=' + this.productInfo.id,
       promise: new Promise((resolve, reject) => {
-        this.$http.request("api/share_message/get_item", { item_id: this.productInfo.id, pages: "/pages/score/product" }).then((callback) => {
-          console.log(callback, "api/share_message/get_item");
+        this.$http.request('api/share_message/get_item', { item_id: this.productInfo.id, pages: '/pages/score/product' }).then((callback) => {
+          console.log(callback, 'api/share_message/get_item');
           let obj = {
-            title: callback.data?.title == "" ? `999智控终端平台\n${this.productInfo.name}` : callback.data.title,
-            path: "/pages/score/product?id=" + this.productInfo.id,
+            title: callback.data?.title == '' ? `999智控终端平台\n${this.productInfo.name}` : callback.data.title,
+            path: '/pages/score/product?id=' + this.productInfo.id,
           };
-          if (callback.data?.image_url !== "") {
+          if (callback.data?.image_url !== '') {
             obj.imageUrl = callback.data.image_url;
           }
           resolve(obj);
@@ -180,9 +180,9 @@ export default {
     // 如果存在产品ID的话
     if (this.requestParam.id > 0) {
       // 请求详情
-      this.$http.request("api/score_product/get_detail", this.requestParam).then((re) => {
+      this.$http.request('api/score_product/get_detail', this.requestParam).then((re) => {
         // 成功渲染数据
-        if (re.code == "success") {
+        if (re.code == 'success') {
           // 刷新数据
           this.productInfo = re.data;
         }
@@ -193,14 +193,14 @@ export default {
     // 地址弹出层
     showAddrPopup() {
       // 显示下单弹出层
-      this.$refs.addrPopup.open("bottom");
+      this.$refs.addrPopup.open('bottom');
     },
     // 规格弹出层
     showSpecPopup(type) {
       // 登录提示
       // if( !this.$checkAccess.alterLogin()) return ;
       // 显示下单弹出层
-      this.$refs.specPopup.open("bottom");
+      this.$refs.specPopup.open('bottom');
       // 地址列表
       this.getAddrList();
       // 计算价格
@@ -217,14 +217,14 @@ export default {
       if (this.quantity > this.productInfo.stock) {
         this.quantity = this.productInfo.stock;
         uni.showToast({
-          title: "库存不足",
-          icon: "none",
+          title: '库存不足',
+          icon: 'none',
         });
       }
       // 如果小于1.设置为1
       if (this.quantity < 1) {
         this.quantity = 1;
-        uni.showToast({ title: "数量不可以小于0", icon: "none" });
+        uni.showToast({ title: '数量不可以小于0', icon: 'none' });
       }
       // 计算价格
       this.priceHandler();
@@ -236,46 +236,46 @@ export default {
       // 下单数量小于0
       if (this.quantity < 1) {
         uni.showToast({
-          title: "至少兑换1个",
+          title: '至少兑换1个',
         });
         return;
       }
       // 如果大于库存设置为库存
       if (this.productInfo.stock < 1) {
         uni.showToast({
-          title: "库存不足",
-          icon: "none",
+          title: '库存不足',
+          icon: 'none',
         });
         return;
       }
       // 地址未填
       if (!this.checkedAddr.id) {
         uni.showToast({
-          title: "请选择收货地址",
-          icon: "none",
+          title: '请选择收货地址',
+          icon: 'none',
         });
         return;
       }
       // 请求接口
       this.$http
         .request(
-          "api/score_orders/create",
+          'api/score_orders/create',
           {
             product_id: this.productInfo.id,
             buy_num: this.quantity,
             addr_id: this.checkedAddr.id,
           },
-          "post"
+          'post'
         )
         .then((re) => {
           // 判断结果
-          if (re.code == "success") {
+          if (re.code == 'success') {
             // 处理结果
             this.productInfo.stock = this.productInfo.stock - this.quantity;
             // 关闭弹窗
             this.$refs.specPopup.close();
             // 跳转到订单列表
-            uni.navigateTo({ url: "/pages/score/orders" });
+            uni.navigateTo({ url: '/pages/score/orders' });
             return;
           } else {
             uni.showModal({ title: re.msg, showCancel: false });
@@ -298,9 +298,9 @@ export default {
     },
     getAddrList() {
       // 判断数据
-      this.$http.request("api/custom_addr/get_list").then((callback) => {
+      this.$http.request('api/custom_addr/get_list').then((callback) => {
         // 获取成功
-        if (callback.code == "success") {
+        if (callback.code == 'success') {
           this.addrList = callback.data;
           // 如果有的话
           if (this.addrList.length) {
@@ -455,7 +455,7 @@ export default {
     text-align: center;
     margin: 0rpx auto;
     border-radius: 40rpx;
-    background-color: #e03519;
+    background-color: #f89c33;
   }
 }
 .popup {
@@ -497,7 +497,7 @@ export default {
         font-size: 24rpx;
         line-height: 50rpx;
         .contact_none {
-          color: #e03519;
+          color: #f89c33;
           font-size: 26rpx;
           font-weight: bold;
         }
@@ -702,7 +702,7 @@ export default {
         line-height: 80rpx;
         padding: 0rpx 0rpx;
         border-radius: 40rpx;
-        background-color: #e03519;
+        background-color: #f89c33;
         border: 0rpx solid transparent;
       }
       .to_order::after {
@@ -882,7 +882,7 @@ export default {
       margin: 0rpx auto;
       margin-top: 20rpx;
       border-radius: 40rpx;
-      background-color: #e03519;
+      background-color: #f89c33;
     }
   }
 }

+ 148 - 150
pages/score/record.vue

@@ -1,158 +1,156 @@
 <template>
-	<view>
-		<view class="record_box">
-			<view class="to_bottom" v-if="!recordList.length"> -----还没有产品啦-----</view>
-			<view class="record_list" >
-				<!-- Vue3 项目部分小程序端事件延迟或调用失败 在执行事件的元素上添加 data-eventsync="true" 属性以解决此问题 -->
-				<view class="record_item" v-for="(item,index) in recordList" :key="index" >
-					<view class="item_info">
-						<view class="pay_desc">{{item.description}}</view>
-						<view class="pay_time">{{item.pay_time}}</view>
-					</view>
-					<view class="score">
-						<view class="text_red" v-if="item.score>=0">+{{item.score}}</view>
-						<view class="text_green" v-if="item.score<0">{{item.score}}</view>
-					</view>
-				</view>
-			</view>
-		</view>
-		<view class="to_bottom" v-if="isLast"> -----到底啦-----</view>
-	</view>
+  <view>
+    <view class="record_box">
+      <view class="to_bottom" v-if="!recordList.length"> -----还没有产品啦-----</view>
+      <view class="record_list">
+        <!-- Vue3 项目部分小程序端事件延迟或调用失败 在执行事件的元素上添加 data-eventsync="true" 属性以解决此问题 -->
+        <view class="record_item" v-for="(item, index) in recordList" :key="index">
+          <view class="item_info">
+            <view class="pay_desc">{{ item.description }}</view>
+            <view class="pay_time">{{ item.pay_time }}</view>
+          </view>
+          <view class="score">
+            <view class="text_red" v-if="item.score >= 0">+{{ item.score }}</view>
+            <view class="text_green" v-if="item.score < 0">{{ item.score }}</view>
+          </view>
+        </view>
+      </view>
+    </view>
+    <view class="to_bottom" v-if="isLast"> -----到底啦-----</view>
+  </view>
 </template>
 
 <script>
-	export default {
-		data() {
-			return {
-				// 列表
-				recordList:[],
-				// 请求参数
-				requestParam:{
-					page:1,
-				},
-				// 是否最后一页
-				isLast:false,
-				// 是否请求中
-				isReqing:false,
-			}
-		},
-		onShow() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return ;
-			// 没有数据的话,或者请求中,不允许刷新
-			if( this.isReqing )		return ;
-			// 请求参数
-			this.requestParam.page	= 1;
-			// 是否是最后一页
-			this.isLast			 	= false;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求
-			this.$http.request('api/custom_score/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					this.recordList = re.data.data;
-				}
-			});
-		},
-		onPullDownRefresh() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return uni.stopPullDownRefresh();
-			// 如果请求中,不允许请求,
-			if( this.isReqing )		return uni.stopPullDownRefresh();
-			// 初始化页码为1
-			this.requestParam.page	= 1;
-			// 是否是最后一页
-			this.isLast			 	= false;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求列表
-			this.$http.request('api/custom_score/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					this.recordList = re.data.data;
-				}
-			});
-			uni.stopPullDownRefresh();
-		},
-		onReachBottom() {
-			// 登录提示
-			if( !this.$checkAccess.alterLogin() )  return ;
-			// 如果页码是0,避免第一页重复
-			if( this.requestParam.page < 1 ) return;
-			// 最后一页不再请求
-			if( this.isLast ) 	return;
-			// 请求中,不再请求
-			if( this.isReqing ) return;
-			// 增加一页
-			this.requestParam.page = this.requestParam.page+1;
-			// 设置请求中
-			this.isReqing			= true;
-			// 请求列表
-			this.$http.request('api/custom_score/get_record',this.requestParam).then((re)=>{
-				// 设置非请求中
-				this.isReqing		= false;
-				// 成功结果
-				if( re.code == 'success' ){
-					// 最后一页
-					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
-					// 追加数据
-					this.recordList.push(...re.data.data);
-				}
-			});
-		},
-		methods: {
-			
-		}
-	}
+export default {
+  data() {
+    return {
+      // 列表
+      recordList: [],
+      // 请求参数
+      requestParam: {
+        page: 1,
+      },
+      // 是否最后一页
+      isLast: false,
+      // 是否请求中
+      isReqing: false,
+    };
+  },
+  onShow() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return;
+    // 没有数据的话,或者请求中,不允许刷新
+    if (this.isReqing) return;
+    // 请求参数
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求
+    this.$http.request('api/custom_score/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        this.recordList = re.data.data;
+      }
+    });
+  },
+  onPullDownRefresh() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return uni.stopPullDownRefresh();
+    // 如果请求中,不允许请求,
+    if (this.isReqing) return uni.stopPullDownRefresh();
+    // 初始化页码为1
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/custom_score/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        this.recordList = re.data.data;
+      }
+    });
+    uni.stopPullDownRefresh();
+  },
+  onReachBottom() {
+    // 登录提示
+    if (!this.$checkAccess.alterLogin()) return;
+    // 如果页码是0,避免第一页重复
+    if (this.requestParam.page < 1) return;
+    // 最后一页不再请求
+    if (this.isLast) return;
+    // 请求中,不再请求
+    if (this.isReqing) return;
+    // 增加一页
+    this.requestParam.page = this.requestParam.page + 1;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/custom_score/get_record', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        // 最后一页
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        // 追加数据
+        this.recordList.push(...re.data.data);
+      }
+    });
+  },
+  methods: {},
+};
 </script>
 
 <style lang="less">
-	.record_box{
-		display: block;
-		overflow: hidden;
-		margin: 10rpx auto;
-		.record_list{
-			display: block;
-			overflow: hidden;
-			.record_item{
-				display: block;
-				height: 100rpx;
-				margin: 10rpx auto;
-				background: #FFFFFF;
-				padding: 0rpx 35rpx;
-				.item_info{
-					float: left;
-					height: 100rpx;
-					.pay_desc{
-						height: 60rpx;
-						color: #666666;
-						font-size: 28rpx;
-						line-height: 60rpx;
-					}
-					.pay_time{
-						color: #999999;
-						height: 40rpx;
-						font-size: 24rpx;
-						line-height: 40rpx;
-					}
-				}
-				.score{
-					float: right;
-					height: 100rpx;
-					color: forestgreen;
-					line-height: 100rpx;
-					.text_red{
-						color: #E03519;
-					}
-				}
-			}
-		}
-	}
+.record_box {
+  display: block;
+  overflow: hidden;
+  margin: 10rpx auto;
+  .record_list {
+    display: block;
+    overflow: hidden;
+    .record_item {
+      display: block;
+      height: 100rpx;
+      margin: 10rpx auto;
+      background: #ffffff;
+      padding: 0rpx 35rpx;
+      .item_info {
+        float: left;
+        height: 100rpx;
+        .pay_desc {
+          height: 60rpx;
+          color: #666666;
+          font-size: 28rpx;
+          line-height: 60rpx;
+        }
+        .pay_time {
+          color: #999999;
+          height: 40rpx;
+          font-size: 24rpx;
+          line-height: 40rpx;
+        }
+      }
+      .score {
+        float: right;
+        height: 100rpx;
+        color: forestgreen;
+        line-height: 100rpx;
+        .text_red {
+          color: #f89c33;
+        }
+      }
+    }
+  }
+}
 </style>

+ 228 - 77
pages/user/index.vue

@@ -1,24 +1,37 @@
 <template>
-  <view>
-    <view class="user_box">
-      <view class="box_left">
-        <navigator url="/pages/user/settings">
-          <image class="user_image" :src="userInfo.userpic"></image>
-        </navigator>
+  <view style="height: 100vh; overflow: hidden">
+    <view class="page-header">
+      <view class="page-header-title" :style="status_bar_style">我的</view>
+      <view class="user_box">
+        <view class="box_left">
+          <navigator url="/pages/user/settings">
+            <image class="user_image" :src="userInfo?.userpic"></image>
+          </navigator>
+        </view>
+        <view class="box_center">
+          <view class="user_name" v-if="is_login">{{ userInfo?.username }}</view>
+          <navigator class="user_name" url="/pages/login/index" v-if="!is_login">请登录</navigator>
+          <view class="user_info">{{ userInfo?.phone }}</view>
+        </view>
+      </view>
+    </view>
+    <view class="customized-page">
+      <view class="icon-list">
+        <icon-list mode="row8" :icons="icons_1" :gap="0" :small="true" />
+      </view>
+      <view class="icon-list">
+        <icon-list mode="row8" :icons="icons_2" :gap="0" :small="true" />
       </view>
-      <view class="box_center">
-        <view class="user_name" v-if="is_login">{{ userInfo.username }}</view>
-		<navigator class="user_name" url="/pages/login/index" v-if="!is_login">请登录</navigator>
-        <view class="user_info">{{ userInfo.phone }}</view>
+      <view class="icon-list">
+        <icon-list mode="row8" :icons="icons_3" :gap="0" :small="true" />
       </view>
-      <view class="box_right">
-        <navigator url="/pages/user/info" class="company_text" v-if="!userInfo.city_id">请选择城市</navigator>
-        <navigator url="/pages/user/settings" class="setting_page" v-if="userInfo.city_id">
-          <image class="setting_icon" src="https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/setting.png"></image>
-        </navigator>
+      <view class="user_list">
+        <list v-bind="list_props" />
       </view>
+      <view class="alter_info">本程序暂不提供在线交易以及支付功能,您所提交的预约,我们将验证您的购药资质并交由有售卖药品资质的商业公司与您联系确认并提供线下后续服务。</view>
     </view>
-    <view class="balance_content">
+
+    <!-- <view class="balance_content">
       <view class="balance_content_main">
         <view style="display: flex">
           <view class="price_content" style="margin-right: 45rpx">
@@ -58,21 +71,77 @@
         <image class="navigator_image" src="https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/article.png" mode=""></image>
         <view class="navigator_title">资讯</view>
       </navigator>
-	  <navigator class="navigator_item" url="/pages/video/index" v-if="userInfo.is_video_vip == 1">
+      <navigator class="navigator_item" url="/pages/video/index" v-if="userInfo.is_video_vip == 1">
         <image class="navigator_image" src="https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/video.png" mode=""></image>
         <view class="navigator_title">学习</view>
-      </navigator> 
-    </view>
-    <view class="alter_info">本程序暂不提供在线交易以及支付功能,您所提交的预约,我们将验证您的购药资质并交由有售卖药品资质的商业公司与您联系确认并提供线下后续服务。</view>
+      </navigator>
+    </view> -->
     <view class="packet_content" v-if="show_packet">
       <view class="close_btn" @click="closePacket"> X </view>
       <image src="https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/red_packet.gif" class="red_packet" @click="_getredpacket" />
     </view>
+    <cc-myTabbar :tabBarShow="4"></cc-myTabbar>
   </view>
 </template>
 
 <script>
+import IconList from '@/components/IconList';
+import List from '@/components/List';
+const line1_icons = [
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/order.png',
+    text: '全部订单',
+    urlMap: { internal_url: '/pages/orders/index?status=0' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/order_1.png',
+    text: '待付款',
+    urlMap: { internal_url: '/pages/orders/index?status=1' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/order_2.png',
+    text: '已取消',
+    urlMap: { internal_url: '/pages/orders/index?status=4' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/order_3.png',
+    text: '已完成',
+    urlMap: { internal_url: '/pages/orders/index?status=8' },
+  },
+];
+
+const line2_icons = [
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/line_2_1.png',
+    text: '余额',
+    urlMap: { internal_url: '/pages/balance/index' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/line_2_2.png',
+    text: '积分订单',
+    urlMap: { internal_url: '/pages/score/orders' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/line_2_3.png',
+    text: '我的优惠卷',
+    urlMap: { internal_url: '/pages/coupon/index' },
+  },
+];
+
+const line3_icons = [
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/line_3_1.png',
+    text: '签到',
+    urlMap: { internal_url: '/pages/score/clockin' },
+  },
+  {
+    image: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/user/line_3_2.png',
+    text: '积分商城',
+    urlMap: { internal_url: '/pages/score/index' },
+  },
+];
 export default {
+  components: { IconList, List },
   data() {
     return {
       userInfo: {
@@ -81,13 +150,26 @@ export default {
         phone: 'kailin',
         status: 0,
         city_id: 0,
-		is_video_vip:0,
-		amount:0.00,
-		transfer_amount:0.00
+        is_video_vip: 0,
+        amount: 0.0,
+        transfer_amount: 0.0,
       },
-	  is_login:0,
+      is_login: 0,
       packetList: [],
       show_packet: false,
+      icons_1: line1_icons,
+      icons_2: line2_icons,
+      icons_3: line3_icons,
+      list_props: {
+        iconShow: false,
+        lists: [
+          { text: '地址', url: '/pages/addr/index' },
+          { text: '设置', url: '/pages/user/settings' },
+        ],
+        showTitle: false,
+        title: '列表设置',
+      },
+      status_bar_style: {},
     };
   },
   onLoad(param) {
@@ -97,6 +179,25 @@ export default {
       console.log('share_uid', param.share_uid);
     }
     // #ifdef MP-WEIXIN
+    uni.hideTabBar();
+
+    // #ifdef MP-WEIXIN
+
+    const menuButtonInfo = uni.getMenuButtonBoundingClientRect();
+    // #endif
+
+    this.status_bar_style = {
+      // #ifdef MP-WEIXIN
+      height: menuButtonInfo.height + 'px',
+      top: menuButtonInfo.top + 'px',
+      'line-height': menuButtonInfo.height + 'px',
+      // #endif
+      // #ifdef H5
+      height: '44px',
+      'line-height': '44px',
+      // #endif
+    };
+
     //分享按钮
     uni.showShareMenu({
       withShareTicket: true,
@@ -135,22 +236,21 @@ export default {
     return shareObj;
   },
   onShow() {
-	  
-	this.is_login = this.$checkAccess.checkLogin()
+    this.is_login = this.$checkAccess.checkLogin();
     // 未登录不请求
-    if ( !this.is_login ) {
-		this.userInfo = {
-			username: '请登录',
-			userpic: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/doctor.png',
-			phone: 'kailin',
-			status: 0,
-			city_id: 0,
-			is_video_vip:0,
-			amount:0.00,
-			transfer_amount:0.00
-		};
-		return;
-	}
+    if (!this.is_login) {
+      this.userInfo = {
+        username: '请登录',
+        userpic: 'https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/icon/doctor.png',
+        phone: 'kailin',
+        status: 0,
+        city_id: 0,
+        is_video_vip: 0,
+        amount: 0.0,
+        transfer_amount: 0.0,
+      };
+      return;
+    }
     // 判断数据
     this.$http.request('api/custom/get_info').then((callback) => {
       if (callback.code == 'success') {
@@ -201,18 +301,79 @@ export default {
 };
 </script>
 
-<style lang="less">
+<style lang="less" scoped>
+.icon-list {
+  padding: 0 32rpx;
+  box-sizing: border-box;
+  margin: 24rpx 0 0;
+}
+.user_list {
+  margin-top: 24rpx;
+  padding: 0 32rpx;
+}
+.page-header {
+  width: 100%;
+  height: 494rpx;
+  background: url(https://kailin-saas.oss-cn-shenzhen.aliyuncs.com/images/index/user-mask.png) no-repeat center;
+  background-size: contain;
+  position: fixed;
+  z-index: 100;
+  .page-header-title {
+    position: absolute;
+    width: 100%;
+    color: #ffffff;
+    text-align: center;
+  }
+}
+.shop-info-header-right {
+  width: 184rpx;
+  height: 56rpx;
+  background: #ffffff;
+  border-radius: 200rpx 200rpx 200rpx 200rpx;
+  color: #999;
+  font-size: 28rpx;
+  text-align: center;
+  line-height: 56rpx;
+  position: absolute;
+  right: 50rpx;
+  top: 20rpx;
+}
+.customized-page {
+  display: flex;
+  flex-direction: column;
+  padding-bottom: calc(env(safe-area-inset-bottom) + 120rpx);
+  position: absolute;
+  top: 350rpx;
+  z-index: 100;
+  .customized-item {
+    margin: 10rpx 0;
+    padding: 0 16rpx;
+    box-sizing: border-box;
+  }
+  .alter_info {
+    display: block;
+    color: var(--primary-color);
+    font-size: 20rpx;
+    overflow: hidden;
+    line-height: 40rpx;
+    padding: 32rpx 32rpx;
+    color: #f89c33;
+  }
+}
 .user_box {
   width: 680rpx;
   height: 180rpx;
   overflow: hidden;
-  background: #ffffff;
   padding: 10rpx 35rpx;
+  color: #ffffff;
+  position: absolute;
+  bottom: 100rpx;
   .box_left {
     float: left;
     display: block;
     width: 140rpx;
     height: 140rpx;
+
     .user_image {
       display: block;
       width: 120rpx;
@@ -231,38 +392,10 @@ export default {
       line-height: 80rpx;
     }
     .user_info {
-      color: #999999;
       font-size: 24rpx;
       line-height: 60rpx;
     }
   }
-  .box_right {
-    float: right;
-    width: 140rpx;
-    height: 140rpx;
-    font-size: 20rpx;
-    line-height: 140rpx;
-    .setting_page {
-      width: 140rpx;
-      height: 140rpx;
-      display: block;
-      overflow: hidden;
-      .setting_icon {
-        width: 60rpx;
-        height: 60rpx;
-        display: block;
-        margin: 40rpx auto;
-      }
-    }
-    .company_text {
-      color: #e03519;
-      width: 140rpx;
-      height: 140rpx;
-      font-size: 20rpx;
-      text-align: center;
-      line-height: 140rpx;
-    }
-  }
 }
 .navigator_list {
   display: flex; // 弹性盒模型
@@ -274,9 +407,8 @@ export default {
     float: left;
     height: 160rpx;
     display: block;
-    // margin: 0rpx auto;
+    margin: 0rpx auto;
     text-align: center;
-    width: 25%;
     .navigator_image {
       width: 80rpx;
       height: 80rpx;
@@ -284,7 +416,7 @@ export default {
       border-radius: 5rpx;
     }
     .navigator_title {
-      width: 100%;
+      width: 120rpx;
       display: block;
       font-size: 30rpx;
       line-height: 40rpx;
@@ -292,16 +424,34 @@ export default {
     }
   }
 }
-.alter_info {
-  display: block;
-  color: #e03519;
-  font-size: 20rpx;
+.navigator_list_community {
+  display: block; // 弹性盒模型
   overflow: hidden;
   margin: 20rpx auto;
   background: #ffffff;
-  line-height: 40rpx;
   padding: 35rpx 35rpx;
+  .navigator_item {
+    float: left;
+    height: 160rpx;
+    display: block;
+    margin: 0rpx auto;
+    text-align: center;
+    .navigator_image {
+      width: 80rpx;
+      height: 80rpx;
+      margin: 20rpx auto;
+      border-radius: 5rpx;
+    }
+    .navigator_title {
+      width: 120rpx;
+      display: block;
+      font-size: 30rpx;
+      line-height: 40rpx;
+      text-align: center;
+    }
+  }
 }
+
 .balance_content {
   margin: 20rpx;
   padding: 35rpx;
@@ -345,6 +495,7 @@ export default {
   bottom: 15%;
   width: 160rpx;
   height: 160rpx;
+  z-index: 101;
   .red_packet {
     width: 100%;
     height: 100%;

+ 188 - 189
pages/user/info.vue

@@ -1,197 +1,196 @@
 <template>
-	<view>
-		<view class="alter_info">请选择您药店/诊所所在城市,选择后不可更改,请谨慎选择</view>
-		<view class="form"  >
-			<!-- 地区代表表单 -->
-			<form class="info_form">
-				<view class="form_group">
-					<view class="group_title">所在城市:</view>
-					<view class="group_box">
-						<picker mode="multiSelector" class="form_ctrl" :range="cityArray"  @columnchange="cityChange" @change="cityFinish" >
-							<view class="area_text">
-								<text v-if="requestParam.province"> {{requestParam.province}} </text>
-								<text v-if="requestParam.city"> / {{requestParam.city}} </text>
-							</view>
-						</picker>
-					</view>
-				</view>
-				<button @click="toApply" class="submit_btn" >提交</button>
-			</form>
-		</view>
-	</view>
+  <view>
+    <view class="alter_info">请选择您药店/诊所所在城市,选择后不可更改,请谨慎选择</view>
+    <view class="form">
+      <!-- 地区代表表单 -->
+      <form class="info_form">
+        <view class="form_group">
+          <view class="group_title">所在城市:</view>
+          <view class="group_box">
+            <picker mode="multiSelector" class="form_ctrl" :range="cityArray" @columnchange="cityChange" @change="cityFinish">
+              <view class="area_text">
+                <text v-if="requestParam.province"> {{ requestParam.province }} </text>
+                <text v-if="requestParam.city"> / {{ requestParam.city }} </text>
+              </view>
+            </picker>
+          </view>
+        </view>
+        <button @click="toApply" class="submit_btn">提交</button>
+      </form>
+    </view>
+  </view>
 </template>
 
 <script>
-	
-	import {getProvinces,getMyCity} from "../../utils/city";
-	
-	export default {
-		data() {
-			return {
-				requestParam:{
-					province:"",
-					city:"",
-				},
-				cityArray: [[],[]],
-				cityValue: [0,0],
-			}
-		},
-		onLoad(){
-			// 替换对应的数据
-			this.cityArray.splice(0,1,getProvinces());
-			this.cityArray.splice(1,1,getMyCity(this.cityValue[0]));
-			// 默认地址
-			// this.requestParam.province 	= this.cityArray[0][this.cityValue[0]]
-			// this.requestParam.city 		= this.cityArray[1][this.cityValue[1]];
-		},
-		onShow(){
-			// 登录信息
-			if( !this.$checkAccess.alterLogin() ) return ;
-			// 授权成功以后,调用绑定
-			this.$http.request('api/custom/get_city',{},'get').then((re)=>{
-				// 成功的话
-				if( re.code != 'success' ){
-					// 跳转
-					uni.showToast({title: re.msg,icon:"none"});
-					return;
-				}
-				this.requestParam.province	= re.data.province;
-				this.requestParam.city 		= re.data.city;
-			});
-		},
-		methods: {
-			toApply(){
-				// 登录信息
-				if( !this.$checkAccess.alterLogin() ) return ;
-				// 提示信息
-				if( !this.requestParam.province ){
-					uni.showToast({
-						title:"请选择所在城市",
-						icon:"none"
-					})
-					return ;
-				}
-				// 提示信息
-				if( !this.requestParam.city ){
-					uni.showToast({
-						title:"请选择所在城市",
-						icon:"none"
-					})
-					return ;
-				}
-				// 请求状态
-				uni.showLoading({mask:true});
-				// 授权成功以后,调用绑定
-				this.$http.request('api/custom/set_city',this.requestParam,'post').then((re)=>{
-					// 关闭
-					uni.hideLoading();
-					// 成功的话
-					if( re.code != 'success' ){
-						// 跳转
-						uni.showToast({title: re.msg,icon:"none"});
-						return;
-					}
-					uni.switchTab({url: '/pages/user/index'});
-				});
-			},
-			cityChange(e){
-				// 替换三个选项
-				this.cityValue.splice(e.detail.column,1,e.detail.value);
-				// 下一级设置为0
-				if( e.detail.column == 0 ){
-					this.cityValue.splice(1,1,0);
-					this.cityValue.splice(2,1,0);
-				}
-				if( e.detail.column == 1 ){
-					this.cityValue.splice(2,1,0);
-				}
-				// 替换对应的数据
-				this.cityArray.splice(0,1,getProvinces());
-				this.cityArray.splice(1,1,getMyCity(this.cityValue[0]));
-			},
-			cityFinish(e){
-				this.requestParam.province 	= this.cityArray[0][this.cityValue[0]];
-				this.requestParam.city 		= this.cityArray[1][this.cityValue[1]];
-			},
-		}
-	}
+import { getProvinces, getMyCity } from '../../utils/city';
+
+export default {
+  data() {
+    return {
+      requestParam: {
+        province: '',
+        city: '',
+      },
+      cityArray: [[], []],
+      cityValue: [0, 0],
+    };
+  },
+  onLoad() {
+    // 替换对应的数据
+    this.cityArray.splice(0, 1, getProvinces());
+    this.cityArray.splice(1, 1, getMyCity(this.cityValue[0]));
+    // 默认地址
+    // this.requestParam.province 	= this.cityArray[0][this.cityValue[0]]
+    // this.requestParam.city 		= this.cityArray[1][this.cityValue[1]];
+  },
+  onShow() {
+    // 登录信息
+    if (!this.$checkAccess.alterLogin()) return;
+    // 授权成功以后,调用绑定
+    this.$http.request('api/custom/get_city', {}, 'get').then((re) => {
+      // 成功的话
+      if (re.code != 'success') {
+        // 跳转
+        uni.showToast({ title: re.msg, icon: 'none' });
+        return;
+      }
+      this.requestParam.province = re.data.province;
+      this.requestParam.city = re.data.city;
+    });
+  },
+  methods: {
+    toApply() {
+      // 登录信息
+      if (!this.$checkAccess.alterLogin()) return;
+      // 提示信息
+      if (!this.requestParam.province) {
+        uni.showToast({
+          title: '请选择所在城市',
+          icon: 'none',
+        });
+        return;
+      }
+      // 提示信息
+      if (!this.requestParam.city) {
+        uni.showToast({
+          title: '请选择所在城市',
+          icon: 'none',
+        });
+        return;
+      }
+      // 请求状态
+      uni.showLoading({ mask: true });
+      // 授权成功以后,调用绑定
+      this.$http.request('api/custom/set_city', this.requestParam, 'post').then((re) => {
+        // 关闭
+        uni.hideLoading();
+        // 成功的话
+        if (re.code != 'success') {
+          // 跳转
+          uni.showToast({ title: re.msg, icon: 'none' });
+          return;
+        }
+        uni.switchTab({ url: '/pages/user/index' });
+      });
+    },
+    cityChange(e) {
+      // 替换三个选项
+      this.cityValue.splice(e.detail.column, 1, e.detail.value);
+      // 下一级设置为0
+      if (e.detail.column == 0) {
+        this.cityValue.splice(1, 1, 0);
+        this.cityValue.splice(2, 1, 0);
+      }
+      if (e.detail.column == 1) {
+        this.cityValue.splice(2, 1, 0);
+      }
+      // 替换对应的数据
+      this.cityArray.splice(0, 1, getProvinces());
+      this.cityArray.splice(1, 1, getMyCity(this.cityValue[0]));
+    },
+    cityFinish(e) {
+      this.requestParam.province = this.cityArray[0][this.cityValue[0]];
+      this.requestParam.city = this.cityArray[1][this.cityValue[1]];
+    },
+  },
+};
 </script>
 
 <style lang="less">
-	.alter_info{
-		display: block;
-		color: #E03519;
-		font-size: 20rpx;
-		overflow: hidden;
-		margin: 20rpx auto;
-		background: #FFFFFF;
-		line-height: 40rpx;
-		padding: 35rpx 35rpx;
-		text-align: center;
-	}
-	.info_form{
-		display: block;
-		overflow: hidden;
-		padding: 20rpx 0rpx;
-		background: #FFFFFF;
-		.form_group{
-			display: block;
-			overflow: hidden;
-			line-height: 60rpx;
-			padding: 20rpx 35rpx;
-			.group_title{
-				float: left;
-				width: 160rpx;
-				display: block;
-				overflow: hidden;
-				font-size: 30rpx;
-				margin-right: 20rpx;
-			}
-			.group_box{
-				width: 480rpx;
-				float: left;
-				display: block;
-				.form_ctrl{
-					height: 56rpx;
-					font-size: 24rpx;
-					padding: 0rpx 20rpx;
-					line-height: 56rpx;;
-					border: 2rpx solid #DDDDDD;
-					.area_text{
-						width: 446rpx;
-						height: 56rpx;
-						font-size: 20rpx;
-						overflow: hidden;
-						white-space: nowrap;
-						line-height: 56rpx;
-						text-overflow: ellipsis;
-					}
-				}
-				.group_image{
-					width: 200rpx;
-					height: 200rpx;
-				}
-				.choose_image{
-					display: block;
-					width: 200rpx;
-					height: 200rpx;
-					font-size: 38rpx;
-					text-align: center;
-					line-height: 200rpx;
-					border: 2rpx solid #DDDDDD;
-				}
-			}
-		}
-		.submit_btn{
-			color: #FFFFFF;
-			width: 220rpx;
-			height: 80rpx;
-			display: block;
-			font-size: 30rpx;
-			padding: 0rpx 0rpx;
-			line-height: 80rpx;
-			margin: 50rpx auto;
-			background-color: forestgreen;
-		}
-	}
+.alter_info {
+  display: block;
+  color: #f89c33;
+  font-size: 20rpx;
+  overflow: hidden;
+  margin: 20rpx auto;
+  background: #ffffff;
+  line-height: 40rpx;
+  padding: 35rpx 35rpx;
+  text-align: center;
+}
+.info_form {
+  display: block;
+  overflow: hidden;
+  padding: 20rpx 0rpx;
+  background: #ffffff;
+  .form_group {
+    display: block;
+    overflow: hidden;
+    line-height: 60rpx;
+    padding: 20rpx 35rpx;
+    .group_title {
+      float: left;
+      width: 160rpx;
+      display: block;
+      overflow: hidden;
+      font-size: 30rpx;
+      margin-right: 20rpx;
+    }
+    .group_box {
+      width: 480rpx;
+      float: left;
+      display: block;
+      .form_ctrl {
+        height: 56rpx;
+        font-size: 24rpx;
+        padding: 0rpx 20rpx;
+        line-height: 56rpx;
+        border: 2rpx solid #dddddd;
+        .area_text {
+          width: 446rpx;
+          height: 56rpx;
+          font-size: 20rpx;
+          overflow: hidden;
+          white-space: nowrap;
+          line-height: 56rpx;
+          text-overflow: ellipsis;
+        }
+      }
+      .group_image {
+        width: 200rpx;
+        height: 200rpx;
+      }
+      .choose_image {
+        display: block;
+        width: 200rpx;
+        height: 200rpx;
+        font-size: 38rpx;
+        text-align: center;
+        line-height: 200rpx;
+        border: 2rpx solid #dddddd;
+      }
+    }
+  }
+  .submit_btn {
+    color: #ffffff;
+    width: 220rpx;
+    height: 80rpx;
+    display: block;
+    font-size: 30rpx;
+    padding: 0rpx 0rpx;
+    line-height: 80rpx;
+    margin: 50rpx auto;
+    background-color: forestgreen;
+  }
+}
 </style>

+ 22 - 22
pages/user/withdraw.vue

@@ -10,16 +10,16 @@
         <text>当前可提现余额{{ maxWithdrawAmount }}元</text>
         <view style="color: #5baff4" @click="_getAll">全部提现</view>
       </view>
-	  <view class="alter_info">若提现不成功,将在24小时内返回您的余额,可重新提现</view>
+      <view class="alter_info">若提现不成功,将在24小时内返回您的余额,可重新提现</view>
     </view>
     <button class="withdraw_btn" :class="isDisabled ? 'disabled' : ''" @click="_getMoney">确定提现</button>
   </view>
 </template>
 
 <script setup>
-import { ref, watch, onMounted } from "vue";
-import http from "@/utils/request";
-import common from "@/utils/common";
+import { ref, watch, onMounted } from 'vue';
+import http from '@/utils/request';
+import common from '@/utils/common';
 
 const withdrawAmount = ref(0);
 const maxWithdrawAmount = ref(0);
@@ -50,29 +50,29 @@ const _getMoney = common.debounce(async () => {
   if (isDisabled.value || loading.value) return;
 
   if (withdrawAmount.value < 0.1) {
-    uni.showToast({ icon: "none", title: "提现金额不能小于0.1元" });
+    uni.showToast({ icon: 'none', title: '提现金额不能小于0.1元' });
     return;
   }
 
   loading.value = true;
-  uni.showLoading({ title: "正在发起提现..." });
+  uni.showLoading({ title: '正在发起提现...' });
 
   try {
-    const loginRes = await uni.login({ provider: "weixin" });
-    const response = await http.request("/api/wechat_transfer/transfer", { code: loginRes.code, amount: withdrawAmount.value }, "POST");
+    const loginRes = await uni.login({ provider: 'weixin' });
+    const response = await http.request('/api/wechat_transfer/transfer', { code: loginRes.code, amount: withdrawAmount.value }, 'POST');
 
-    if (response.code !== "success") {
+    if (response.code !== 'success') {
       throw new Error(response.msg);
     }
 
     const systemInfo = uni.getSystemInfoSync();
-    if (systemInfo.uniPlatform !== "mp-weixin" || !wx.canIUse("requestMerchantTransfer")) {
-      throw new Error("你的微信版本过低,请更新至最新版本。");
+    if (systemInfo.uniPlatform !== 'mp-weixin' || !wx.canIUse('requestMerchantTransfer')) {
+      throw new Error('你的微信版本过低,请更新至最新版本。');
     }
 
     await new Promise((resolve, reject) => {
       wx.requestMerchantTransfer({
-        mchId: "1612111355",
+        mchId: '1612111355',
         appId: wx.getAccountInfoSync().miniProgram.appId,
         package: response.data.package_info,
         success: resolve,
@@ -81,10 +81,10 @@ const _getMoney = common.debounce(async () => {
     });
 
     uni.showModal({
-      title: "温馨提示",
-      content: "您已成功提现,请注意查看信息",
+      title: '温馨提示',
+      content: '您已成功提现,请注意查看信息',
       showCancel: false,
-      confirmText: "确认",
+      confirmText: '确认',
       success: (res) => {
         if (res.confirm) {
           _getUserInfo();
@@ -93,10 +93,10 @@ const _getMoney = common.debounce(async () => {
     });
   } catch (error) {
     uni.showModal({
-      title: "温馨提示",
-      content: error.message || "提现失败,请稍后再试",
+      title: '温馨提示',
+      content: error.message || '提现失败,请稍后再试',
       showCancel: false,
-      confirmText: "确认",
+      confirmText: '确认',
     });
   } finally {
     loading.value = false;
@@ -105,10 +105,10 @@ const _getMoney = common.debounce(async () => {
 }, 300);
 
 const _getUserInfo = () => {
-  http.request("api/custom/get_info").then((callback) => {
-    if (callback.code == "success") {
+  http.request('api/custom/get_info').then((callback) => {
+    if (callback.code == 'success') {
       maxWithdrawAmount.value = callback.data.amount;
-      uni.setStorageSync("userInfo", callback.data);
+      uni.setStorageSync('userInfo', callback.data);
     }
   });
 };
@@ -185,7 +185,7 @@ watch(withdrawAmount, (newValue) => {
 }
 .alter_info {
   display: block;
-  color: #e03519;
+  color: #f89c33;
   font-size: 20rpx;
   overflow: hidden;
   margin: 20rpx auto;

+ 420 - 4
pages/wait/index.vue

@@ -1,7 +1,40 @@
 <template>
   <view class="page">
     <image :src="imgUrl" mode="widthFix" />
-    <view v-if="!imagePage">即将开放,敬请期待</view>
+    <view class="wait_content" v-if="imagePage && requestParam.class_id == 11">敬请期待</view>
+    <view class="product_box" v-if="!imagePage">
+      <view class="to_bottom" v-if="!productList.length && !isReqing"> -----还没有产品啦-----</view>
+      <!-- 产品列表 -->
+      <view class="product_list">
+        <!-- Vue3 项目部分小程序端事件延迟或调用失败 在执行事件的元素上添加 data-eventsync="true" 属性以解决此问题 -->
+        <view @click="toDetail(item)" data-eventsync="true" class="product_item" v-for="(item, index) in productList" :key="index">
+          <view class="product_item_content">
+            <view class="product_image_content">
+              <image class="product_image" :src="item.thumb" mode=""></image>
+            </view>
+            <view>
+              <view class="product_name">
+                <text v-if="item.promo_title" class="regiment_title">{{ item.promo_title }}</text>
+                <text v-if="item.regiment_title" class="regiment_title">{{ item.regiment_title }}</text>
+                <text>{{ item.name }}</text></view
+              >
+              <view class="product_spec"
+                ><text>{{ item.spec }}</text></view
+              ></view
+            >
+          </view>
+          <view class="product_item_bottom">
+            <view class="stock_price">
+              <view class="product_price" v-if="isShowPrice">
+                <text>¥{{ item.price }} </text>
+              </view>
+              <view class="product_stock">剩{{ item.stock }}个</view>
+            </view>
+            <view class="stock_button">立即抢购</view>
+          </view>
+        </view>
+      </view>
+    </view>
   </view>
 </template>
 
@@ -11,15 +44,268 @@ export default {
     return {
       imagePage: false,
       imgUrl: '',
+      // 轮播图
+      bannerList: [],
+      // 产品列表
+      productList: [],
+      // 请求参数
+      requestParam: {
+        name: '',
+        page: 1,
+        class_id: '',
+      },
+      // 是否最后一页
+      isLast: false,
+      // 是否请求中
+      isReqing: false,
+      // 是否显示价格
+      isShowPrice: false,
+      // 城市名称
+      cityName: '选城市',
+      // 选择城市
+      toSelectedCity: false,
+      // 是否是管理员
+      isManager: false,
     };
   },
   onLoad(param) {
+    // #ifdef MP-WEIXIN
+    //分享按钮
+    uni.showShareMenu({
+      withShareTicket: true,
+      menus: ['shareAppMessage', 'shareTimeline'],
+    });
+    // #endif
+
     this.imgUrl = `https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/index/banner_${param.id}.png`;
-    this.imagePage = ['3', '11'].includes(param.id);
+    this.imagePage = ['101', '11', '1'].includes(param.id);
+    this.requestParam.class_id = param.id;
     uni.setNavigationBarTitle({
       title: param.name,
     });
   },
+  onShareAppMessage(obj) {
+    // 获取分享信息
+    let shareList = getApp().globalData.shareList;
+    // 获取分享信息
+    let shareObj = {
+      title: '999智控终端平台\n药优惠 得积分 兑豪礼',
+      path: '/pages/index/index',
+      imageUrl: '',
+    };
+    // 循环列表
+    for (let i in shareList) {
+      if (shareList[i].pages == 'pages/index/index') {
+        shareObj.path = shareList[i].path ? shareList[i].path : shareObj.path;
+        shareObj.title = shareList[i].title ? `999智控终端平台\n${shareList[i].title}` : shareObj.title;
+        shareObj.imageUrl = shareList[i].image_url ? shareList[i].image_url : shareObj.imageUrl;
+      }
+    }
+    // 返回分享信息
+    return shareObj;
+  },
+  onShow() {
+    // 是否显示价格
+    this.isShowPrice = this.$checkAccess.checkShowPrice();
+    // 城市名
+    this.cityName = this.$checkAccess.getCity();
+    // 选城市
+    (this.cityName = this.cityName ? this.cityName : '选城市'),
+      // 登录并且未选择城市,才可以选择城市
+      (this.toSelectedCity = !this.$checkAccess.getCity() ? true : false);
+    // 数据
+
+    //未选城市先弹窗提醒选择城市
+    if (!this.$checkAccess.getCity() && this.$checkAccess.checkLogin()) {
+      uni.showModal({
+        title: '',
+        content: '请先选择城市',
+        success: (res) => {
+          if (res.confirm) {
+            uni.navigateTo({
+              url: '/pages/user/info',
+            });
+          }
+        },
+      });
+    }
+
+    //如果已选城市且没有添加客服每天弹窗一次
+    if (this.$checkAccess.getCity() && this.$checkAccess.getFollowQrcode()) {
+      // 获取弹出时间
+      let followPopupTime = uni.getStorageSync('followPopupTime');
+      // 现在的时候
+      let nowTime = new Date().getTime();
+      // 时间戳
+      followPopupTime = followPopupTime ? followPopupTime : 0;
+      // 弹出结果
+      if (followPopupTime <= 0 || followPopupTime - nowTime > 86400000) {
+        this.$refs.addFollow.open('center');
+        uni.setStorageSync('followPopupTime', nowTime);
+      }
+    }
+    this.isManager = this.$checkAccess.isManager();
+    // 没有数据的话,或者请求中,不允许刷新
+    if (this.isReqing) return;
+    // 获取列表
+    this.$http.request('/api/banner/get_list').then((re) => {
+      if (re.code === 'success') {
+        this.bannerList = re.data;
+      }
+    });
+    // 请求参数
+    this.requestParam.name = '';
+    // 请求参数
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求
+    this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        // 如果是最后一页
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        // 赋值
+        this.productList = re.data.data;
+        // 获取下一页
+        this.getMore(re);
+      }
+    });
+  },
+  onPullDownRefresh() {
+    // 如果请求中,不允许请求,
+    if (this.isReqing) return false;
+    // 初始化页码为1
+    this.requestParam.page = 1;
+    // 是否是最后一页
+    this.isLast = false;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        // 如果是最后一页
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        // 赋值
+        this.productList = re.data.data;
+        // 获取下一页
+        this.getMore(re);
+      }
+    });
+    uni.stopPullDownRefresh();
+  },
+  onReachBottom() {
+    // 如果页码是0,避免第一页重复
+    if (this.requestParam.page < 1) return;
+    // 最后一页不再请求
+    if (this.isLast) return;
+    // 请求中,不再请求
+    if (this.isReqing) return;
+    // 增加一页
+    this.requestParam.page = this.requestParam.page + 1;
+    // 设置请求中
+    this.isReqing = true;
+    // 请求列表
+    this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+      // 设置非请求中
+      this.isReqing = false;
+      // 成功结果
+      if (re.code == 'success') {
+        // 最后一页
+        if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+        // 追加数据
+        this.productList.push(...re.data.data);
+      }
+    });
+  },
+  methods: {
+    // 请求加载下一页
+    getMore(callback) {
+      // 首页不足10个,并且下一页存在大于当前页
+      if (this.productList.length < 10 && callback.data.last_page > this.requestParam.page) {
+        // 最后一页不再请求
+        if (this.isLast) return;
+        // 增加一页
+        this.requestParam.page = this.requestParam.page + 1;
+        // 请求列表
+        this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+          // 成功结果
+          if (re.code == 'success') {
+            // 最后一页
+            if (re.data.last_page <= this.requestParam.page) this.isLast = true;
+            // 追加数据
+            this.productList.push(...re.data.data);
+            // 获取下一页
+            this.getMore(re);
+          }
+        });
+      }
+    },
+    searchChange(e) {
+      // 如果没有搜索词
+      if (!this.requestParam.name) {
+        this.searchOpen();
+      }
+    },
+    searchOpen() {
+      // 请求中,不再请求
+      if (this.isReqing) return;
+      // 是否是最后一页
+      this.isLast = false;
+      // 初始化页码为1
+      this.requestParam.page = 1;
+      // 设置请求中
+      this.isReqing = true;
+      // 请求列表
+      this.$http.request('api/product/get_list', this.requestParam).then((re) => {
+        // 设置非请求中
+        this.isReqing = false;
+        // 成功结果
+        if (re.code == 'success') {
+          this.productList = re.data.data;
+          if (re.data.data.length && re.data.last_page >= this.requestParam.page) this.isLast = true;
+        }
+      });
+    },
+    toDetail(item) {
+      uni.navigateTo({
+        url: '/pages/product/index?product_id=' + item.id,
+      });
+    },
+    navLottery(url) {
+      // 没有路径,不跳转
+      if (!url) return;
+      // 判断是不是小程序链接
+      if (url.includes('http')) {
+        // 转码
+        let link_url = encodeURIComponent(url);
+        // 跳转到webview
+        uni.redirectTo({
+          url: `/pages/webview/index?link_url=${link_url}`,
+        });
+      } else {
+        // 跳转到webview
+        uni.navigateTo({
+          url: url,
+        });
+      }
+    },
+    closePopup() {
+      this.$refs.addFollow.close();
+      //存key以及时间
+      uni.setStorage({
+        key: 'followPopupTime',
+        data: new Date().getTime(),
+      });
+    },
+  },
 };
 </script>
 
@@ -29,10 +315,29 @@ export default {
   height: 100vh;
   display: flex;
   flex-direction: column;
-  overflow: hidden;
   > image {
-    height: 300rpx;
     width: 100%;
+    position: sticky;
+    margin-bottom: 20rpx;
+    flex-shrink: 0;
+  }
+  .wait_content {
+    position: absolute;
+    bottom: 5%;
+    left: 50%;
+    transform: translate(-50%, -50%);
+    font-size: 30rpx;
+    color: #999;
+    text-align: center;
+    width: 550rpx;
+    height: 75rpx;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    box-sizing: border-box;
+    background-color: #ffffff;
+    opacity: 0.9;
+    border-radius: 20rpx;
   }
   > view {
     flex: 1;
@@ -42,5 +347,116 @@ export default {
     justify-content: center;
     align-items: center;
   }
+  .product_box {
+    display: block;
+    padding: 0rpx 35rpx;
+    .product_list {
+      display: block;
+      overflow: hidden;
+      margin: 0rpx auto;
+      .product_item {
+        // float: left;
+        width: 100%;
+        // height: 520rpx;
+        display: block;
+        overflow: hidden;
+        margin: 20rpx 0rpx;
+        margin-right: 40rpx;
+        background-color: #ffffff;
+        border-radius: 20rpx;
+        padding: 16rpx;
+        box-sizing: border-box;
+        .product_item_content {
+          display: flex;
+          gap: 10rpx;
+        }
+        .product_item_bottom {
+          display: flex;
+          justify-content: space-between;
+          align-items: center;
+        }
+        .product_image_content {
+          width: 168rpx;
+          height: 168rpx;
+          background: #f5f5f5;
+          border-radius: 16rpx 16rpx 16rpx 16rpx;
+          display: flex;
+          align-items: center;
+          justify-content: center;
+          flex-shrink: 0;
+        }
+        .product_image {
+          width: 143rpx;
+          height: 149rpx;
+          flex-shrink: 0;
+        }
+        .product_name {
+          // height: 80rpx;
+          font-size: 30rpx;
+          line-height: 40rpx;
+          overflow: hidden;
+          margin: 10rpx 0rpx;
+          padding: 0rpx 10rpx;
+          text-overflow: ellipsis;
+          .regiment_title {
+            background-color: red;
+            color: #f9f9f9;
+          }
+        }
+        .product_spec {
+          height: 30rpx;
+          color: #999999;
+          font-size: 24rpx;
+          line-height: 30rpx;
+          padding: 0rpx 10rpx;
+          overflow: hidden;
+          white-space: nowrap;
+          text-overflow: ellipsis;
+        }
+        .stock_price {
+          color: #dddddd;
+          font-size: 20rpx;
+          overflow: hidden;
+          line-height: 30rpx;
+          padding: 0rpx 10rpx;
+          display: flex;
+          gap: 10rpx;
+          align-items: baseline;
+          padding-left: 185rpx;
+          box-sizing: border-box;
+          .product_price {
+            color: red;
+            font-size: 30rpx;
+            line-height: 60rpx;
+            .product_market {
+              font-size: 24rpx;
+              color: #999999;
+              line-height: 30rpx;
+              vertical-align: top;
+              text-decoration: line-through;
+            }
+          }
+          .product_stock {
+            font-size: 20rpx;
+            line-height: 60rpx;
+          }
+        }
+        .stock_button {
+          width: 152rpx;
+          height: 60rpx;
+          background: #f89c33;
+          border-radius: 500rpx 500rpx 500rpx 500rpx;
+          color: #ffffff;
+          color: 26rpx;
+          text-align: center;
+          line-height: 60rpx;
+          font-size: 24rpx;
+        }
+      }
+      .product_item:nth-child(even) {
+        margin-right: 0rpx;
+      }
+    }
+  }
 }
 </style>

BIN
static/icon/car.png


BIN
static/icon/car_active.png


BIN
static/icon/home.png


BIN
static/icon/home_active.png


BIN
static/icon/product.png


BIN
static/icon/product_active.png


BIN
static/icon/user.png


BIN
static/icon/user_active.png


BIN
static/icon/video.png


BIN
static/icon/video_active.png


+ 12 - 0
uni_modules/cc-myTabbar/changelog.md

@@ -0,0 +1,12 @@
+## 2.2.4(2024-10-03)
+组件优化
+## 2.2.2(2024-07-13)
+组件优化
+## 2.2(2024-06-27)
+优化
+## 2.0(2024-05-16)
+组件优化
+## 1.0.1(2023-06-22)
+组件使用说明优化
+## 1.0.0(2023-06-22)
+组件初始化

+ 42 - 0
uni_modules/cc-myTabbar/components/cc-myTabbar/cc-myTabbar.scss

@@ -0,0 +1,42 @@
+/* 主要颜色 */
+$base: #F89C33; // 基础颜色
+.page-total{
+		position: fixed;
+		left: 0;
+		bottom: 0;
+		width: 100%;
+		// height: 100rpx;
+		z-index: 999;
+	}
+	.tab-list{
+		display: flex;
+		justify-content: space-between;
+		align-items: center;
+		width: 100%;
+		height: 120rpx;
+		padding-bottom: 10px;
+		background-color: #FFFFFF;
+		.list{
+			display: flex;
+			flex-direction: column;
+			align-items: center;
+			justify-content: center;
+			width: 20%;
+			height: 120rpx;
+			image{
+				width: 48rpx;
+				height: 48rpx;
+				background-color: white;
+				flex-shrink: 0;
+				
+			}
+			text{
+				color: #333333;
+				font-size: 24rpx;
+				margin-top: 10rpx;
+			}
+			.action{
+				color: $base;
+			}
+		}
+	}

+ 131 - 0
uni_modules/cc-myTabbar/components/cc-myTabbar/cc-myTabbar.vue

@@ -0,0 +1,131 @@
+<template>
+  <view class="page-total">
+    <view class="tab-list">
+      <view class="list" v-for="(item, index) in TabBarList" @click="onTabBar(item, index)" :style="{ marginTop: index == 2 ? '-12px' : '0px' }" :key="index">
+        <image :src="item.acImg" mode="widthFix" v-show="tabBarShow === index" :style="{ width: index == 2 ? '60px' : '24px', borderRadius: index == 2 ? '50%' : '0px' }"></image>
+        <image :src="item.img" mode="widthFix" v-show="tabBarShow != index" :style="{ width: index == 2 ? '60px' : '24px', borderRadius: index == 2 ? '50%' : '0px' }"></image>
+
+        <!-- background: (index == 2) ?  'red' : '' -->
+        <text :class="{ action: tabBarShow === index }" :style="{ marginTop: index == 2 ? '4px' : '0px' }">{{ item.name }}</text>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      TabBarList: [
+        {
+          index: 0,
+          name: '首页',
+          img: '/static/icon/home.png',
+          acImg: '/static/icon/home_active.png',
+        },
+        {
+          index: 1,
+          name: '执药考试',
+          img: '/static/icon/video.png',
+          acImg: '/static/icon/video_active.png',
+        },
+        {
+          index: 2,
+          name: '',
+          img: '/static/icon/product.png',
+          acImg: '/static/icon/product_active.png',
+        },
+        {
+          index: 3,
+          name: '采购车',
+          img: '/static/icon/car.png',
+          acImg: '/static/icon/car_active.png',
+        },
+        {
+          index: 4,
+          name: '我的',
+          img: '/static/icon/user.png',
+          acImg: '/static/icon/user_active.png',
+        },
+      ],
+      codeheight: 0,
+      isOverall: 0,
+      phoneModel: '',
+    };
+  },
+  props: {
+    tabBarShow: {
+      type: Number,
+      default: 0,
+    },
+  },
+  mounted() {
+    try {
+      const res = uni.getSystemInfoSync();
+      let that = this;
+      // 获取系统信息
+      uni.getSystemInfo({
+        success(res) {
+          console.log(res.brand); //手机牌子
+          console.log(res.model); //手机型号
+          console.log(res.screenWidth); //屏幕宽度
+          console.log(res.screenHeight); //屏幕高度
+          that.codeheight = Math.round(res.screenHeight);
+          that.phoneModel = res.model;
+          if (res.model.search('iPhone')) {
+            that.isOverall = 0;
+          } else if (Math.round(res.screenHeight) > 740) {
+            that.isOverall = 1;
+          }
+          console.log(that.isOverall);
+        },
+      });
+    } catch (e) {
+      // error
+    }
+  },
+  methods: {
+    /**
+     * @param {Object} item
+     * @param {Number} index
+     */
+    onTabBar(item, index) {
+      // this.tabBarShow = index;
+      switch (index) {
+        case 0:
+          uni.switchTab({
+            url: '/pages/index/index',
+          });
+          break;
+        case 1:
+          //   uni.switchTab({
+          //     url: '/pages/shop/shop',
+          //   });
+          uni.navigateToMiniProgram({
+            appId: 'wx37802f7af7be337e',
+          });
+          break;
+        case 2:
+          uni.switchTab({
+            url: '/pages/product/list',
+          });
+          break;
+        case 3:
+          uni.switchTab({
+            url: '/pages/car/index',
+          });
+          break;
+        case 4:
+          uni.switchTab({
+            url: '/pages/user/index',
+          });
+          break;
+      }
+    },
+  },
+};
+</script>
+
+<style scoped lang="scss">
+@import 'cc-myTabbar.scss';
+</style>

+ 86 - 0
uni_modules/cc-myTabbar/package.json

@@ -0,0 +1,86 @@
+{
+  "id": "cc-myTabbar",
+  "displayName": "自定义tabbar底部tabbar凸起tabbar兼容苹果刘海屏小程序和APP",
+  "version": "2.2.4",
+  "description": "自定义tabbar底部tabbar凸起tabbar兼容苹果刘海屏Home键小程序和APP 可自定义tabbar图片文字大小及位置",
+  "keywords": [
+    "tabbar",
+    "自定义tabbar",
+    "底部导航",
+    "自定义",
+    "凸起导航"
+],
+  "repository": "",
+  "engines": {
+    "HBuilderX": "^3.8.0"
+  },
+  "dcloudext": {
+    "type": "component-vue",
+    "sale": {
+      "regular": {
+        "price": "0.00"
+      },
+      "sourcecode": {
+        "price": "0.00"
+      }
+    },
+    "contact": {
+      "qq": ""
+    },
+    "declaration": {
+      "ads": "无",
+      "data": "无",
+      "permissions": "无"
+    },
+    "npmurl": ""
+  },
+  "uni_modules": {
+    "dependencies": [],
+    "encrypt": [],
+    "platforms": {
+      "cloud": {
+        "tcb": "y",
+        "aliyun": "y",
+        "alipay": "n"
+      },
+      "client": {
+        "Vue": {
+          "vue2": "y",
+          "vue3": "y"
+        },
+        "App": {
+          "app-vue": "y",
+          "app-nvue": "y"
+        },
+        "H5-mobile": {
+          "Safari": "y",
+          "Android Browser": "y",
+          "微信浏览器(Android)": "y",
+          "QQ浏览器(Android)": "y"
+        },
+        "H5-pc": {
+          "Chrome": "y",
+          "IE": "y",
+          "Edge": "y",
+          "Firefox": "y",
+          "Safari": "y"
+        },
+        "小程序": {
+          "微信": "y",
+          "阿里": "y",
+          "百度": "y",
+          "字节跳动": "y",
+          "QQ": "y",
+          "钉钉": "y",
+          "快手": "y",
+          "飞书": "y",
+          "京东": "y"
+        },
+        "快应用": {
+          "华为": "y",
+          "联盟": "y"
+        }
+      }
+    }
+  }
+}

+ 89 - 0
uni_modules/cc-myTabbar/readme.md

@@ -0,0 +1,89 @@
+# cc-myTabbar  
+ 
+ 
+##uniapp专属精品组件页面模板(由前端组件开发出品)精品组件页面模板
+
+###●组件模板规划:
+由前端组件开发出品的精品组件页面模板,将陆续发布,预计高达约几百种供您使用,是快速快发项目、创业的必备精品。
+
+合集地址: uni-app模板合集地址:(https://ext.dcloud.net.cn/publisher?id=274945) 如查看全部页面模板,请前往上述uniapp插件市场合集地址;
+
+###●组件模板效果图:
+可下载项目后预览,效果图见右侧图片;
+
+###●组件模板费用:
+学习:免费下载,进行学习,无费用;
+
+使用/商用:本页面地址赞赏10元后,可终身商用;
+
+###●组件模板使用版权/商用:
+本组件模板免费下载可供学习,如需使用及商用,请在本组件页面模板进行赞赏10元
+
+(仅需10元获取精品页面模板代码-物有所值,1个组件页面市场价100元 )
+
+赞赏10后(当前项目产生赞赏订单可追溯)即可终身商用当前本地址下载的页面模版代码,不同下载地址需进行不同的赞赏。(不赞赏就进行商用使用者,面临侵权!保留追究知识产权法律责任!后果自负!)
+
+
+
+### 我的技术公众号(私信可加前端技术交流群)
+
+群内气氛挺不错的,应该或许可能大概,算是为数不多的,专搞技术的前端群,偶尔聊天摸鱼
+
+![图片](https://i.postimg.cc/RZ0sjnYP/front-End-Component.jpg)
+
+
+#### 使用方法 
+```使用方法	
+<!-- tabBarShow:显示第几个tabbar -->
+<cc-myTabbar :tabBarShow="0"></cc-myTabbar>
+
+<!-- 隐藏原生tabbar -->				
+onReady() {
+		uni.hideTabBar()
+}
+
+<!-- 页面距离底部140rpx(自定义tabbar的高度) -->
+page {
+		padding-bottom: 140rpx;
+}
+```
+
+#### HTML代码实现部分
+```html
+
+<template>
+	<view class="page">
+
+		<!-- tabBarShow:显示第几个tabbar -->
+		<cc-myTabbar :tabBarShow="0"></cc-myTabbar>
+
+	</view>
+</template>
+
+<script>
+	export default {
+		
+		data() {
+			return {
+
+			};
+		},
+		onReady() {
+			uni.hideTabBar()
+		},
+
+		methods: {
+
+		}
+	}
+</script>
+
+<style scoped lang="scss">
+	page {
+		padding-bottom: 140rpx;
+
+	}
+</style>
+
+
+```