...
|
...
|
@@ -15,6 +15,7 @@ var phoneReg = /^(13[0-9]|15[012356789]|17[678]|18[0-9]|14[57])[0-9]{8}$/; |
|
|
var validate = require('./order/validation');
|
|
|
|
|
|
var imgBoxTpl = require('../../tpl/me/thumbnail.hbs');
|
|
|
var changeTypeTpl = require('../../tpl/me/change-type.hbs');
|
|
|
|
|
|
var validateMap = {
|
|
|
user: {
|
...
|
...
|
@@ -462,13 +463,33 @@ function bindKeyUpEvent() { |
|
|
});
|
|
|
}
|
|
|
|
|
|
function getChangeType(areaCode) {
|
|
|
$.ajax({
|
|
|
url: '/me/return/getChangeType',
|
|
|
data: {
|
|
|
areaCode: areaCode
|
|
|
}
|
|
|
}).done(function(result) {
|
|
|
var changeTypeHtml = changeTypeTpl({
|
|
|
type: result.data
|
|
|
});
|
|
|
|
|
|
if (changeTypeHtml.length) {
|
|
|
$('.change-type .box-title').after(changeTypeHtml);
|
|
|
bindTypeEvent();
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
|
|
|
$(document).on('ready', function() {
|
|
|
var areaCode = $('#city').data('code');
|
|
|
|
|
|
getProductInfo();
|
|
|
getChangeType(areaCode);
|
|
|
initAddr(areaCode);
|
|
|
bindSelectEvent();
|
|
|
bindTypeEvent();
|
|
|
bindCheckboxEvent();
|
|
|
bindConfirmEvent();
|
|
|
initAddr($('#city').data('code'));
|
|
|
bindBlurEvent();
|
|
|
bindUploadEvent();
|
|
|
bindKeyUpEvent();
|
...
|
...
|
|