Pārlūkot izejas kodu

Merge branch 'master' of http://150.158.33.144:3000/lalalashen/MoeNovaClient

ck@123911.net 2 mēneši atpakaļ
vecāks
revīzija
c204502230

+ 6 - 3
components/CustomDialog/CustomDialog.vue

@@ -6,7 +6,7 @@
         <text class="dialog-title">{{title}}</text>
       </view>
       <view class="dialog-close" @click="closeDialog" v-if="!closeImg">×</view>
-      <image v-if="closeImg" class="dialog-close-img" :src="closeImg" @click="closeDialog" mode="aspectFit"></image>
+      <image v-if="closeImg" class="dialog-close-img" :src="closeImg" @click="closeDialog" mode="aspectFit" :style="{ top: closeImgTop && closeImgTop.length > 0 ? closeImgTop : '20rpx' }"></image>
       <view class="dialog-body">
         <slot></slot>
       </view>
@@ -33,6 +33,10 @@ export default {
     closeImg: {
       type: String,
       default: ''
+    },
+    closeImgTop: {
+      type: String,
+      default: ''
     }
   },
   data() {
@@ -151,7 +155,6 @@ export default {
   .dialog-close-img {
     position: absolute;
     right: 20rpx;
-    top: 20rpx;
     width: 60rpx;
     height: 60rpx;
     z-index: 1;
@@ -163,7 +166,7 @@ export default {
   }
   
   .dialog-body {
-    padding: 30rpx;
+    padding: 0rpx;
   }
 }
 </style> 

+ 6 - 0
components/SharePopup/SharePopup.vue

@@ -234,6 +234,11 @@ export default {
     },
     handleReport() {
       // 实现举报功能
+      uni.$emit('check_login', () => {
+				uni.navigateTo({
+					url: '/pages/my/feedback'
+				})
+			})
       uni.showToast({
         title: '举报功能开发中',
         icon: 'none'
@@ -255,6 +260,7 @@ export default {
           })
         }
       })
+      // #endif
     },
     moreShare() {
       // 更多分享方式

+ 11 - 3
pages/index/Search.vue

@@ -77,10 +77,10 @@
 
         <view v-show="currentTab === 1" class="follow-list">
           <block v-if="recommendList.length > 0">
-            <view class="follow-item" v-for="(item, index) in recommendList" :key="index">
-              <CircleAvatar class="avator" :src="item.avator"></CircleAvatar>
+            <view class="follow-item" v-for="(item, index) in recommendList" :key="index" @click="goToUserHomepage(item.id)"> 
+              <CircleAvatar  @click="goToUserHomepage(item.user_id)" class="avator" :src="item.avator"></CircleAvatar>
               <view class="info">
-                <view class="top-box">
+                <view class="top-box" @click="goToUserHomepage(item.user_id)"> 
                   <view class="name one-omit">{{ item.nickname }}</view>
                   <image src="../../static/icon/wd_icon_nan.png" mode="widthFix" v-if="item.sex_id == 1" />
                   <image src="../../static/icon/wd_icon_nv.png" mode="widthFix" v-else-if="item.sex_id == 2" />
@@ -531,6 +531,14 @@ export default {
     },
     // 搜索请求
     searchRequest() {
+    },
+    	goToUserHomepage(id) {
+			if (!id) {
+				return;
+			} 
+      uni.navigateTo({
+        url: "/pages/my/userHomepage?id=" + id,
+      });
     },
   }
 }

+ 10 - 2
pages/index/articleDetail.vue

@@ -12,7 +12,7 @@
 				<text class="fa fa-angle-left"></text>
 			</view>
 			<view class="navbar-center">
-				<view class="navbar-title" v-if="isMessage">
+				<view class="navbar-title" v-if="isMessage" @click="goToUserHomepage(author.id)">
 					<image class="navbar-avatar" :src="author.avator" mode="aspectFill"></image>
 					<text class="navbar-text">{{ author.nickname }}</text>
 					<!-- <text class="navbar-badge" v-if="author.is_vip > 0">VIP</text> -->
@@ -219,7 +219,7 @@ export default {
 			this.isMessage = false;
 		}
 		if (parms.sms_id) {
-			this.sms_id = parms.sms_id; 
+			this.sms_id = parms.sms_id;
 		}
 	},
 	onShow() {
@@ -680,6 +680,14 @@ export default {
 					// this.delCloseFun()
 				});
 		},
+			goToUserHomepage(id) {
+			if (!id) {
+				return;
+			}
+			uni.navigateTo({
+				url: "/pages/my/userHomepage?id=" + id,
+			});
+		},
 	},
 };
 </script>

+ 6 - 6
pages/index/index.vue

@@ -32,7 +32,7 @@
 								<p>{{ getDayOfWeek }}</p>
 							</view>
 						</view>
-						<view class="search" @click="goPage('/pages/index/Search')">
+						<view class="search step1" @click="goPage('/pages/index/Search')">
 							<uv-input placeholder="🔥“潮玩大作战” 派对季重磅开启!" border="none"
 								:custom-style="{ background: '#fff', paddingLeft: '25rpx' }" shape="circle">
 
@@ -50,7 +50,7 @@
 					</template>
 				</page-navbar>
 			</template>
-			<z-paging-cell class="benner-box">
+			<z-paging-cell class="benner-box ">
 				<sortble :default-sorts="['uvSwiper', 'classModel', 'uvSwiperCard']">
 					<template #uvSwiper>
 						<uv-swiper :list="bannerList" :autoplay="true" circular :interval="5000" indicator
@@ -71,7 +71,7 @@
 							</view>
 							<view class="benner-box benner-right-box" ref="classModel1"
 								>
-								<view class="guard">
+								<view class="guard ">
 									<view class="text">
 										潮玩IP
 									</view>
@@ -101,7 +101,7 @@
 				</sortble>
 			</z-paging-cell>
 			<z-paging-cell style="background: #fff;">
-				<view class="tab-nav">
+				<view class="tab-nav ">
 					<view v-for="(tab, index) in tabs" :key="index"
 						:class="['tab-item', currentTab === index ? 'active' : '']" @click="switchTab(index)">
 						{{ tab }}
@@ -159,7 +159,7 @@
 
 				<!-- 根据当前标签显示不同样式的列表 -->
 				<!-- 关注列表 - 类似my.vue -->
-				<view v-show="currentTab === 0" class="follow-list">
+				<view v-show="currentTab === 0" class="follow-list ">
 					<block v-if="followList.length > 0">
 						<!-- 		<view class="works-list">
 							<view class="work-item" v-for="(item, index) in followList" :key="index"
@@ -191,7 +191,7 @@
 				</w-waterfall>
 
 				<!-- 探索列表 - 热点新闻已经有现成的热搜资讯组件,只需添加新闻列表 -->
-				<view v-show="currentTab === 2 && newsList.length > 0" class="news-list">
+				<view v-show="currentTab === 2 && newsList.length > 0" class="news-list ">
 					<!-- <view class="news-grid">
 						<view class="news-item" v-for="(item, index) in newsList" :key="index"
 							@click="goToArticleDetail(item.id)">

+ 10 - 1
pages/index/workDetail.vue

@@ -14,7 +14,7 @@
         <text class="fa fa-angle-left"></text>
       </view>
       <view class="navbar-center">
-        <view class="navbar-title">
+        <view class="navbar-title" @click="goToUserHomepage(author.id)">
           <image
             class="navbar-avatar"
             :src="author.avator"
@@ -420,6 +420,7 @@ export default {
             if (res.data.article) {
 							this.articleInfo = res.data.article;
 						}
+            this.articleInfo = res.data.data;
             this.articleInfo.sms_id = this.sms_id;
             this.content = res.data.data.content;
             this.home_image = res.data.data.images;
@@ -645,6 +646,14 @@ export default {
         // 指定要切换到的页面路径
         url: "/pages/make/index",
       });
+    },
+    	goToUserHomepage(id) {
+			if (!id) {
+				return;
+			} 
+      uni.navigateTo({
+        url: "/pages/my/userHomepage?id=" + id,
+      });
     },
   },
 };

+ 1 - 1
pages/isLand/FarmDialog.scss

@@ -113,7 +113,7 @@
       left: 0;
       right: 0;
       bottom: 0;
-      background: url('/static/weeds.png') center/cover;
+      // background: url('/static/weeds.png') center/cover;
       opacity: 0.5;
       border-radius: 8rpx;
     }

+ 86 - 56
pages/isLand/TaskDialog.scss

@@ -1,35 +1,55 @@
 .task-board {
-  padding: 30rpx;
-  background: transparent;
-  width: 600rpx;
-  margin: 0 auto;
+  margin-top: 25rpx;
+  margin-left: 10rpx;
+  background: url('/static/island/UI/task/rw_bg.png') no-repeat center center;
+  background-size: cover;
+  width: 702rpx;
+  // margin: 0 auto;
+  height: 984rpx;
+  display: flex;
+  flex-direction: column;
   
   .board-title {
+    flex-shrink: 0;
     display: flex;
     align-items: center;
     justify-content: center;
-    margin-bottom: 30rpx;
-    
-    .title-dot {
-      width: 12rpx;
-      height: 12rpx;
-      border-radius: 50%;
-      background-color: #A67C52;
-      margin: 0 20rpx;
-    }
+    padding-top: 60rpx;
+    // margin-bottom: 30rpx;
     
     text {
-      color: #A67C52;
+      color: #FFF;
       font-size: 32rpx;
       font-weight: bold;
     }
   }
 
+  .task-cards-container {
+    flex: 1;
+    overflow-y: auto;
+    // padding: 0 16rpx;
+    margin-top: 10rpx;
+    margin-bottom: 18rpx;
+    
+    &::-webkit-scrollbar {
+      width: 6rpx;
+    }
+    
+    &::-webkit-scrollbar-thumb {
+      background: rgba(166, 124, 82, 0.3);
+      border-radius: 3rpx;
+    }
+    
+    &::-webkit-scrollbar-track {
+      background: transparent;
+    }
+  }
+
   .task-card {
     background-color: rgba(255, 246, 235, 0.95);
     border-radius: 20rpx;
     padding: 24rpx;
-    margin-bottom: 16rpx;
+    margin: 10rpx 43rpx 15rpx 43rpx  ;
     position: relative;
     
     .task-header,
@@ -37,13 +57,14 @@
       margin-bottom: 16rpx;
       
       .task-label {
-        color: #A67C52;
+        color: #987453;
         font-size: 26rpx;
-        font-weight: 500;
+        // font-weight: 500;
+        font-weight: bold;
       }
       
       .task-content {
-        color: #8B6244;
+        color: #987453;
         font-size: 26rpx;
         margin-left: 8rpx;
       }
@@ -51,18 +72,19 @@
     
     .task-rewards {
       margin-bottom: 24rpx;
+      display: flex;
+      align-items: flex-start;
       
       .task-label {
-        color: #A67C52;
+        color: #987453;
         font-size: 26rpx;
-        font-weight: 500;
-        display: block;
-        margin-bottom: 16rpx;
+        font-weight: bold;
+        margin-right: 16rpx;
       }
       
       .reward-list {
         display: flex;
-        gap: 30rpx;
+        gap: 10rpx;
         
         .reward-item {
           display: flex;
@@ -70,80 +92,88 @@
           align-items: center;
           
           .reward-box {
-            width: 90rpx;
-            height: 90rpx;
+            width: 70rpx;
+            height: 70rpx;
             background: linear-gradient(to bottom right, #B8E986, #7EC242);
-            border-radius: 14rpx;
+            border-radius: 12rpx;
             display: flex;
             align-items: center;
             justify-content: center;
-            margin-bottom: 8rpx;
+            margin-bottom: 6rpx;
             
             &:nth-child(3) {
               background: linear-gradient(to bottom right, #E5C1FF, #9D7EE0);
             }
             
             .reward-icon {
-              width: 60rpx;
-              height: 60rpx;
+              width: 45rpx;
+              height: 45rpx;
             }
           }
           
           .reward-text {
             color: #B3894A;
-            font-size: 22rpx;
+            font-size: 20rpx;
             text-align: center;
           }
         }
       }
     }
     
+
     .task-footer {
       display: flex;
-      justify-content: space-between;
+      justify-content: flex-end;
       align-items: center;
-      
+      margin-top: 16rpx;
+      padding-top: 16rpx;
+      position: relative;
+
+      &::before {
+        content: '';
+        position: absolute;
+        left: 0;
+        right: 0;
+        top: 0;
+        height: 2rpx;
+        background: linear-gradient(to right, 
+          transparent, 
+          rgba(179, 137, 74, 0.3) 20%, 
+          rgba(179, 137, 74, 0.3) 80%, 
+          transparent
+        );
+      }
+
       .task-date {
         color: #CCAB8F;
         font-size: 24rpx;
+        margin-right: auto;
       }
       
       .task-button {
-        min-width: 140rpx;
-        height: 60rpx;
-        line-height: 60rpx;
+        min-width: 170rpx;
+        height: 62rpx;
         text-align: center;
-        border-radius: 30rpx;
         font-size: 24rpx;
         border: none;
-        padding: 0 24rpx;
+        background-size: 100% 100%;
+        background-repeat: no-repeat;
         
         &.completed {
-          background: linear-gradient(to right, #FFD879, #FFA751);
+          background-image: url('/static/island/UI/btn_green.png');
           color: #ffffff;
-          box-shadow: 0 4rpx 8rpx rgba(255, 167, 81, 0.3);
+          
+          &:active {
+            transform: scale(0.95);
+            opacity: 0.9;
+          }
         }
         
-        &.available {
-          background: linear-gradient(to right, #ADE277, #7EC242);
+        &.uncompleted {
+          background-image: url('/static/island/UI/btn_yellow.png');
           color: #ffffff;
-          box-shadow: 0 4rpx 8rpx rgba(126, 194, 66, 0.3);
         }
       }
     }
-    
-    .card-divider {
-      position: absolute;
-      left: 24rpx;
-      right: 24rpx;
-      bottom: 0;
-      height: 2rpx;
-      background: linear-gradient(to right, 
-        transparent, 
-        rgba(179, 137, 74, 0.3) 20%, 
-        rgba(179, 137, 74, 0.3) 80%, 
-        transparent
-      );
-    }
   }
 } 

+ 53 - 31
pages/isLand/TaskDialog.vue

@@ -1,41 +1,43 @@
 <template>
-  <custom-dialog :visible="visible" title="" content-width="720rpx" @close="onClose">
+  <custom-dialog :visible="visible" title="" content-width="720rpx" closeImg="/static/island/UI/btn_close.png" closeImgTop="0rpx" @close="onClose">
     <view class="task-board">
       <view class="board-title">
         <view class="title-dot"></view>
         <text>任务看板</text>
         <view class="title-dot"></view>
       </view>
-      <view v-for="(task, index) in tasks" :key="index" class="task-card">
-        <view class="task-header">
-          <text class="task-label">任务目标:</text>
-          <text class="task-content">{{task.title}}</text>
-        </view>
-        <view class="task-desc">
-          <text class="task-label">任务描述:</text>
-          <text class="task-content">{{task.description}}</text>
-        </view>
-        <view class="task-rewards">
-          <text class="task-label">任务奖励:</text>
-          <view class="reward-list">
-            <view v-for="(reward, rIndex) in task.rewards" :key="rIndex" class="reward-item">
-              <view class="reward-box">
-                <image :src="reward.icon" class="reward-icon"></image>
+      <view class="task-cards-container">
+        <view v-for="(task, index) in tasks" :key="index" class="task-card">
+          <view class="task-header">
+            <text class="task-label">任务目标:</text>
+            <text class="task-content">{{task.title}}</text>
+          </view>
+          <view class="task-desc">
+            <text class="task-label">任务描述:</text>
+            <text class="task-content">{{task.description}}</text>
+          </view>
+          <view class="task-rewards">
+            <text class="task-label">任务奖励:</text>
+            <view class="reward-list">
+              <view v-for="(reward, rIndex) in task.rewards" :key="rIndex" class="reward-item">
+                <view class="reward-box">
+                  <image :src="reward.icon" class="reward-icon"></image>
+                </view>
+                <text class="reward-text">{{reward.text}}</text>
               </view>
-              <text class="reward-text">{{reward.text}}</text>
             </view>
           </view>
+          <view class="task-footer">
+            <text class="task-date">{{task.date}}</text>
+            <button 
+              :class="['task-button', task.status === 'completed' ? 'completed' : 'uncompleted']"
+              @click="handleTaskAction(task)"
+            >
+              {{task.status === 'completed' ? '完成任务' : '未完成'}}
+            </button>
+          </view>
+          <view class="card-divider"></view>
         </view>
-        <view class="task-footer">
-          <text class="task-date">{{task.date}}</text>
-          <button 
-            :class="['task-button', task.status === 'completed' ? 'completed' : 'available']"
-            @click="handleTaskAction(task)"
-          >
-            {{task.status === 'completed' ? '完成任务' : '领取任务'}}
-          </button>
-        </view>
-        <view class="card-divider"></view>
       </view>
     </view>
   </custom-dialog>
@@ -78,6 +80,26 @@ export default {
           date: '2024/04/08',
           status: 'completed'
         },
+        {
+          title: '负债累累的冒险家',
+          description: '终极目标就是偿还移民的债务,做一个无债一身轻的玩家',
+          rewards: [
+            {
+              icon: '/static/icons/coin.png',
+              text: '金币×3000'
+            },
+            {
+              icon: '/static/icons/exp.png',
+              text: '经验×3000'
+            },
+            {
+              icon: '/static/icons/blueprint.png',
+              text: '升级房屋图纸×1'
+            }
+          ],
+          date: '2024/04/08',
+          status: 'available'
+        },
         {
           title: '负债累累的冒险家',
           description: '终极目标就是偿还移民的债务,做一个无债一身轻的玩家',
@@ -114,10 +136,10 @@ export default {
         })
       } else {
         // 处理领取任务的逻辑
-        uni.showToast({
-          title: '已领取任务',
-          icon: 'success'
-        })
+        // uni.showToast({
+        //   title: '已领取任务',
+        //   icon: 'success'
+        // })
       }
     }
   }

+ 6 - 1
pages/isLand/homeLand.vue

@@ -37,7 +37,7 @@
     <inventory-dialog :visible.sync="inventoryVisible" @close="onInventoryClose"></inventory-dialog>
     <character-dialog :visible.sync="characterVisible" @close="onCharacterClose"></character-dialog>
     <shop-dialog :visible.sync="shopVisible" @close="onShopClose" @buy="onShopBuy"></shop-dialog>
-    <task-dialog :visible.sync="taskVisible" @close="onTaskClose"></task-dialog>
+    <task-dialog class="task-dialog" :visible.sync="taskVisible" @close="onTaskClose"></task-dialog>
   </view> 
 </template>
 
@@ -416,4 +416,9 @@ export default {
     margin-top: 10rpx;
   }
 }
+.task-dialog{
+	 ::v-deep.dialog-content{
+		  background: transparent !important;
+	  }
+}
 </style> 

+ 130 - 0
pages/login/login - copy.scss

@@ -0,0 +1,130 @@
+page {
+	background-color: #161616;
+	width: 100%;
+	height: 100%;
+}
+.page {
+	background-color: #161616;
+	width: 100%;
+	height:100vh;
+}
+.header {
+	display: flex;
+	flex-direction: row;
+	justify-content: flex-start;
+	align-items: center;
+	width: 750rpx;height: 220rpx;
+	padding-top: calc(var(--status-bar-height) + 0rpx);
+	.left {
+		display: flex;flex-direction: row;width:100rpx;height:60rpx;
+		justify-content: center;
+		padding-left:50rpx;
+		image {
+			width:36rpx;height:36rpx;
+		}
+	}
+}
+.thread {
+	height: 20rpx;
+}
+.thread2 {
+	height: 60rpx;
+}
+
+.tbody {
+	display: flex;flex-direction: column;justify-content: center;align-items: center;
+	image {
+		width:152rpx;height:152rpx;
+	}
+	.mobile {
+		font-weight: bold;margin-top:84rpx;
+		font-size: 52rpx;
+		color: #FFFFFF;
+	}
+	.tips {
+		font-weight: 400;margin-top:76rpx;
+		font-size: 24rpx;
+		color: #D0D0D0;
+	}
+	.btn_submit {
+		width: 660rpx;height: 96rpx;margin-top:38rpx;
+		background: linear-gradient( 142deg, #FF5967 0%, #FF2A95 100%);
+		border-radius: 28rpx 28rpx 28rpx 28rpx;
+		display: flex;flex-direction: column;justify-content: center;align-items: center;
+		font-weight: bold;
+		font-size: 32rpx;
+		color: #FFFFFF;
+	}
+	.other {
+		margin-top:38rpx;
+		display: flex;flex-direction: row;justify-content: center;align-items: center;
+		color:#fff;font-size:24rpx;
+		.line {
+			width:2rpx;height:24rpx;background-color: #fff;margin-left: 30rpx;margin-right: 30rpx;
+		}
+	}
+	.name {
+		width:690rpx;display: flex;flex-direction: row;justify-content: space-between;align-items: flex-start;
+		color:#fff;font-size: 28rpx;margin-top: 20rpx;
+		.right {
+			font-size: 28rpx;
+			color: #FF2A95;
+		}
+	}
+	.item {
+		width: 690rpx;height: 84rpx;margin-top: 20rpx;
+		background: #282828;position: relative;
+		border-radius: 24rpx 24rpx 24rpx 24rpx;
+		input {
+			width:100%;height:100%;padding-left: 20rpx;font-size: 28rpx;color:#fff;
+		}
+		.btn {
+			position: absolute;right:20rpx;top:0rpx;
+			font-weight: 400;
+			font-size: 28rpx;line-height: 84rpx;
+			color: #FF2A95;
+		}
+		.arrow {
+			width:36rpx;position: absolute;right:20rpx;top:24rpx;
+		}
+	}
+	.other_list {
+		width: 690rpx;display: flex;flex-direction: row;justify-content: space-between;align-items: center;margin-top:38rpx;
+		.left {
+			font-weight: bold;
+			font-size: 28rpx;
+			color: #FF2A95;
+		}
+		.right {
+			font-weight: bold;
+			font-size: 28rpx;
+			color: #FFFFFF;
+		}
+	}
+	.wechat {
+		width: 88rpx;height: 88rpx;margin-top:200rpx;
+		background: rgba(255,255,255,0);
+		border: 2rpx solid #D0D0D0;border-radius: 44rpx;
+		display: flex;flex-direction: row;justify-content: center;align-items: center;
+		image {
+			width:62rpx;
+		}
+	}
+	.agree {
+		width:100%;text-align: center;color:#959595;font-size: 22rpx;margin-top: 40rpx;
+		display: flex;flex-direction: row;justify-content: center;align-items: center;
+		.agree2 {
+			display: flex;flex-direction: row;justify-content: center;align-items: center;
+		}
+		.xy {
+			color:#FF2A95;
+		}
+		image {
+			width:32rpx;margin-right: 8rpx;
+		}
+	}
+	
+}
+.blankHeight {
+	width:750rpx;height:180rpx;
+}

+ 412 - 0
pages/login/login - copy.vue

@@ -0,0 +1,412 @@
+<template>
+	<view class="page">
+		<view class="header">
+			<view class="left">
+				<!-- <image class="img" mode="widthFix" src="../../static/login/close.png"></image> -->
+			</view>
+		</view>
+
+		<view class="tbody">
+			<block v-if="type == 'onelogin'">
+				<image class="icon" mode="widthFix" src="../../static/me/avator.png"></image>
+				<text class="mobile">+ 86 1**********</text>
+				<text class="tips">首次验证通过即注册萌创星球账号</text>
+				<text class="btn_submit">本机号码一键登录</text>
+				<view class="other">
+					<view class="pass" @click="type = 'pass'">密码登录</view>
+					<view class="line"></view>
+					<view class="mob" @click="type = 'mobile'">手机号登录</view>
+				</view>
+			</block>
+			<block v-if="type == 'pass' || type == 'mobile'">
+				<view class="name">手机号码:</view>
+				<view class="item">
+					<input type="text" class="input" v-model="mobile" placeholder="请输入手机号码" maxlength="11" />
+				</view>
+				<block v-if="type == 'pass'">
+					<view class="name">登录密码:</view>
+					<view class="item">
+						<input type="password" class="input" v-model="password" placeholder="请输入登录密码" maxlength="32" />
+					</view>
+					<view class="other_list">
+						<text class="left" v-if="true" @click="type = 'mobile'">验证码登录</text>
+						<text class="left" v-else></text>
+						<text class="right" @click="type = 'mobile'" v-if="false">验证码登录</text>
+						<text class="right" @click="toRegist">还没有账号?开始注册</text>
+					</view>
+				</block>
+				<block v-if="type == 'mobile'">
+					<view class="name">验证码:</view>
+					<view class="item">
+						<input type="text" class="input" v-model="code" placeholder="请输入验证码" maxlength="6" />
+						<view class="btn" v-if="captchaTime === 0" @click="getCode">获取验证码</view>
+						<view class="btn" v-if="captchaTime > 0">{{ captchaTime }}秒后重试</view>
+					</view>
+					<view class="other_list">
+						<text class="left"></text>
+						<text class="right" @click="type = 'pass'">密码登录</text>
+					</view>
+				</block>
+				<text class="btn_submit" @click="toLogin">登录</text>
+			</block>
+
+			<view class="wechat" v-if="false">
+				<image class="img" mode="widthFix" src="../../static/login/wechat.png"></image>
+			</view>
+			<view class="agree">
+				<view class="agree2" @click="agreeChk()">
+					<image mode="widthFix" src="../../static/login/sel_no.png" v-if="is_agree == 0"></image>
+					<image mode="widthFix" src="../../static/login/sel_yes.png" v-if="is_agree == 1"></image>
+					<text>我已阅读并同意</text>
+				</view>
+				《
+				<text class="xy" @click="goPage('yhxy')">
+					隐私协议
+				</text>
+				》和《
+				<text class="xy" @click="goPage('yszc')">
+					用户使用协议
+				</text>
+				》
+			</view>
+			<view class="agree" v-if="false"><text class="agree2">{{ push_token }}</text></view>
+		</view>
+		<view class="blankHeight"></view>
+
+		<DialogBox ref="DialogBox"></DialogBox>
+	</view>
+</template>
+
+<script>
+import pubc from '@/common/public.js'
+export default {
+	components: {},
+	data() {
+		return {
+			skey: '',
+			sel: 1,
+			is_agree: 0,
+			type: 'pass',
+			myinfo: {
+				nickname: '王思思',
+				join_name: '注册日期:2024年5月',
+				num_1: 0,
+				num_2: 0,
+				num_3: 0,
+				num_4: 0,
+				is_login: 'no',
+				num_history: 0,
+				num_collection: 0
+			},
+			mobile: '18899990000',
+			password: '111111',
+			code: '',
+			captchaTime: 0,
+			push_token: '',
+			lat: '',
+			lng: '',
+		}
+	},
+	onLoad() {
+		setTimeout(function () {
+			uni.setNavigationBarColor({
+				frontColor: '#ffffff',
+				backgroundColor: '#00000000',
+				animation: {
+					duration: 400,
+					timingFunc: 'easeIn'
+				}
+			})
+		}, 200);
+		let that = this;
+		uni.getPushClientId({
+			success: (res) => {
+				console.log("su:", res.cid);
+				that.push_token = res.cid;
+			},
+			fail(err) {
+				that.push_token = '';
+				console.log(err)
+			}
+		});
+	},
+	onShow() {
+		// let hsign = pubc.Encrypt("aboa-wifl-kwfl-zjfk-wlaa_FA0412932BAE9D98506580ADB348BEF9");
+		// console.log("hsign", hsign)
+
+
+		// let skey = uni.getStorageSync("wapptoken");
+		// if (skey != null && skey != "" && skey != undefined) {
+		// 	uni.switchTab({
+		// 		url: "/pages/index/index"
+		// 	});
+		// 	return;
+		// }
+		// let that = this;
+		// uni.getLocation({
+		// 	type: 'wgs84',
+		// 	success: function(res) {
+		// 		that.lat = res.latitude;
+		// 		that.lng = res.longitude;
+		// 	},
+		// 	fail: function(error) {
+		// 		console.error('获取位置失败:', error);
+		// 	}
+		// });
+	},
+	methods: {
+		onBack() { },
+		agreeChk() {
+			if (this.is_agree == 0) {
+				this.is_agree = 1;
+			} else {
+				this.is_agree = 0;
+			}
+		},
+		goPage(page) {
+			if (page == 'yhxy') {
+				uni.navigateTo({
+					url: '/pages/AboutUs/yhxy'
+				})
+			} else if (page == 'yszc') {
+				// #ifdef APP-PLUS
+				plus.runtime.openWeb('https://e.zhichao.art/web/yszc.php') // plus.runtime.openWeb(href);
+				// #endif
+
+				// #ifdef H5
+				window.open('https://e.zhichao.art/web/yszc.php')
+				// #endif
+
+				// uni.navigateTo({
+				// 	url: '/pages/AboutUs/yszc'
+				// })
+			} else {
+				uni.navigateTo({
+					url: page,
+				});
+			}
+		},
+		toRegist() {
+			uni.navigateTo({
+				url: "/pages/login/reg",
+			});
+		},
+		toLogin() {
+			console.log('aaa');
+			let that = this;
+			if (this.mobile.length != 11) {
+				uni.showToast({
+					title: "请输入手机号",
+					icon: "none",
+				});
+				return;
+			}
+			if (this.type == 'pass') {
+				if (this.password.length < 6) {
+					uni.showToast({
+						title: "请输入不小于6位的密码",
+						icon: "none",
+					});
+					return;
+				}
+			} else {
+				if (this.code.length < 4) {
+					uni.showToast({
+						title: "请输入手机验证码",
+						icon: "none",
+					});
+					return;
+				}
+			}
+			if (this.is_agree == 0) {
+				uni.showToast({
+					title: "请确认并选择协议",
+					icon: "none",
+				});
+				return;
+			}
+			let method = '/Member/gamelogin';
+			if (this.btn_type == 'reg') {
+				method = '/Member/register';
+				if (this.code.length < 4) {
+					uni.showToast({
+						title: '请输入验证码',
+						icon: 'none'
+					});
+					return;
+				}
+			} else if (this.btn_type == 'reset') {
+				method = '/Member/resetPass';
+				if (this.code.length < 4) {
+					uni.showToast({
+						title: '请输入验证码',
+						icon: 'none'
+					});
+					return;
+				}
+			}
+			let channel = "";
+			// #ifdef APP-PLUS
+			channel = plus.runtime.channel;
+			// #endif
+
+			uni.showLoading({
+				mask: true,
+			});
+			console.log("host", this.$apiHost + method);
+			uni.request({
+				url: this.$apiHost + method,
+				data: {
+					uuid: getApp().globalData.uuid,
+					channel: channel,
+					loginType: this.type,
+					mobile: this.mobile,
+					password: this.password,
+					code: this.code,
+					push_token: this.push_token,
+					lat: this.lat,
+					lng: this.lng,
+				},
+				header: {
+					"content-type": "application/json",
+				},
+				success: (res) => {
+					console.log("----", res.data);
+					if (res.data.success == "yes") {
+						console.log("res.data", res.data);
+						if (res.data.uuid.length > 5) {
+							uni.setStorageSync("app_uuid", res.data.uuid);
+							getApp().globalData.uuid = res.data.uuid;
+						}
+						uni.setStorageSync("is_login", "yes");
+						uni.setStorageSync("wapptoken", res.data.skey);
+						getApp().globalData.skey = res.data.skey;
+						if (res.data.header_c != "") {
+							getApp().globalData.headerSign = pubc.Encrypt(res.data.header_c + "_" +
+								getApp().globalData.uuid);
+							uni.setStorageSync("headerSign", getApp().globalData.headerSign);
+						}
+						getApp().globalData.headerC = res.data.header_c;
+						if (res.data.nickname == '') {
+							uni.redirectTo({
+								url: '/pages/my/step'
+							});
+							return;
+						}
+						// 获取用户信息储存全局
+						uni.request({
+							url: this.$apiHost + '/User/getinfo',
+							data: {
+								uuid: getApp().globalData.uuid,
+								skey: getApp().globalData.skey
+							},
+							header: {
+								"content-type": "application/json",
+								'sign': getApp().globalData.headerSign
+							},
+							success: (res) => {
+								console.log("--获取用户信息--:", res.data);
+								if (res.data.need_login == "yes") {
+
+								}
+								if (res.data.aihao) {
+									this.aihao_tags = res.data.aihao.split(",");
+								}
+								if (res.data.nickname) {
+									getApp().globalData.nickname = res.data.nickname
+									uni.removeStorageSync("nickname" );
+									uni.setStorageSync("nickname", res.data.nickname);
+								}
+								if (res.data.mobile) {
+									getApp().globalData.mobile = res.data.mobile
+									uni.removeStorageSync("mobile", res.data.mobile);
+									uni.setStorageSync("mobile", res.data.mobile);
+								}
+								if (res.data.user_id) {
+									getApp().globalData.user_id = res.data.user_id
+									uni.removeStorageSync("user_id" );
+									uni.setStorageSync("user_id", res.data.user_id);
+								}
+								if (res.data.avator) {
+									getApp().globalData.avator = res.data.avator
+									uni.removeStorageSync("avator" );
+									uni.setStorageSync("avator", res.data.avator);
+								}
+
+							},
+							complete: (com) => {
+								// uni.hideLoading();
+							},
+							fail: (e) => {
+								console.log("----e:", e);
+							}
+						});
+						uni.switchTab({
+							url: "/pages/index/index",
+						});
+					} else if (res.data.success == "no") {
+						uni.showToast({
+							title: res.data.str,
+							icon: "none",
+						});
+					} else {
+						uni.showToast({
+							title: "操作失败,请联系客服",
+							icon: "none",
+						});
+					}
+				},
+				complete: (com) => {
+					uni.hideLoading();
+				},
+			});
+		},
+		getCode() {
+			if (this.mobile.length != 11) {
+				uni.showToast({
+					title: '请输入手机号',
+					icon: 'none'
+				});
+				return;
+			}
+			if (this.captchaTime > 0) {
+				uni.showToast({
+					title: '不能重复获取',
+					icon: 'none'
+				});
+				return;
+			}
+			this.captchaTime = 60;
+
+			uni.request({
+				url: this.$apiHost + '/Web/getcode', //仅为示例,并非真实接口地址。
+				data: {
+					skey: this.skey,
+					mobile: this.mobile,
+				},
+				header: {
+					'content-type': 'application/json' //自定义请求头信息
+				},
+				success: (res) => {
+					console.log("----", res.data)
+					uni.showToast({
+						title: res.data.str,
+						icon: 'none'
+					})
+					if (res.data.success == 'yes') {
+						this.getCodeTime();
+					} else {
+						this.captchaTime = 0;
+					}
+				}
+			});
+
+		},
+
+	}
+}
+</script>
+
+<style scoped lang="scss">
+@import 'login.scss';
+</style>

+ 64 - 16
pages/login/login.scss

@@ -1,27 +1,45 @@
 page {
-	background-color: #161616;
+	background-color:#fff;
 	width: 100%;
 	height: 100%;
 }
 .page {
-	background-color: #161616;
+	background-color:#fff;
 	width: 100%;
 	height:100vh;
 }
 .header {
 	display: flex;
-	flex-direction: row;
+	flex-direction: column;
 	justify-content: flex-start;
 	align-items: center;
 	width: 750rpx;height: 220rpx;
-	padding-top: calc(var(--status-bar-height) + 0rpx);
-	.left {
-		display: flex;flex-direction: row;width:100rpx;height:60rpx;
-		justify-content: center;
-		padding-left:50rpx;
-		image {
-			width:36rpx;height:36rpx;
-		}
+	padding-top: calc(var(--status-bar-height) + 90rpx);
+	// .left {
+	// 	display: flex;flex-direction: row;width:100rpx;height:60rpx;
+	// 	justify-content: center;
+	// 	padding-left:50rpx;
+	// 	image {
+	// 		width:36rpx;height:36rpx;
+	// 	}
+	// }
+	.title {
+		text-align: center; 
+		width: 100%;
+		font-weight: 600;
+		font-family: PingFang SC, PingFang SC;
+		font-weight: 500;
+		font-size: 48rpx;
+		color: #1F1F1F;
+	}
+
+	.subtitle {
+		font-size: 24rpx;
+		font-weight: 400;
+		color: #959595;
+		text-align: center;
+		margin-top: 20rpx;
+		width: 100%;
 	}
 }
 .thread {
@@ -48,8 +66,10 @@ page {
 	}
 	.btn_submit {
 		width: 660rpx;height: 96rpx;margin-top:38rpx;
-		background: linear-gradient( 142deg, #FF5967 0%, #FF2A95 100%);
+		// background: linear-gradient( 142deg, #FF5967 0%, #FF2A95 100%);
+		background-color: #1f1f1f;
 		border-radius: 28rpx 28rpx 28rpx 28rpx;
+		border-radius: 58rpx;
 		display: flex;flex-direction: column;justify-content: center;align-items: center;
 		font-weight: bold;
 		font-size: 32rpx;
@@ -82,7 +102,7 @@ page {
 			position: absolute;right:20rpx;top:0rpx;
 			font-weight: 400;
 			font-size: 28rpx;line-height: 84rpx;
-			color: #FF2A95;
+			color: #fff;
 		}
 		.arrow {
 			width:36rpx;position: absolute;right:20rpx;top:24rpx;
@@ -93,7 +113,7 @@ page {
 		.left {
 			font-weight: bold;
 			font-size: 28rpx;
-			color: #FF2A95;
+			color: #0084FF;
 		}
 		.right {
 			font-weight: bold;
@@ -111,19 +131,47 @@ page {
 		}
 	}
 	.agree {
-		width:100%;text-align: center;color:#959595;font-size: 22rpx;margin-top: 40rpx;
+		width:100%;text-align: center;color: #1f1f1f;font-size: 22rpx;margin-top: 40rpx;
 		display: flex;flex-direction: row;justify-content: center;align-items: center;
 		.agree2 {
 			display: flex;flex-direction: row;justify-content: center;align-items: center;
 		}
 		.xy {
-			color:#FF2A95;
+			color:#0084FF;
 		}
 		image {
 			width:32rpx;margin-right: 8rpx;
 		}
 	}
 	
+	// 自定义输入框样式
+	.item{
+		background-color: #fff;
+		border: solid 4rpx #000000;
+		border-radius: 74rpx;
+		::v-deep.uni-input-placeholder{
+			color: #999;
+		}
+		::v-deep.uni-input-input{
+			color: #1f1f1f;
+		}
+		.btn{
+			background: #1f1f1f;
+			display: inline-block;
+			line-height: 1; 
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			top: 50%;
+			right: 8rpx;
+			transform: translateY(-50%);
+			padding: 18rpx 25rpx;
+			height: auto;
+			border-radius: 74rpx;
+			
+		}
+	}
+	
 }
 .blankHeight {
 	width:750rpx;height:180rpx;

+ 19 - 10
pages/login/login.vue

@@ -1,11 +1,13 @@
 <template>
 	<view class="page">
 		<view class="header">
-			<view class="left">
+			<!-- <view class="left"> -->
 				<!-- <image class="img" mode="widthFix" src="../../static/login/close.png"></image> -->
-			</view>
+			<!-- </view> -->
+			<view class="title">登录/注册</view>
+			<view class="subtitle">手机号登录/注册</view>
 		</view>
-
+		
 		<view class="tbody">
 			<block v-if="type == 'onelogin'">
 				<image class="icon" mode="widthFix" src="../../static/me/avator.png"></image>
@@ -44,10 +46,10 @@
 					</view>
 					<view class="other_list">
 						<text class="left"></text>
-						<text class="right" @click="type = 'pass'">密码登录</text>
+						<text class="right" @click="type = 'pass'" style="color: blue;">密码登录</text>
 					</view>
 				</block>
-				<text class="btn_submit" @click="toLogin">登录</text>
+				<text class="btn_submit" @click="toLogin">登录/注册</text>
 			</block>
 
 			<view class="wechat" v-if="false">
@@ -55,8 +57,8 @@
 			</view>
 			<view class="agree">
 				<view class="agree2" @click="agreeChk()">
-					<image mode="widthFix" src="../../static/login/sel_no.png" v-if="is_agree == 0"></image>
-					<image mode="widthFix" src="../../static/login/sel_yes.png" v-if="is_agree == 1"></image>
+					<image mode="widthFix" src="../../static/icon/wd_icon_gouxuan04.png" v-if="is_agree == 0"></image>
+					<image mode="widthFix" src="../../static/icon/wd_icon_gouxuan05.png" v-if="is_agree == 1"></image>
 					<text>我已阅读并同意</text>
 				</view>
@@ -86,7 +88,7 @@ export default {
 			skey: '',
 			sel: 1,
 			is_agree: 0,
-			type: 'pass',
+			type: 'mobile',
 			myinfo: {
 				nickname: '王思思',
 				join_name: '注册日期:2024年5月',
@@ -399,9 +401,16 @@ export default {
 						this.captchaTime = 0;
 					}
 				}
-			});
-
+			}); 
 		},
+		getCodeTime() {
+			if (this.captchaTime > 0) {
+				setTimeout(() => {
+					this.captchaTime--;
+					this.getCodeTime();
+				}, 1000);
+			}
+		}
 
 	}
 }

+ 1 - 1
pages/makedetail/makeDetail.vue

@@ -11,7 +11,7 @@
 				<text class="fa fa-angle-left"></text>
 			</view>
 			<view class="navbar-center">
-				<view class="navbar-title">
+				<view class="navbar-title" v-if="false">
 					<image class="navbar-avatar" :src="myinfo.avator" mode="aspectFill"></image>
 					<text class="navbar-text">{{ myinfo.nickname }}</text>
 					<text class="navbar-badge" v-if="myinfo.is_vip > 0">VIP</text>

+ 41 - 43
pages/my/feedback.vue

@@ -7,13 +7,9 @@
 			<!-- 问题描述区域 -->
 			<view class="description-area">
 				<view class="title">问题描述</view>
-				<textarea class="input-area" 
-					v-model="content" 
-					placeholder="请尽可能详细地描述您的反馈或问题"
-					:maxlength="200"
-					show-count
-				></textarea>
-				<view class="word-count">{{content.length}}/200</view>
+				<textarea class="input-area" v-model="content" placeholder="请尽可能详细地描述您的反馈或问题" :maxlength="200"
+					show-count></textarea>
+				<view class="word-count">{{ content.length }}/200</view>
 			</view>
 
 			<!-- 图片上传区域 -->
@@ -32,7 +28,7 @@
 						<text class="fa fa-plus"></text>
 					</view>
 				</view>
-		
+
 			</view>
 
 			<!-- 提交按钮 -->
@@ -62,31 +58,31 @@ export default {
 				});
 				return;
 			}
-			
+
 			let that = this;
 			uni.chooseImage({
 				count: 5 - this.imgList.length,
 				sizeType: ['compressed'],
 				sourceType: ['album', 'camera'],
-				success: function(res) {
+				success: function (res) {
 					let tempFilePaths = [];
-					
+
 					// #ifdef H5
 					res.tempFiles.forEach(file => {
 						tempFilePaths.push(file.path);
 					});
 					// #endif
-					
+
 					// #ifdef APP-PLUS || MP
 					tempFilePaths = res.tempFilePaths;
 					// #endif
-					
+
 					for (let i = 0; i < tempFilePaths.length; i++) {
 						const uploadTask = uni.uploadFile({
 							url: that.$apiHost + '/Xweb/upload_img?skey=' + that.skey,
 							filePath: tempFilePaths[i],
 							name: 'file',
-							success: function(uploadFileRes) {
+							success: function (uploadFileRes) {
 								let resdata = JSON.parse(uploadFileRes.data);
 								if (resdata.success == 'yes') {
 									that.imgList.push(resdata.url);
@@ -97,7 +93,7 @@ export default {
 									});
 								}
 							},
-							fail: function(err) {
+							fail: function (err) {
 								console.error('上传失败:', err);
 								uni.showToast({
 									title: '图片上传失败',
@@ -109,12 +105,12 @@ export default {
 				}
 			});
 		},
-		
+
 		// 删除图片
 		deleteImage(index) {
 			this.imgList.splice(index, 1);
 		},
-		
+
 		// 提交反馈
 		submitFeedback() {
 			if (!this.content.trim()) {
@@ -124,26 +120,27 @@ export default {
 				});
 				return;
 			}
-			
+
 			let imgStr = this.imgList.join('|');
-			
+
 			uni.request({
-				url: this.$apiHost + '/Feedback/submit',
+				url: this.$apiHost + '/Member/feedback',
 				method: 'POST',
 				data: {
 					uuid: getApp().globalData.uuid,
 					content: this.content,
-					images: imgStr
+					image: imgStr
 				},
 				header: {
 					'Content-Type': 'application/x-www-form-urlencoded',
-					'sign': getApp().globalData.headerSign
+					'sign': getApp().globalData.headerSign,
+					uuid: getApp().globalData.uuid,
 				},
 				success: (res) => {
 					if (res.data.success === 'yes') {
 						uni.showToast({
-							title: '提交成功',
-							icon: 'success'
+							title: '反馈成功!我们将尽快处理',
+							icon: 'no'
 						});
 						setTimeout(() => {
 							uni.navigateBack();
@@ -171,6 +168,7 @@ export default {
 <style lang="scss">
 // 导入FontAwesome
 @import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css");
+
 .page {
 	min-height: 100vh;
 	background-color: #f8f8f8;
@@ -179,20 +177,20 @@ export default {
 
 .feedback-container {
 	padding: 30rpx;
-	
+
 	.description-area {
 		background: #fff;
 		border-radius: 16rpx;
 		padding: 24rpx;
 		margin-bottom: 30rpx;
 		position: relative;
-		
+
 		.title {
 			font-size: 32rpx;
 			color: #333;
 			margin-bottom: 20rpx;
 		}
-		
+
 		.input-area {
 			width: 100%;
 			height: 300rpx;
@@ -202,7 +200,7 @@ export default {
 			background: #f8f8f8;
 			border-radius: 12rpx;
 		}
-		
+
 		.word-count {
 			position: absolute;
 			right: 44rpx;
@@ -211,60 +209,60 @@ export default {
 			color: #999;
 		}
 	}
-	
+
 	.upload-area {
 		background: #fff;
 		border-radius: 16rpx;
 		padding: 24rpx;
 		margin-bottom: 30rpx;
-		
+
 		.title {
 			font-size: 32rpx;
 			color: #333;
 			margin-bottom: 20rpx;
-			
+
 			.subtitle {
 				font-size: 24rpx;
 				color: #999;
 			}
 		}
-		
+
 		.image-list {
 			display: flex;
 			flex-wrap: wrap;
 			gap: 16rpx;
 			margin-bottom: 20rpx;
-			
+
 			.image-item {
 				width: 200rpx;
 				height: 200rpx;
 				position: relative;
-				
+
 				.preview {
 					width: 100%;
 					height: 100%;
 					border-radius: 12rpx;
 				}
-				
+
 				.delete-btn {
 					position: absolute;
 					top: -16rpx;
 					right: -16rpx;
 					width: 40rpx;
 					height: 40rpx;
-					background: rgba(0,0,0,0.5);
+					background: rgba(0, 0, 0, 0.5);
 					border-radius: 50%;
 					display: flex;
 					align-items: center;
 					justify-content: center;
-					
+
 					.fa {
 						color: #fff;
 						font-size: 24rpx;
 					}
 				}
 			}
-			
+
 			.upload-btn {
 				width: 200rpx;
 				height: 200rpx;
@@ -273,21 +271,21 @@ export default {
 				display: flex;
 				align-items: center;
 				justify-content: center;
-				
+
 				.fa {
 					font-size: 48rpx;
 					color: #999;
 				}
 			}
 		}
-		
+
 		.tips {
 			font-size: 24rpx;
 			color: #999;
 			line-height: 1.6;
 		}
 	}
-	
+
 	.submit-btn {
 		width: 100%;
 		height: 88rpx;
@@ -299,10 +297,10 @@ export default {
 		align-items: center;
 		justify-content: center;
 		margin-top: 60rpx;
-		
+
 		&:active {
 			opacity: 0.9;
 		}
 	}
 }
-</style> 
+</style>

+ 14 - 4
pages/my/follow.vue

@@ -13,9 +13,10 @@
 		<view style="height: 90rpx;"></view>
 
 		<view class="follow-list">
-			<view class="follow-item" v-for="(item, index) in currentList" :key="index">
-				<CircleAvatar class="avator" v-if="item.avator" :src="item.avator"></CircleAvatar>
-				<view class="info">
+			<view class="follow-item" v-for="(item, index) in currentList" :key="index"
+				>
+				<CircleAvatar class="avator" v-if="item.avator" :src="item.avator"> @click="goToUserHomepage(item.user_id)"</CircleAvatar>
+				<view class="info" @click="goToUserHomepage(item.user_id)">
 					<view class="top-box">
 						<view class="name">{{ item.nickname }}</view>
 
@@ -73,11 +74,12 @@ export default {
 			this.isLoadingFollow = false // 是否正在加载关注列表
 			this.hasMoreFollow = true // 是否有更多关注数据可加载
 			this.followOffset = 0
+			this.followList= []
 			// 加载对应的数据
 			this.loadFollowList();
 
 		},
-		toggleFollow(item) { 
+		toggleFollow(item) {
 			//  关注的逻辑
 			uni.request({
 				url: this.$apiHost + '/Member/attention',
@@ -162,6 +164,14 @@ export default {
 				},
 			});
 		},
+		goToUserHomepage(id) {
+			if (!id) {
+				return;
+			}
+			uni.navigateTo({
+				url: "/pages/my/userHomepage?id=" + id,
+			});
+		},
 	}
 }
 </script>

+ 175 - 152
pages/my/myStar.vue

@@ -15,7 +15,7 @@
 		</view>
 
 		<!-- 加载动画区域 -->
-		<view class="loading-area" v-if="state == 2">
+		<view class="loading-area" v-if="state == 2 || isLoading">
 			<image src="../../static/me/loadAnimation.gif" mode="widthFix"></image>
 		</view>
 
@@ -51,20 +51,23 @@
 				<view class="form-group">
 					<view class="label">性别</view>
 					<view class="gender-options">
-						<view class="gender-option" :class="sex == 'male' ? 'selected' : ''">
-							<view class="gender-icon male" @tap="selectGender('male')">
+						<view class="gender-option" :class="sex == 'male' ? 'selected' : ''"
+							@tap="selectGender('male')">
+							<view class="gender-icon male">
 								<image src="../../static/me/wd_icon_nan.png" mode="aspectFit"></image>
 								男性
 							</view>
 						</view>
-						<view class="gender-option" :class="sex == 'female' ? 'selected' : ''">
-							<view class="gender-icon female" @tap="selectGender('female')">
+						<view class="gender-option" :class="sex == 'female' ? 'selected' : ''"
+							@tap="selectGender('female')">
+							<view class="gender-icon female">
 								<image src="../../static/me/wd_icon_nv.png" mode="aspectFit"></image>
 								女性
 							</view>
 						</view>
-						<view class="gender-option" :class="sex == 'other' ? 'selected' : ''">
-							<view class="gender-icon other" @tap="selectGender('other')">
+						<view class="gender-option" :class="sex == 'other' ? 'selected' : ''"
+							@tap="selectGender('other')">
+							<view class="gender-icon other">
 								<image src="../../static/me/wd_icon_qita.png" mode="aspectFit"></image>
 								其它
 							</view>
@@ -109,7 +112,7 @@
 		</view>
 
 		<!-- 角色信息展示页面 -->
-		<view class="character-info" v-else-if="state == 5">
+		<view class="character-info" v-else-if="state == 5 || state == 6">
 
 			<view class="custom-navbar">
 				<view class="navbar-left" @click="goBack">
@@ -130,7 +133,7 @@
 				<!-- 角色信息板块 -->
 				<view class="info-section">
 					<view class="character-name">
-						{{ starInfo.name }}
+						{{ starInfo.nickname }}
 						<image class="male" v-if="starInfo.sex == 0" src="../../static/me/wd_icon_nan.png"
 							mode="aspectFit">
 						</image>
@@ -157,7 +160,7 @@
 						<view class="description-title">
 							<view>人物标签</view>
 						</view>
-						<view class="tags-box"> 
+						<view class="tags-box">
 							<view class="tag-item" v-for="tag in starInfo.tags" :key="tag">
 								{{ tag }}
 							</view>
@@ -167,7 +170,8 @@
 			</view>
 
 			<!-- 底部按钮 -->
-			<view class="join-button" @tap="handleJoin"> 入驻星球 </view>
+			<view class="join-button" @tap="handleJoin(1)" v-if="state == 5"> 入驻星球 </view>
+			<view class="join-button" @tap="handleJoin(0)" v-if="state == 6"> 已驻星球 </view>
 		</view>
 
 		<SharePopup :visible="showShare" :share-url="shareUrl" :share-title="shareTitle" :share-desc="shareDesc"
@@ -177,6 +181,7 @@
 
 <script>
 import tabbarView from "@/components/tabbar/tabbar.vue";
+import value from '../../uni_modules/uv-text/components/uv-text/value';
 
 export default {
 	components: {
@@ -198,11 +203,10 @@ export default {
 				"#9A8194", // 紫色
 				"#FF9F1C", // 橙色
 			],
-			showForm: false,
 			showError: false,
 			formData: {
 				nickname: "",
-				gender: "其他",
+				sex: "其他",
 				description: "",
 				tags: [],
 			},
@@ -211,7 +215,7 @@ export default {
 			starImg: "",
 			noteContent: "",
 			starInfo: {},
-			state: 5, //0 是用户输入星灵基因重组仓的状态   1 是用户已经完成了匹星灵展示页面   2是用户匹配中加载的状态 3是匹配到了待点击进入设置界面 (根据其它字段判断是否失败)  4是用户设置星灵信息的页面  5是用户查看星灵信息的页面 待入驻 6是用户已经已经入驻星球了
+			state: 2, //0 是用户输入星灵基因重组仓的状态   1 是用户已经完成了匹星灵展示页面   2是用户匹配中加载的状态 3是匹配到了待点击进入设置界面 (根据其它字段判断是否失败)  4是用户设置星灵信息的页面  5是用户查看星灵信息的页面 待入驻 6是用户已经已经入驻星球了
 			sex: "",
 			selectTags: [],
 			info: {
@@ -226,15 +230,19 @@ export default {
 				"tags": "",
 				"status": 0
 			},
+			timeoutId: 0,
 			showShare: false,
 			shareUrl: "https://your-share-url.com",
 			shareTitle: "分享标题",
 			shareDesc: "分享描述",
 			shareImg: "https://your-share-image.com/image.jpg",
+			maxRetries: 10, // 最大重试次数
+			retryCount: 0,  // 当前重试次数
+			pollingInterval: 30000, // 轮询间隔时间(毫秒)
 		};
 	},
 	onLoad() {
-		this.getStar("get");
+		this.aIpipeiGetinfo("get");
 	},
 	methods: {
 		// 返回上一页
@@ -244,14 +252,18 @@ export default {
 			});
 		},
 		confirmGender() {
-			if (!this.noteContent) return;
 			// this.selectedGender = this.noteContent;
 			this.isLoading = true;
-
-			this.getStar("make");
+			this.closeContentPopUpWindow();
+			this.state = 2
+			this.apiPeiStar();
 		},
 		goToSetProfile() {
-			this.showForm = true;
+			this.state = 4;
+			this.formData.nickname = ''
+			this.formData.sex = ''
+			this.formData.tags = ''
+
 		},
 		toggleTag(tag) {
 			const index = this.formData.tags.indexOf(tag);
@@ -264,93 +276,32 @@ export default {
 		handleJoin() {
 			console.log("入驻星球");
 			// 处理入驻逻辑
-		},
-		getStar(act) {
-			let that = this;
-			console.log("uuid", getApp().globalData.uuid);
-
-			// 设置加载状态
-			if (act === "make") {
-				this.isLoading = true;
-			}
-
 			uni.request({
-				url: this.$apiHost + "/Work/getStar",
+				url: this.$apiHost + "/AIpipei/gogogo",
 				data: {
 					uuid: getApp().globalData.uuid,
-					sex: this.tempGender,
-					// noteContent: this.noteContent,
-					act: act,
 				},
 				header: {
-					"content-type": "application/json",
+					"content-type": "application/x-www-form-urlencoded",
 					sign: getApp().globalData.headerSign,
 				},
+				method: "POST",
 				// 设置60秒超时
 				timeout: 60000,
 				success: (res) => {
-					console.log("res.data", res.data);
-					// res.data.have = 0
-					if (res.data.have == 0) {
-						this.showInfo = false;
-						this.starImg = res.data.image;
-					} else {
-						//首次进来获取到了
-						this.showInfo = true;
-					}
-					this.openContentPopUpWindow();
-					if (res.data.success === "yes") {
-						this.starImg = res.data.image;
-					}
-					if (res.data.info && res.data.info.tags != "") {
-						let tags = res.data.info.tags.split(",");
-						this.predefinedTags = tags.map(tag => ({
-							text: tag,
-							value: tag
-						}));
-					}
-					this.starInfo = res.data.info || {};
-					this.starInfo.tags = this.starInfo.tags.trim().split(",");
-					console.log("starInfo", this.starInfo);
+					this.aIpipeiGetinfo({ polling: false })
 
-					this.formData.description = this.starInfo.content;
-					if (act == "make") {
-						// 模拟加载过程
-						setTimeout(() => {
-							that.isLoading = false;
-						}, 300);
-					}
 				},
 				fail: (err) => {
-					console.error("请求失败:", err);
-					// 显示错误提示
-					uni.showToast({
-						title: "网络请求失败,请重试",
-						icon: "none",
-						duration: 2000,
-					});
-
-					// 重置加载状态
-					if (act === "make") {
-						that.isLoading = false;
-					}
 
-					// 如果是网络超时,自动重试一次
-					if (err.errMsg.includes("timeout")) {
-						setTimeout(() => {
-							console.log("请求超时,正在重试...");
-							that.getStar(act);
-						}, 1000);
-					}
 				},
 				complete: () => {
-					// 确保在任何情况下都能重置加载状态
-					if (act === "make" && this.isLoading) {
-						this.isLoading = false;
-					}
+
 				},
 			});
+
 		},
+
 		// 提交用户 开始创建的命令
 		apiPeiStar() {
 			if (!this.noteContent) {
@@ -367,44 +318,31 @@ export default {
 					content: this.noteContent,
 				},
 				header: {
-					"content-type": "application/json",
+					"content-type": "application/x-www-form-urlencoded",
 					sign: getApp().globalData.headerSign,
 				},
 				// 设置60秒超时
 				timeout: 60000,
-				methods: "POST",
+				method: 'POST',
 				success: (res) => {
-					console.log("开始AI匹配", res.data);
-					state
-					if (res.data.have == 0) {
-						this.showInfo = false;
-						this.starImg = res.data.image;
-					} else {
-						//首次进来获取到了
-						this.showInfo = true;
-					}
-					this.openContentPopUpWindow();
-					if (res.data.success === "yes") {
-						this.starImg = res.data.image;
-					}
-					if (res.data.info && res.data.info.tags != "") {
-						let tags = res.data.info.tags.split(",");
-						this.predefinedTags = tags.map(tag => ({
-							text: tag,
-							value: tag
-						}));
-					}
-					this.starInfo = res.data.info || {};
-					this.starInfo.tags = this.starInfo.tags.trim().split(",");
-					console.log("starInfo", this.starInfo);
+					setTimeout(() => {
+						uni.showToast({
+							title: res.data.str,
+							icon: "none",
+							duration: 2000,
+						});
+						if (res.data.str == "内容不能为空") {
+							this.openContentPopUpWindow();
+							this.state = 0
+							this.apiPeiStar();
+						}
+						if (res.data.str == "开始匹配") {
+							this.aIpipeiGetinfo({ polling: true })
+
+						}
+
+					}, 3000);
 
-					this.formData.description = this.starInfo.content;
-					if (act == "make") {
-						// 模拟加载过程
-						setTimeout(() => {
-							that.isLoading = false;
-						}, 300);
-					}
 				},
 				fail: (err) => {
 					console.error("请求失败:", err);
@@ -416,28 +354,36 @@ export default {
 					});
 
 					// 重置加载状态
-					if (act === "make") {
-						that.isLoading = false;
-					}
 
-					// 如果是网络超时,自动重试一次
-					if (err.errMsg.includes("timeout")) {
-						setTimeout(() => {
-							console.log("请求超时,正在重试...");
-							that.getStar(act);
-						}, 1000);
-					}
 				},
 				complete: () => {
-					// 确保在任何情况下都能重置加载状态
-					if (act === "make" && this.isLoading) {
-						this.isLoading = false;
-					}
+
 				},
 			});
+
+
 		},
 		// 查询Ai匹配信息
-		aIpipeiGetinfo(act) {
+		aIpipeiGetinfo({ polling }) {
+			// 清除之前的定时器
+			if (this.timeoutId) {
+				clearTimeout(this.timeoutId);
+				this.timeoutId = 0;
+			}
+
+			// 检查是否超过最大重试次数
+			if (polling && this.retryCount >= this.maxRetries) {
+				uni.showToast({
+					title: '匹配超时,请重新尝试',
+					icon: 'none',
+					duration: 2000
+				});
+				this.retryCount = 0;
+				this.state = 0;
+				return;
+			}
+
+			// 发起请求
 			uni.request({
 				url: this.$apiHost + "/AIpipei/getinfo",
 				data: {
@@ -447,55 +393,113 @@ export default {
 					"content-type": "application/json",
 					sign: getApp().globalData.headerSign,
 				},
-				// 设置60秒超时
 				timeout: 60000,
 				success: (res) => {
 					console.log("查询到生成信息", res.data);
+					// 重置重试计数
+					this.retryCount = 0;
+					
+					if (res && res.data && res.data.info) {
+						if (res.data.info && res.data.info.tags != "") {
+							res.data.info.tags = res.data.info.tags.split(",");
+							this.predefinedTags = res.data.info.tags.map(tag => { return { text: tag, value: tag } }) 
+							console.log(666, res);
+
+						} else {
+							res.data.info.tags = []
+
+						}
+						// 实现状态的判断
+						// 更改状态为 用户还未匹配过 待输入匹配内容
+						if (res.data.str == "没有匹配过" && res.data.info) {
+							this.state = 0
+							setTimeout(() => {
+								this.openContentPopUpWindow();
+							}, 300);
+						}
+						// 更改状态为 用户还匹配成功时 待点击设置心灵简介
+						if (res.data.info.image && res.data.info.status == 2) {
+							this.state = 1
+							this.openContentPopUpWindow();
+						}
+						if (res.data.info.image && res.data.info.status == 1) {
+							this.state = 6
+						}
+						if (res.data.info.image && res.data.info.status == 3) {
+							this.state = 5
+						}
+						this.starInfo = res.data.info;
+
+						if (res.data.info.content) {
+							this.formData.description = res.data.info.content;
+						}
+					}
+
 				},
 				fail: (err) => {
 					console.error("请求失败:", err);
+					// 增加重试计数
+					this.retryCount++;
+					
 					// 显示错误提示
 					uni.showToast({
-						title: "网络请求失败,请重试",
+						title: `网络请求失败,第${this.retryCount}次重试`,
 						icon: "none",
 						duration: 2000,
 					});
-					// 如果是网络超时,自动重试一次
+
+					// 如果是网络超时,自动重试
 					if (err.errMsg.includes("timeout")) {
 						setTimeout(() => {
 							console.log("请求超时,正在重试...");
-							that.aIpipeiGetinfo(act);
+							this.aIpipeiGetinfo({ polling: true });
 						}, 6000);
 					}
 				},
 				complete: () => {
-
-				},
+					// 如果需要继续轮询,设置下一次请求
+					if (polling) {
+						this.timeoutId = setTimeout(() => {
+							this.aIpipeiGetinfo({ polling: true });
+						}, this.pollingInterval);
+					}
+				} 
 			});
 		},
 		// 保存表单信息
 		submitStar() {
 			this.formData.tags = this.selectTags.join(",");
-			this.state = 5
-			return
 			let that = this;
 			uni.showLoading({
 				mask: true,
 			});
+			if (this.formData.sex) {
+				this.formData.sex = this.genderScreeningId(this.formData.sex);
+			}
+			console.log({
+				uuid: getApp().globalData.uuid,
+				sex: this.formData.sex,
+				name: this.formData.nickname,
+				content: this.formData.description,
+				tags: this.formData.tags,
+
+			}, 2000);
+
 			uni.request({
 				url: this.$apiHost + "/AIpipei/save",
 				data: {
 					uuid: getApp().globalData.uuid,
-					sex: this.tempGender,
-					// noteContent: this.noteContent,
-					name: this.formData.nickname,
+					sex: this.formData.sex,
+					nickname: this.formData.nickname,
 					content: this.formData.description,
+					tags: this.formData.tags,
 
 				},
 				header: {
-					"content-type": "application/json",
+					"content-type": "application/x-www-form-urlencoded",
 					sign: getApp().globalData.headerSign,
 				},
+				method: 'POST',
 				// 设置60秒超时
 				timeout: 10000,
 				success: (res) => {
@@ -507,7 +511,7 @@ export default {
 					});
 					if (res.data.success === "yes") {
 						setTimeout(() => {
-							that.aIpipeiGetinfo();
+							that.aIpipeiGetinfo({ polling: false });
 						}, 300);
 					}
 				},
@@ -540,7 +544,26 @@ export default {
 				this.$refs.openContentPopUpWindow.close();
 			}
 		},
-
+		genderScreening(str) {
+			switch (str) {
+				case '0':
+					return '男'
+				case '1':
+					return '女'
+				case '2':
+					return '其它'
+			}
+		},
+		genderScreeningId(str) {
+			switch (str) {
+				case 'male':
+					return 0
+				case 'female':
+					return 1
+				case 'other':
+					return 2
+			}
+		}
 	},
 };
 </script>
@@ -562,7 +585,7 @@ export default {
 			min-height: 200rpx !important;
 			font-weight: 400;
 			font-size: 28rpx;
-			color: #999999;
+			color: #1f1f1f;
 		}
 	}
 }
@@ -578,8 +601,6 @@ export default {
 
 
 	::v-deep.checklist-box {
-
-
 		border-radius: 16rpx !important;
 		border: 2rpx solid #1f1f1f !important;
 		background-color: #fff !important;
@@ -605,6 +626,8 @@ export default {
 	}
 }
 
+
+
 .star-container {
 
 	/* 自定义导航栏样式 */
@@ -641,7 +664,7 @@ export default {
 			display: flex;
 			align-items: center;
 			justify-content: center;
-			
+
 			.fa-angle-left {
 				font-size: 48rpx;
 				color: #333;

+ 2 - 0
pages/my/setting.vue

@@ -313,7 +313,9 @@ export default {
 				uni.removeStorageSync("nickname");
 				uni.removeStorageSync("avator");
 				uni.removeStorageSync("mobile");
+				uni.removeStorageSync("uuid");
 				uni.removeStorageSync("user_id");
+				uni.removeStorageSync("is_login");
 				uni.redirectTo({
 					url: '/pages/login/login',
 				})

+ 27 - 62
pages/my/userHomepage.vue

@@ -12,7 +12,7 @@
                 <image @click="clickShare()" src="@/static/me/wd_icon_fenxian.png" mode=""></image>
               </view>
             </view>
-            <view class="userinfo-box" >
+            <view class="userinfo-box">
               <view class="userinfo-left">
                 <CircleAvatar class="avator" :src="myinfo.avator"></CircleAvatar>
               </view>
@@ -39,7 +39,7 @@
               </uv-text>
             </view>
             <view class="bom">
-              <view class="follow_info" >
+              <view class="follow_info">
                 <view class="follow-box">
                   <view class="num">{{ myinfo.num_attention }}</view>
                   <view class="label">关注</view>
@@ -56,8 +56,8 @@
                 </view>
               </view>
               <view class="points-box">
-                <text class="followTheAuthor followTheAuthor1" v-if="1" @click="followTheAuthor(1)">+关注</text>
-                <text class="followTheAuthor followTheAuthor0" v-if="0" @click="followTheAuthor(0)">已关注</text>
+                <text class="followTheAuthor followTheAuthor1" v-if="!myinfo.is_attention" @click="followTheAuthor(1)">+关注</text>
+                <text class="followTheAuthor followTheAuthor0" v-else @click="followTheAuthor(0)">已关注</text>
               </view>
             </view>
           </view>
@@ -66,8 +66,8 @@
 
       <view class="myinfo">
         <!-- 作品列表 -->
-        <view class="numlist1" v-if="activeTab === 0" style="margin-top: 30rpx">
-          <WorkItem v-for="(item, index) in worksList" :secrecy="true" :subtitle="true" :key="index" :item="item"
+        <view class="numlist1"   style="margin-top: 30rpx">
+          <WorkItem v-for="(item, index) in worksList" :subtitle="true" :key="index" :item="item"
             @click="goWork(item)" />
         </view>
       </view>
@@ -126,8 +126,14 @@ export default {
       shareTitle: "分享标题",
       shareDesc: "分享描述",
       shareImg: "https://your-share-image.com/image.jpg",
+      id: 0,
     };
   },
+  onLoad(e) {
+    if (e.id) {
+      this.id = e.id
+    }
+  },
   onShow() {
     uni.$emit("check_login", () => { });
     this.offset = 0;
@@ -143,13 +149,12 @@ export default {
   },
   methods: {
     // 关注作者
-    followTheAuthor(n) {
-      return
+    followTheAuthor(n) { 
       uni.request({
         url: this.$apiHost + "/Member/attention",
         data: {
           uuid: getApp().globalData.uuid,
-          id: this.author.id,
+          id: this.id,
         },
         header: {
           "content-type": "application/json",
@@ -161,10 +166,7 @@ export default {
             title: res.data.str,
             icon: "none",
           });
-          if (res.data.success === "yes") {
-            console.log("关注结果:", res.data, n);
-            this.author.is_attention = n;
-          }
+          this.loadInfo();
         },
         fail: (e) => {
           console.log("关注失败:", e);
@@ -222,10 +224,12 @@ export default {
         skey: getApp().globalData.skey,
       });
       uni.request({
-        url: this.$apiHost + "/User/getinfo",
+        url: this.$apiHost + "/Member/getHomeInfo",
+       
         data: {
           uuid: getApp().globalData.uuid,
           skey: getApp().globalData.skey,
+          user_id: this.id,
         },
         header: {
           "content-type": "application/json",
@@ -265,24 +269,15 @@ export default {
       this.isLoading = true;
 
       // 根据activeTab选择不同的API
-      let apiUrl = "";
-      if (this.firstLevelNavActive == 0) {
-        if (this.activeTab === 0) {
-          apiUrl = "/Work/getlist";
-        } else {
-          apiUrl = "/WorkAI/getMyQueueList";
-        }
-      } else if (this.firstLevelNavActive == 1) {
-        apiUrl = "/Article/getlist";
-      }
+      
       uni.request({
-        url: this.$apiHost + apiUrl,
+        url: this.$apiHost + '/Work/getlist',
         data: {
           uuid: getApp().globalData.uuid,
           skey: getApp().globalData.skey,
-          type: "my", // 固定为my,表示获取自己的作品
+          type: "other", // 固定为my,表示获取自己的作品
           offset: this.offset,
-          status: this.activeTab === 0 ? 1 : undefined, // 只有我的作品需要status参数
+          user_id:this.id
         },
         header: {
           "content-type": "application/json",
@@ -302,12 +297,8 @@ export default {
           } else {
             this.hasMore = false;
           }
-
-          // 只有在"我的作品"标签下才更新data_list
-          if (this.activeTab === 0) {
-            this.updateDataList();
-          }
-          console.log("作品列表数据:", this.worksList);
+ 
+         
         },
         complete: () => {
           this.isLoading = false;
@@ -346,36 +337,10 @@ export default {
     },
     goWork(item) {
       uni.$emit("check_login", () => { });
-      // , //任务状态(1:排队中,3:生成失败,4:生成失败,9:创作完成)
-      if (this.activeTab == 0) {
-        uni.navigateTo({
-          url:
-            "/pages/makedetail/makeDetail?id=" +
-            item.queue_id +
-            "&queueId=" +
-            item.id,
-        });
-      } else {
-        if (item.status >= 9) {
-          uni.navigateTo({
-            url: "/pages/makedetail/makeDetail?id=" + item.id,
+      
+      uni.navigateTo({
+            url: "/pages/index/workDetail?id=" + item.id,
           });
-        }
-        if (item.status < 9 && item.status != 3 && item.status != 4) {
-          var url = "";
-          if (item.task_type === 1) {
-            url = "/makedetail/makeImgDetail";
-          }
-          if (item.task_type === 2) {
-            url = "/makedetail/makeMusicDetail";
-          }
-          if (url) {
-            uni.navigateTo({
-              url: "/pages" + url + "?id=" + item.id,
-            });
-          }
-        }
-      }
     },
     navigateToFollow() {
       uni.navigateTo({

BIN
static/dome/er-code.png


BIN
static/island/UI/btn_close.png


BIN
static/island/UI/btn_green.png


BIN
static/island/UI/btn_yellow.png


BIN
static/island/UI/task/rw_bg.png