...
|
...
|
@@ -7,6 +7,7 @@ |
|
|
'use strict';
|
|
|
const api = global.yoho.API;
|
|
|
const userApi = require('./user-api');
|
|
|
const Images = require('../../../utils/images');
|
|
|
const headerModel = require('../../../doraemon/models/header');
|
|
|
|
|
|
const configData = {
|
...
|
...
|
@@ -71,18 +72,18 @@ const configData = { |
|
|
value: '1',
|
|
|
text: '目的型购物'
|
|
|
},
|
|
|
{
|
|
|
type: 'radio',
|
|
|
key: 'shopping',
|
|
|
value: '2',
|
|
|
text: '冲动型购物'
|
|
|
},
|
|
|
{
|
|
|
type: 'radio',
|
|
|
key: 'shopping',
|
|
|
value: '3',
|
|
|
text: '保守型购物'
|
|
|
}],
|
|
|
{
|
|
|
type: 'radio',
|
|
|
key: 'shopping',
|
|
|
value: '2',
|
|
|
text: '冲动型购物'
|
|
|
},
|
|
|
{
|
|
|
type: 'radio',
|
|
|
key: 'shopping',
|
|
|
value: '3',
|
|
|
text: '保守型购物'
|
|
|
}],
|
|
|
|
|
|
// 着装习惯
|
|
|
dressHabits: [{
|
...
|
...
|
@@ -92,48 +93,50 @@ const configData = { |
|
|
value: '1',
|
|
|
text: '正装'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-2',
|
|
|
value: '2',
|
|
|
text: '商务'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-3',
|
|
|
value: '3',
|
|
|
text: '街头流行'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-4',
|
|
|
value: '4',
|
|
|
text: '运动休闲'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-5',
|
|
|
value: '5',
|
|
|
text: '文艺气质'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-6',
|
|
|
value: '6',
|
|
|
text: '甜美可爱'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-7',
|
|
|
value: '7',
|
|
|
text: '另类'
|
|
|
}]
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-2',
|
|
|
value: '2',
|
|
|
text: '商务'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-3',
|
|
|
value: '3',
|
|
|
text: '街头流行'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-4',
|
|
|
value: '4',
|
|
|
text: '运动休闲'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-5',
|
|
|
value: '5',
|
|
|
text: '文艺气质'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-6',
|
|
|
value: '6',
|
|
|
text: '甜美可爱'
|
|
|
},
|
|
|
{
|
|
|
type: 'checkbox',
|
|
|
key: 'dress[]',
|
|
|
index: 'dress-7',
|
|
|
value: '7',
|
|
|
text: '另类'
|
|
|
}],
|
|
|
headDefaultImgIcon: '//img10.static.yhbimg.com/headimg/' +
|
|
|
'2013/11/28/09/01cae078abe5fe320c88cdf4c220212688.gif?imageView/2/w/100/h/100'
|
|
|
};
|
|
|
|
|
|
const getDays = (year, month) => {
|
...
|
...
|
@@ -260,6 +263,9 @@ const getUserInfo = (channel, uid) => { |
|
|
|
|
|
userInfo = result[1].data || {};
|
|
|
|
|
|
finalResult.userThumb = userInfo.head_ico === '' ?
|
|
|
configData.headDefaultImgIcon : Images.getImageUrl(userInfo.head_ico, 100, 100, 2);
|
|
|
|
|
|
if (userInfo) {
|
|
|
gender = userInfo.gender || 3;
|
|
|
birthday = userInfo.birthday || '';
|
...
|
...
|
@@ -477,6 +483,21 @@ const getUserInfo = (channel, uid) => { |
|
|
});
|
|
|
};
|
|
|
|
|
|
const editUserInfo = (req, uid) => {
|
|
|
console.info(req.body);
|
|
|
console.info(req.body.nickname);
|
|
|
console.info(req.body.username);
|
|
|
console.info(req.body.gender);
|
|
|
console.info(req.body.year);
|
|
|
console.info(req.body.month);
|
|
|
console.info(req.body.day);
|
|
|
console.info(req.body.profession);
|
|
|
console.info(req.body.income);
|
|
|
|
|
|
return '';
|
|
|
};
|
|
|
|
|
|
module.exports = {
|
|
|
getUserInfo
|
|
|
getUserInfo,
|
|
|
editUserInfo
|
|
|
}; |
...
|
...
|
|