...
|
...
|
@@ -5,6 +5,7 @@ import $ from 'yoho-jquery'; |
|
|
import Page from 'yoho-page';
|
|
|
import tip from 'plugin/tip';
|
|
|
import cityRender from 'home/chosen-city.hbs';
|
|
|
import yoho from 'yoho-app';
|
|
|
|
|
|
class UserInfo extends Page {
|
|
|
constructor() {
|
...
|
...
|
@@ -25,7 +26,8 @@ class UserInfo extends Page { |
|
|
$cancelBtn: $('.swiper-header .cancel'),
|
|
|
$okBtn: $('.swiper-header .ok'),
|
|
|
$provinceText: $('.province-text'),
|
|
|
$cityText: $('.city-text')
|
|
|
$cityText: $('.city-text'),
|
|
|
$userPic: $('.user-pic')
|
|
|
};
|
|
|
|
|
|
this.view = {
|
...
|
...
|
@@ -60,6 +62,17 @@ class UserInfo extends Page { |
|
|
this.selector.$cancelBtn.on('click', this.cancelFun.bind(this));
|
|
|
this.selector.$okBtn.on('click', this.okFun.bind(this));
|
|
|
this.selector.$chosenCity.on('DOMNodeInserted', this.modifyInp.bind(this));
|
|
|
this.selector.$userPic.on('click', this.userPic.bind(this));
|
|
|
}
|
|
|
|
|
|
userPic() {
|
|
|
if (yoho.isApp) {
|
|
|
yoho.ready(function() {
|
|
|
yoho.invokeMethod('go.setAvatar', {}, (data) => {
|
|
|
alert(data);
|
|
|
});
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
|
|
|
cancelFun() {
|
...
|
...
|
|