Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
FlashMan
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
华国豪
FlashMan
Commits
024c2dc2
Commit
024c2dc2
authored
Jul 01, 2019
by
华国豪
🙄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增个人中心设置相关
parent
01f94434
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
1369 additions
and
57 deletions
+1369
-57
app.js
app.js
+1
-1
app.json
app.json
+2
-0
area.js
component/region-picker/area.js
+44
-0
lizus.js
component/region-picker/lizus.js
+237
-0
orz.js
component/region-picker/orz.js
+10
-0
region-picker.js
component/region-picker/region-picker.js
+173
-0
region-picker.json
component/region-picker/region-picker.json
+4
-0
region-picker.wxml
component/region-picker/region-picker.wxml
+18
-0
region-picker.wxss
component/region-picker/region-picker.wxss
+5
-0
passwod.png
images/memberInfo/passwod.png
+0
-0
memberInfo.js
pages/member/memberInfo/memberInfo.js
+138
-2
memberInfo.wxml
pages/member/memberInfo/memberInfo.wxml
+111
-18
memberInfo.wxss
pages/member/memberInfo/memberInfo.wxss
+115
-3
memberInfoED.js
pages/member/memberInfoED/memberInfoED.js
+104
-21
memberInfoED.wxml
pages/member/memberInfoED/memberInfoED.wxml
+7
-11
memberInfoED.wxss
pages/member/memberInfoED/memberInfoED.wxss
+16
-1
memberInfoEDAddr.js
pages/member/memberInfoEDAddr/memberInfoEDAddr.js
+149
-0
memberInfoEDAddr.json
pages/member/memberInfoEDAddr/memberInfoEDAddr.json
+5
-0
memberInfoEDAddr.wxml
pages/member/memberInfoEDAddr/memberInfoEDAddr.wxml
+17
-0
memberInfoEDAddr.wxss
pages/member/memberInfoEDAddr/memberInfoEDAddr.wxss
+30
-0
memberInfoEDPasswod.js
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.js
+132
-0
memberInfoEDPasswod.json
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.json
+3
-0
memberInfoEDPasswod.wxml
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.wxml
+17
-0
memberInfoEDPasswod.wxss
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.wxss
+31
-0
No files found.
app.js
View file @
024c2dc2
...
...
@@ -56,7 +56,7 @@ App({
},
success
(
res
)
{
wx
.
hideLoading
()
if
(
res
.
data
.
resultCode
===
1
)
{
if
(
res
.
data
.
resultCode
===
1
)
{
resolve
(
res
.
data
.
data
);
}
else
if
(
res
.
data
.
resultCode
===
10000
||
res
.
data
.
resultCode
===
10001
)
{
wx
.
reLaunch
({
...
...
app.json
View file @
024c2dc2
...
...
@@ -13,6 +13,8 @@
"pages/member/memberCenter/memberCenter"
,
"pages/member/memberInfo/memberInfo"
,
"pages/member/memberInfoED/memberInfoED"
,
"pages/member/memberInfoEDPasswod/memberInfoEDPasswod"
,
"pages/member/memberInfoEDAddr/memberInfoEDAddr"
,
"pages/visa/visa"
,
"pages/Voucher/Voucher"
,
"pages/Voucher/rating/rating"
,
...
...
component/region-picker/area.js
0 → 100644
View file @
024c2dc2
This diff is collapsed.
Click to expand it.
component/region-picker/lizus.js
0 → 100644
View file @
024c2dc2
/* ---=*--*=*-=*-=-*-=* 🌹 *---=*--*=*-=*-=-*-=*
Lizus核心库
Author: lizus.com
---=*--*=*-=*-=-*-=* 🌹 *---=*--*=*-=*-=-*-=* */
//用于获取x的类型
//getType :: a -> string
var
getType
=
function
getType
(
x
)
{
var
type
=
Object
.
prototype
.
toString
.
call
(
x
);
return
type
.
slice
(
8
,
-
1
);
};
//用于切换谓词函数的返回值
//not :: () -> ( a -> boolean )
var
not
=
function
not
(
fn
)
{
return
function
()
{
return
!
fn
.
apply
(
null
,[].
slice
.
apply
(
arguments
,[
0
]));
}
};
//用于判断x是否存在
// isExist :: a -> boolean
var
isExist
=
function
isExist
(
x
)
{
return
x
!=
null
;
};
//判断x是否为真,使用Boolean的结果
// isTrue :: a -> boolean
var
isTrue
=
Boolean
;
//判断x是否为空,此处判断空对象不算empty
//isEmpty :: a -> boolean
var
isEmpty
=
function
isEmpty
(
x
)
{
if
(
isTrue
(
x
)
&&
Math
.
abs
(
Number
(
x
))
!=
0
)
return
false
;
return
true
;
};
//生成返回自身的函数
//of :: x -> () -> x
var
of
=
function
(
x
)
{
return
function
()
{
return
x
;
};
};
//用于生成只接受len个参数的fn
//arity :: number -> () -> ()
var
arity
=
function
arity
(
len
,
fn
)
{
if
(
len
<
1
)
len
=
1
;
if
(
typeof
fn
!=
'function'
)
return
null
;
return
function
()
{
var
args
=
[].
slice
.
apply
(
arguments
,[
0
,
len
]);
return
fn
.
apply
(
null
,
args
);
}
};
//生成反转参数的函数
//reverseArg :: () -> ()
var
reverseArg
=
function
reverseArg
(
fn
)
{
if
(
typeof
fn
!=
'function'
)
return
null
;
return
function
()
{
var
args
=
[].
slice
.
apply
(
arguments
,[
0
]).
reverse
();
return
fn
.
apply
(
null
,
args
);
}
};
//curry函数
//curry :: () -> ()
var
curry
=
function
curry
(
fn
)
{
if
(
typeof
fn
!=
'function'
)
return
null
;
return
function
curryMe
()
{
var
args
=
[].
slice
.
apply
(
arguments
,[
0
]);
if
(
args
.
length
>=
fn
.
length
)
return
fn
.
apply
(
null
,
args
);
return
function
()
{
return
curryMe
.
apply
(
null
,
args
.
concat
([].
slice
.
apply
(
arguments
,[
0
])));
}
}
};
//用于调试,tag用于标识调试信息,x为调试项,最终返回x不阻止程序运行
//trace :: string -> a -> a
var
trace
=
curry
(
function
trace
(
tag
,
x
)
{
if
(
isExist
(
console
))
{
console
.
log
(
tag
,
x
);
}
else
{
alert
(
tag
);
alert
(
opt
);
}
return
x
;
});
//compose函数,用于组合函数,从右至左执行
//compose :: () -> a
var
compose
=
function
compose
()
{
var
args
=
[].
slice
.
apply
(
arguments
,[
0
]).
reverse
();
return
function
()
{
var
result
=
[].
slice
.
apply
(
arguments
,[
0
]);
for
(
var
i
=
0
;
i
<
args
.
length
;
i
++
)
{
if
(
typeof
args
[
i
]
!=
'function'
)
return
trace
(
'the arguments is not a function'
,
args
[
i
]);
result
=
args
[
i
].
apply
(
null
,[].
concat
(
result
));
}
return
result
;
}
};
//同compose,但是从左至右执行
//flow:: () -> a
var
flow
=
reverseArg
(
compose
);
//用于判断两个参数是否相等
//e :: a -> b -> boolean
var
e
=
curry
(
function
e
(
a
,
b
)
{
return
a
==
b
;
});
//用于判断b < a
//lt :: a -> b -> boolean
var
lt
=
curry
(
function
lt
(
a
,
b
)
{
return
b
<
a
;
});
//用于判断b > a
//gt :: a -> b -> boolean
var
gt
=
curry
(
function
(
a
,
b
)
{
return
b
>
a
;
});
//用于判断x是否是a类型
//isType :: a -> x -> boolean
var
isType
=
curry
(
function
isType
(
a
,
x
)
{
return
e
(
a
,
getType
(
x
));
});
//判断a是否是数组
//isArray :: a -> boolean
var
isArray
=
isType
(
'Array'
);
//判断a是否是对象
//isObject :: a -> boolean
var
isObject
=
isType
(
'Object'
);
//判断a是否是字符串
//isString :: a -> boolean
var
isString
=
isType
(
'String'
);
//判断a是否是数字
//isNumber :: a -> boolean
var
isNumber
=
isType
(
'Number'
);
//判断a是否是函数
//isFunction :: a -> boolean
var
isFunction
=
isType
(
'Function'
);
//判断a是否是正则表达式
//isRegExp :: a -> boolean
var
isRegExp
=
isType
(
'RegExp'
);
//判断a是否是布尔值
//isBoolean :: a -> boolean
var
isBoolean
=
isType
(
'Boolean'
);
//判断a是否是日期对象
//isDate :: a -> boolean
var
isDate
=
isType
(
'Date'
);
//curry化的Array重要函数,并将fn放在第一个参数位置上
//map :: () -> array -> array
var
map
=
curry
(
function
map
(
fn
,
col
)
{
return
Array
.
prototype
.
map
.
call
(
col
,
fn
);
});
//filter :: () -> array -> array
var
filter
=
curry
(
function
filter
(
fn
,
col
)
{
return
Array
.
prototype
.
filter
.
call
(
col
,
fn
);
});
//reduce :: () -> array -> array
var
reduce
=
curry
(
function
reduce
(
fn
,
col
)
{
return
Array
.
prototype
.
reduce
.
call
(
col
,
fn
);
});
//深度复制,主要解决数组和对象的引用问题,通过深度复制去除引用
//deepCopy :: a -> b
var
deepCopy
=
function
(
sth
)
{
var
re
;
if
(
isObject
(
sth
))
{
re
=
{};
for
(
var
key
in
sth
)
{
if
(
sth
.
hasOwnProperty
(
key
))
{
re
[
key
]
=
deepCopy
(
sth
[
key
]);
}
}
}
else
if
(
isArray
(
sth
)){
re
=
map
(
deepCopy
,
sth
);
}
else
{
re
=
sth
;
}
return
re
;
};
//转变为数组
//toArray :: a -> b
var
toArray
=
function
(
sth
)
{
var
re
=
[];
if
(
isObject
(
sth
))
{
for
(
var
key
in
sth
)
{
if
(
sth
.
hasOwnProperty
(
key
))
{
if
(
isObject
(
sth
[
key
]))
{
re
.
push
([
key
,
toArray
(
sth
[
key
])]);
}
else
{
re
.
push
([
key
,
sth
[
key
]]);
}
}
}
}
else
{
re
=
re
.
concat
(
deepCopy
(
sth
));
}
return
re
;
};
module
.
exports
=
{
trace
:
trace
,
arity
:
arity
,
reverseArg
:
reverseArg
,
curry
:
curry
,
compose
:
compose
,
flow
:
flow
,
not
:
not
,
of
:
of
,
e
:
e
,
lt
:
lt
,
gt
:
gt
,
getType
:
getType
,
isType
:
isType
,
isArray
:
isArray
,
isObject
:
isObject
,
isString
:
isString
,
isDate
:
isDate
,
isNumber
:
isNumber
,
isBoolean
:
isBoolean
,
isFunction
:
isFunction
,
isRegExp
:
isRegExp
,
isExist
:
isExist
,
isTrue
:
isTrue
,
isEmpty
:
isEmpty
,
map
:
map
,
filter
:
filter
,
reduce
:
reduce
,
deepCopy
:
deepCopy
,
toArray
:
toArray
};
\ No newline at end of file
component/region-picker/orz.js
0 → 100644
View file @
024c2dc2
const
lizus
=
require
(
'./lizus'
);
/**
* 用于查询匹配,正确返回匹配数组,错误返回false
*/
lizus
.
match
=
lizus
.
curry
(
function
(
q
,
str
)
{
if
(
lizus
.
isEmpty
(
str
))
return
false
;
return
String
.
prototype
.
match
.
call
(
str
,
q
)
||
false
;
});
module
.
exports
=
lizus
;
component/region-picker/region-picker.js
0 → 100644
View file @
024c2dc2
/** ---=*--*=*-=*-=-*-=* ^.^ *---=*--*=*-=*-=-*-=*
* 省市县三联picker选择组件
*
* @author lizus.com
* @updated 20190429
*
* @数据源 https://docs.alipay.com/isv/10327
*
* @使用范例:
<region-picker bind:change="regionChange" province="浙江省" city="台州市" county="天台县"></region-picker>
* @获取到的数据示例:
e.detail={
province:'浙江省',
city:'台州市',
county:'天台县'
};
---=*--*=*-=*-=-*-=* ^.^ *---=*--*=*-=*-=-*-=* */
const
area
=
require
(
'./area'
);
const
orz
=
require
(
'./orz'
);
const
areaArr
=
area
.
data
;
//省市县数据数组
/** provinces,cities,counties以数组的形式存储省市区数据,单位数组格式为[地方名称,地方名称在areaArr中的索引号] */
let
provinces
=
[];
//所有省,ready设定后不变
let
cities
=
[];
//城市数据,根据省的选择而变
let
counties
=
[];
//县区数据,根据市的选择而变
const
matchProvince
=
orz
.
match
(
/
([
1-9
]\d
|
\d[
1-9
])
0000/
);
//省的编号特征
const
matchCity
=
orz
.
match
(
/
\d\d([
1-9
]\d
|
\d[
1-9
])
00/
);
//市的编号特征
const
matchCounty
=
orz
.
match
(
/
\d\d\d\d([
1-9
]\d
|
\d[
1-9
])
/
);
//县的编号特征
const
notCounty
=
orz
.
not
(
matchCounty
);
/** 用于获取某索引后符合fn条件的索引,fn为谓词函数 */
const
getNextIndex
=
orz
.
curry
(
function
(
fn
,
index
)
{
let
n
=
areaArr
.
length
;
for
(
let
i
=
index
+
1
;
i
<
n
;
i
++
)
{
if
(
fn
(
areaArr
[
i
][
0
]))
{
n
=
i
;
break
;
}
}
return
n
;
});
const
getNextCountyIndex
=
getNextIndex
(
notCounty
);
const
getNextCityIndex
=
getNextIndex
(
matchProvince
);
/** 用于获取省市区各数据数组中的地区名称 */
const
getName
=
function
(
arr
,
index
)
{
if
(
index
>=
arr
.
length
)
return
''
;
return
arr
[
index
][
0
];
};
/** 用于获取某数组中元素的索引号 */
const
getIndex
=
orz
.
curry
(
function
(
arr
,
name
)
{
let
idx
=
Array
.
prototype
.
indexOf
.
call
(
arr
,
name
);
return
(
idx
<
1
)
?
0
:
idx
;
});
/** 用于获取省份数据,并传递给全局provinces,此函数只在ready中执行一次就可以了 */
const
getProvinces
=
function
()
{
let
col
=
[];
areaArr
.
forEach
(
function
(
item
,
index
)
{
let
num
=
item
[
0
];
let
val
=
item
[
1
];
if
(
matchProvince
(
num
)){
provinces
.
push
([
val
,
index
]);
col
.
push
(
val
);
}
});
return
col
;
};
/**
* 用于获取某一省份下市的数据,返回市名称的列表数组,同时重写全局cities数组
* @param provinceIndex 省份在provinces数组中索引值
* @returns {Array}
*/
const
getCities
=
function
(
provinceIndex
)
{
cities
=
[];
let
targetProvince
=
provinces
[
provinceIndex
];
let
targetIndex
=
targetProvince
[
1
];
let
nextIndex
=
getNextCityIndex
(
targetIndex
);
let
col
=
[];
for
(
let
i
=
targetIndex
;
i
<
nextIndex
;
i
++
)
{
let
item
=
areaArr
[
i
];
let
num
=
item
[
0
];
let
val
=
item
[
1
];
if
(
matchCity
(
num
)){
cities
.
push
([
val
,
i
]);
col
.
push
(
val
);
}
}
return
col
;
};
const
getCounties
=
function
(
cityIndex
)
{
counties
=
[];
let
targetCity
=
cities
[
cityIndex
];
let
targetIndex
=
targetCity
[
1
];
let
nextIndex
=
getNextCountyIndex
(
targetIndex
);
let
col
=
[];
for
(
let
i
=
targetIndex
+
1
;
i
<
nextIndex
;
i
++
)
{
let
item
=
areaArr
[
i
];
let
val
=
item
[
1
];
counties
.
push
([
val
,
i
]);
col
.
push
(
val
);
}
return
col
;
};
Component
({
properties
:{
province
:{
type
:
String
},
city
:{
type
:
String
},
county
:{
type
:
String
}
},
data
:{
province
:
'北京'
,
//省
city
:
'北京市'
,
//市
county
:
'东城区'
,
//县区
value
:[
0
,
0
,
0
],
//省,市,县在pickArr中的索引值
pickArr
:[[],[],[]]
//省,市,县
},
methods
:{
colChange
:
function
(
e
)
{
let
col
=
e
.
detail
.
column
;
let
val
=
e
.
detail
.
value
;
let
pickArr
=
this
.
data
.
pickArr
;
let
value
=
this
.
data
.
value
;
if
(
col
==
0
)
{
//用户更换第一列数据,联动二三列,并重置二三列索引为0
pickArr
[
1
]
=
getCities
(
val
);
pickArr
[
2
]
=
getCounties
(
0
);
value
=
[
val
,
0
,
0
];
this
.
setData
({
value
:
value
});
}
if
(
col
==
1
)
{
//用户更换第二列数据,联动第三列,并重置第三列索引为0
pickArr
[
2
]
=
getCounties
(
val
);
value
[
1
]
=
val
;
value
[
2
]
=
0
;
this
.
setData
({
value
:
value
});
}
this
.
setData
({
pickArr
:
pickArr
,
});
},
valChange
:
function
(
e
)
{
let
val
=
e
.
detail
.
value
;
let
obj
=
{
province
:
getName
(
provinces
,
val
[
0
]),
city
:
getName
(
cities
,
val
[
1
]),
county
:
getName
(
counties
,
val
[
2
])
};
this
.
setData
(
obj
);
this
.
triggerEvent
(
'change'
,
obj
);
},
},
ready
:
function
()
{
let
col1
=
getProvinces
();
let
provinceIndex
=
getIndex
(
col1
,
this
.
data
.
province
);
let
col2
=
getCities
(
provinceIndex
);
let
cityIndex
=
getIndex
(
col2
,
this
.
data
.
city
);
let
col3
=
getCounties
(
cityIndex
);
let
countyIndex
=
getIndex
(
col3
,
this
.
data
.
county
);
let
value
=
[
provinceIndex
,
cityIndex
,
countyIndex
];
let
pickArr
=
[
col1
,
col2
,
col3
];
this
.
setData
({
pickArr
:
pickArr
,
value
:
value
});
}
});
\ No newline at end of file
component/region-picker/region-picker.json
0 → 100644
View file @
024c2dc2
{
"component"
:
true
,
"usingComponents"
:
{}
}
\ No newline at end of file
component/region-picker/region-picker.wxml
0 → 100644
View file @
024c2dc2
<picker value="{{value}}" mode="multiSelector" range="{{pickArr}}" bindcolumnchange="colChange" bindchange="valChange">
<view class="region-picker ">
<block wx:if="{{province.length>0}}">
<text class="province">{{province}}</text>
</block>
<block wx:if="{{city.length>0}}">
<text class="line"> - </text>
<text class="city">{{city}}</text>
</block>
<block wx:if="{{county.length>0}}">
<text class="line"> - </text>
<text class="county">{{county}}</text>
</block>
<block wx:if="{{county.length<1 && city.length<1 && province.length<1}}">
<text class="empty-region">请选择所在地</text>
</block>
</view>
</picker>
\ No newline at end of file
component/region-picker/region-picker.wxss
0 → 100644
View file @
024c2dc2
.region-picker {
color: #999;
white-space: nowrap;
overflow: hidden;
}
\ No newline at end of file
images/memberInfo/passwod.png
0 → 100644
View file @
024c2dc2
679 Bytes
pages/member/memberInfo/memberInfo.js
View file @
024c2dc2
// pages/member/memberInfo/memberInfo.js
let
app
=
getApp
()
Page
({
/**
* 页面的初始数据
*/
data
:
{
active
:
1
,
active
:
5
,
userInfo
:
{},
custormInfo
:
{},
branchList
:
[],
sanImg
:
''
,
sanImg1
:
''
,
sanImg2
:
''
,
sanImg3
:
''
,
orderAdd
:
{},
verificationMsg
:
{
CertificationPics
:
[],
CustomerID
:
0
,
ApplyType
:
1
,
ID
:
0
},
},
seveSanMsg
:
function
(
e
)
{
let
index
=
e
.
target
.
id
.
split
(
'save'
)[
1
];
this
.
data
.
verificationMsg
.
CustomerID
=
this
.
data
.
userInfo
.
id
;
if
(
index
==
'0'
)
{
if
(
this
.
data
.
sanImg
===
''
)
{
wx
.
showToast
({
title
:
'请先上传图片'
,
icon
:
'none'
,
duration
:
1000
})
return
}
this
.
data
.
verificationMsg
.
ApplyType
=
2
;
this
.
data
.
verificationMsg
.
CertificationPics
.
push
(
this
.
data
.
sanImg
);
}
else
{
if
(
this
.
data
.
sanImg1
===
''
||
this
.
data
.
sanImg2
===
''
||
this
.
data
.
sanImg3
===
''
)
{
wx
.
showToast
({
title
:
'请先上传图片'
,
icon
:
'none'
,
duration
:
1000
})
return
}
this
.
data
.
verificationMsg
.
CertificationPics
=
[
this
.
data
.
sanImg1
,
this
.
data
.
sanImg2
,
this
.
data
.
sanImg3
];
}
app
.
$api
(
"app_customer_SetCertification"
,
this
.
data
.
verificationMsg
).
then
(
res
=>
{
wx
.
showToast
({
title
:
'保存成功'
,
icon
:
'none'
,
duration
:
1000
})
}).
catch
(
err
=>
{
})
},
chooseImage
:
function
(
e
)
{
let
index
=
e
.
target
.
id
.
split
(
'img'
)[
1
];
console
.
log
(
index
)
let
_this
=
this
,
path
=
'/Upload/DMC/'
;
wx
.
chooseImage
({
count
:
1
,
sizeType
:
[
'original'
,
'compressed'
],
sourceType
:
[
'album'
,
'camera'
],
success
(
res
)
{
const
tempFilePaths
=
res
.
tempFilePaths
res
.
tempFilePaths
.
map
(
x
=>
{
wx
.
uploadFile
({
url
:
'http://upload.oytour.com/Upload?filePath='
+
path
,
//仅为示例,非真实的接口地址
filePath
:
x
,
name
:
'file'
,
formData
:
{
'user'
:
x
},
success
:
function
(
res
)
{
var
data
=
JSON
.
parse
(
res
.
data
)
let
img
=
"http://imgfile.oytour.com"
+
data
.
FilePath
if
(
index
==
'0'
)
{
_this
.
setData
({
sanImg
:
img
})
}
else
if
(
index
==
'1'
)
{
_this
.
setData
({
sanImg1
:
img
})
}
else
if
(
index
==
'2'
)
{
_this
.
setData
({
sanImg2
:
img
})
}
else
if
(
index
==
'3'
)
{
_this
.
setData
({
sanImg3
:
img
})
}
}
})
})
}
})
},
setActive
:
function
(
e
)
{
let
type
=
e
.
target
.
id
.
split
(
'active'
)[
1
]
...
...
@@ -13,14 +106,47 @@ Page({
active
:
Number
(
type
)
})
},
getOrderAdd
:
function
()
{
app
.
$api
(
'b2b_post_MiniProgramGetAccountInfoByPhone'
,
{
account
:
this
.
data
.
custormInfo
.
contactNumber
,
}).
then
(
res
=>
{
var
token
=
this
.
data
.
userInfo
.
token
;
var
secretKey
=
this
.
data
.
userInfo
.
secretKey
;
var
uid
=
res
.
customerId
;
var
groupId
=
res
.
groupId
;
app
.
$apiJava
(
"api/orderForm/getOrderAdd"
,
{},
groupId
,
uid
,
token
,
secretKey
,).
then
(
res
=>
{
this
.
setData
({
orderAdd
:
res
})
}).
catch
(
err
=>
{
})
}).
catch
(
err
=>
{
})
},
getUserInfo
:
function
()
{
app
.
$api
(
"b2b_get_GetCustomerManagerInfo"
,
{}).
then
(
res
=>
{
this
.
setData
({
custormInfo
:
res
,
branchList
:
res
.
branchList
})
this
.
getOrderAdd
()
}).
catch
(
err
=>
{
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
//修改title
let
data
=
{},
_this
=
this
;
wx
.
setNavigationBarTitle
({
title
:
'个人信息'
})
this
.
getUserInfo
()
wx
.
getStorage
({
key
:
'admin'
,
success
(
res
)
{
data
=
res
.
data
_this
.
setData
({
userInfo
:
data
})
}
})
},
/**
...
...
@@ -34,7 +160,17 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
let
_this
=
this
;
this
.
getUserInfo
()
wx
.
getStorage
({
key
:
'admin'
,
success
(
res
)
{
let
data
=
res
.
data
_this
.
setData
({
userInfo
:
data
})
}
})
},
/**
...
...
pages/member/memberInfo/memberInfo.wxml
View file @
024c2dc2
<view class='memberInfo'>
<view class='memberInfo-info'
wx:if="{{active === 1}}"
>
<view class='head'>
<view class='memberInfo'
style='margin-top: {{active === 3 || active === 4 ? "0px" : "57rpx"}};min-height: {{active === 3 || active === 4 ? "1080rpx" : "987rpx"}}'
>
<view class='memberInfo-info'>
<view class='head'
wx:if="{{active === 1 || active === 2}}"
>
<view class="boxF">
<view class="boxS">
<view class="boxT" style="background-image: url(http://b.hiphotos.baidu.com/image/pic/item/10dfa9ec8a1363272bc51737938fa0ec08fac78e.jpg);"></view>
<view wx:if="{{!userInfo.photo}}" class="boxT" style="background-image: url(http://imgfile.oytour.com/New/Upload/Cloud/2019-06/20190628030353039.png);"></view>
<view wx:else class="boxT" style="background-image: url({{userInfo.photo}});"></view>
</view>
</view>
</view>
<view class='name'>
<text>
唐先生
</text>
<navigator url="/pages/member/memberInfoED
/memberInfoED
" hover-class="navigator-hover"><image src='../../../images/memberInfo/qianbi.png'></image></navigator>
<view class='name'
wx:if="{{active === 1 || active === 2}}"
>
<text>
{{userInfo.name}}
</text>
<navigator url="/pages/member/memberInfoED
Passwod/memberInfoEDPasswod
" hover-class="navigator-hover"><image src='../../../images/memberInfo/qianbi.png'></image></navigator>
</view>
<view class='info-box'>
<view class='info-box'
wx:if="{{active === 1}}"
>
<view class='info-box-tit'>
<text>门店基本资料</text>
<view class='line'></view>
...
...
@@ -19,30 +20,125 @@
<view class='info-box-info'>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/fangzi.png'></image>
<text>
唐菲旅行社
</text>
<text>
{{custormInfo.customerName}}
</text>
</view>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/hehe.png'></image>
<text>
wr15645646123
</text>
<text>
{{custormInfo.account}}
</text>
</view>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/phone.png'></image>
<text>
1895678489
</text>
<text>
{{custormInfo.account}}
</text>
</view>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/dizhi.png'></image>
<text>
中国四川成都锦江区,成都锦江区东风南路288号168号楼5楼44
</text>
<text>
{{custormInfo.address}}
</text>
</view>
<view class='info-box-info-item'>
<view class='info-box-info-item
info-span
'>
<image mode='widthFix' src='../../../images/memberInfo/biaoqian.png'></image>
<text>驴妈妈/七彩旅行社/省国旅</text>
<view>
<text wx:for="{{branchList}}" wx:for-item="item" wx:for-index="index" wx:key="index">{{item.brandName}}</text>
</view>
</view>
</view>
</view>
<view class='info-box' wx:if="{{active === 2}}">
<view class='info-box-tit'>
<text>个人安全设置</text>
<view class='line'></view>
</view>
<view class='info-box-info'>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/hehe.png'></image>
<text>{{custormInfo.account}}</text>
</view>
<view class='info-box-info-item'>
<image mode='widthFix' src='../../../images/memberInfo/passwod.png'></image>
<text>******</text>
</view>
</view>
</view>
<view class='info-box' wx:if="{{active === 3 || active === 4}}" style='margin-top: -50rpx;'>
<view class='info-box-tit'>
<text>实名认证</text>
<view class='line'></view>
</view>
<view wx:if="{{active === 3}}">
<view class='winxin-tips'>
<view>温馨提示:</view>
<view>1.照片要求:jpg/png格式,大小不超过1M;</view>
<view>2.请确保三证合一的营业执照照片边框完整,字体清晰,亮度均匀。</view>
</view>
<view class='shangchuan-box'>
<view class='left'>
<view>
<view class='img-box tianjia' id="img0" bindtap='chooseImage' wx:if="{{sanImg===''}}">+</view>
<view class='img-box' id="img0" bindtap='chooseImage' wx:else><image src='{{sanImg}}'></image></view>
</view>
<view class='text'>上传<text class='b'>三证合一</text>的营业执照</view>
</view>
<view class='right'>
<view class='img-box shili'></view>
<view class='text'>营业执照 <text class='b'>示例图</text></view>
</view>
</view>
<view style='text-align: center'>
<view class='save-btn' id="save0" bindtap='seveSanMsg'>
保存
</view>
</view>
</view>
<view wx:elif="{{active === 4}}">
<view class='winxin-tips'>
<view>温馨提示:</view>
<view>1.照片要求:jpg/png格式,大小不超过1M;</view>
<view>2.请确保身份证照片边框完整,字体清晰,亮度均匀。</view>
</view>
<view class='shangchuan-box2'>
<view class='img-box'>
<view class='img-box tianjia' id="img1" bindtap='chooseImage' wx:if="{{sanImg1===''}}">+</view>
<view class='img-box' id="img1" bindtap='chooseImage' wx:else><image id="img1" src='{{sanImg1}}'></image></view>
</view>
<view class='text'>上传身份证<text class='b'>人像面</text></view>
<view class='img-box'>
<view class='img-box tianjia' id="img2" bindtap='chooseImage' wx:if="{{sanImg2===''}}">+</view>
<view class='img-box' id="img2" bindtap='chooseImage' wx:else><image id="img2" src='{{sanImg2}}'></image></view>
</view>
<view class='text'>上传身份证<text class='b'>国徽面</text></view>
<view class='img-box'>
<view class='img-box tianjia' id="img3" bindtap='chooseImage' wx:if="{{sanImg3===''}}">+</view>
<view class='img-box' id="img3" bindtap='chooseImage' wx:else><image id="img3" src='{{sanImg3}}'></image></view>
</view>
<view class='text'>上传身份证<text class='b'>名片</text>有姓名、联系方式的一面</view>
</view>
<view style='text-align: center'>
<view class='save-btn' id="save1" bindtap='seveSanMsg'>
保存
</view>
</view>
</view>
</view>
<view wx:elif="{{active === 5}}" style='margin-top: -50rpx;'>
<view class='info-box-tit'>
<text>收货地址管理</text>
<view class='line'></view>
</view>
<view class='dizhi'>
<view>
<text class='name'>{{orderAdd.uname}}</text>
<text class='phone'>{{orderAdd.uphone}}</text>
</view>
<view class='addr-info'>
<text class='addr-info-tag'>默认</text>
<text class='addr-info-detais'>{{orderAdd.address}}</text>
<navigator url="/pages/member/memberInfoEDAddr/memberInfoEDAddr?id={{orderAdd.id}}" hover-class="navigator-hover"><image mode='widthFix' src='../../../images/memberInfo/qianbi.png'></image></navigator>
</view>
</view>
</view>
</view>
</view>
<view>
<scroll-view scroll-x style="width: 100%;white-space: nowrap;">
<scroll-view scroll-x style="width: 100%;white-space: nowrap;
padding-right: 80rpx;
">
<view class='bottom-nav'>
<view class='{{active === 1? "active" : ""}}' id="active1" bindtap='setActive'>
门店基本资料
...
...
@@ -56,9 +152,6 @@
<view class='{{active === 4? "active" : ""}}' id="active4" bindtap='setActive'>
个人认证
</view>
<view class='{{active === 4? "active" : ""}}' id="active4" bindtap='setActive'>
个人认证
</view>
<view class='{{active === 5? "active" : ""}}' id="active5" bindtap='setActive'>
收货地址管理
</view>
...
...
pages/member/memberInfo/memberInfo.wxss
View file @
024c2dc2
...
...
@@ -8,7 +8,7 @@ page {
background: transparent;
}
.memberInfo{
height: 987rpx;
min-
height: 987rpx;
margin-top: 57rpx;
background: url(http://imgfile.oytour.com/New/Upload/Cloud/2019-06/20190628101804297.png) no-repeat;
background-size:100% 100%;
...
...
@@ -60,13 +60,13 @@ page {
-webkit-transform: rotate(-60deg);
visibility: visible;
}
.name{
.
memberInfo-info>.
name{
text-align: center;
font-size: 32rpx;
position: relative;
margin: 0 65rpx;
}
.name image{
.
memberInfo-info>.
name image{
position: absolute;
right: 0;
top: -48rpx;
...
...
@@ -99,12 +99,18 @@ page {
align-items:center;
margin-bottom: 58rpx;
}
.info-box-info-item.info-span view{
flex-wrap:wrap;
display:flex;
}
.info-box-info image{
width: 33rpx;
}
.info-box-info text{
font-size: 28rpx;
margin-left: 29rpx;
/* word-break: keep-all;
word-wrap: break-word; */
}
.bottom-nav{
padding: 0 60rpx 0 285rpx;
...
...
@@ -122,3 +128,109 @@ page {
background: #AFE4F8;
color:#4393B1;
}
.winxin-tips{
font-size: 24rpx;
color: rgba(102,102,102,1);
line-height: 42rpx;
}
.shangchuan-box{
display: flex;
justify-content: space-between;
padding: 28rpx 27rpx;
text-align: center;
}
.shangchuan-box2{
height: 470rpx;
overflow: auto;
padding: 28rpx 27rpx;
margin-bottom: 40rpx;
text-align: center;
}
.shangchuan-box2 .img-box{
margin-bottom: 28rpx;
}
.shangchuan-box2 .tianjia{
font-size: 120rpx;
color: #E1E1E1;
line-height: 322rpx;
}
.shangchuan-box2 .img-box{
width:590rpx;
height:362rpx;
background:rgba(244,244,244,1);
border:1rpx solid rgba(229,229,229,1);
}
.shangchuan-box .img-box{
width: 268rpx;
height: 362rpx;
background: rgba(244,244,244,1);
border: 1px solid rgba(229,229,229,1);
margin-bottom: 28rpx;
}
.shangchuan-box .img-box.tianjia{
font-size: 120rpx;
color: #E1E1E1;
line-height: 322rpx;
}
.shangchuan-box .img-box.shili{
background: url(http://imgfile.oytour.com/New/Upload/Cloud/2019-07/20190701024832288.png) no-repeat;
background-size:100% 100%;
border: none;
}
.shangchuan-box .text,.shangchuan-box2 .text{
font-size: 24rpx;
}
.shangchuan-box .text .b,.shangchuan-box2 .text .b{
color: #1468F3;
}
.shangchuan-box2 .text{
margin-bottom: 30rpx;
}
.save-btn{
padding: 30rpx 0;
width: 360rpx;
margin: 0 auto 25rpx;
text-align: center;
font-size: 28rpx;
background:rgba(238,68,84,1);
border-radius:12rpx;
color: #FFFFFF
}
.dizhi{
padding: 0 76rpx;
}
.dizhi>view{
margin-bottom: 10rpx;
}
.dizhi .name{
font-size:28rpx;
color:rgba(0,0,0,1);
padding-right: 32rpx;
/* width: 66rpx; */
display: inline-block;
margin-right: 18rpx;
}
.dizhi .phone{
font-size:28rpx;
color: #666666;
}
.addr-info{
display: flex;
font-size: 24rpx;
align-items:center;
}
.addr-info image{
width: 35rpx;
/* height: 38rpx; */
}
.addr-info-tag{
display: inline-block;
width: 66rpx;
background:rgba(238, 68, 84, .2);
color: #EE4454;
}
.addr-info-detais{
display: inline-block;
margin: 0 32rpx;
}
\ No newline at end of file
pages/member/memberInfoED/memberInfoED.js
View file @
024c2dc2
// pages/member/memberInfoED/memberInfoED.js
let
app
=
getApp
()
Page
({
/**
...
...
@@ -6,36 +7,118 @@ Page({
*/
data
:
{
index
:
0
,
objectArrayobjectArray
:
[
{
id
:
0
,
name
:
'美国'
},
{
id
:
1
,
name
:
'中国'
},
{
id
:
2
,
name
:
'巴西'
},
{
id
:
3
,
name
:
'日本'
}
],
branchList
:
[],
custormInfo
:
{},
brandList
:
[],
},
inputName
:
function
(
e
)
{
this
.
data
.
custormInfo
.
customerName
=
e
.
detail
.
value
},
inputNumber
:
function
(
e
)
{
this
.
data
.
custormInfo
.
contactNumber
=
e
.
detail
.
value
},
inputAddr
:
function
(
e
)
{
this
.
data
.
custormInfo
.
address
=
e
.
detail
.
value
},
seveMsg
:
function
()
{
const
phoneReg
=
/
(
^1
[
3|4|5|7|8|6
]\d{9}
$
)
|
(
^09
\d{8}
$
)
/
;
//电话 验证
let
_this
=
this
;
let
phone
=
this
.
data
.
custormInfo
.
contactNumber
.
replace
(
/^
\s
+|
\s
+$/gm
,
""
);
if
(
!
phoneReg
.
test
(
_this
.
data
.
custormInfo
.
contactNumber
))
{
wx
.
showToast
({
title
:
'请输入有效的手机号码!'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
!
_this
.
data
.
custormInfo
.
address
)
{
wx
.
showToast
({
title
:
'请填写所在地址'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
!
_this
.
data
.
custormInfo
.
customerName
)
{
wx
.
showToast
({
title
:
'请填写门店名称'
,
icon
:
'none'
,
duration
:
1000
})
return
}
let
list
=
[];
this
.
data
.
branchList
.
forEach
(
x
=>
{
list
.
push
(
x
.
brandId
)
})
this
.
data
.
custormInfo
.
brandIds
=
list
;
app
.
$api
(
'b2b_post_ModifyCustomerManagerInfo'
,
this
.
data
.
custormInfo
).
then
(
res
=>
{
wx
.
navigateBack
({
delta
:
2
})
}).
catch
(
err
=>
{
})
},
deleteItem
:
function
(
e
)
{
let
index
=
e
.
target
.
id
.
split
(
'item'
)[
1
]
this
.
data
.
branchList
.
splice
(
index
,
1
)
this
.
setData
({
branchList
:
this
.
data
.
branchList
})
},
getUserInfo
:
function
()
{
app
.
$api
(
"b2b_get_GetCustomerManagerInfo"
,
{}).
then
(
res
=>
{
this
.
setData
({
custormInfo
:
res
,
branchList
:
res
.
branchList
})
}).
catch
(
err
=>
{
})
},
app_get_customer_brand
:
function
()
{
// 获取品牌
app
.
$api
(
'app_get_customer_brand'
,
{}).
then
(
res
=>
{
this
.
setData
({
brandList
:
res
})
}).
catch
(
err
=>
{
})
},
bindPickerChange
:
function
(
e
)
{
console
.
log
(
'picker发送选择改变,携带值为'
,
e
.
detail
.
value
)
let
index
=
e
.
detail
.
value
let
list
=
this
.
data
.
branchList
let
isTags
=
false
;
this
.
data
.
brandList
.
map
((
x
,
i
)
=>
{
console
.
log
(
index
,
typeof
index
)
if
(
index
==
i
)
{
console
.
log
(
x
)
list
.
map
(
y
=>
{
console
.
log
(
y
)
if
(
y
.
brandId
==
x
.
id
)
{
isTags
=
true
}
})
if
(
!
isTags
)
{
list
.
push
({
brandName
:
x
.
name
,
brandId
:
x
.
id
})
}
}
})
this
.
setData
({
index
:
e
.
detail
.
value
branchList
:
list
})
console
.
log
(
'picker发送选择改变,携带值为'
,
e
.
detail
.
value
)
// this.setData({
// index: e.detail.value
// })
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
this
.
getUserInfo
();
this
.
app_get_customer_brand
()
},
/**
...
...
pages/member/memberInfoED/memberInfoED.wxml
View file @
024c2dc2
<view class='edit'>
<view class='edit-item'>
<label>登录账户:</label><input disabled='disabled'></input>
<label>登录账户:</label><input disabled='disabled'
value='{{custormInfo.account}}'
></input>
</view>
<view class='edit-item'>
<label>门店名称:</label><input></input>
<label>门店名称:</label><input
bindinput='inputName' value='{{custormInfo.customerName}}'
></input>
</view>
<view class='edit-item'>
<label>联系电话:</label><input></input>
<label>联系电话:</label><input
bindinput='inputNumber' value='{{custormInfo.contactNumber}}'
></input>
</view>
<view class='edit-item'>
<label>详细地址:</label><input></input>
<label>详细地址:</label><input
bindinput='inputAddr' value='{{custormInfo.address}}'
></input>
</view>
<view class='edit-item'>
<label>所属品牌:</label>
<view class='brand-box'>
<text>四川华夏国旅</text>
<text>四川国旅</text>
<text>四川国旅</text>
<text>四川国旅</text>
<text>四川国旅</text>
<view wx:for="{{branchList}}" wx:for-item="item" wx:for-index="index" wx:key="index">{{item.brandName}}<text class='delete-item' bindtap='deleteItem' id="item{{index}}">x</text></view>
</view>
</view>
<view class="section">
<picker mode="selector" bindchange="bindPickerChange" range-key="{{'name'}}" value="{{'name'}}" range="{{
objectArrayobjectArray
}}">
<picker mode="selector" bindchange="bindPickerChange" range-key="{{'name'}}" value="{{'name'}}" range="{{
brandList
}}">
<view class="picker">
请选择
<image mode='widthFix' src='../../../images/memberInfo/sanjiao.png'></image>
</view>
</picker>
</view>
<view class='save-btn'>
<view class='save-btn'
bindtap='seveMsg'
>
保存
</view>
</view>
\ No newline at end of file
pages/member/memberInfoED/memberInfoED.wxss
View file @
024c2dc2
...
...
@@ -29,12 +29,16 @@ page {
.picker image{
width: 24px;
}
.brand-box text{
.brand-box{
position: relative;
}
.brand-box>view{
padding: 17rpx 37rpx;
background:rgba(201,240,254,.4);
border-radius:30rpx;
display: inline-block;
margin: 0 30rpx 15rpx 0;
position: relative;
}
.save-btn{
padding: 30rpx 0;
...
...
@@ -44,4 +48,15 @@ page {
background:rgba(238,68,84,1);
border-radius:12rpx;
color: #FFFFFF
}
.delete-item{
position: absolute;
right: -5rpx;
top: -5rpx;
display: inline-block;
width: 10rpx;
height: 10rpx;
text-align: center;
line-height: 10rpx;
font-size: 24rpx;
}
\ No newline at end of file
pages/member/memberInfoEDAddr/memberInfoEDAddr.js
0 → 100644
View file @
024c2dc2
let
app
=
getApp
();
Page
({
/**
* 页面的初始数据
*/
data
:
{
msg
:
{
id
:
0
,
province
:
''
,
city
:
''
,
district
:
''
,
address
:
''
,
uname
:
''
,
uphone
:
''
,
postcode
:
''
,
},
province
:
''
,
city
:
''
,
county
:
''
,
},
seveMsg
:
function
()
{
if
(
!
this
.
data
.
msg
.
uname
){
wx
.
showToast
({
title
:
'请填写收货人'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
!
this
.
data
.
msg
.
uphone
)
{
wx
.
showToast
({
title
:
'请填写手机号'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
!
this
.
data
.
msg
.
address
)
{
wx
.
showToast
({
title
:
'请填写详细地址'
,
icon
:
'none'
,
duration
:
1000
})
return
}
app
.
$apiJavaNew
(
"api/orderForm/saveOrUpdateOrderAdd"
,
this
.
data
.
msg
).
then
(
res
=>
{
wx
.
showToast
({
title
:
'修改成功'
,
icon
:
'none'
,
duration
:
1000
})
setTimeout
(()
=>
{
wx
.
navigateBack
({
delta
:
2
})
},
1000
)
}).
catch
(
err
=>
{
})
},
regionChange
:
function
(
e
)
{
console
.
log
(
e
)
this
.
setData
({
province
:
e
.
detail
.
province
,
city
:
e
.
detail
.
city
,
county
:
e
.
detail
.
county
,
'msg.province'
:
e
.
detail
.
province
,
'msg.city'
:
e
.
detail
.
city
,
'msg.district'
:
e
.
detail
.
district
,
});
},
inputName
:
function
(
e
)
{
console
.
log
(
e
)
let
id
=
e
.
target
.
id
,
value
=
e
.
detail
.
value
;
if
(
id
==
'name'
)
{
this
.
setData
({
'msg.uname'
:
value
})
}
else
if
(
id
==
'phone'
)
{
this
.
setData
({
'msg.uphone'
:
value
})
}
else
if
(
id
==
'details'
)
{
this
.
setData
({
'msg.address'
:
value
})
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
this
.
setData
({
'msg.id'
:
options
.
id
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{
//修改title
wx
.
setNavigationBarTitle
({
title
:
'修改收货地址'
})
},
/**
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide
:
function
()
{
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload
:
function
()
{
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh
:
function
()
{
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom
:
function
()
{
},
/**
* 用户点击右上角分享
*/
onShareAppMessage
:
function
()
{
}
})
\ No newline at end of file
pages/member/memberInfoEDAddr/memberInfoEDAddr.json
0 → 100644
View file @
024c2dc2
{
"usingComponents"
:
{
"region-picker"
:
"../../../component/region-picker/region-picker"
}
}
\ No newline at end of file
pages/member/memberInfoEDAddr/memberInfoEDAddr.wxml
0 → 100644
View file @
024c2dc2
<view class='edit'>
<view class='edit-item'>
<input bindinput='inputName' id="name" placeholder='收货人' value='{{custormInfo.account}}'></input>
</view>
<view class='edit-item'>
<input bindinput='inputName' id="phone" placeholder='手机号码' value='{{custormInfo.customerName}}'></input>
</view>
<view class='edit-item section-box'>
<region-picker bind:change="regionChange" province="{{province}}" city="{{city}}" county="{{county}}"></region-picker>
</view>
<view class='edit-item'>
<input bindinput='inputName' id="details" placeholder='详细地址:如街道、门牌号和小区单元等' value='{{custormInfo.address}}'></input>
</view>
<view class='save-btn' bindtap='seveMsg'>
保存
</view>
</view>
\ No newline at end of file
pages/member/memberInfoEDAddr/memberInfoEDAddr.wxss
0 → 100644
View file @
024c2dc2
page {
width: 100%;
height: 100VH;
background:#f8f5f5;
overflow: hidden;
}
.edit{
font-size: 28rpx;
color: #999999;
padding: 40rpx 0;
}
.edit .edit-item{
padding: 34rpx 28rpx;
border-bottom: 1px solid #E8E8E8;
}
input{
width: 100%;
}
.save-btn{
padding: 30rpx 0;
margin: 61rpx 25rpx 0 25rpx;
text-align: center;
font-size: 28rpx;
background:rgba(238,68,84,1);
border-radius:12rpx;
color: #FFFFFF
}
.section-box{
display: flex;
}
\ No newline at end of file
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.js
0 → 100644
View file @
024c2dc2
// pages/member/memberInfoED/memberInfoED.js
let
app
=
getApp
()
Page
({
/**
* 页面的初始数据
*/
data
:
{
userInfo
:
{},
saveMsg
:
{
oldPassword
:
''
,
newPassword
:
''
,
},
newPassword
:
''
,
},
inputOldPwd
:
function
(
e
)
{
this
.
data
.
saveMsg
.
oldPassword
=
e
.
detail
.
value
},
inputNewPwd
:
function
(
e
)
{
this
.
data
.
saveMsg
.
newPassword
=
e
.
detail
.
value
},
inputNewPwdS
:
function
(
e
)
{
this
.
data
.
newPassword
=
e
.
detail
.
value
},
seveMsg
:
function
()
{
if
(
this
.
data
.
saveMsg
.
oldPassword
===
''
){
wx
.
showToast
({
title
:
'请填写旧密码'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
this
.
data
.
saveMsg
.
newPassword
===
''
)
{
wx
.
showToast
({
title
:
'请填写新密码'
,
icon
:
'none'
,
duration
:
1000
})
return
}
if
(
this
.
data
.
saveMsg
.
newPassword
!==
this
.
data
.
newPassword
)
{
wx
.
showToast
({
title
:
'两次新密码不一致'
,
icon
:
'none'
,
duration
:
1000
})
return
}
app
.
$api
(
'b2b_post_ModifyAccountPassowrd'
,
this
.
data
.
saveMsg
).
then
(
res
=>
{
wx
.
showToast
({
title
:
'修改成功'
,
icon
:
'none'
,
duration
:
1000
})
setTimeout
(()
=>
{
wx
.
navigateBack
({
delta
:
2
})
},
1000
)
}).
catch
(
err
=>
{
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{
//修改title
wx
.
setNavigationBarTitle
({
title
:
'个人安全设置'
})
let
_this
=
this
;
wx
.
getStorage
({
key
:
'admin'
,
success
(
res
)
{
let
data
=
res
.
data
_this
.
setData
({
userInfo
:
data
})
}
})
},
/**
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide
:
function
()
{
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload
:
function
()
{
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh
:
function
()
{
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom
:
function
()
{
},
/**
* 用户点击右上角分享
*/
onShareAppMessage
:
function
()
{
}
})
\ No newline at end of file
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.json
0 → 100644
View file @
024c2dc2
{
"usingComponents"
:
{}
}
\ No newline at end of file
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.wxml
0 → 100644
View file @
024c2dc2
<view class='edit'>
<view class='edit-item'>
<label>登录账户:</label><input disabled='disabled' value='{{userInfo.account}}'></input>
</view>
<view class='edit-item'>
<label>输入密码:</label><input bindinput='inputOldPwd' value='{{saveMsg.oldPassword}}'></input>
</view>
<view class='edit-item'>
<label>输入新密码:</label><input bindinput='inputNewPwd' value='{{saveMsg.newPassword}}'></input>
</view>
<view class='edit-item'>
<label>再次输入新密码:</label><input bindinput='inputNewPwdS' value='{{newPassword}}'></input>
</view>
<view class='save-btn' bindtap='seveMsg'>
保存
</view>
</view>
\ No newline at end of file
pages/member/memberInfoEDPasswod/memberInfoEDPasswod.wxss
0 → 100644
View file @
024c2dc2
page {
width: 100%;
height: 100VH;
background:#f8f5f5;
overflow: hidden;
}
.edit{
font-size: 28rpx;
color: #999999;
padding: 40rpx 0;
}
.edit .edit-item{
padding: 34rpx 28rpx;
border-bottom: 1px solid #E8E8E8;
display: flex;
}
.edit .edit-item label{
flex: 2;
}
.edit .edit-item input{
flex: 3;
}
.save-btn{
padding: 30rpx 0;
margin: 61rpx 25rpx 0 25rpx;
text-align: center;
font-size: 28rpx;
background:rgba(238,68,84,1);
border-radius:12rpx;
color: #FFFFFF
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment