Преглед изворни кода

我的页面添加商城订单入口

xiaohaizhao пре 11 месеци
родитељ
комит
f66b549538
1 измењених фајлова са 159 додато и 130 уклоњено
  1. 159 130
      pages/index/index/userCenter.vue

+ 159 - 130
pages/index/index/userCenter.vue

@@ -1,172 +1,201 @@
 <template>
-	<view>
-		<view class="user-info">
-			<UserInfo @upData="getUserInfo()" :isCode="false" :userInfoValue="userInfoValue"></UserInfo>
-		</view>
-		<view class="border-list-box">
-			<navigator class="border-list-top" url="/packageA/shop/history?title=我访问的店铺" hover-class="navigator-hover">
-				<view class="text-style">
-					我的访问店铺
-				</view>
-				<view class="right">
-					<view class="iconfont icon-a-wodetiaozhuan icon-style-long"></view>
-				</view>
-			</navigator>
-			<navigator class="border-list-content" url="/cloud/mySubscription/index" hover-class="navigator-hover">
-				<view class="text-style">
-					我的预约
-				</view>
-				<view class="right">
-					<view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
-				</view>
-			</navigator>
-			<!--        <navigator class="border-list-content" url="" hover-class="navigator-hover">
+  <view>
+    <view class="user-info">
+      <UserInfo
+        @upData="getUserInfo()"
+        :isCode="false"
+        :userInfoValue="userInfoValue"
+      ></UserInfo>
+    </view>
+    <view class="border-list-box">
+      <navigator
+        class="border-list-top"
+        url="/packageA/shop/history?title=我访问的店铺"
+        hover-class="navigator-hover"
+      >
+        <view class="text-style"> 我的访问店铺 </view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style-long"></view>
+        </view>
+      </navigator>
+      <navigator
+        class="border-list-content"
+        url="/cloud/mySubscription/index"
+        hover-class="navigator-hover"
+      >
+        <view class="text-style"> 我的预约 </view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
+        </view>
+      </navigator>
+      <navigator
+        class="border-list-content"
+        url="/store/orderForm/index"
+        hover-class="navigator-hover"
+      >
+        <view class="text-style"> 商城订单 </view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
+        </view>
+      </navigator>
+      <!--        <navigator class="border-list-content" url="" hover-class="navigator-hover">
           <view class="text-style">优惠券</view>
           <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
         </navigator> -->
-			<navigator class="border-list-content" url="/store/deliveryAddress/index" hover-class="navigator-hover">
-				<view class="text-style">收货地址</view>
-				<view class="right">
-					<view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
-				</view>
-			</navigator>
-			<navigator class="border-list-content" url="/cloud/winningNews/index" hover-class="navigator-hover"
-				v-if="isWinning">
-				<view class="text-style">中奖信息</view>
-				<view class="right">
-					<view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
-				</view>
-			</navigator>
-			<navigator class="border-list-content" url="/cloud/collect/mylist" hover-class="navigator-hover">
-				<view class="text-style">我的收藏</view>
-				<view class="right">
-					<view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
-				</view>
-			</navigator>
-			<!-- <navigator class="border-list-bottom" url="" hover-class="navigator-hover">
+      <navigator
+        class="border-list-content"
+        url="/store/deliveryAddress/index"
+        hover-class="navigator-hover"
+      >
+        <view class="text-style">收货地址</view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
+        </view>
+      </navigator>
+      <navigator
+        class="border-list-content"
+        url="/cloud/winningNews/index"
+        hover-class="navigator-hover"
+        v-if="isWinning"
+      >
+        <view class="text-style">中奖信息</view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
+        </view>
+      </navigator>
+      <navigator
+        class="border-list-content"
+        url="/cloud/collect/mylist"
+        hover-class="navigator-hover"
+      >
+        <view class="text-style">我的收藏</view>
+        <view class="right">
+          <view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
+        </view>
+      </navigator>
+      <!-- <navigator class="border-list-bottom" url="" hover-class="navigator-hover">
 				<view class="text-style">活动订单</view>
 				<view class="iconfont icon-a-wodetiaozhuan icon-style"></view>
 			</navigator> -->
-		</view>
-	</view>
+    </view>
+  </view>
 </template>
 
 <script>
-import UserInfo from '../cloud/userInfo.vue'
+import UserInfo from "../cloud/userInfo.vue";
 export default {
-	components: { UserInfo },
-	data() {
-		return {
-			updatePage: true,
-			isWinning: true,
-			userInfoValue: {},
-			countObj:{}
-		}
-	},
-	methods: {
-		init(callBack) {
-			this.updatePage = false;
-			this.queryAuth()
-			this.getUserInfo().then(res => {
-				callBack()
-			})
-		},
-		getUserInfo() {
-			return new Promise(async (resolve, reject) => {
-				let res = await this.$Http.basic({
-					"id": "20240510104102",
-					"content": {}
-				})
-                if (this.cutoff(res.msg)) return;
-				resolve()
-				this.userInfoValue = res.data
-			})
-
-		},
-		queryAuth() {
-			let auth = uni.getStorageSync("authList")
-			if (auth.工作台导航.中奖明细) {
-				this.isWinning = true
-			} else {
-				this.isWinning = false
-			}
-		}
-	},
-}
+  components: { UserInfo },
+  data() {
+    return {
+      updatePage: true,
+      isWinning: true,
+      userInfoValue: {},
+      countObj: {},
+    };
+  },
+  methods: {
+    init(callBack) {
+      this.updatePage = false;
+      this.queryAuth();
+      this.getUserInfo().then((res) => {
+        callBack();
+      });
+    },
+    getUserInfo() {
+      return new Promise(async (resolve, reject) => {
+        let res = await this.$Http.basic({
+          id: "20240510104102",
+          content: {},
+        });
+        if (this.cutoff(res.msg)) return;
+        resolve();
+        this.userInfoValue = res.data;
+      });
+    },
+    queryAuth() {
+      let auth = uni.getStorageSync("authList");
+      if (auth.工作台导航.中奖明细) {
+        this.isWinning = true;
+      } else {
+        this.isWinning = false;
+      }
+    },
+  },
+};
 </script>
 
 <style lang="scss">
 .border-list-box {
-	width: 355px;
-	border-radius: 8px;
-	background: #FFFFFF;
-	margin: 20px 10px 0px 10px;
+  width: 355px;
+  border-radius: 8px;
+  background: #ffffff;
+  margin: 20px 10px 0px 10px;
 }
 
 .user-info {
-	margin: 0 0 0 10px;
+  margin: 0 0 0 10px;
 }
 
 .border-list-top {
-	background: #FFFFFF;
-	border-bottom: 1px solid #F7F7F7;
-	display: flex;
-	justify-content: space-between;
-	margin-left: 10px;
+  background: #ffffff;
+  border-bottom: 1px solid #f7f7f7;
+  display: flex;
+  justify-content: space-between;
+  margin-left: 10px;
 }
 
 .border-list-content {
-	background: #FFFFFF;
-	border-bottom: 1px solid #F7F7F7;
-	display: flex;
-	justify-content: space-between;
-	margin-left: 10px;
+  background: #ffffff;
+  border-bottom: 1px solid #f7f7f7;
+  display: flex;
+  justify-content: space-between;
+  margin-left: 10px;
 }
 
 .border-list-bottom {
-	background: #FFFFFF;
-	display: flex;
-	justify-content: space-between;
-	margin-left: 10px;
+  background: #ffffff;
+  display: flex;
+  justify-content: space-between;
+  margin-left: 10px;
 }
 
 .text-style {
-	font-family: Source Han Sans SC, Source Han Sans SC;
-	font-weight: 400px;
-	font-size: 14px;
-	color: #333333;
-	height: 20px;
-	line-height: 20px;
-	text-align: left;
-	vertical-align: auto;
-	font-style: normal;
-	text-transform: none;
-	padding: 15px 15px 15px 0px;
+  font-family: Source Han Sans SC, Source Han Sans SC;
+  font-weight: 400px;
+  font-size: 14px;
+  color: #333333;
+  height: 20px;
+  line-height: 20px;
+  text-align: left;
+  vertical-align: auto;
+  font-style: normal;
+  text-transform: none;
+  padding: 15px 15px 15px 0px;
 }
 
 .icon-style-long {
-	color: #999999;
-	padding: 15px 15px 15px 10px;
+  color: #999999;
+  padding: 15px 15px 15px 10px;
 }
 
 .icon-style {
-	color: #999999;
-	padding: 15px 10px 15px 10px;
+  color: #999999;
+  padding: 15px 10px 15px 10px;
 }
 
 .right {
-	display: flex;
-	align-items: center;
-	align-content: center;
+  display: flex;
+  align-items: center;
+  align-content: center;
 
-	.tag {
-		background: #BBBBBB;
-		border-radius: 50px 50px 50px 50px;
-		padding: 3px 12px;
-		font-family: PingFang SC, PingFang SC;
-		font-weight: 400;
-		font-size: 10px;
-		color: #FFFFFF;
-	}
+  .tag {
+    background: #bbbbbb;
+    border-radius: 50px 50px 50px 50px;
+    padding: 3px 12px;
+    font-family: PingFang SC, PingFang SC;
+    font-weight: 400;
+    font-size: 10px;
+    color: #ffffff;
+  }
 }
 </style>