From 5bdd5271d1c3b8aeec4ceac149b81e68cbe23505 Mon Sep 17 00:00:00 2001
From: yvan.ni <765199919@qq.com>
Date: Sat, 14 Mar 2020 11:55:30 +0800
Subject: [PATCH] 会员资料的修改!生日的保存,是否农历的修改
---
pages/user/userinfo/userinfo.js | 8 +++++---
pages/user/userinfo/userinfo.wxml | 14 +++++++++++---
2 files changed, 16 insertions(+), 6 deletions(-)
diff --git a/pages/user/userinfo/userinfo.js b/pages/user/userinfo/userinfo.js
index fef23f5..01be957 100644
--- a/pages/user/userinfo/userinfo.js
+++ b/pages/user/userinfo/userinfo.js
@@ -51,7 +51,7 @@ Page({
ispwhid: 1, //是否隐藏密码显示
isstcsp: 0, //是否启动密码消费
isGender: 1, //什么性别
- iscalendar: 1, //是否是农历
+ iscalendar: 0, //是否是农历
consumption: "", //消费密码
identity_card: "", //身份证值
address: "", //地址
@@ -127,6 +127,8 @@ Page({
},
//出生日期是否是农历
iscalendar: function() {
+
+ if(this.data.user.birthday) return false;
var th = this;
var iscalendar = th.data.iscalendar;
if (iscalendar == 0) {
@@ -628,8 +630,8 @@ Page({
if(!a) a={};
var time ="",birthday ="";
- if(a && a.reg_time) util.formatTime(a.reg_time, "'Y/M/D");
- if(a && a.birthday) util.formatTime(a.birthday, "'Y/M/D");
+ if(a && a.reg_time) time=util.formatTime(a.reg_time, "'Y/M/D");
+ if(a && a.birthday) birthday=util.formatTime(a.birthday, "'Y/M/D");
a.reg_time = time;
a.birthday = birthday
diff --git a/pages/user/userinfo/userinfo.wxml b/pages/user/userinfo/userinfo.wxml
index 5c64773..66d1311 100644
--- a/pages/user/userinfo/userinfo.wxml
+++ b/pages/user/userinfo/userinfo.wxml
@@ -116,7 +116,10 @@
出生日期
-
+
+
+
+
@@ -124,20 +127,25 @@
+
+
+
+
农历
-
+
+ {{datet?datet:"请选择时间"}}
{{datet==""? user.birthday==""?"":filters.replace_time2(user.birthday):datet}}
-
+
--
libgit2 0.21.4