Commit 59e8e9ca by doszhang

dos

parent 742b9a0a
...@@ -65,6 +65,8 @@ let noInfo = { ...@@ -65,6 +65,8 @@ let noInfo = {
height: 12 height: 12
} }
let createPosterLock = false;
preloadimages(preloadImageList, function () { preloadimages(preloadImageList, function () {
$('.page1').show(); $('.page1').show();
$('input[name=name]').attr('placeholder', '姓名').attr('id', 'name');; $('input[name=name]').attr('placeholder', '姓名').attr('id', 'name');;
...@@ -131,26 +133,32 @@ function backToHome() { ...@@ -131,26 +133,32 @@ function backToHome() {
} }
function checkInfo() { function checkInfo() {
let name = $('input[name=name]').val(); if (!createPosterLock) {
let business = $('input[name=business]').val(); createPosterLock = true;
// name = '张三三'; let name = $('input[name=name]').val();
// business = '1234567890'; let business = $('input[name=business]').val();
if (name.match(/^\s*$/)) { // name = '张三三';
$('#notification_area').remove(); // business = '1234567890';
my_notify('请填写姓名'); if (name.match(/^\s*$/)) {
return false; $('#notification_area').remove();
} my_notify('请填写姓名');
if (!business.match(/^\d{10}$/)) { createPosterLock = false;
$('#notification_area').remove(); return false;
my_notify('业务号填写有误'); }
return false; if (!business.match(/^\d{10}$/)) {
} $('#notification_area').remove();
if ($('input[name=btn-upload]').val() == '') { my_notify('业务号填写有误');
$('#notification_area').remove(); createPosterLock = false;
my_notify('请上传头像'); return false;
return false; }
if ($('input[name=btn-upload]').val() == '') {
$('#notification_area').remove();
my_notify('请上传头像');
createPosterLock = false;
return false;
}
createPoster(name, business);
} }
createPoster(name, business);
} }
function createPoster(name, business) { function createPoster(name, business) {
...@@ -191,6 +199,7 @@ function createPoster(name, business) { ...@@ -191,6 +199,7 @@ function createPoster(name, business) {
$('.page1').hide(); $('.page1').hide();
$('.poster-page').show(); $('.poster-page').show();
$('#notification_area').remove(); $('#notification_area').remove();
createPosterLock = false;
}, 500); }, 500);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment