1
0

2 کامیت‌ها e024a28ab2 ... 5e9b219f7d

نویسنده SHA1 پیام تاریخ
  ck110 5e9b219f7d Merge branch 'master' of http://150.158.33.144:3000/lalalashen/MeetMateApp 2 هفته پیش
  ck110 d97a685412 修改bug 2 هفته پیش
5فایلهای تغییر یافته به همراه248 افزوده شده و 234 حذف شده
  1. 179 179
      manifest.json
  2. 4 1
      pages/article/addArticle.vue
  3. 1 1
      pages/index/index.vue
  4. 26 25
      pages/my/editInfo.vue
  5. 38 28
      pages/my/managePhoto.vue

+ 179 - 179
manifest.json

@@ -1,180 +1,180 @@
 {
-    "name" : "遇见玛特",
-    "appid" : "__UNI__A59181F",
-    "description" : "",
-    "versionName" : "1.0.9",
-    "versionCode" : 109,
-    "transformPx" : false,
-    /* 5+App特有相关 hfhz-mrro-iqmv-igdl storygarden2024@outlook.com*/
-    "app-plus" : {
-        "compatible" : {
-            "ignoreVersion" : true //true表示忽略版本检查提示框,HBuilderX1.9.0及以上版本支持  
-        },
-        "usingComponents" : true,
-        "nvueStyleCompiler" : "uni-app",
-        "compilerVersion" : 3,
-        "splashscreen" : {
-            "alwaysShowBeforeRender" : true,
-            "waiting" : true,
-            "autoclose" : true,
-            "delay" : 0
-        },
-        "safearea" : {
-            "background" : "#00000000",
-            "bottom" : {
-                "offset" : "none"
-            }
-        },
-        /* 模块配置 */
-        "modules" : {
-            "Push" : {},
-            "Geolocation" : {},
-            "Camera" : {},
-            "Record" : {}
-        },
-        /* 应用发布信息 */
-        "distribute" : {
-            /* android打包配置 */
-            "android" : {
-                "permissions" : [
-                    "<uses-feature android:name=\"android.hardware.camera\"/>",
-                    "<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
-                    "<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
-                    "<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
-                    "<uses-permission android:name=\"android.permission.CAMERA\"/>",
-                    "<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
-                    "<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
-                    "<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
-                    "<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
-                    "<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
-                    "<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
-                    "<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
-                    "<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
-                    "<uses-permission android:name=\"android.permission.VIBRATE\"/>",
-                    "<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
-                    "<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
-                ],
-                "abiFilters" : [ "armeabi-v7a", "arm64-v8a" ],
-                "enableOAID" : false
-            },
-            /* ios打包配置 */
-            "ios" : {
-                "UIBackgroundModes" : "audio",
-                "dSYMs" : false,
-                "idfa" : false
-            },
-            /* SDK配置 */
-            "sdkConfigs" : {
-                "ad" : {},
-                "payment" : {},
-                "speech" : {},
-                "oauth" : {},
-                "push" : {
-                    "unipush" : {
-                        "version" : "2",
-                        "offline" : false,
-                        "hms" : {},
-                        "oppo" : {},
-                        "vivo" : {},
-                        "mi" : {},
-                        "meizu" : {},
-                        "honor" : {}
-                    }
-                },
-                "geolocation" : {
-                    "system" : {
-                        "__platform__" : [ "android" ]
-                    }
-                },
-                "share" : {
-                    "weixin" : {
-                        "appid" : "",
-                        "UniversalLinks" : ""
-                    }
-                }
-            },
-            "splashscreen" : {
-                "androidStyle" : "default",
-                "useOriginalMsgbox" : false,
-                "iosStyle" : "common",
-                "ios" : {},
-                "android" : {
-                    "xxhdpi" : "static/loading_1080.png",
-                    "xhdpi" : "static/loading_720.png",
-                    "hdpi" : "static/loading_480.png"
-                }
-            },
-            "icons" : {
-                "android" : {
-                    "hdpi" : "unpackage/res/icons/72x72.png",
-                    "xhdpi" : "unpackage/res/icons/96x96.png",
-                    "xxhdpi" : "unpackage/res/icons/144x144.png",
-                    "xxxhdpi" : "unpackage/res/icons/192x192.png"
-                },
-                "ios" : {
-                    "appstore" : "unpackage/res/icons/1024x1024.png",
-                    "ipad" : {
-                        "app" : "unpackage/res/icons/76x76.png",
-                        "app@2x" : "unpackage/res/icons/152x152.png",
-                        "notification" : "unpackage/res/icons/20x20.png",
-                        "notification@2x" : "unpackage/res/icons/40x40.png",
-                        "proapp@2x" : "unpackage/res/icons/167x167.png",
-                        "settings" : "unpackage/res/icons/29x29.png",
-                        "settings@2x" : "unpackage/res/icons/58x58.png",
-                        "spotlight" : "unpackage/res/icons/40x40.png",
-                        "spotlight@2x" : "unpackage/res/icons/80x80.png"
-                    },
-                    "iphone" : {
-                        "app@2x" : "unpackage/res/icons/120x120.png",
-                        "app@3x" : "unpackage/res/icons/180x180.png",
-                        "notification@2x" : "unpackage/res/icons/40x40.png",
-                        "notification@3x" : "unpackage/res/icons/60x60.png",
-                        "settings@2x" : "unpackage/res/icons/58x58.png",
-                        "settings@3x" : "unpackage/res/icons/87x87.png",
-                        "spotlight@2x" : "unpackage/res/icons/80x80.png",
-                        "spotlight@3x" : "unpackage/res/icons/120x120.png"
-                    }
-                }
-            }
-        }
-    },
-    "networkTimeout" : {
-        "request" : 6000
-    },
-    /* 快应用特有相关 */
-    "quickapp" : {},
-    /* 小程序特有相关 */
-    "mp-weixin" : {
-        "appid" : "",
-        "setting" : {
-            "urlCheck" : false
-        },
-        "usingComponents" : true
-    },
-    "mp-alipay" : {
-        "usingComponents" : true
-    },
-    "mp-baidu" : {
-        "usingComponents" : true
-    },
-    "mp-toutiao" : {
-        "usingComponents" : true
-    },
-    "uniStatistics" : {
-        "enable" : false
-    },
-    "vueVersion" : "2",
-    "h5" : {
-        "router" : {
-            "base" : "./",
-            "mode" : "hash"
-        },
-        "template" : "h5.template.html",
-        "optimization" : {
-            "treeShaking" : {
-                "enable" : true
-            }
-        }
-    },
-    "fallbackLocale" : "zh-Hans"
-}
+	"name": "遇见玛特",
+	"appid": "__UNI__A59181F",
+	"description": "",
+	"versionName": "1.1.1",
+	"versionCode": 111,
+	"transformPx": false,
+	/* 5+App特有相关 hfhz-mrro-iqmv-igdl storygarden2024@outlook.com*/
+	"app-plus": {
+		"compatible": {
+			"ignoreVersion": true //true表示忽略版本检查提示框,HBuilderX1.9.0及以上版本支持  
+		},
+		"usingComponents": true,
+		"nvueStyleCompiler": "uni-app",
+		"compilerVersion": 3,
+		"splashscreen": {
+			"alwaysShowBeforeRender": true,
+			"waiting": true,
+			"autoclose": true,
+			"delay": 0
+		},
+		"safearea": {
+			"background": "#00000000",
+			"bottom": {
+				"offset": "none"
+			}
+		},
+		/* 模块配置 */
+		"modules": {
+			"Push": {},
+			"Geolocation": {},
+			"Camera": {},
+			"Record": {}
+		},
+		/* 应用发布信息 */
+		"distribute": {
+			/* android打包配置 */
+			"android": {
+				"permissions": [
+					"<uses-feature android:name=\"android.hardware.camera\"/>",
+					"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
+					"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
+					"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
+					"<uses-permission android:name=\"android.permission.CAMERA\"/>",
+					"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
+					"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
+					"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
+					"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
+					"<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
+					"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
+					"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
+					"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
+					"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
+					"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
+					"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
+				],
+				"abiFilters": ["armeabi-v7a", "arm64-v8a"],
+				"enableOAID": false
+			},
+			/* ios打包配置 */
+			"ios": {
+				"UIBackgroundModes": "audio",
+				"dSYMs": false,
+				"idfa": false
+			},
+			/* SDK配置 */
+			"sdkConfigs": {
+				"ad": {},
+				"payment": {},
+				"speech": {},
+				"oauth": {},
+				"push": {
+					"unipush": {
+						"version": "2",
+						"offline": false,
+						"hms": {},
+						"oppo": {},
+						"vivo": {},
+						"mi": {},
+						"meizu": {},
+						"honor": {}
+					}
+				},
+				"geolocation": {
+					"system": {
+						"__platform__": ["android"]
+					}
+				},
+				"share": {
+					"weixin": {
+						"appid": "",
+						"UniversalLinks": ""
+					}
+				}
+			},
+			"splashscreen": {
+				"androidStyle": "default",
+				"useOriginalMsgbox": false,
+				"iosStyle": "common",
+				"ios": {},
+				"android": {
+					"xxhdpi": "static/loading_1080.png",
+					"xhdpi": "static/loading_720.png",
+					"hdpi": "static/loading_480.png"
+				}
+			},
+			"icons": {
+				"android": {
+					"hdpi": "unpackage/res/icons/72x72.png",
+					"xhdpi": "unpackage/res/icons/96x96.png",
+					"xxhdpi": "unpackage/res/icons/144x144.png",
+					"xxxhdpi": "unpackage/res/icons/192x192.png"
+				},
+				"ios": {
+					"appstore": "unpackage/res/icons/1024x1024.png",
+					"ipad": {
+						"app": "unpackage/res/icons/76x76.png",
+						"app@2x": "unpackage/res/icons/152x152.png",
+						"notification": "unpackage/res/icons/20x20.png",
+						"notification@2x": "unpackage/res/icons/40x40.png",
+						"proapp@2x": "unpackage/res/icons/167x167.png",
+						"settings": "unpackage/res/icons/29x29.png",
+						"settings@2x": "unpackage/res/icons/58x58.png",
+						"spotlight": "unpackage/res/icons/40x40.png",
+						"spotlight@2x": "unpackage/res/icons/80x80.png"
+					},
+					"iphone": {
+						"app@2x": "unpackage/res/icons/120x120.png",
+						"app@3x": "unpackage/res/icons/180x180.png",
+						"notification@2x": "unpackage/res/icons/40x40.png",
+						"notification@3x": "unpackage/res/icons/60x60.png",
+						"settings@2x": "unpackage/res/icons/58x58.png",
+						"settings@3x": "unpackage/res/icons/87x87.png",
+						"spotlight@2x": "unpackage/res/icons/80x80.png",
+						"spotlight@3x": "unpackage/res/icons/120x120.png"
+					}
+				}
+			}
+		}
+	},
+	"networkTimeout": {
+		"request": 6000
+	},
+	/* 快应用特有相关 */
+	"quickapp": {},
+	/* 小程序特有相关 */
+	"mp-weixin": {
+		"appid": "",
+		"setting": {
+			"urlCheck": false
+		},
+		"usingComponents": true
+	},
+	"mp-alipay": {
+		"usingComponents": true
+	},
+	"mp-baidu": {
+		"usingComponents": true
+	},
+	"mp-toutiao": {
+		"usingComponents": true
+	},
+	"uniStatistics": {
+		"enable": false
+	},
+	"vueVersion": "2",
+	"h5": {
+		"router": {
+			"base": "./",
+			"mode": "hash"
+		},
+		"template": "h5.template.html",
+		"optimization": {
+			"treeShaking": {
+				"enable": true
+			}
+		}
+	},
+	"fallbackLocale": "zh-Hans"
+}

+ 4 - 1
pages/article/addArticle.vue

@@ -168,12 +168,15 @@
 									},
 									complete: () => {
 										console.log('Complete:');
+										if (i >= res.tempFilePaths.length - 1) {
+											uni.hideLoading()
+										}
 									}
 								});
 							}
 							setTimeout(function() {
 								uni.hideLoading()
-							}, 2000);
+							}, 20000);
 						}
 					},
 					error: function(e) {

+ 1 - 1
pages/index/index.vue

@@ -60,7 +60,7 @@
 		<view class="list">
 			<view class="item" v-for="(item,index) of list" :key="index" @click="goHome(item.uid)">
 				<view class="img">
-					<image class="icon" mode="widthFix" :src="item.avator"></image>
+					<image class="icon" mode="aspectFill" :src="item.avator"></image>
 				</view>
 				<view class="tit">
 					<text class="name">{{item.nickname}}</text>

+ 26 - 25
pages/my/editInfo.vue

@@ -127,9 +127,7 @@
 			this.list_tag = tagStr.split("、");
 			this.getInfoData();
 		},
-		onShow() {
-			
-		},
+		onShow() {},
 		methods: {
 			onBack() {},
 			onPreview() {},
@@ -303,29 +301,32 @@
 					sourceType: ['album', 'camera'], //从相册、相机选择
 					success: function(res) {
 						console.log('res:', res)
-						_self.imglocal = res.tempFilePaths[0]
-						const tempFilePaths = res.tempFilePaths[0];
-						console.log('tempFilePaths:', tempFilePaths);
-						// 图片上传
-						const uploadTask = uni.uploadFile({
-							url: _self.$apiHost + '/Xweb/upload_img?skey=' + _self.skey, // post请求地址
-							filePath: res.tempFilePaths[0],
-							name: 'file', // 待确认
-							success: function(uploadFileRes) {
-								let resdata = JSON.parse(uploadFileRes.data)
-								console.log('Success11:', uploadFileRes);
-								console.log('Success21:', resdata);
-								if (resdata.success == 'yes') {
-									_self.avator = resdata.url;
+						if (res.tempFilePaths.length > 0) {
+							_self.imglocal = res.tempFilePaths[0]
+							const tempFilePaths = res.tempFilePaths[0];
+							console.log('tempFilePaths:', tempFilePaths);
+							// 图片上传
+							const uploadTask = uni.uploadFile({
+								url: _self.$apiHost + '/Xweb/upload_img?skey=' + _self
+								.skey, // post请求地址
+								filePath: res.tempFilePaths[0],
+								name: 'file', // 待确认
+								success: function(uploadFileRes) {
+									let resdata = JSON.parse(uploadFileRes.data)
+									console.log('Success11:', uploadFileRes);
+									console.log('Success21:', resdata);
+									if (resdata.success == 'yes') {
+										_self.avator = resdata.url;
+									}
+								},
+								fail: function(uploadFileFail) {
+									console.log('Error:', uploadFileFail.data);
+								},
+								complete: () => {
+									console.log('Complete:');
 								}
-							},
-							fail: function(uploadFileFail) {
-								console.log('Error:', uploadFileFail.data);
-							},
-							complete: () => {
-								console.log('Complete:');
-							}
-						});
+							});
+						}
 					},
 					error: function(e) {
 						console.log(e);

+ 38 - 28
pages/my/managePhoto.vue

@@ -84,6 +84,13 @@
 			},
 			submitData() {
 				let str = "";
+				if (this.list.length > 5) {
+					uni.showToast({
+						title: "最多上传5张图片",
+						icon: 'none'
+					});
+					return;
+				}
 				if (this.list != null) {
 					for (var i = 0; i < this.list.length; i++) {
 						str += this.list[i] + "|";
@@ -133,39 +140,42 @@
 					return;
 				}
 				uni.chooseImage({
-					count: 1,
+					count: 5,
 					sizeType: ['compressed'], //可以指定是原图还是压缩图,默认二者都有
 					sourceType: ['album', 'camera'], //从相册、相机选择
 					success: function(res) {
 						console.log('res:', res)
-						that.imglocal = res.tempFilePaths[0]
-						const tempFilePaths = res.tempFilePaths[0];
-						console.log('tempFilePaths:', tempFilePaths);
-						uni.showLoading({
-
-						})
-						// 图片上传
-						const uploadTask = uni.uploadFile({
-							url: that.$apiHost + '/Xweb/upload_img?skey=' + that.skey, // post请求地址
-							filePath: res.tempFilePaths[0],
-							name: 'file', // 待确认
-							success: function(uploadFileRes) {
-								let resdata = JSON.parse(uploadFileRes.data)
-								console.log('Success11:', uploadFileRes);
-								console.log('Success21:', resdata);
-								if (resdata.success == 'yes') {
-									that.list.push(resdata.url);
-									// _self.avator = resdata.url;
-								}
-							},
-							fail: function(uploadFileFail) {
-								console.log('Error:', uploadFileFail.data);
-							},
-							complete: () => {
-								console.log('Complete:');
-								uni.hideLoading()
+						uni.showLoading({})
+						if (res.tempFilePaths.length > 0) {
+							for (var i = 0; i < res.tempFilePaths.length; i++) {
+								const tempFilePaths = res.tempFilePaths[i];
+								console.log('tempFilePaths:', tempFilePaths);
+								// 图片上传
+								const uploadTask = uni.uploadFile({
+									url: that.$apiHost + '/Xweb/upload_img?skey=' + that.skey,
+									filePath: tempFilePaths,
+									name: 'file',
+									success: function(uploadFileRes) {
+										let resdata = JSON.parse(uploadFileRes.data)
+										if (resdata.success == 'yes') {
+											that.list.push(resdata.url);
+										}
+									},
+									fail: function(uploadFileFail) {
+										console.log('Error:', uploadFileFail.data);
+									},
+									complete: () => {
+										console.log('Complete:');
+										if (i >= res.tempFilePaths.length - 1) {
+											uni.hideLoading()
+										}
+									}
+								});
 							}
-						});
+							setTimeout(function() {
+								uni.hideLoading()
+							}, 20000);
+						}
 					},
 					error: function(e) {
 						console.log(e);