...
|
...
|
@@ -78,14 +78,13 @@ function isValidate(rules, datas) { |
|
|
message = rule.name + '不可为空';
|
|
|
break;
|
|
|
}
|
|
|
|
|
|
// if (rule.regex) {
|
|
|
// reg = $.trim(data).match(rule.regex);
|
|
|
// if (!reg || (reg && !reg.length)) {
|
|
|
// message = rule.msg;
|
|
|
// break;
|
|
|
// }
|
|
|
// }
|
|
|
if (rule.regex) {
|
|
|
reg = $.trim(data).match(rule.regex);
|
|
|
if (!reg || (reg && !reg.length)) {
|
|
|
message = rule.msg;
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
if (rule.is !== void (0) && data !== rule.is) {
|
|
|
message = rule.msg;
|
|
|
}
|
...
|
...
|
@@ -232,10 +231,10 @@ Filter.prototype = { |
|
|
var html = [],
|
|
|
name;
|
|
|
|
|
|
// if (this.__select__ && this.__title__ && this.__select__[this.__feild__]) {
|
|
|
// html.push('<h6 class=\'s-title\'>当前地区</h6>');
|
|
|
// html.push('<div class=\'s-item close\'>' + this.__select__[this.__feild__] + '</div>');
|
|
|
// }
|
|
|
if (this.__select__ && this.__title__ && this.__select__[this.__feild__]) {
|
|
|
html.push('<h6 class=\'s-title\'>当前地区</h6>');
|
|
|
html.push('<div class=\'s-item close\'>' + this.__select__[this.__feild__] + '</div>');
|
|
|
}
|
|
|
|
|
|
for (name in data) {
|
|
|
if (data.hasOwnProperty(name)) {
|
...
|
...
|
@@ -274,13 +273,9 @@ Filter.prototype = { |
|
|
|
|
|
province = new Filter('[data-aslider=province]', '当前地区', 'addresseeName');
|
|
|
|
|
|
$.ajax({
|
|
|
url: '/activity/student/province',
|
|
|
cache: true,
|
|
|
success: function(res) {
|
|
|
province.set(res.data);
|
|
|
province.init();
|
|
|
}
|
|
|
$.get('/activity/student/province', function(res) {
|
|
|
province.set(res.data);
|
|
|
province.init();
|
|
|
});
|
|
|
|
|
|
$(document).on('keyup', '#s-search-provinces', function() {
|
...
|
...
|
@@ -367,13 +362,9 @@ window.JI_getselectvalue = function(type, value) { |
|
|
$('.s-blue').click(function() {
|
|
|
localStorage.setItem(STUDENTCOOKIES, JSON.stringify(changeSuccess().data));
|
|
|
});
|
|
|
$(function() {
|
|
|
try {
|
|
|
setFormByCookes(localStorage.getItem(STUDENTCOOKIES));
|
|
|
} catch (e) {
|
|
|
console.log(e);
|
|
|
}
|
|
|
});
|
|
|
setFormByCookes(localStorage.getItem(STUDENTCOOKIES));
|
|
|
|
|
|
|
|
|
|
|
|
// data-aslider-in="education|fade"
|
|
|
$(document).on('click', '#s-education .s-item', function() {
|
...
|
...
|
@@ -456,3 +447,8 @@ $(document).on('click', '.s-submit', function() { |
|
|
$('#tb-is-read').change(function() {
|
|
|
changeSuccess();
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
...
|
...
|
|