|
@@ -144,7 +144,13 @@ Ext.onReady(function () {
|
|
|
if (form.isValid()) {
|
|
|
var query = new Object();
|
|
|
query.name = Ext.getCmp('fa_name').getValue();
|
|
|
+ if(query.name == null || query.name == ""){
|
|
|
+ Ext.Msg.alert('系统提示', '姓名不能为空!');
|
|
|
+ }
|
|
|
query.phone = Ext.getCmp('fa_phone').getValue();
|
|
|
+ if(query.phone == null || query.phone == ""){
|
|
|
+ Ext.Msg.alert('系统提示', '手机号不能为空!');
|
|
|
+ }
|
|
|
query.Job_duties = Ext.getCmp('fa_Job_duties').getValue();
|
|
|
query.company_code = Ext.getCmp('fa_company_code').getValue();
|
|
|
var jsonstr = Ext.JSON.encode(query);
|
|
@@ -207,11 +213,9 @@ Ext.onReady(function () {
|
|
|
anchor: '75%',
|
|
|
listeners: {
|
|
|
change: function (o, e) {
|
|
|
- if (e.length > 10) {
|
|
|
- Ext.Msg.alert('提示', '姓名长度不可超过10个字!', function (btn, txt) {
|
|
|
- Ext.getCmp('ff_name').setValue('');
|
|
|
- });
|
|
|
- return false;
|
|
|
+ if (e.length > 20) {
|
|
|
+ Ext.getCmp('ff_name').setValue(e.substring(0, 20));
|
|
|
+ return;
|
|
|
}
|
|
|
}
|
|
|
}
|