Commit 3d4f84dce4e582a85965118414e474df8c246cde

Authored by WXD-SEASON\season
1 parent 31ea14fa

测肤修改

packageD/pages/AI-test-skin/analyse/analyse.js
@@ -26,6 +26,7 @@ Page({ @@ -26,6 +26,7 @@ Page({
26 err_map: null, 26 err_map: null,
27 skin_type: 0, 27 skin_type: 0,
28 ce_user_id:0, 28 ce_user_id:0,
  29 + img_remark:''
29 }, 30 },
30 31
31 /** 32 /**
@@ -36,6 +37,7 @@ Page({ @@ -36,6 +37,7 @@ Page({
36 var plugin = requirePlugin('mtSkinSdk') 37 var plugin = requirePlugin('mtSkinSdk')
37 plugin.setConfig(pluginGD) 38 plugin.setConfig(pluginGD)
38 } 39 }
  40 + this.setData({img_remark:options.img_remark})
39 41
40 if(options.ce_user_id) 42 if(options.ce_user_id)
41 this.data.ce_user_id=options.ce_user_id; 43 this.data.ce_user_id=options.ce_user_id;
@@ -519,6 +521,7 @@ Page({ @@ -519,6 +521,7 @@ Page({
519 resultjson: JSON.stringify(analyse_data), 521 resultjson: JSON.stringify(analyse_data),
520 detectjson: JSON.stringify(analyse_info), 522 detectjson: JSON.stringify(analyse_info),
521 skin_type: 1, 523 skin_type: 1,
  524 + img_remark:th.data.img_remark
522 } 525 }
523 //要保存一下分析的结果 526 //要保存一下分析的结果
524 th.json_post("/api/weshop/face/storeSkinface/save", req_data, function (res) { 527 th.json_post("/api/weshop/face/storeSkinface/save", req_data, function (res) {
@@ -556,6 +559,8 @@ Page({ @@ -556,6 +559,8 @@ Page({
556 resultjson: JSON.stringify(res.data.data), 559 resultjson: JSON.stringify(res.data.data),
557 detectjson: JSON.stringify(th.data.check_data), 560 detectjson: JSON.stringify(th.data.check_data),
558 skin_type: 0, 561 skin_type: 0,
  562 + img_remark:th.data.img_remark
  563 +
559 } 564 }
560 565
561 var txt=[]; 566 var txt=[];
packageD/pages/AI-test-skin/history_record/history_record.js
@@ -203,6 +203,7 @@ Page({ @@ -203,6 +203,7 @@ Page({
203 for (let i = 0; i < data.length; i++) { 203 for (let i = 0; i < data.length; i++) {
204 let history = data[i]; 204 let history = data[i];
205 let id = history.id; 205 let id = history.id;
  206 + let img_remark = history.img_remark;
206 let now = new Date(history['addtime'] * 1000); 207 let now = new Date(history['addtime'] * 1000);
207 let year = now.getFullYear(); //年 208 let year = now.getFullYear(); //年
208 let month = (now.getMonth() + 1).toString().padStart(2, 0); //月 209 let month = (now.getMonth() + 1).toString().padStart(2, 0); //月
@@ -218,10 +219,12 @@ Page({ @@ -218,10 +219,12 @@ Page({
218 let obj = { 219 let obj = {
219 time, 220 time,
220 id, 221 id,
  222 + img_remark,
221 }; 223 };
222 if (arr.length > 0) { 224 if (arr.length > 0) {
223 let index = arr.findIndex(item => { 225 let index = arr.findIndex(item => {
224 return item['history_time'] === history_time; 226 return item['history_time'] === history_time;
  227 +
225 }) 228 })
226 if (index > -1) { 229 if (index > -1) {
227 arr[index]['time_arr'].push(obj); 230 arr[index]['time_arr'].push(obj);
packageD/pages/AI-test-skin/history_record/history_record.wxml
@@ -14,9 +14,14 @@ @@ -14,9 +14,14 @@
14 <view class="history_list"> 14 <view class="history_list">
15 <view class="history_list_month" wx:for="{{history}}"> 15 <view class="history_list_month" wx:for="{{history}}">
16 <view style="color:#333;font-size:26rpx;margin-top: 30rpx">{{item.history_time}}</view> 16 <view style="color:#333;font-size:26rpx;margin-top: 30rpx">{{item.history_time}}</view>
17 - <view class="souce" wx:for="{{item.time_arr}}" wx:for-item="subitem" bindtap="go_result" data-id="{{subitem.id}}" wx:for-index="subindex" wx:key="subindex"> 17 + <view wx:for="{{item.time_arr}}" wx:for-item="subitem" bindtap="go_result" data-id="{{subitem.id}}" wx:for-index="subindex" wx:key="subindex">
  18 +
  19 + <view class="pdt16 fs28" wx:if="{{subitem.img_remark}}">{{subitem.img_remark}}</view>
  20 + <view class="souce">
18 <view style="font-weight: 600;">{{subitem.time}}</view> 21 <view style="font-weight: 600;">{{subitem.time}}</view>
19 <view style="color: #9b9b9b;" >去查看<text style="font-size: 24rpx;" class="iconfont icon-arrow_right"></text></view> 22 <view style="color: #9b9b9b;" >去查看<text style="font-size: 24rpx;" class="iconfont icon-arrow_right"></text></view>
  23 + </view>
  24 +
20 </view> 25 </view>
21 </view> 26 </view>
22 </view> 27 </view>
packageD/pages/AI-test-skin/select_photo/select_photo.js
@@ -13,7 +13,8 @@ Page({ @@ -13,7 +13,8 @@ Page({
13 iurl: setting.imghost, 13 iurl: setting.imghost,
14 gl_skin_img: null, 14 gl_skin_img: null,
15 skin_type: 0, 15 skin_type: 0,
16 - ce_user_id:0 16 + ce_user_id:0,
  17 + img_remark:''
17 }, 18 },
18 19
19 /** 20 /**
@@ -40,9 +41,13 @@ Page({ @@ -40,9 +41,13 @@ Page({
40 if (e.data.code == 0) { 41 if (e.data.code == 0) {
41 getApp().globalData.face_img = e.data.data.img; 42 getApp().globalData.face_img = e.data.data.img;
42 getApp().globalData.face_SourceImg = e.data.data.SourceImg; 43 getApp().globalData.face_SourceImg = e.data.data.SourceImg;
43 - let url = "/packageD/pages/AI-test-skin/analyse/analyse"; //跳到分析页 44 + var getimg_remark=th.data.img_remark;
  45 +
  46 +
  47 + let url = "/packageD/pages/AI-test-skin/analyse/analyse"; //跳到分析页
  48 + url+="?img_remark="+getimg_remark;
44 if(th.data.ce_user_id) 49 if(th.data.ce_user_id)
45 - url+="?ce_user_id="+th.data.ce_user_id; 50 + url+="&ce_user_id="+th.data.ce_user_id;
46 51
47 console.log("select_ph"); 52 console.log("select_ph");
48 console.log(url); 53 console.log(url);
@@ -60,6 +65,20 @@ Page({ @@ -60,6 +65,20 @@ Page({
60 }) 65 })
61 66
62 }, 67 },
  68 +
  69 + getInput(e) {
  70 + let val = e.detail.value;
  71 + if (val) {
  72 + this.setData({
  73 + img_remark: e.detail.value,
  74 + });
  75 + } else {
  76 + this.setData({
  77 + img_remark: '',
  78 + });
  79 + }
  80 +
  81 + },
63 //-- 重新从相册中选择图片 -- 82 //-- 重新从相册中选择图片 --
64 show_pai_pop: function () { 83 show_pai_pop: function () {
65 var th = this; 84 var th = this;
packageD/pages/AI-test-skin/select_photo/select_photo.wxml
@@ -3,6 +3,11 @@ @@ -3,6 +3,11 @@
3 <image style="width: 100%;border-radius: 3%;" mode="widthFix" src="{{gl_skin_img['path']}}"></image> 3 <image style="width: 100%;border-radius: 3%;" mode="widthFix" src="{{gl_skin_img['path']}}"></image>
4 <!-- <image wx:else style="width: 100%;border-radius: 3%;" mode="widthFix" src="{{gl_skin_img['path']}}"></image> --> 4 <!-- <image wx:else style="width: 100%;border-radius: 3%;" mode="widthFix" src="{{gl_skin_img['path']}}"></image> -->
5 </view> 5 </view>
  6 +
  7 + <view>
  8 + <input class="inputclass" name="img_remark" value="" placeholder="请填写备注" bindinput="getInput"> </input>
  9 + </view>
  10 +
6 <view class="foot_btn"> 11 <view class="foot_btn">
7 <view class="reset_select" bindtap="takePhoto"> 12 <view class="reset_select" bindtap="takePhoto">
8 <text class="iconfont icon-zuojiantou" style="font-size: 40rpx"></text> 13 <text class="iconfont icon-zuojiantou" style="font-size: 40rpx"></text>
packageD/pages/AI-test-skin/select_photo/select_photo.wxss
@@ -28,3 +28,13 @@ page { @@ -28,3 +28,13 @@ page {
28 /* margin: 0 auto; */ 28 /* margin: 0 auto; */
29 color: #fff; 29 color: #fff;
30 } 30 }
  31 +
  32 +.inputclass{
  33 + width: 540rpx;
  34 + height: 55rpx;
  35 + line-height: 55rpx;
  36 + background-color: rgb(238, 238, 238);
  37 + border-radius: 6rpx;
  38 + padding-left: 40rpx;
  39 + padding-right: 15rpx;
  40 +}
31 \ No newline at end of file 41 \ No newline at end of file