Explorar o código

Merge branch 'master' of http://192.168.10.18:3000/sooka_shop/sooka_consult_uniapp

付宇航 hai 1 ano
pai
achega
cb4dae4f93

+ 8 - 0
api/handleAffairs/matter.js

@@ -9,6 +9,14 @@ export function listDept(query) {
   })
 }
 // 查询事项列表
+export function listMatters(query) {
+  return request({
+    url: '/system/matter/list',
+    method: 'get',
+    params: query
+  })
+}
+// 查询事项列表
 export function getMattersAll(query) {
   return request({
     url: '/system/matter/listAll',

+ 30 - 0
pages.json

@@ -345,6 +345,36 @@
 			}
 		},
 		{
+			"path": "pages/asking/asking",
+			"style": {
+				"usingComponents": {},
+				"navigationBarBackgroundColor": "#07c160",
+				"navigationBarTextStyle": "white",
+				"navigationBarTitleText": "问吧"
+
+			}
+		},
+		{
+			"path": "pages/me/nameAuthentication",
+			"style": {
+				"usingComponents": {},
+				"navigationBarBackgroundColor": "#07c160",
+				"navigationBarTextStyle": "white",
+				"navigationBarTitleText": "实名认证"
+
+			}
+		},
+		{
+			"path": "pages/me/officialAuthentication",
+			"style": {
+				"usingComponents": {},
+				"navigationBarBackgroundColor": "#07c160",
+				"navigationBarTextStyle": "white",
+				"navigationBarTitleText": "官方认证"
+
+			}
+		},
+		{
 			"path": "pages/me/meOperate",
 			"style": {
 				"usingComponents": {},

+ 65 - 11
pages/matterAll/matterAll.vue

@@ -1,18 +1,45 @@
 <template>
 	<view>
-		<uni-list>
+		<!-- <uni-list>
 			<uni-list-item  :title="item.title" v-for="(item,index) in dataList" @click="onclick(item)"></uni-list-item>
-		</uni-list>
+		</uni-list> -->
+		
+		<view class="list" @tap.stop="onclick(item)" v-for="(item, index) in dataList" :key="item.id">
+		    <span class="listTitle">{{ item.title }}</span>
+			<view class="jlSj">
+			     <span class="jf">
+			        {{ item.updateTime || item.createTime }}
+			         <!-- <em class="iconfont icon-jifen"></em> -->
+			     </span>
+			   <!-- <view class="ck">
+			        
+			         <span>
+			             <em class="iconfont icon-chakan"></em>
+			             {{ item.watchNum }}
+			         </span>
+			         <span :class=" favoriteList.includes(item.id) ? 'favorite' : 'not-favorite' ">
+			             <em class="iconfont icon-shoucang" @click.stop="addFavorite(item)"></em>
+			             {{ currentFavoriteCount(item) }}
+			         </span>
+			     </view> -->
+			 </view>
+		</view>
+		 
 	</view>
 </template>
 
 <script>
 	import {
-		getMattersAll
+		listMatters
 	} from "@/api/handleAffairs/matter.js"
 	export default {
 		data() {
 			return {
+				queryForm:{
+					pageNum: 1,
+					pageSize: 10,
+				},
+				total:0,
 				dataList: [],
 			};
 		},
@@ -20,24 +47,51 @@
 
 		},
 		onLoad(option) {
-			const data = uni.getStorageSync('data');
-			this.getMatters(data)
+			this.queryForm = Object.assign(uni.getStorageSync('data'), this.queryForm)
+			this.getMatters()
+		},
+		onReachBottom(){
+			let pageNum = this.queryForm.pageNum
+			let pageSize = this.queryForm.pageSize
+			let total = this.total
+			if(pageNum * pageSize >= total){
+				uni.showToast({
+					title:'暂无更多数据'
+				})
+				return
+			} else {
+				this.queryForm.pageSize += 5;
+				this.getMatters()
+			}
 		},
 		methods: {
 			onclick(data){//点击详情
 				
 			},
-			getMatters(data) {
+			getMatters() {
 				let _that = this
-				getMattersAll(data).then(res => {
-					_that.dataList = res.data
-					console.log(_that.dataList)
+				listMatters(_that.queryForm).then(res => {
+					_that.dataList = res.rows
+					_that.total = res.total
+					console.log(res)
 				})
 			}
 		}
 	}
 </script>
 
-<style>
-
+<style lang="scss">
+@import './matterAll.css';
+.container{
+	height: 100%;
+	content: '\e633';
+}
+.favorite{
+	.icon-shoucang:before{
+		color: red;
+	}
+}
+.not-favorite{
+	
+}
 </style>

+ 1 - 1
pages/me/me.vue

@@ -109,7 +109,7 @@ export default {
 			getUserInfo(userId).then(res =>{
 				this.initInfo.wechatName = res.data.wechatName;
 				this.initInfo.name = res.data.name;
-				this.initInfo.wechatName = res.data.wechatName;
+				this.initInfo.headImg = res.data.headImg;
 			})
 		},
 		//获取当前积分

+ 12 - 6
pages/me/nameAuthentication.vue

@@ -83,12 +83,18 @@
             },
             /** 提交按钮 */
             submitForm(e) {
-                this.$refs[e].validate().then(res => {
-                    appletAdd(this.form).then(res => {
-						uni.navigateBack();
-					});
-                }).catch(err => {
-                })
+				this.$refs[e].validate().then(res => {
+					if(this.imageList.length!=2){
+						uni.showToast({
+							title: "身份证正反面照片为两张!",
+							icon: "none"
+						})
+					}else{
+						appletAdd(this.form).then(res => {
+							uni.navigateBack();
+						});
+					}
+				})
             },
 
             updateImg(imgList) {

+ 16 - 8
pages/me/officialAuthentication.vue

@@ -13,7 +13,7 @@
                     <uni-easyinput v-model="form.phone" placeholder="请输入联系电话" maxlength="13"/>
                 </uni-forms-item>
                 <uni-forms-item label="证照信息" required name="path">
-                    <upload :imgArr="imageList" name="path" v-model="form.path" :fileSize="1" :limit="3"
+                    <upload :imgArr="imageList" name="path" v-model="form.path" :fileSize="1" :limit="2"
                             @updateImg="updateImg"></upload>
                 </uni-forms-item>
             </uni-forms>
@@ -79,14 +79,22 @@
             },
             /** 提交按钮 */
             submitForm(e) {
-                this.$refs[e].validate().then(res => {
-					appletAdd(this.form).then(res => {
-						uni.navigateBack();
-					})
-                }).catch(err => {
-                    console.log('err', err);
-                })
+				this.$refs[e].validate().then(res => {
+					if(this.imageList.length!=2){
+						uni.showToast({
+							title: "证照信息照片为两张!",
+							icon: "none"
+						})
+					}else{
+						appletAdd(this.form).then(res => {
+							console.log("1111111111")
+							uni.navigateBack();
+							console.log("2222222222222")
+						});
+					}
+				})
             },
+			
             updateImg(imgList) {
                 this.imageList = imgList;
                 this.form.path = this.imageList.join(',');