Pārlūkot izejas kodu

更新202108251605

fanghuisheng 3 gadi atpakaļ
vecāks
revīzija
8b7afc75be

+ 399 - 349
WebRoot/opt/inspectors/scripts/inspectors.js

@@ -6,250 +6,300 @@
  */
 
 Ext.Loader.setConfig({
-    enabled: true
+	enabled: true
 });
 
 Ext.Loader.setPath('Ext.ux', '../../res/extjs/examples/ux');
 
 Ext.require([
-    'Ext.grid.*',
-    'Ext.data.*',
-    'Ext.ux.RowExpander',
-    'Ext.selection.CheckboxModel'
+	'Ext.grid.*',
+	'Ext.data.*',
+	'Ext.ux.RowExpander',
+	'Ext.selection.CheckboxModel'
 ]);
 
 var sm = Ext.create('Ext.selection.CheckboxModel');
 
-Ext.define('Inspectors',{
+Ext.define('Inspectors', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'name',  type:'string'},
-		{name:'phone',  type:'string'},
-		{name:'Job_duties',  type:'string'},
-		{name:'company_code',  type:'string'},
+		{ name: 'id', type: 'string' },
+		{ name: 'name', type: 'string' },
+		{ name: 'phone', type: 'string' },
+		{ name: 'Job_duties', type: 'string' },
+		{ name: 'company_code', type: 'string' },
 	]
 });
 
-Ext.onReady(function(){  
+Ext.onReady(function () {
 	var baseUrl = document.getElementById('basePath').value;
 	var theme = document.getElementById('theme').value;
-	var chkIcon = '<img src="'+baseUrl+'res/img/common/check.gif"/>'
-	var unchkIcon = '<img src="'+baseUrl+'res/img/common/uncheck.gif"/>'
+	var chkIcon = '<img src="' + baseUrl + 'res/img/common/check.gif"/>'
+	var unchkIcon = '<img src="' + baseUrl + 'res/img/common/uncheck.gif"/>'
 	var countPerPage = 20;
 	var maxHeight = 10000;
-	
-	var chkBoolean = function(flag) {
-		if(flag)
+
+	var chkBoolean = function (flag) {
+		if (flag)
 			return chkIcon;
 		return unchkIcon;
 	}
-	
 
-	var clear_append_form = function (){
+
+	var clear_append_form = function () {
 		Ext.getCmp('fa_name').setValue("");
 		Ext.getCmp('fa_phone').setValue("");
 		Ext.getCmp('fa_Job_duties').setValue("");
 		Ext.getCmp('fa_company_code').setValue("");
 		Ext.getCmp('InspectorsListPanel').getStore().reload();
 	}
-		
+
 	var myStore = Ext.create('Ext.data.Store', {
-	    model: 'Inspectors',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        url: baseUrl+'iot/inspectors/getList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        }
-	    },
-	    remoteSort: true
+		model: 'Inspectors',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			url: baseUrl + 'iot/inspectors/getList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			}
+		},
+		remoteSort: true
 	});
-	
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_phone').setValue('');
+				Ext.getCmp('ff_phone').setValue('');
+			});
+			return false;
+		}
+	}
+
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsAppendForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectors/append',
+		url: baseUrl + 'iot/inspectors/append',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'姓名',
+			fieldLabel: '姓名',
 			id: 'fa_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-			fieldLabel:'手机号',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '手机号',
 			id: 'fa_phone',
 			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			fieldLabel:'职务',
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			fieldLabel: '职务',
 			id: 'fa_Job_duties',
-			name:'Job_duties',
+			name: 'Job_duties',
 			maxLength: 30,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			fieldLabel:'单位编号',
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
 			id: 'fa_company_code',
-			name:'company_code',
+			name: 'company_code',
 			maxLength: 30,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			id:'fa_queryJson',
-			name:'queryJson',
-			hidden:true
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			id: 'fa_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	query.name = Ext.getCmp('fa_name').getValue();
-		        	query.phone = Ext.getCmp('fa_phone').getValue();
-		        	query.Job_duties = Ext.getCmp('fa_Job_duties').getValue();
-		        	query.company_code = Ext.getCmp('fa_company_code').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fa_queryJson').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-		                	   clear_append_form();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_append_form();
-		                   });
-		                }
-		            });
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					query.name = Ext.getCmp('fa_name').getValue();
+					query.phone = Ext.getCmp('fa_phone').getValue();
+					query.Job_duties = Ext.getCmp('fa_Job_duties').getValue();
+					query.company_code = Ext.getCmp('fa_company_code').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								clear_append_form();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_append_form();
+							});
+						}
+					});
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var appendwin = function(){
+
+	var appendwin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    width: 400,
-		    layout: 'fit',
-		    items:  AppendForm,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			width: 400,
+			layout: 'fit',
+			items: AppendForm,
+			closeAction: 'hide'
 		}).show();
 	}
-	
+
 	//筛选
-	var clear_filter_form = function(){
+	var clear_filter_form = function () {
 		Ext.getCmp('ff_name').setValue("");
 		Ext.getCmp('ff_phone').setValue("");
 		Ext.getCmp('ff_Job_duties').setValue("");
 		Ext.getCmp('ff_company_code').setValue("");
 	}
-	
+
 	var FilterWin = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsFilterForm',
 		labelWidth: 55,
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'姓名',
+			fieldLabel: '姓名',
 			id: 'ff_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('name').value,
-			anchor:'75%'
-		},{
-			fieldLabel:'手机号',
-			id:'ff_phone',
-			name:'phone',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('name').value,
+			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;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '手机号',
+			id: 'ff_phone',
+			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-	        value : document.getElementById('phone').value,
-	        editable : false 
-		},{
-			fieldLabel:'职务',
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('phone').value,
+			editable: false,
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('ff_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			fieldLabel: '职务',
 			id: 'ff_Job_duties',
 			name: 'Job_duties',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('Job_duties').value,
-			anchor:'95%'
-		},{
-			fieldLabel:'单位编号',
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('Job_duties').value,
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
 			id: 'ff_company_code',
 			name: 'company_code',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('company_code').value,
-			anchor:'95%'
-		},{
-			id:'ff_queryJson',
-			name:'queryJson',
-			hidden:true
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('company_code').value,
+			anchor: '95%'
+		}, {
+			id: 'ff_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	if(Ext.getCmp('ff_name').getValue().length>0)
-		        		query.name = Ext.getCmp('ff_name').getValue();
-		        	if(Ext.getCmp('ff_phone').getValue().length>0)
-		        		query.phone = Ext.getCmp('ff_phone').getValue();	        	
-		        	if(Ext.getCmp('ff_Job_duties').getValue().length>0)
-		        		query.Job_duties = Ext.getCmp('ff_Job_duties').getValue();
-		        		if(Ext.getCmp('ff_company_code').getValue().length>0)
-			        		query.company_code = Ext.getCmp('ff_company_code').getValue();
-		        	
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	myStore.getProxy().extraParams = {
-		        		queryJson : jsonstr
-		        	};	
-		        	Ext.getCmp('InspectorsListPageToolbar').moveFirst();
-		        	Ext.getCmp('name').setValue(query.name);
-		        	Ext.getCmp('phone').setValue(query.phone);
-		        	Ext.getCmp('Job_duties').setValue(query.Job_duties);
-		        	Ext.getCmp('company_code').setValue(query.company_code);
-//		        	myStore.reload();
-		        	clear_filter_form();
-		        	this.up('window').hide();
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					if (Ext.getCmp('ff_name').getValue().length > 0)
+						query.name = Ext.getCmp('ff_name').getValue();
+					if (Ext.getCmp('ff_phone').getValue().length > 0)
+						query.phone = Ext.getCmp('ff_phone').getValue();
+					if (Ext.getCmp('ff_Job_duties').getValue().length > 0)
+						query.Job_duties = Ext.getCmp('ff_Job_duties').getValue();
+					if (Ext.getCmp('ff_company_code').getValue().length > 0)
+						query.company_code = Ext.getCmp('ff_company_code').getValue();
+
+					var jsonstr = Ext.JSON.encode(query);
+					myStore.getProxy().extraParams = {
+						queryJson: jsonstr
+					};
+					Ext.getCmp('InspectorsListPageToolbar').moveFirst();
+					Ext.getCmp('name').setValue(query.name);
+					Ext.getCmp('phone').setValue(query.phone);
+					Ext.getCmp('Job_duties').setValue(query.Job_duties);
+					Ext.getCmp('company_code').setValue(query.company_code);
+					//		        	myStore.reload();
+					clear_filter_form();
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
 
-	
-	
-	
-	var filterwin = function() {
-		Ext.create('Ext.window.Window',{
+
+
+
+	var filterwin = function () {
+		Ext.create('Ext.window.Window', {
 			title: '筛选',
 			height: 300,
 			width: 350,
@@ -258,8 +308,8 @@ Ext.onReady(function(){
 			closeAction: 'hide'
 		}).show();
 	}
-	
-	var clear_modify_form = function (){
+
+	var clear_modify_form = function () {
 		Ext.getCmp('fm_id').setValue("");
 		Ext.getCmp('fm_name').setValue("");
 		Ext.getCmp('fm_phone').setValue("");
@@ -267,228 +317,228 @@ Ext.onReady(function(){
 		Ext.getCmp('fm_company_code').setValue("");
 		Ext.getCmp('InspectorsListPanel').getStore().reload();
 	}
-	
-	
-	
+
+
+
 	var ModifyForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsEditForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectors/update',
+		url: baseUrl + 'iot/inspectors/update',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-				fieldLabel:'姓名',
-				id: 'fm_name',
-				name:'name',
-				maxLength:20,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
-			},{
-				fieldLabel:'手机号',
-				id: 'fm_phone',
-				name: 'phone',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
-				fieldLabel:'职务',
-				id: 'fm_Job_duties',
-				name: 'Job_duties',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
-				fieldLabel:'单位编号',
-				id: 'fm_company_code',
-				name: 'company_code',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
+			fieldLabel: '姓名',
+			id: 'fm_name',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%'
+		}, {
+			fieldLabel: '手机号',
+			id: 'fm_phone',
+			name: 'phone',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '职务',
+			id: 'fm_Job_duties',
+			name: 'Job_duties',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
+			id: 'fm_company_code',
+			name: 'company_code',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
 			id: 'fm_id',
-			name:'id',
-			hidden:true
-		},{
-			id:'fm_queryJson',
-			name:'queryJson',
-			hidden:true
+			name: 'id',
+			hidden: true
+		}, {
+			id: 'fm_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '修改',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		    	var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	query.id = Ext.getCmp('fm_id').getValue();
-		        	query.name = Ext.getCmp('fm_name').getValue();
-		        	query.phone = Ext.getCmp('fm_phone').getValue();
-		        	query.Job_duties = Ext.getCmp('fm_Job_duties').getValue();
-		        	query.company_code = Ext.getCmp('fm_company_code').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fm_queryJson').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                }
-		            });
-		            this.up('window').hide();
-		        }
-		    }
-		},{
+			text: '修改',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					query.id = Ext.getCmp('fm_id').getValue();
+					query.name = Ext.getCmp('fm_name').getValue();
+					query.phone = Ext.getCmp('fm_phone').getValue();
+					query.Job_duties = Ext.getCmp('fm_Job_duties').getValue();
+					query.company_code = Ext.getCmp('fm_company_code').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fm_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+								clear_modify_form();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_modify_form();
+							});
+						}
+					});
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var modifywin = function(){
+
+	var modifywin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '修改',
-		    height: 350,
-		    width: 400,
-		    layout: 'fit',
-		    items:  ModifyForm,
-		    closeAction: 'hide'
+			title: '修改',
+			height: 350,
+			width: 400,
+			layout: 'fit',
+			items: ModifyForm,
+			closeAction: 'hide'
 		}).show();
 	}
-		
-	var chk_sm = function() {
-		if(sm.getCount()==1){
+
+	var chk_sm = function () {
+		if (sm.getCount() == 1) {
 			modifywin();
-			var selected = sm.getSelection( );
+			var selected = sm.getSelection();
 			Ext.getCmp('fm_id').setValue(selected[0].raw.id);
 			Ext.getCmp('fm_name').setValue(selected[0].raw.name);
 			Ext.getCmp('fm_phone').setValue(selected[0].raw.phone);
 			Ext.getCmp('fm_Job_duties').setValue(selected[0].raw.Job_duties);
 			Ext.getCmp('fm_company_code').setValue(selected[0].raw.company_code);
-		}else{
-			Ext.Msg.alert('请先选择','请先选择一条记录,再点击修改');
+		} else {
+			Ext.Msg.alert('请先选择', '请先选择一条记录,再点击修改');
 		}
 	}
-	
-//	
-//	var deletewin = function() {
-//		window.alert("无此功能");
-//		
-//	}
-	
+
+	//	
+	//	var deletewin = function() {
+	//		window.alert("无此功能");
+	//		
+	//	}
+
 	Ext.create('Ext.grid.Panel', {
-	    title: '巡检人管理',
-	    id: 'InspectorsListPanel',
-	    store: myStore,
-	    selModel: sm,
-	    columns: [
-	    	 //{ header: 'ID',  dataIndex: 'UQ_POINT_ID',hidden:true, menuDisabled:true },
-		     { header: 'ID',  dataIndex: 'id', width:40, menuDisabled:true },
-		     { header: '姓名', dataIndex: 'name', width:120,align:'center', menuDisabled:true },
-		     { header: '手机号', dataIndex: 'phone', width:160,align:'center', menuDisabled:true },
-		     { header: '职务', dataIndex: 'Job_duties', width:120,align:'center', menuDisabled:true },
-		     { header: '单位编号', dataIndex: 'company_code', width:120,align:'center', menuDisabled:true },
-//		     { header: '记录版本', dataIndex: 'I_VERSION', width:120, align:'center', menuDisabled:true },
-//		     { 
-//	        	xtype : 'actioncolumn',
-//	        	width:20,
-//	        	sortable:false,
-//	        	
-//	        	
-//	        	//这里
-//	        	align:'center',
-//	        	menuDisabled:true,
-//	        	items:[{
-//	        		icon: '../../res/img/common/forum.gif',
-//	        		tooltip: '版本记录',
-//	        		handler: function(grid, rowIndex, colIndex) {
-//	                    var rec = grid.getStore().getAt(rowIndex);
-//	        			window.location = 'version.jsp?theme='+theme+'&pointId='+rec.get('UQ_POINT_ID');
-//	                }
-//	        	}]
-//    		}
-	    ],
-	    columnLines: true,
-	    tbar: [
-	    	{
-				  xtype: 'button', 
-				  iconCls:'filter_btn',  
-				  text: '筛选',
-				  listeners: {
-				        click: filterwin
-				  }
-	    	},'-',
-	    	{xtype: 'tbfill'},'-',
-			{ 
-				  xtype: 'button', 
-				  iconCls:'append_btn',  
-				  text: '新增',
-				  listeners: {
-				        click: appendwin
-				  }
+		title: '巡检人管理',
+		id: 'InspectorsListPanel',
+		store: myStore,
+		selModel: sm,
+		columns: [
+			//{ header: 'ID',  dataIndex: 'UQ_POINT_ID',hidden:true, menuDisabled:true },
+			{ header: 'ID', dataIndex: 'id', width: 40, menuDisabled: true },
+			{ header: '姓名', dataIndex: 'name', width: 120, align: 'center', menuDisabled: true },
+			{ header: '手机号', dataIndex: 'phone', width: 160, align: 'center', menuDisabled: true },
+			{ header: '职务', dataIndex: 'Job_duties', width: 120, align: 'center', menuDisabled: true },
+			{ header: '单位编号', dataIndex: 'company_code', width: 120, align: 'center', menuDisabled: true },
+			//		     { header: '记录版本', dataIndex: 'I_VERSION', width:120, align:'center', menuDisabled:true },
+			//		     { 
+			//	        	xtype : 'actioncolumn',
+			//	        	width:20,
+			//	        	sortable:false,
+			//	        	
+			//	        	
+			//	        	//这里
+			//	        	align:'center',
+			//	        	menuDisabled:true,
+			//	        	items:[{
+			//	        		icon: '../../res/img/common/forum.gif',
+			//	        		tooltip: '版本记录',
+			//	        		handler: function(grid, rowIndex, colIndex) {
+			//	                    var rec = grid.getStore().getAt(rowIndex);
+			//	        			window.location = 'version.jsp?theme='+theme+'&pointId='+rec.get('UQ_POINT_ID');
+			//	                }
+			//	        	}]
+			//    		}
+		],
+		columnLines: true,
+		tbar: [
+			{
+				xtype: 'button',
+				iconCls: 'filter_btn',
+				text: '筛选',
+				listeners: {
+					click: filterwin
+				}
+			}, '-',
+			{ xtype: 'tbfill' }, '-',
+			{
+				xtype: 'button',
+				iconCls: 'append_btn',
+				text: '新增',
+				listeners: {
+					click: appendwin
+				}
 			},
-			{ 
-				xtype: 'button', 
-				iconCls:'modify_btn', 
+			{
+				xtype: 'button',
+				iconCls: 'modify_btn',
 				text: '修改',
 				listeners: {
 					click: chk_sm
 				}
 			},
-//			{ 
-//				xtype: 'button',
-//				iconCls:'delete_btn',
-//				text: '注销',
-//				listeners: {
-//					click: deletewin
-//				}
-//			}
-//			,{ 
-//				xtype: 'button',
-//				iconCls:'delete_btn',
-//				text: '导出',
-//				listeners: {
-//					click: export_sj
-//				}
-//			}
-			
-    	],
-	    height: maxHeight,
-	    width: '100%',
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore,  
-            id:'InspectorsListPageToolbar',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-//            doRefresh:function(start){  
-//            	alert(start);
-//                relushDataFunction(start); // 调用函数刷新数据  
-//                this.cursor = start; // 更新页签  
-//            }
+			//			{ 
+			//				xtype: 'button',
+			//				iconCls:'delete_btn',
+			//				text: '注销',
+			//				listeners: {
+			//					click: deletewin
+			//				}
+			//			}
+			//			,{ 
+			//				xtype: 'button',
+			//				iconCls:'delete_btn',
+			//				text: '导出',
+			//				listeners: {
+			//					click: export_sj
+			//				}
+			//			}
+
+		],
+		height: maxHeight,
+		width: '100%',
+		bbar: new Ext.PagingToolbar({
+			store: myStore,
+			id: 'InspectorsListPageToolbar',
+			displayInfo: true,
+			pageSize: countPerPage,
+			prependButtons: true,
+			displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+			emptyMsg: "没有记录",
+			firstText: '第一页',
+			prevText: '前一页',
+			nextText: '后一页',
+			lastText: '最后一页',
+			refreshText: '刷新',
+			//            doRefresh:function(start){  
+			//            	alert(start);
+			//                relushDataFunction(start); // 调用函数刷新数据  
+			//                this.cursor = start; // 更新页签  
+			//            }
 
-        }),
-        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid',
-	    renderTo: Ext.getBody()
+		}),
+		frame: true,
+		border: false,
+		iconCls: 'icon-grid',
+		renderTo: Ext.getBody()
 	});
 	myStore.reload();
-	maxHeight =  document.documentElement.clientHeight;
+	maxHeight = document.documentElement.clientHeight;
 	Ext.getCmp('InspectorsListPanel').setHeight(maxHeight);
-	
+
 });

+ 54 - 4
WebRoot/view/companyxx/scripts/companyxx.js

@@ -186,6 +186,16 @@ Ext.onReady(function(){
 		Ext.getCmp('fa_sbtype').setValue("");
 		Ext.getCmp('PatrolPlanListPageToolbar').getStore().reload();
 	}
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_bjhm').setValue('');
+				Ext.getCmp('fm_bjhm').setValue('');
+			});
+			return false;
+		}
+	}
 	
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'companyxxAppendForm1',
@@ -206,14 +216,34 @@ Ext.onReady(function(){
 			name:'name',
 			maxLength:20,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '责任人姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
 		},{
 			fieldLabel:'责任人手机号',
 			id: 'fa_bjhm',
 			name:'bjhm',
 			maxLength:20,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_bjhm').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
 		},{
 			fieldLabel:'显号',
 			id:'fa_bjxh',
@@ -768,14 +798,34 @@ Ext.onReady(function(){
 					name:'name',
 					maxLength:20,
 					maxLengthText:'长度不得超出{0}',
-					anchor:'75%'
+					anchor:'75%',
+					listeners: {
+						change: function (o, e) {
+							if (e.length > 10) {
+								Ext.Msg.alert('提示', '责任人姓名长度不可超过10个字!', function (btn, txt) {
+									Ext.getCmp('fm_name').setValue('');
+								});
+								return false;
+							}
+						}
+					}
 				},{
 					fieldLabel:'责任人手机号',
 					id: 'fm_bjhm',
 					name:'bjhm',
 					maxLength:20,
 					maxLengthText:'长度不得超出{0}',
-					anchor:'75%'
+					anchor:'75%',
+					listeners: {
+						change: function (o, e) {
+							if (e.length == 11) {
+								public_phone(e);
+							} else {
+								Ext.getCmp('fm_bjhm').setValue(e.substring(0, 11));
+								e.length == 11 ? public_phone(e) : ''
+							}
+						}
+					}
 				},{
 					fieldLabel:'显号',
 					id:'fm_bjxh',

+ 1431 - 1362
WebRoot/view/inspectors/scripts/inspectors.js

@@ -6,23 +6,23 @@
  */
 
 Ext.Loader.setConfig({
-    enabled: true
+	enabled: true
 });
 
 Ext.Loader.setPath('Ext.ux', '../../res/extjs/examples/ux');
 
 Ext.require([
-    'Ext.grid.*',
-    'Ext.data.*',
-    'Ext.ux.RowExpander',
-    'Ext.selection.CheckboxModel'
+	'Ext.grid.*',
+	'Ext.data.*',
+	'Ext.ux.RowExpander',
+	'Ext.selection.CheckboxModel'
 ]);
 
 var company_code;
-var myStore=null;
-var myStore1=null;
-var myStore2=null;
-var V_LOGINNAME='',V_PASSWORD='';
+var myStore = null;
+var myStore1 = null;
+var myStore2 = null;
+var V_LOGINNAME = '', V_PASSWORD = '';
 var menuidx = '';
 var mouseon;
 var mouseoff;
@@ -34,456 +34,495 @@ var panel2;
 var changeon1;
 
 var sm = Ext.create('Ext.selection.CheckboxModel');
-var addsm = Ext.create('Ext.selection.CheckboxModel',{
-	handleMouseDown : Ext.emptyFn,  
-    singleSelect : false 
+var addsm = Ext.create('Ext.selection.CheckboxModel', {
+	handleMouseDown: Ext.emptyFn,
+	singleSelect: false
 });
-var sm1 = Ext.create('Ext.selection.CheckboxModel',{
-	injectCheckbox:1,//checkbox位于哪一列,默认值为0
-	mode:'single',//multi,simple,single;默认为多选multi
-//	checkOnly:true,//如果值为true,则只用点击checkbox列才能选中此条记录
-	allowDeselect:true,//如果值true,并且mode值为单选(single)时,可以通过点击checkbox取消对其的选择
-	enableKeyNav:false,
+var sm1 = Ext.create('Ext.selection.CheckboxModel', {
+	injectCheckbox: 1,//checkbox位于哪一列,默认值为0
+	mode: 'single',//multi,simple,single;默认为多选multi
+	//	checkOnly:true,//如果值为true,则只用点击checkbox列才能选中此条记录
+	allowDeselect: true,//如果值true,并且mode值为单选(single)时,可以通过点击checkbox取消对其的选择
+	enableKeyNav: false,
 	listeners: {
-	 deselect: function(model,record,index) {//取消选中时产生的事件
-	 }
+		deselect: function (model, record, index) {//取消选中时产生的事件
+		}
 	}
 });
 
-Ext.define('MaintenancePerson',{
+Ext.define('MaintenancePerson', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'name',  type:'string'},
-		{name:'phone',  type:'string'},
-		{name:'zn_name',  type:'string'},
-		{name:'xh',  type:'int'},
+		{ name: 'id', type: 'string' },
+		{ name: 'name', type: 'string' },
+		{ name: 'phone', type: 'string' },
+		{ name: 'zn_name', type: 'string' },
+		{ name: 'xh', type: 'int' },
 	]
 });
-Ext.define('MaintenancePerson1',{
+Ext.define('MaintenancePerson1', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'rid',  type:'int'},
-		{name:'xh',  type:'int'},
-		{name:'name',  type:'string'},
-		{name:'tdid',  type:'string'},
-		{name:'pd',  type:'int'},
-//		{name:'zrr',  type:'string'},
+		{ name: 'rid', type: 'int' },
+		{ name: 'xh', type: 'int' },
+		{ name: 'name', type: 'string' },
+		{ name: 'tdid', type: 'string' },
+		{ name: 'pd', type: 'int' },
+		//		{name:'zrr',  type:'string'},
 	]
 });
 
-Ext.define('MaintenancePerson2',{
+Ext.define('MaintenancePerson2', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'xh',  type:'int'},
-		{name:'team_name',  type:'string'},
-		{name:'person_liable_id',  type:'string'},
-		
+		{ name: 'id', type: 'string' },
+		{ name: 'xh', type: 'int' },
+		{ name: 'team_name', type: 'string' },
+		{ name: 'person_liable_id', type: 'string' },
+
 	]
 });
 
-function exportbtn_click(){
+function exportbtn_click() {
 	baseUrl = document.getElementById('basePath').value;
 	V_LOGINNAME = $("#V_LOGINNAME").val();
 	V_PASSWORD = $("#V_PASSWORD").val();
 	name = document.getElementById('name').value;
 	zn = document.getElementById('zn').value;
-	
-//	zn_name = document.getElementById('zn_name').value;
+
+	//	zn_name = document.getElementById('zn_name').value;
 	var fields = '';
-	var array = ['id','xh','name','phone','zn_name'];
-	var excelname = ['ID','序号','姓名','手机号','职务'];
-	for(var i=0;i<5;i++){
-		if(i>0)
+	var array = ['id', 'xh', 'name', 'phone', 'zn_name'];
+	var excelname = ['ID', '序号', '姓名', '手机号', '职务'];
+	for (var i = 0; i < 5; i++) {
+		if (i > 0)
 			fields += ',';
-	    fields += '{id:"'+array[i]+'",title:"'+excelname[i]+'",shown:"'+true+'"}';
+		fields += '{id:"' + array[i] + '",title:"' + excelname[i] + '",shown:"' + true + '"}';
 	}
-			var query = new Object();
-			// query.V_LOGINNAME = V_LOGINNAME;
-			// query.V_PASSWORD = V_PASSWORD;
-			query.name = name;
-			query.zn = zn;
-			query.EXPORT_FILE = '维保人列表';
-			query.fields = '['+fields+']';
-			$.ajax({
-		        type:'POST',
-		        url: baseUrl+"iot/excel/view/XjInspectorsExcel",
-		        data: {
-		        	queryJson : Ext.JSON.encode(query)
-		    	 },
-		    	 success: function(result){
-		    		
-			            var json = eval('(' + result + ')');
-			            if(json.action=='dormExport'){
-			                ConfirmStore = json.RESULT;
-			               
-			                var elemIF = document.createElement("iframe");
-							elemIF.src = baseUrl+json.filename;
-							elemIF.style.display = "none"; 
-							document.body.appendChild(elemIF);
-			            }
-			    
-			        }
-		    });
-			
+	var query = new Object();
+	// query.V_LOGINNAME = V_LOGINNAME;
+	// query.V_PASSWORD = V_PASSWORD;
+	query.name = name;
+	query.zn = zn;
+	query.EXPORT_FILE = '维保人列表';
+	query.fields = '[' + fields + ']';
+	$.ajax({
+		type: 'POST',
+		url: baseUrl + "iot/excel/view/XjInspectorsExcel",
+		data: {
+			queryJson: Ext.JSON.encode(query)
+		},
+		success: function (result) {
+
+			var json = eval('(' + result + ')');
+			if (json.action == 'dormExport') {
+				ConfirmStore = json.RESULT;
+
+				var elemIF = document.createElement("iframe");
+				elemIF.src = baseUrl + json.filename;
+				elemIF.style.display = "none";
+				document.body.appendChild(elemIF);
+			}
+
+		}
+	});
+
 }
 
-var body_resize = function(){
-	maxHeight =  document.documentElement.clientHeight;
-	maxHeight-=34;
+var body_resize = function () {
+	maxHeight = document.documentElement.clientHeight;
+	maxHeight -= 34;
 	maxWidth = document.documentElement.clientWidth;
 	Ext.getCmp('InspectorsPiebar').setHeight(maxHeight);
 	Ext.getCmp('InspectorsPiebar').setWidth(maxWidth);
 }
-var body_resize1 = function(){
-	maxHeight =  document.documentElement.clientHeight;
-	maxHeight-=34;
+var body_resize1 = function () {
+	maxHeight = document.documentElement.clientHeight;
+	maxHeight -= 34;
 	maxWidth = document.documentElement.clientWidth;
 	Ext.getCmp('InspectorsPiebar2').setHeight(maxHeight);
 	Ext.getCmp('InspectorsPiebar2').setWidth(maxWidth);
 }
 
-Ext.onReady(function(){  
+Ext.onReady(function () {
 	var baseUrl = document.getElementById('basePath').value;
 	var theme = document.getElementById('theme').value;
-	var chkIcon = '<img src="'+baseUrl+'res/img/common/check.gif"/>'
-	var unchkIcon = '<img src="'+baseUrl+'res/img/common/uncheck.gif"/>'
+	var chkIcon = '<img src="' + baseUrl + 'res/img/common/check.gif"/>'
+	var unchkIcon = '<img src="' + baseUrl + 'res/img/common/uncheck.gif"/>'
 	$("#V_LOGINNAME").val(sessionStorage.getItem('V_LOGINNAME'));
 	$("#V_PASSWORD").val(sessionStorage.getItem('V_PASSWORD'));
 	V_LOGINNAME = $("#V_LOGINNAME").val();
-    V_PASSWORD = $("#V_PASSWORD").val();
+	V_PASSWORD = $("#V_PASSWORD").val();
 	var countPerPage = 15;
 	var maxHeight = 10000;
-	
-	var chkBoolean = function(flag) {
-		if(flag)
+
+	var chkBoolean = function (flag) {
+		if (flag)
 			return chkIcon;
 		return unchkIcon;
 	}
-	
+
 	var queryJson = new Object();
 	queryJson.V_LOGINNAME = V_LOGINNAME;
 	// queryJson.V_PASSWORD =  V_PASSWORD;
-//	queryJson.COMMSTATUS = 'NO';
-	if((company_code!=null)&&(company_code!='null')&&(company_code.length>0))
+	//	queryJson.COMMSTATUS = 'NO';
+	if ((company_code != null) && (company_code != 'null') && (company_code.length > 0))
 		queryJson.company_code = company_code;
-	
-	var clear_append_form1 = function (){
+
+	var clear_append_form1 = function () {
 		Ext.getCmp('fa_Inspectors_team_name').setValue("");
 		Ext.getCmp('fa_Inspectors_person_liable_id').setValue("");
 		Ext.getCmp('InspectorsListPageToolbar2').moveFirst();
 	}
-	
+
 	myStore = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-	    remoteSort: true
+		model: 'MaintenancePerson',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		remoteSort: true
 	});
-	
+
 	myStore2 = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson2',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/planteam/getList1',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-	    remoteSort: true
+		model: 'MaintenancePerson2',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/planteam/getList1',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		remoteSort: true
 	});
-	
-	var mystore2_fun = function(id){
-		  if(id== 0){
-		   myStore2.on('load',function(myStore2, record){
-		    for (var i = 0; i < record.length; i++) { 
-		     var records = record[i]; 
-		     if (records.get('xh') == 1) {
-		      Ext.getCmp('InspectorsListPanel2').getSelectionModel().select(records, true);
-		     }
-		    };
-		      });
-		  }else{
-		   myStore2.reload();
-		   myStore2.on('load',function(myStore2, record){
-		    for (var i = 0; i < record.length; i++) { 
-		     var records = record[i]; 
-		     if (records.get('id') == id) {
-		      Ext.getCmp('InspectorsListPanel2').getSelectionModel().select(records, true);
-		     }
-		    };
-		      });
-		  }
-		 }
-	
+
+	var mystore2_fun = function (id) {
+		if (id == 0) {
+			myStore2.on('load', function (myStore2, record) {
+				for (var i = 0; i < record.length; i++) {
+					var records = record[i];
+					if (records.get('xh') == 1) {
+						Ext.getCmp('InspectorsListPanel2').getSelectionModel().select(records, true);
+					}
+				};
+			});
+		} else {
+			myStore2.reload();
+			myStore2.on('load', function (myStore2, record) {
+				for (var i = 0; i < record.length; i++) {
+					var records = record[i];
+					if (records.get('id') == id) {
+						Ext.getCmp('InspectorsListPanel2').getSelectionModel().select(records, true);
+					}
+				};
+			});
+		}
+	}
+
 	myStore1 = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson1',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getTeamMembersListxj',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-	    remoteSort: true
+		model: 'MaintenancePerson1',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getTeamMembersListxj',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		remoteSort: true
 	});
-	
-	myStore1.on('load',function(myStore1, record){
-		for (var i = 0; i < record.length; i++) { 
-		    var records = record[i]; 
-		    if (records.get('pd') == 1) {
-		     Ext.getCmp('InspectorsListPanel3').getSelectionModel().select(records, true);
-		     }
-		   };
+
+	myStore1.on('load', function (myStore1, record) {
+		for (var i = 0; i < record.length; i++) {
+			var records = record[i];
+			if (records.get('pd') == 1) {
+				Ext.getCmp('InspectorsListPanel3').getSelectionModel().select(records, true);
+			}
+		};
 	});
-	
-	
-	Ext.define('getJobDutiesStore1',{
-		extend:'Ext.data.Model',
+
+
+	Ext.define('getJobDutiesStore1', {
+		extend: 'Ext.data.Model',
 		fields: [
-			{name:'name',  type:'string'},
-			{name:'rid',type:'int'}
+			{ name: 'name', type: 'string' },
+			{ name: 'rid', type: 'int' }
 		]
 	});
 
-	var getJobDutiesStore1 = Ext.create('Ext.data.Store',{
+	var getJobDutiesStore1 = Ext.create('Ext.data.Store', {
 		model: 'getJobDutiesStore1',
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getTeamMembersList1xj',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    }
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getTeamMembersList1xj',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		}
 	});
-	
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_Inspectors_phone').setValue('');
+			});
+			return false;
+		}
+	}
+
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsAppendForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectorsx/append',
+		url: baseUrl + 'iot/inspectorsx/append',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'人员姓名',
+			fieldLabel: '人员姓名',
 			id: 'fa_Inspectors_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
 			listeners: {
-				select: function(o,e){
-					console.log(o,e)
-					// value.replace(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/,'')
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_Inspectors_name').setValue('');
+						});
+						return false;
+					}
 				}
 			}
-		},{
-			fieldLabel:'电话号码',
+		}, {
+			fieldLabel: '电话号码',
 			id: 'fa_Inspectors_phone',
 			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-		   xtype: 'checkboxgroup',
-           fieldLabel: '人员职能',
-           id:"fa_Inspectors_inspectiontime",
-           columns: 3,
-           items: [
-              {boxLabel: '维保', name: 'maintenance',inputValue:"1"},
-              {boxLabel: '巡检', name: 'inspection',inputValue:"2"},
-              {boxLabel: '报修', name: 'event_processing',inputValue:"4"}
-            
-       ]},{
-    	   id:'fa_Inspectors_queryJson',
-    	   name:'queryJson',
-    	   hidden:true
-       }],
-       buttons: [{
-        text: '提交',
-        iconCls:'ok_btn',
-        handler: function() {
-        	var form = this.up('form').getForm();
-        	if (form.isValid()) {
-        		var InspectiontimeValue = Ext.getCmp('fa_Inspectors_inspectiontime').getChecked();
-        		var Inspectiontime=0;
-        		Ext.Array.each(InspectiontimeValue, function(item){
-        			Inspectiontime +=parseInt(item.inputValue);
-          });
-        		var query = new Object();
-        		// query.V_LOGINNAME = V_LOGINNAME;
-        		query.zn=Inspectiontime;
-        		query.name = Ext.getCmp('fa_Inspectors_name').getValue();
-        		query.phone = Ext.getCmp('fa_Inspectors_phone').getValue();
-          var jsonstr = Ext.JSON.encode(query);
-          Ext.getCmp('fa_Inspectors_queryJson').setValue(jsonstr);
-             form.submit({
-              method:'post',
-                 success: function(form, action) {
-                    Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-                     Ext.getCmp('InspectorsAppendForm').getForm().reset();
-                 	 Ext.getCmp('InspectorsListPageToolbar').moveFirst();
-                    });
-                 },
-                 failure: function(form, action) {
-                    Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-              
-                    });
-                 }
-             });
-         }
-     }
- },{
-  text: '关闭',
-  iconCls: 'cancel_btn',
-  handler: function() {
-   this.up('window').hide();
-  }
- }]
-});
-	
-	var appendwin = function(){
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_Inspectors_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			xtype: 'checkboxgroup',
+			fieldLabel: '人员职能',
+			id: "fa_Inspectors_inspectiontime",
+			columns: 3,
+			items: [
+				{ boxLabel: '维保', name: 'maintenance', inputValue: "1" },
+				{ boxLabel: '巡检', name: 'inspection', inputValue: "2" },
+				{ boxLabel: '报修', name: 'event_processing', inputValue: "4" }
+
+			]
+		}, {
+			id: 'fa_Inspectors_queryJson',
+			name: 'queryJson',
+			hidden: true
+		}],
+		buttons: [{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var InspectiontimeValue = Ext.getCmp('fa_Inspectors_inspectiontime').getChecked();
+					var Inspectiontime = 0;
+					Ext.Array.each(InspectiontimeValue, function (item) {
+						Inspectiontime += parseInt(item.inputValue);
+					});
+					var query = new Object();
+					// query.V_LOGINNAME = V_LOGINNAME;
+					query.name = Ext.getCmp('fa_Inspectors_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
+					query.phone = Ext.getCmp('fa_Inspectors_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					}else if (query.phone.length < 11){
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if(query.zn == 0){
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_Inspectors_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								Ext.getCmp('InspectorsAppendForm').getForm().reset();
+								Ext.getCmp('InspectorsListPageToolbar').moveFirst();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+
+							});
+						}
+					});
+				}
+			}
+		}, {
+			text: '关闭',
+			iconCls: 'cancel_btn',
+			handler: function () {
+				this.up('window').hide();
+			}
+		}]
+	});
+
+	var appendwin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    width: 400,
-		    modal: true,
-		    layout: 'fit',
-		    items:  AppendForm,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			width: 400,
+			modal: true,
+			layout: 'fit',
+			items: AppendForm,
+			closeAction: 'hide'
 		}).show();
 	}
-	
-	
+
+
 	var AppendForm1 = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsAppendForm1',
 		labelWidth: 55,
-		url: baseUrl+'iot/planteam/append1',
+		url: baseUrl + 'iot/planteam/append1',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'班组名称',
+			fieldLabel: '班组名称',
 			id: 'fa_Inspectors_team_name',
-			name:'team_name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-			fieldLabel:'负责人',
+			name: 'team_name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%'
+		}, {
+			fieldLabel: '负责人',
 			id: 'fa_Inspectors_person_liable_id',
-			name:'person_liable_id',
-			xtype:'combo',
-			store:getJobDutiesStore1,
-			displayField : 'name',  
-	        valueField : 'rid',
-	        editable : false,
-			anchor:'75%'
-		},{
-			id:'fa_Inspectors_queryJson1',
-			name:'queryJson',
-			hidden:true
+			name: 'person_liable_id',
+			xtype: 'combo',
+			store: getJobDutiesStore1,
+			displayField: 'name',
+			valueField: 'rid',
+			editable: false,
+			anchor: '75%'
+		}, {
+			id: 'fa_Inspectors_queryJson1',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	// query.V_LOGINNAME = $("#V_LOGINNAME").val();
-		        	query.team_name = Ext.getCmp('fa_Inspectors_team_name').getValue();
-		        	query.person_liable_id = Ext.getCmp('fa_Inspectors_person_liable_id').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fa_Inspectors_queryJson1').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-		                	   clear_append_form1();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_append_form1();
-		                   });
-		                }
-		            });
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					// query.V_LOGINNAME = $("#V_LOGINNAME").val();
+					query.team_name = Ext.getCmp('fa_Inspectors_team_name').getValue();
+					query.person_liable_id = Ext.getCmp('fa_Inspectors_person_liable_id').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_Inspectors_queryJson1').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								clear_append_form1();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_append_form1();
+							});
+						}
+					});
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var appendwin1 = function(){
+
+	var appendwin1 = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    width: 400,
-		    modal: true,
-		    layout: 'fit',
-		    items:  AppendForm1,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			width: 400,
+			modal: true,
+			layout: 'fit',
+			items: AppendForm1,
+			closeAction: 'hide'
 		}).show();
 	}
-	
-	var clear_modify_form = function (){
+
+	var clear_modify_form = function () {
 		Ext.getCmp('fm_inspectors_id').setValue("");
 		Ext.getCmp('fm_inspectors_queryJson').setValue("");
 		Ext.getCmp('fm_inspectors_name').setValue("");
@@ -491,1159 +530,1189 @@ Ext.onReady(function(){
 		Ext.getCmp('fm_inspectors_inspectiontime').setValue(false);
 		Ext.getCmp('InspectorsListPanel').getStore().reload();
 	}
-	
-	
-	
+
+
+
 	var ModifyForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsEditForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectorsx/update',
+		url: baseUrl + 'iot/inspectorsx/update',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-				fieldLabel:'人员姓名',
-				id: 'fm_inspectors_name',
-				name:'name',
-				maxLength:20,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%',
-				listeners: {
-					select: function(o,e){
-						console.log(o,e)
-						// value.replace(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/,'')
+			fieldLabel: '人员姓名',
+			id: 'fm_inspectors_name',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_Inspectors_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '电话号码',
+			id: 'fm_inspectors_phone',
+			name: 'phone',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_Inspectors_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
 					}
 				}
-			},{
-				fieldLabel:'电话号码',
-				id: 'fm_inspectors_phone',
-				name: 'phone',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
-			},{
-			    xtype: 'checkboxgroup',
-			    fieldLabel: '人员职能',
-			    id:"fm_inspectors_inspectiontime",
-			    columns: 3,
-			    items: [
-			            {boxLabel: '维保', name: 'maintenance',inputValue:"1",id:'inspectors_maintenance'},
-			            {boxLabel: '巡检', name: 'inspection',inputValue:"2",id:'inspectors_inspection'},
-			            {boxLabel: '报修', name: 'event_processing',inputValue:"4",id:'inspectors_event_processing'}
-			              
-			]},{
-			   id: 'fm_inspectors_id',
-			   name:'id',
-			   hidden:true
-			},{
-			   id:'fm_inspectors_queryJson',
-			   name:'queryJson',
-			   hidden:true
-			  }],
-			  buttons: [{
-			         text: '修改',
-			         iconCls:'ok_btn',
-			      handler: function() {
-			       var form = this.up('form').getForm();
-			          if (form.isValid()) {
-			           var InspectiontimeValue = Ext.getCmp('fm_inspectors_inspectiontime').getChecked();
-			           var Inspectiontime=0;
-			           Ext.Array.each(InspectiontimeValue, function(item){
-			            Inspectiontime +=parseInt(item.inputValue);
-			           });
-			           var query = new Object();
-			           query.zn=Inspectiontime;
-			           query.id = Ext.getCmp('fm_inspectors_id').getValue();
-			           query.name = Ext.getCmp('fm_inspectors_name').getValue();
-			           query.phone = Ext.getCmp('fm_inspectors_phone').getValue();
-			           var jsonstr = Ext.JSON.encode(query);
-			           Ext.getCmp('fm_inspectors_queryJson').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                }
-		            });
-		            this.up('window').hide();
-		        }
-		    }
-		},{
+			}
+		}, {
+			xtype: 'checkboxgroup',
+			fieldLabel: '人员职能',
+			id: "fm_inspectors_inspectiontime",
+			columns: 3,
+			items: [
+				{ boxLabel: '维保', name: 'maintenance', inputValue: "1", id: 'inspectors_maintenance' },
+				{ boxLabel: '巡检', name: 'inspection', inputValue: "2", id: 'inspectors_inspection' },
+				{ boxLabel: '报修', name: 'event_processing', inputValue: "4", id: 'inspectors_event_processing' }
+
+			]
+		}, {
+			id: 'fm_inspectors_id',
+			name: 'id',
+			hidden: true
+		}, {
+			id: 'fm_inspectors_queryJson',
+			name: 'queryJson',
+			hidden: true
+		}],
+		buttons: [{
+			text: '修改',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var InspectiontimeValue = Ext.getCmp('fm_inspectors_inspectiontime').getChecked();
+					var Inspectiontime = 0;
+					Ext.Array.each(InspectiontimeValue, function (item) {
+						Inspectiontime += parseInt(item.inputValue);
+					});
+					var query = new Object();
+					query.id = Ext.getCmp('fm_inspectors_id').getValue();
+					query.name = Ext.getCmp('fm_inspectors_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
+					query.phone = Ext.getCmp('fm_inspectors_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					}else if (query.phone.length < 11){
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if(query.zn == 0){
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fm_inspectors_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+								clear_modify_form();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_modify_form();
+							});
+						}
+					});
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 				clear_modify_form();
 			}
 		}]
 	});
-	
-	var modifywin = function(){
+
+	var modifywin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '修改',
-		    height: 350,
-		    width: 400,
-		    modal: true,
-		    layout: 'fit',
-		    items:  ModifyForm,
-		    closeAction: 'hide'
+			title: '修改',
+			height: 350,
+			width: 400,
+			modal: true,
+			layout: 'fit',
+			items: ModifyForm,
+			closeAction: 'hide'
 		}).show();
 	}
-		
-	var chk_sm = function() {
-		  if(sm.getCount()==1){
-		   modifywin();
-		   var selected = sm.getSelection();
-		   var fm_inspectiontime = selected[0].raw.zn
-		   if(fm_inspectiontime=='1'){
-		    var domainArr = ['1'];
-		   }else if(fm_inspectiontime=='2'){
-		    var domainArr = ['2'];
-		   }else if(fm_inspectiontime=='3'){
-		    var domainArr = ['1','2'];
-		   }else if(fm_inspectiontime=='4'){
-		    var domainArr = ['4'];
-		   }else if(fm_inspectiontime=='5'){
-		    var domainArr = ['1','4'];
-		   }else if(fm_inspectiontime=='6'){
-		    var domainArr = ['2','4'];
-		   }else if(fm_inspectiontime=='7'){
-		    var domainArr = ['1','2','4'];
-		   }
-		   for(var i = 0 ;i < domainArr.length;i++) {
-		    switch(domainArr[i]) {
-		    case "1":
-		     Ext.getCmp('inspectors_maintenance').setValue(true);
-		     break; 
-		       case "2":
-		        Ext.getCmp('inspectors_inspection').setValue(true);
-		        break; 
-		       case "4":
-		        Ext.getCmp('inspectors_event_processing').setValue(true);
-		        break; 
-		    }
-		    }
-		   Ext.getCmp('fm_inspectors_id').setValue(selected[0].raw.id);
-		   Ext.getCmp('fm_inspectors_name').setValue(selected[0].raw.name);
-		   Ext.getCmp('fm_inspectors_phone').setValue(selected[0].raw.phone);
-		  }else{
-		   Ext.Msg.alert('请先选择','请先选择一条记录,再点击修改');
-		  }
-		 }
-	
-	var del_sm = function() {
-		if(sm.getCount()==1){
-			var selected = sm.getSelection( );
+
+	var chk_sm = function () {
+		if (sm.getCount() == 1) {
+			modifywin();
+			var selected = sm.getSelection();
+			var fm_inspectiontime = selected[0].raw.zn
+			if (fm_inspectiontime == '1') {
+				var domainArr = ['1'];
+			} else if (fm_inspectiontime == '2') {
+				var domainArr = ['2'];
+			} else if (fm_inspectiontime == '3') {
+				var domainArr = ['1', '2'];
+			} else if (fm_inspectiontime == '4') {
+				var domainArr = ['4'];
+			} else if (fm_inspectiontime == '5') {
+				var domainArr = ['1', '4'];
+			} else if (fm_inspectiontime == '6') {
+				var domainArr = ['2', '4'];
+			} else if (fm_inspectiontime == '7') {
+				var domainArr = ['1', '2', '4'];
+			}
+			for (var i = 0; i < domainArr.length; i++) {
+				switch (domainArr[i]) {
+					case "1":
+						Ext.getCmp('inspectors_maintenance').setValue(true);
+						break;
+					case "2":
+						Ext.getCmp('inspectors_inspection').setValue(true);
+						break;
+					case "4":
+						Ext.getCmp('inspectors_event_processing').setValue(true);
+						break;
+				}
+			}
+			Ext.getCmp('fm_inspectors_id').setValue(selected[0].raw.id);
+			Ext.getCmp('fm_inspectors_name').setValue(selected[0].raw.name);
+			Ext.getCmp('fm_inspectors_phone').setValue(selected[0].raw.phone);
+		} else {
+			Ext.Msg.alert('请先选择', '请先选择一条记录,再点击修改');
+		}
+	}
+
+	var del_sm = function () {
+		if (sm.getCount() == 1) {
+			var selected = sm.getSelection();
 			var query = new Object();
 			var list = new Array();
 			var o = new Object();
 			o.id = selected[0].raw.id;
 			list.push(o);
 			query.ID_LIST = list;
-			var jsonstr= Ext.JSON.encode(query);
-			Ext.MessageBox.confirm('删除人员信息','是否删除'+selected[0].raw.name+' 维保人员?',function(btn){
-				if(btn=='yes'){
-					
+			var jsonstr = Ext.JSON.encode(query);
+			Ext.MessageBox.confirm('删除人员信息', '是否删除' + selected[0].raw.name + ' 维保人员?', function (btn) {
+				if (btn == 'yes') {
+
 					$.ajax({
-			             type:'POST',
-			             url: baseUrl+"iot/inspectorsx/del",
-			             data: {
-			              queryJson : jsonstr
-			            
-			           },
-			           success: function(result){
-			             
-			             var json = eval('(' + result + ')');
-			                 if(json.action=='deleteInspectors'){
-			         
-			                  if(json.success==true){
-			                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-			                	      Ext.getCmp('InspectorsListPanel').getStore().reload();
-			                       }); 
-			                	 }else{
-			                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-				                	      Ext.getCmp('InspectorsListPanel').getStore().reload();
-				                      }); 
-			                	 }
-			                 }
-			             
-			            }
-			     });
-				
+						type: 'POST',
+						url: baseUrl + "iot/inspectorsx/del",
+						data: {
+							queryJson: jsonstr
+
+						},
+						success: function (result) {
+
+							var json = eval('(' + result + ')');
+							if (json.action == 'deleteInspectors') {
+
+								if (json.success == true) {
+									Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+										Ext.getCmp('InspectorsListPanel').getStore().reload();
+									});
+								} else {
+									Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+										Ext.getCmp('InspectorsListPanel').getStore().reload();
+									});
+								}
+							}
+
+						}
+					});
+
 				}
-			},this);
-		}else{
-			if(sm.getCount()>1){
+			}, this);
+		} else {
+			if (sm.getCount() > 1) {
 				var query = new Object();
 				var list = new Array();
-				for(var i=0;i<sm.getCount();i++){
-					var selected = sm.getSelection( );
+				for (var i = 0; i < sm.getCount(); i++) {
+					var selected = sm.getSelection();
 					var o = new Object();
 					o.id = selected[i].raw.id;
 					list.push(o);
 				}
 				query.ID_LIST = list;
-				
-				var jsonstr= Ext.JSON.encode(query);
-				Ext.MessageBox.confirm('删除人员信息','是否删除选中的'+sm.getCount()+' 个维保人员?',function(btn){
-					if(btn=='yes'){
-						
+
+				var jsonstr = Ext.JSON.encode(query);
+				Ext.MessageBox.confirm('删除人员信息', '是否删除选中的' + sm.getCount() + ' 个维保人员?', function (btn) {
+					if (btn == 'yes') {
+
 						$.ajax({
-				             type:'POST',
-				             url: baseUrl+"iot/inspectorsx/del",
-				             data: {
-				              queryJson : jsonstr
-				            
-				           },
-				           success: function(result){
-				             
-				             var json = eval('(' + result + ')');
-				                 if(json.action=='deleteInspectors'){
-				                	 if(json.success==true){
-					                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-					                	      Ext.getCmp('InspectorsListPanel').getStore().reload();
-					                       }); 
-					                	 }else{
-					                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-						                	      Ext.getCmp('InspectorsListPanel').getStore().reload();
-						                      }); 
-					                	 } 
-				                 }
-				             
-				            }
-				     });
-					
+							type: 'POST',
+							url: baseUrl + "iot/inspectorsx/del",
+							data: {
+								queryJson: jsonstr
+
+							},
+							success: function (result) {
+
+								var json = eval('(' + result + ')');
+								if (json.action == 'deleteInspectors') {
+									if (json.success == true) {
+										Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+											Ext.getCmp('InspectorsListPanel').getStore().reload();
+										});
+									} else {
+										Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+											Ext.getCmp('InspectorsListPanel').getStore().reload();
+										});
+									}
+								}
+
+							}
+						});
+
 					}
-				},this);
-			}else{
-			Ext.Msg.alert('请先选择','至少选择一条记录,再点击删除');
-		}
+				}, this);
+			} else {
+				Ext.Msg.alert('请先选择', '至少选择一条记录,再点击删除');
+			}
 		}
 	}
-	
-	var del_sm1 = function() {
-		if(sm1.getCount()==1){
-			var selected = sm1.getSelection( );
+
+	var del_sm1 = function () {
+		if (sm1.getCount() == 1) {
+			var selected = sm1.getSelection();
 			var query = new Object();
 			var list = new Array();
 			var o = new Object();
 			o.id = selected[0].raw.id;
 			list.push(o);
 			query.ID_LIST = list;
-			var jsonstr= Ext.JSON.encode(query);
-			Ext.MessageBox.confirm('删除班组','是否删除'+selected[0].raw.name+' 班组?',function(btn){
-				if(btn=='yes'){
-					
-				 $.ajax({
-			             type:'POST',
-			             url: baseUrl+"iot/planteam/del",
-			             data: {
-			              queryJson : jsonstr
-			            
-			           },
-			           success: function(result){
-			             
-			             var json = eval('(' + result + ')');
-			                 if(json.action=='deletePlanTeam'){
-			                
-			                  if(json.success==true){
-			                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-			                	      Ext.getCmp('InspectorsListPanel2').getStore().reload();
-			                       }); 
-			                	 }else{
-			                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-				                	      Ext.getCmp('InspectorsListPanel2').getStore().reload();
-				                      }); 
-			                	 }
-			                 }
-			             
-			            }
-			     });
-				
+			var jsonstr = Ext.JSON.encode(query);
+			Ext.MessageBox.confirm('删除班组', '是否删除' + selected[0].raw.name + ' 班组?', function (btn) {
+				if (btn == 'yes') {
+
+					$.ajax({
+						type: 'POST',
+						url: baseUrl + "iot/planteam/del",
+						data: {
+							queryJson: jsonstr
+
+						},
+						success: function (result) {
+
+							var json = eval('(' + result + ')');
+							if (json.action == 'deletePlanTeam') {
+
+								if (json.success == true) {
+									Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+										Ext.getCmp('InspectorsListPanel2').getStore().reload();
+									});
+								} else {
+									Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+										Ext.getCmp('InspectorsListPanel2').getStore().reload();
+									});
+								}
+							}
+
+						}
+					});
+
 				}
-			},this);
-		}else{
-			if(sm1.getCount()>1){
+			}, this);
+		} else {
+			if (sm1.getCount() > 1) {
 				var query = new Object();
 				var list = new Array();
-				for(var i=0;i<sm.getCount();i++){
-					var selected = sm1.getSelection( );
+				for (var i = 0; i < sm.getCount(); i++) {
+					var selected = sm1.getSelection();
 					var o = new Object();
 					o.id = selected[i].raw.id;
 					list.push(o);
 				}
 				query.ID_LIST = list;
-				
-				var jsonstr= Ext.JSON.encode(query);
-				Ext.MessageBox.confirm('删除班组','是否删除选中的'+sm1.getCount()+' 个班组?',function(btn){
-					if(btn=='yes'){
-						
+
+				var jsonstr = Ext.JSON.encode(query);
+				Ext.MessageBox.confirm('删除班组', '是否删除选中的' + sm1.getCount() + ' 个班组?', function (btn) {
+					if (btn == 'yes') {
+
 						$.ajax({
-				             type:'POST',
-				             url: baseUrl+"iot/planteam/del",
-				             data: {
-				              queryJson : jsonstr
-				            
-				           },
-				           success: function(result){
-				             
-				             var json = eval('(' + result + ')');
-				                 if(json.action=='deletePlanTeam'){
-				                	 if(json.success==true){
-					                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-					                	      Ext.getCmp('InspectorsListPanel2').getStore().reload();
-					                       }); 
-					                	 }else{
-					                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-						                	      Ext.getCmp('InspectorsListPanel2').getStore().reload();
-						                      }); 
-					                	 }
-				                 }
-				             
-				            }
-				     });
-					
+							type: 'POST',
+							url: baseUrl + "iot/planteam/del",
+							data: {
+								queryJson: jsonstr
+
+							},
+							success: function (result) {
+
+								var json = eval('(' + result + ')');
+								if (json.action == 'deletePlanTeam') {
+									if (json.success == true) {
+										Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+											Ext.getCmp('InspectorsListPanel2').getStore().reload();
+										});
+									} else {
+										Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+											Ext.getCmp('InspectorsListPanel2').getStore().reload();
+										});
+									}
+								}
+
+							}
+						});
+
 					}
 
-				},this);
-			}else{
-			Ext.Msg.alert('请先选择','至少选择一条记录,再点击删除');
-		}
+				}, this);
+			} else {
+				Ext.Msg.alert('请先选择', '至少选择一条记录,再点击删除');
+			}
 		}
 	}
-	
-	var show_page = function(){
+
+	var show_page = function () {
 		var arr = 0;
 		var r = document.getElementsByName("zhineng");
-		if(r.length>1){
-		  for(var i = 0; i < r.length; i++) {
-			  if(r[i].checked) {
-				  arr+=parseInt(r[i].value);
-			  }
-		  }
-		}else if(r.length==1){
+		if (r.length > 1) {
+			for (var i = 0; i < r.length; i++) {
+				if (r[i].checked) {
+					arr += parseInt(r[i].value);
+				}
+			}
+		} else if (r.length == 1) {
 			arr = parseInt(r[0].value);
-		}else{
+		} else {
 			arr = 0;
 		}
 		var maintenancePerson_title3_input = document.getElementById('inspectors_title3_input1').value;
 		var query = new Object();
-		if(arr > 0){
+		if (arr > 0) {
 			query.zn = arr;
 			$("#zn").val(arr);
 		}
-		if(maintenancePerson_title3_input.length>0){
-		query.name = maintenancePerson_title3_input;
-		$("#name").val(maintenancePerson_title3_input);
+		if (maintenancePerson_title3_input.length > 0) {
+			query.name = maintenancePerson_title3_input;
+			$("#name").val(maintenancePerson_title3_input);
 		}
 		// query.V_LOGINNAME = V_LOGINNAME;
 		// query.V_PASSWORD =  V_PASSWORD;
 		var jsonstr = Ext.JSON.encode(query);
-    	myStore.getProxy().extraParams = {
-    		queryJson : jsonstr
-    	};
-    	Ext.getCmp('InspectorsListPageToolbar').moveFirst();
+		myStore.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('InspectorsListPageToolbar').moveFirst();
 	}
-	
-	var show_page1 = function(){
+
+	var show_page1 = function () {
 		var maintenancePerson_title21_input = document.getElementById('maintenancePerson_title21_input').value;
 		var maintenancePerson_title31_input = document.getElementById('maintenancePerson_title31_input1').value;
 		var query = new Object();
-		if(maintenancePerson_title21_input.length>0){
-		  query.spot_name = maintenancePerson_title21_input;
+		if (maintenancePerson_title21_input.length > 0) {
+			query.spot_name = maintenancePerson_title21_input;
 		}
-		if(maintenancePerson_title31_input.length>0){
-		query.name = maintenancePerson_title31_input;
+		if (maintenancePerson_title31_input.length > 0) {
+			query.name = maintenancePerson_title31_input;
 		}
 		// query.V_LOGINNAME = V_LOGINNAME;
 		// query.V_PASSWORD =  V_PASSWORD;
 		var jsonstr = Ext.JSON.encode(query);
-    	myStore.getProxy().extraParams = {
-    		queryJson : jsonstr
-    	};
-    	Ext.getCmp('InspectorsListPageToolbar2').moveFirst();
+		myStore.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('InspectorsListPageToolbar2').moveFirst();
 	}
-	
-	var reset1 = function(){
+
+	var reset1 = function () {
 		var zn = document.getElementsByName("zhineng");
-        for (var i = 0; i < zn.length; i++) {
-      	  zn[i].checked = true;
-        }
+		for (var i = 0; i < zn.length; i++) {
+			zn[i].checked = true;
+		}
 		document.getElementById('inspectors_title3_input1').value = '';
 		$("#zn").val('');
 		$("#name").val('');
 		show_page();
 	}
-	
-	var reset11 = function(){
+
+	var reset11 = function () {
 		document.getElementById('maintenancePerson_title21_input').value = '';
 		document.getElementById('maintenancePerson_title31_input1').value = '';
 	}
-	
-	mouseon = function(obj){
+
+	mouseon = function (obj) {
 		var id = obj.id;
-		$("#"+id).removeClass(id);
-		$("#"+id).addClass(id+'_on');
+		$("#" + id).removeClass(id);
+		$("#" + id).addClass(id + '_on');
 	}
-	
-	mouseon1 = function(obj){
+
+	mouseon1 = function (obj) {
 		var id = obj.id;
-		$("#"+id).removeClass(id);
-		$("#"+id).addClass(id+'_on');
+		$("#" + id).removeClass(id);
+		$("#" + id).addClass(id + '_on');
 	}
-	
-	 mouseoff = function(obj){
+
+	mouseoff = function (obj) {
 		var mid = "inspectors_";
-		for(var i=1;i<7;i++){
-			var id = "inspectors_title"+i+"_div";
-			$("#"+id).removeClass(id+'_on');
-			$("#"+id).addClass(id);
+		for (var i = 1; i < 7; i++) {
+			var id = "inspectors_title" + i + "_div";
+			$("#" + id).removeClass(id + '_on');
+			$("#" + id).addClass(id);
 		}
-		if(menuidx=='m1'){
+		if (menuidx == 'm1') {
 			mid += 'title1_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m2'){
+		else if (menuidx == 'm2') {
 			mid += 'title2_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m3'){
+		else if (menuidx == 'm3') {
 			mid += 'title3_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m4'){
+		else if (menuidx == 'm4') {
 			mid += 'title4_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m5'){
+		else if (menuidx == 'm5') {
 			mid += 'title5_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m6'){
+		else if (menuidx == 'm6') {
 			mid += 'title6_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
 	}
-	
-	 mouseoff1 = function(obj){
-		   var mid = "inspectors_";
-		   for(var i=1;i<5;i++){
-		    var id = "inspectors_title"+i+"1_div";
-		    $("#"+id).removeClass(id+'_on');
-		    $("#"+id).addClass(id);
-		   }
-		      if(menuidx=='m11'){
-		    mid += 'title11_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m21'){
-		    mid += 'title21_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m31'){
-		    mid += 'title31_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m41'){
-		    mid += 'title41_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		  }
-	 
-	 menu_click = function(obj){
-		  var id = obj.id;
-		  if(id=='inspectors_title1_div'){
-		   menuidx = 'm1';
-		   show_page();
-		  }
-		  else if(id=='inspectors_title2_div'){
-		   menuidx = 'm2';
-		   reset1();
-		  }
-		  else if(id=='inspectors_title3_div'){
-		   menuidx = 'm3';
-		   exportbtn_click();
-		  }
-		  else if(id=='inspectors_title4_div'){
-		   menuidx = 'm4';
-		   del_sm();
-		  }
-		  else if(id=='inspectors_title5_div'){
-		   menuidx = 'm5';
-		   appendwin();
-		  }
-		  else if(id=='inspectors_title6_div'){
-		   menuidx = 'm6';
-		   chk_sm();
-		  }
-		  else if(id=='inspectors_title11_div'){
-		   menuidx = 'm11';
-		   del_sm1();
-		  }
-		  else if(id=='inspectors_title21_div'){
-		   menuidx = 'm21';
-		   appendwin1();
-		  }
-		  else if(id=='inspectors_title31_div'){
-		   menuidx = 'm31';
-		   Preservation_panel3();
-		  }
-		  else if(id=='inspectors_title41_div'){
-		   menuidx = 'm41';
-		   cancel_panel3();
-		  }
-		 }
-	
-	var Preservation_panel3 = function(){
+
+	mouseoff1 = function (obj) {
+		var mid = "inspectors_";
+		for (var i = 1; i < 5; i++) {
+			var id = "inspectors_title" + i + "1_div";
+			$("#" + id).removeClass(id + '_on');
+			$("#" + id).addClass(id);
+		}
+		if (menuidx == 'm11') {
+			mid += 'title11_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm21') {
+			mid += 'title21_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm31') {
+			mid += 'title31_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm41') {
+			mid += 'title41_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+	}
+
+	menu_click = function (obj) {
+		var id = obj.id;
+		if (id == 'inspectors_title1_div') {
+			menuidx = 'm1';
+			show_page();
+		}
+		else if (id == 'inspectors_title2_div') {
+			menuidx = 'm2';
+			reset1();
+		}
+		else if (id == 'inspectors_title3_div') {
+			menuidx = 'm3';
+			exportbtn_click();
+		}
+		else if (id == 'inspectors_title4_div') {
+			menuidx = 'm4';
+			del_sm();
+		}
+		else if (id == 'inspectors_title5_div') {
+			menuidx = 'm5';
+			appendwin();
+		}
+		else if (id == 'inspectors_title6_div') {
+			menuidx = 'm6';
+			chk_sm();
+		}
+		else if (id == 'inspectors_title11_div') {
+			menuidx = 'm11';
+			del_sm1();
+		}
+		else if (id == 'inspectors_title21_div') {
+			menuidx = 'm21';
+			appendwin1();
+		}
+		else if (id == 'inspectors_title31_div') {
+			menuidx = 'm31';
+			Preservation_panel3();
+		}
+		else if (id == 'inspectors_title41_div') {
+			menuidx = 'm41';
+			cancel_panel3();
+		}
+	}
+
+	var Preservation_panel3 = function () {
 		var team_name = document.getElementById('inspectors_title211_input').value;
 		var person_liable_id = document.getElementById('inspectors_title111_input').value;
-		var selected = sm1.getSelection( );
-		
-		var selected1 = addsm.getSelection( );
-		var tid=selected1[0].raw.tdid;
-		for(var i=0;i<addsm.getCount();i++){
-            if(i==0)
-            	people_id_list = selected1[i].raw.rid;
+		var selected = sm1.getSelection();
+
+		var selected1 = addsm.getSelection();
+		var tid = selected1[0].raw.tdid;
+		for (var i = 0; i < addsm.getCount(); i++) {
+			if (i == 0)
+				people_id_list = selected1[i].raw.rid;
 			else
-				people_id_list += ","+selected1[i].raw.rid;
-           }
-		
+				people_id_list += "," + selected1[i].raw.rid;
+		}
+
 		var query = new Object();
-		query.team_name=team_name;
-		query.person_liable_id =person_liable_id ;
-		query.tid = tid ;
-		query.people_id_list = people_id_list ;
-		
+		query.team_name = team_name;
+		query.person_liable_id = person_liable_id;
+		query.tid = tid;
+		query.people_id_list = people_id_list;
+
 		$.ajax({
-	         type:'POST',
-	         url: baseUrl+"iot/planteam/update",
-	         data: {
-	          queryJson : Ext.JSON.encode(query)
-	       },
-	         success: function(result){
-	        	 Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-	        		  mystore2_fun(tid);
-//					  cancel_panel3();
-                 });
-	         },
-	         failure : function() {
-				  Ext.Msg.alert('操作失败', function(btn,txt){
-					  cancel_panel3();
-                 });
-			  }
-	     });
-    	
+			type: 'POST',
+			url: baseUrl + "iot/planteam/update",
+			data: {
+				queryJson: Ext.JSON.encode(query)
+			},
+			success: function (result) {
+				Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+					mystore2_fun(tid);
+					//					  cancel_panel3();
+				});
+			},
+			failure: function () {
+				Ext.Msg.alert('操作失败', function (btn, txt) {
+					cancel_panel3();
+				});
+			}
+		});
+
+	}
+
+	var cancel_panel3 = function () {
+		var selected = sm1.getSelection();
+		var stor1_id = selected[0].raw.id;
+		var label1 = selected[0].raw.team_name;
+		var label2 = selected[0].raw.person_liable_id;
+		var query = new Object();
+		query.id = stor1_id;
+
+		// query.V_LOGINNAME = V_LOGINNAME;
+		// query.V_PASSWORD =  V_PASSWORD;
+		var jsonstr = Ext.JSON.encode(query);
+		myStore1.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
+		document.getElementById('inspectors_title211_input').value = label1;
+		document.getElementById('inspectors_title111_input').value = label2;
+	}
+
+	var childPanel1 = function () {
+		var maintenancePersonHtml = document.getElementById('InspectorsHtml');
+		var childPanel1_title = document.createElement('div');
+		childPanel1_title.setAttribute('class', 'maintenanceperson_title2_div');
+		childPanel1_title.innerHTML = '职能';
+		maintenancePersonHtml.appendChild(childPanel1_title);
+		var childPanel1_input1 = document.createElement('input');
+		childPanel1_input1.setAttribute('class', 'input4_class');
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input1.setAttribute('type', 'checkbox');
+		childPanel1_input1.setAttribute('name', 'zhineng');
+		childPanel1_input1.setAttribute('value', '1');
+		maintenancePersonHtml.appendChild(childPanel1_input1);
+		var childPanel1_div = document.createElement('div');
+		childPanel1_div.setAttribute('class', 'childPanel1_div');
+		childPanel1_div.innerHTML = '维保';
+		maintenancePersonHtml.appendChild(childPanel1_div);
+		var childPanel1_input2 = document.createElement('input');
+		childPanel1_input2.setAttribute('class', 'input2_class');
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input2.setAttribute('type', 'checkbox');
+		childPanel1_input2.setAttribute('name', 'zhineng');
+		childPanel1_input2.setAttribute('value', '2');
+		maintenancePersonHtml.appendChild(childPanel1_input2);
+		var childPanel1_div1 = document.createElement('div');
+		childPanel1_div1.setAttribute('class', 'childPanel1_div1');
+		childPanel1_div1.innerHTML = '巡检';
+		maintenancePersonHtml.appendChild(childPanel1_div1);
+		var childPanel1_input3 = document.createElement('input');
+		childPanel1_input3.setAttribute('class', 'input3_class')
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input3.setAttribute('type', 'checkbox');
+		childPanel1_input3.setAttribute('name', 'zhineng');
+		childPanel1_input3.setAttribute('value', '4');
+		maintenancePersonHtml.appendChild(childPanel1_input3);
+		var childPanel1_div2 = document.createElement('div');
+		childPanel1_div2.setAttribute('class', 'childPanel1_div2');
+		childPanel1_div2.innerHTML = '报修';
+		maintenancePersonHtml.appendChild(childPanel1_div2);
+		var childPanel1_title1 = document.createElement('div');
+		childPanel1_title1.setAttribute('class', 'title3_div');
+		childPanel1_title1.innerHTML = '姓名';
+		maintenancePersonHtml.appendChild(childPanel1_title1);
+		var childPanel1_input = document.createElement('input');
+		childPanel1_input.setAttribute('class', 'input1_class');
+		childPanel1_input.setAttribute('id', 'inspectors_title3_input1');
+		childPanel1_input.setAttribute('type', 'text');
+		childPanel1_input.setAttribute('value', '');
+		maintenancePersonHtml.appendChild(childPanel1_input);
+		var childPanel1_title2 = document.createElement('div');
+		childPanel1_title2.setAttribute('class', 'inspectors_title1_div');
+		childPanel1_title2.setAttribute('id', 'inspectors_title1_div');
+		childPanel1_title2.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title2.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title2.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title2);
+		var childPanel1_title3 = document.createElement('div');
+		childPanel1_title3.setAttribute('class', 'inspectors_title2_div');
+		childPanel1_title3.setAttribute('id', 'inspectors_title2_div');
+		childPanel1_title3.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title3.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title3.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title3);
+		var childPanel1_title4 = document.createElement('div');
+		childPanel1_title4.setAttribute('class', 'inspectors_title3_div');
+		childPanel1_title4.setAttribute('id', 'inspectors_title3_div');
+		childPanel1_title4.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title4.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title4.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title4);
+		var childPanel1_title5 = document.createElement('div');
+		childPanel1_title5.setAttribute('class', 'inspectors_title4_div');
+		childPanel1_title5.setAttribute('id', 'inspectors_title4_div');
+		childPanel1_title5.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title5.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title5.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title5);
+		var childPanel1_title6 = document.createElement('div');
+		childPanel1_title6.setAttribute('class', 'inspectors_title5_div');
+		childPanel1_title6.setAttribute('id', 'inspectors_title5_div');
+		childPanel1_title6.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title6.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title6.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title6);
+		var childPanel1_title7 = document.createElement('div');
+		childPanel1_title7.setAttribute('class', 'inspectors_title6_div');
+		childPanel1_title7.setAttribute('id', 'inspectors_title6_div');
+		childPanel1_title7.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title7.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title7.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title7);
+		reset1();
 	}
-	
-	var cancel_panel3 = function() {
-		  var selected = sm1.getSelection( );
-		  var stor1_id=selected[0].raw.id;
-		  var label1 = selected[0].raw.team_name;
-		  var label2 = selected[0].raw.person_liable_id;
-		  var query = new Object(); 
-		    query.id = stor1_id;
-		    
-		    // query.V_LOGINNAME = V_LOGINNAME;
-		    // query.V_PASSWORD =  V_PASSWORD;
-		    var jsonstr = Ext.JSON.encode(query);
-		       myStore1.getProxy().extraParams = {
-		        queryJson : jsonstr
-		       };
-		       Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
-		       document.getElementById('inspectors_title211_input').value = label1;
-		     document.getElementById('inspectors_title111_input').value = label2;
-		 }
-	
-	var childPanel1 = function() {
-		  var maintenancePersonHtml = document.getElementById('InspectorsHtml');
-		  var childPanel1_title = document.createElement('div');
-		  childPanel1_title.setAttribute('class','maintenanceperson_title2_div');
-		  childPanel1_title.innerHTML='职能';
-		  maintenancePersonHtml.appendChild(childPanel1_title);
-		  var childPanel1_input1 = document.createElement('input');
-		   childPanel1_input1.setAttribute('class','input4_class');
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input1.setAttribute('type','checkbox');
-		   childPanel1_input1.setAttribute('name','zhineng');
-		   childPanel1_input1.setAttribute('value','1');
-		   maintenancePersonHtml.appendChild(childPanel1_input1);
-		  var childPanel1_div = document.createElement('div');
-		   childPanel1_div.setAttribute('class','childPanel1_div');
-		   childPanel1_div.innerHTML='维保';
-		   maintenancePersonHtml.appendChild(childPanel1_div);
-		  var childPanel1_input2 = document.createElement('input');
-		   childPanel1_input2.setAttribute('class','input2_class');
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input2.setAttribute('type','checkbox');
-		   childPanel1_input2.setAttribute('name','zhineng');
-		   childPanel1_input2.setAttribute('value','2');
-		   maintenancePersonHtml.appendChild(childPanel1_input2);
-		  var childPanel1_div1 = document.createElement('div');
-		   childPanel1_div1.setAttribute('class','childPanel1_div1');
-		   childPanel1_div1.innerHTML='巡检';
-		   maintenancePersonHtml.appendChild(childPanel1_div1);
-		  var childPanel1_input3 = document.createElement('input');
-		   childPanel1_input3.setAttribute('class','input3_class')
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input3.setAttribute('type','checkbox');
-		   childPanel1_input3.setAttribute('name','zhineng');
-		   childPanel1_input3.setAttribute('value','4');
-		   maintenancePersonHtml.appendChild(childPanel1_input3);
-		  var childPanel1_div2 = document.createElement('div');
-		   childPanel1_div2.setAttribute('class','childPanel1_div2');
-		   childPanel1_div2.innerHTML='报修';
-		   maintenancePersonHtml.appendChild(childPanel1_div2);
-		   var childPanel1_title1 = document.createElement('div');
-		   childPanel1_title1.setAttribute('class','title3_div');
-		   childPanel1_title1.innerHTML='姓名';
-		   maintenancePersonHtml.appendChild(childPanel1_title1);
-		   var childPanel1_input = document.createElement('input');
-		   childPanel1_input.setAttribute('class','input1_class');
-		   childPanel1_input.setAttribute('id','inspectors_title3_input1');
-		   childPanel1_input.setAttribute('type','text');
-		   childPanel1_input.setAttribute('value','');
-		   maintenancePersonHtml.appendChild(childPanel1_input);
-		   var childPanel1_title2 = document.createElement('div');
-		   childPanel1_title2.setAttribute('class','inspectors_title1_div');
-		   childPanel1_title2.setAttribute('id','inspectors_title1_div');
-		   childPanel1_title2.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title2.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title2.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title2);
-		   var childPanel1_title3 = document.createElement('div');
-		   childPanel1_title3.setAttribute('class','inspectors_title2_div');
-		   childPanel1_title3.setAttribute('id','inspectors_title2_div');
-		   childPanel1_title3.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title3.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title3.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title3);
-		   var childPanel1_title4 = document.createElement('div');
-		   childPanel1_title4.setAttribute('class','inspectors_title3_div');
-		   childPanel1_title4.setAttribute('id','inspectors_title3_div');
-		   childPanel1_title4.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title4.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title4.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title4);
-		   var childPanel1_title5 = document.createElement('div');
-		   childPanel1_title5.setAttribute('class','inspectors_title4_div');
-		   childPanel1_title5.setAttribute('id','inspectors_title4_div');
-		   childPanel1_title5.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title5.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title5.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title5);
-		   var childPanel1_title6 = document.createElement('div');
-		   childPanel1_title6.setAttribute('class','inspectors_title5_div');
-		   childPanel1_title6.setAttribute('id','inspectors_title5_div');
-		   childPanel1_title6.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title6.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title6.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title6);
-		   var childPanel1_title7 = document.createElement('div');
-		   childPanel1_title7.setAttribute('class','inspectors_title6_div');
-		   childPanel1_title7.setAttribute('id','inspectors_title6_div');
-		   childPanel1_title7.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title7.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title7.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title7);
-		   reset1();
-		 }
-	
-	changeon1 = function(obj){
-	      var selected = sm1.getSelection();
-	      var id = selected[0].raw.id
-	   var xid = obj.value;
-	   var query = new Object();
-	  if(xid.length>0){
-	    query.xid = xid;
-	  }
-	  query.id = id;
-	  // query.V_LOGINNAME = V_LOGINNAME;
-	  // query.V_PASSWORD =  V_PASSWORD;
-	  var jsonstr = Ext.JSON.encode(query);
-	     myStore1.getProxy().extraParams = {
-	      queryJson : jsonstr
-	     };
-	     Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
-	 }
-	
-//		var childPanel2 = function() {
-//				var maintenancePersonHtml2 = document.getElementById('InspectorsHtml2');
-//				var divhiddle = document.createElement('div');
-//			    divhiddle.id='div26_id_inspectorsPanel3';
-//			    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
-//			    maintenancePersonHtml2.appendChild(divhiddle);
-//				var childPanel2_title = document.createElement('div');
-//				childPanel2_title.setAttribute('class','maintenancePerson_title211_div');
-//				childPanel2_title.innerHTML='班组名称';
-//				maintenancePersonHtml2.appendChild(childPanel2_title);
-//		 		var childPanel2_input = document.createElement('input');
-//		 		childPanel2_input.setAttribute('class','maintenancePerson_input211_class');
-//		 		childPanel2_input.setAttribute('id','inspectors_title211_input');
-//		 		childPanel2_input.setAttribute('type','text');
-//		 		childPanel2_input.setAttribute('value','');
-//		 		maintenancePersonHtml2.appendChild(childPanel2_input);
-//		 		var childPanel2_title1 = document.createElement('div');
-//		 		childPanel2_title1.setAttribute('class','maintenancePerson_title111_div');
-//		 		childPanel2_title1.innerHTML='负责人';
-//				maintenancePersonHtml2.appendChild(childPanel2_title1);
-//				var select = document.createElement('select');
-//				   select.setAttribute('class','maintenancePerson_input111_class');
-//				   select.setAttribute('onchange',"changeon1(this)");
-//				   select.setAttribute('id','inspectors_title111_input');
-//				   maintenancePersonHtml2.appendChild(select);
-//				   for(var i=0;i<ConfirmStore.length;i++){
-//				    var option3 = document.createElement('option');
-//				    option3.innerHTML=ConfirmStore[i].name;
-//				    option3.setAttribute('value',ConfirmStore[i].rid);
-//				    select.appendChild(option3); 
-//				   }
-//		 		var childPanel2_title2 = document.createElement('div');
-//		 		childPanel2_title2.setAttribute('class','inspectors_title11_div');
-//		 		childPanel2_title2.setAttribute('id','inspectors_title11_div');
-//		 		childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
-//		 		childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
-//		 		childPanel2_title2.setAttribute('onclick',"menu_click(this)");
-//		 		maintenancePersonHtml2.appendChild(childPanel2_title2);
-//		 		var childPanel2_title3 = document.createElement('div');
-//		 		childPanel2_title3.setAttribute('class','inspectors_title21_div');
-//		 		childPanel2_title3.setAttribute('id','inspectors_title21_div');
-//		 		childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
-//		 		childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
-//		 		childPanel2_title3.setAttribute('onclick',"menu_click(this)");
-//		 		maintenancePersonHtml2.appendChild(childPanel2_title3);
-//		    }
-	
-	var childPanel2 = function() {
+
+	changeon1 = function (obj) {
+		var selected = sm1.getSelection();
+		var id = selected[0].raw.id
+		var xid = obj.value;
+		var query = new Object();
+		if (xid.length > 0) {
+			query.xid = xid;
+		}
+		query.id = id;
+		// query.V_LOGINNAME = V_LOGINNAME;
+		// query.V_PASSWORD =  V_PASSWORD;
+		var jsonstr = Ext.JSON.encode(query);
+		myStore1.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
+	}
+
+	//		var childPanel2 = function() {
+	//				var maintenancePersonHtml2 = document.getElementById('InspectorsHtml2');
+	//				var divhiddle = document.createElement('div');
+	//			    divhiddle.id='div26_id_inspectorsPanel3';
+	//			    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
+	//			    maintenancePersonHtml2.appendChild(divhiddle);
+	//				var childPanel2_title = document.createElement('div');
+	//				childPanel2_title.setAttribute('class','maintenancePerson_title211_div');
+	//				childPanel2_title.innerHTML='班组名称';
+	//				maintenancePersonHtml2.appendChild(childPanel2_title);
+	//		 		var childPanel2_input = document.createElement('input');
+	//		 		childPanel2_input.setAttribute('class','maintenancePerson_input211_class');
+	//		 		childPanel2_input.setAttribute('id','inspectors_title211_input');
+	//		 		childPanel2_input.setAttribute('type','text');
+	//		 		childPanel2_input.setAttribute('value','');
+	//		 		maintenancePersonHtml2.appendChild(childPanel2_input);
+	//		 		var childPanel2_title1 = document.createElement('div');
+	//		 		childPanel2_title1.setAttribute('class','maintenancePerson_title111_div');
+	//		 		childPanel2_title1.innerHTML='负责人';
+	//				maintenancePersonHtml2.appendChild(childPanel2_title1);
+	//				var select = document.createElement('select');
+	//				   select.setAttribute('class','maintenancePerson_input111_class');
+	//				   select.setAttribute('onchange',"changeon1(this)");
+	//				   select.setAttribute('id','inspectors_title111_input');
+	//				   maintenancePersonHtml2.appendChild(select);
+	//				   for(var i=0;i<ConfirmStore.length;i++){
+	//				    var option3 = document.createElement('option');
+	//				    option3.innerHTML=ConfirmStore[i].name;
+	//				    option3.setAttribute('value',ConfirmStore[i].rid);
+	//				    select.appendChild(option3); 
+	//				   }
+	//		 		var childPanel2_title2 = document.createElement('div');
+	//		 		childPanel2_title2.setAttribute('class','inspectors_title11_div');
+	//		 		childPanel2_title2.setAttribute('id','inspectors_title11_div');
+	//		 		childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
+	//		 		childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
+	//		 		childPanel2_title2.setAttribute('onclick',"menu_click(this)");
+	//		 		maintenancePersonHtml2.appendChild(childPanel2_title2);
+	//		 		var childPanel2_title3 = document.createElement('div');
+	//		 		childPanel2_title3.setAttribute('class','inspectors_title21_div');
+	//		 		childPanel2_title3.setAttribute('id','inspectors_title21_div');
+	//		 		childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
+	//		 		childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
+	//		 		childPanel2_title3.setAttribute('onclick',"menu_click(this)");
+	//		 		maintenancePersonHtml2.appendChild(childPanel2_title3);
+	//		    }
+
+	var childPanel2 = function () {
 		var maintenancePersonHtml2 = document.getElementById('InspectorsHtml2');
 		var divhiddle = document.createElement('div');
-	    divhiddle.id='div26_id_inspectorsPanel3';
-	    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
-	    maintenancePersonHtml2.appendChild(divhiddle);
-	    var title = document.createElement('div');
-		   title.setAttribute('class','MaintenancePersonTitle123');
-		   title.innerHTML='班组列表';
-		   maintenancePersonHtml2.appendChild(title);			
- 		var childPanel2_title2 = document.createElement('div');
- 		childPanel2_title2.setAttribute('class','inspectors_title11_div');
- 		childPanel2_title2.setAttribute('id','inspectors_title11_div');
- 		childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
- 		childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
- 		childPanel2_title2.setAttribute('onclick',"menu_click(this)");
- 		maintenancePersonHtml2.appendChild(childPanel2_title2);
- 		var childPanel2_title3 = document.createElement('div');
- 		childPanel2_title3.setAttribute('class','inspectors_title21_div');
- 		childPanel2_title3.setAttribute('id','inspectors_title21_div');
- 		childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
- 		childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
- 		childPanel2_title3.setAttribute('onclick',"menu_click(this)");
- 		maintenancePersonHtml2.appendChild(childPanel2_title3);
-    }
-	
-	var childPanel3 = function(){
+		divhiddle.id = 'div26_id_inspectorsPanel3';
+		divhiddle.setAttribute('class', 'SpringHandleHtml3DivHiddle');
+		maintenancePersonHtml2.appendChild(divhiddle);
+		var title = document.createElement('div');
+		title.setAttribute('class', 'MaintenancePersonTitle123');
+		title.innerHTML = '班组列表';
+		maintenancePersonHtml2.appendChild(title);
+		var childPanel2_title2 = document.createElement('div');
+		childPanel2_title2.setAttribute('class', 'inspectors_title11_div');
+		childPanel2_title2.setAttribute('id', 'inspectors_title11_div');
+		childPanel2_title2.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title2.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title2.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml2.appendChild(childPanel2_title2);
+		var childPanel2_title3 = document.createElement('div');
+		childPanel2_title3.setAttribute('class', 'inspectors_title21_div');
+		childPanel2_title3.setAttribute('id', 'inspectors_title21_div');
+		childPanel2_title3.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title3.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title3.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml2.appendChild(childPanel2_title3);
+	}
+
+	var childPanel3 = function () {
 		var maintenancePersonHtml3 = document.getElementById('InspectorsHtml3');
 		var divhiddle = document.createElement('div');
-	    divhiddle.id='div26_id_inspectorsHtml3Panel3';
-	    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
-	    maintenancePersonHtml3.appendChild(divhiddle);
-	    var title1 = document.createElement('div');
-		   title1.setAttribute('class','MaintenancePersonTitle123');
-		   title1.innerHTML='班组详情';
-		   maintenancePersonHtml3.appendChild(title1);
+		divhiddle.id = 'div26_id_inspectorsHtml3Panel3';
+		divhiddle.setAttribute('class', 'SpringHandleHtml3DivHiddle');
+		maintenancePersonHtml3.appendChild(divhiddle);
+		var title1 = document.createElement('div');
+		title1.setAttribute('class', 'MaintenancePersonTitle123');
+		title1.innerHTML = '班组详情';
+		maintenancePersonHtml3.appendChild(title1);
 		var childPanel2_title = document.createElement('div');
-		childPanel2_title.setAttribute('class','maintenancePerson_title211_div');
-		childPanel2_title.innerHTML='班组名称';
+		childPanel2_title.setAttribute('class', 'maintenancePerson_title211_div');
+		childPanel2_title.innerHTML = '班组名称';
 		maintenancePersonHtml3.appendChild(childPanel2_title);
-			var childPanel2_input = document.createElement('input');
-			childPanel2_input.setAttribute('class','maintenancePerson_input211_class');
-			childPanel2_input.setAttribute('id','inspectors_title211_input');
-			childPanel2_input.setAttribute('type','text');
-			childPanel2_input.setAttribute('value','');
-			maintenancePersonHtml3.appendChild(childPanel2_input);
-			var childPanel2_title1 = document.createElement('div');
-			childPanel2_title1.setAttribute('class','maintenancePerson_title111_div');
-			childPanel2_title1.innerHTML='负责人';
-			maintenancePersonHtml3.appendChild(childPanel2_title1);
+		var childPanel2_input = document.createElement('input');
+		childPanel2_input.setAttribute('class', 'maintenancePerson_input211_class');
+		childPanel2_input.setAttribute('id', 'inspectors_title211_input');
+		childPanel2_input.setAttribute('type', 'text');
+		childPanel2_input.setAttribute('value', '');
+		maintenancePersonHtml3.appendChild(childPanel2_input);
+		var childPanel2_title1 = document.createElement('div');
+		childPanel2_title1.setAttribute('class', 'maintenancePerson_title111_div');
+		childPanel2_title1.innerHTML = '负责人';
+		maintenancePersonHtml3.appendChild(childPanel2_title1);
 		var select = document.createElement('select');
-		   select.setAttribute('class','maintenancePerson_input111_class');
-		   select.setAttribute('onchange',"changeon1(this)");
-		   select.setAttribute('id','inspectors_title111_input');
-		   maintenancePersonHtml3.appendChild(select);
-		   for(var i=0;i<ConfirmStore.length;i++){
-		    var option3 = document.createElement('option');
-		    option3.innerHTML=ConfirmStore[i].name;
-		    option3.setAttribute('value',ConfirmStore[i].rid);
-		    select.appendChild(option3); 
-		   }
-	   var childPanel2_title2 = document.createElement('div');
-			childPanel2_title2.setAttribute('class','inspectors_title31_div');
-			childPanel2_title2.setAttribute('id','inspectors_title31_div');
-			childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
-			childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
-			childPanel2_title2.setAttribute('onclick',"menu_click(this)");
-			maintenancePersonHtml3.appendChild(childPanel2_title2);
-		   var childPanel2_title3 = document.createElement('div');
-			childPanel2_title3.setAttribute('class','inspectors_title41_div');
-			childPanel2_title3.setAttribute('id','inspectors_title41_div');
-			childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
-			childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
-			childPanel2_title3.setAttribute('onclick',"menu_click(this)");
-			maintenancePersonHtml3.appendChild(childPanel2_title3);
+		select.setAttribute('class', 'maintenancePerson_input111_class');
+		select.setAttribute('onchange', "changeon1(this)");
+		select.setAttribute('id', 'inspectors_title111_input');
+		maintenancePersonHtml3.appendChild(select);
+		for (var i = 0; i < ConfirmStore.length; i++) {
+			var option3 = document.createElement('option');
+			option3.innerHTML = ConfirmStore[i].name;
+			option3.setAttribute('value', ConfirmStore[i].rid);
+			select.appendChild(option3);
+		}
+		var childPanel2_title2 = document.createElement('div');
+		childPanel2_title2.setAttribute('class', 'inspectors_title31_div');
+		childPanel2_title2.setAttribute('id', 'inspectors_title31_div');
+		childPanel2_title2.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title2.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title2.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml3.appendChild(childPanel2_title2);
+		var childPanel2_title3 = document.createElement('div');
+		childPanel2_title3.setAttribute('class', 'inspectors_title41_div');
+		childPanel2_title3.setAttribute('id', 'inspectors_title41_div');
+		childPanel2_title3.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title3.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title3.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml3.appendChild(childPanel2_title3);
+	}
+
+
+	var childPanel3_fun = function () {
+		var query = new Object();
+		query.V_LOGINNAME = $("#V_LOGINNAME").val();
+		$.ajax({
+			type: 'POST',
+			url: baseUrl + "iot/inspectorsx/getTeamMembersList1xj",
+			data: {
+				queryJson: Ext.JSON.encode(query)
+			},
+			success: function (result) {
+				var json = eval('(' + result + ')');
+				if (json.action == 'getTeamMembersList1xj') {
+					ConfirmStore = json.RESULT;
+					childPanel3();
+				}
+			}
+		});
 	}
-	
-	
-	var childPanel3_fun =function(){
-		  var query = new Object();
-		  query.V_LOGINNAME = $("#V_LOGINNAME").val();
-		  $.ajax({
-		         type:'POST',
-		         url: baseUrl+"iot/inspectorsx/getTeamMembersList1xj",
-		         data: {
-		          queryJson : Ext.JSON.encode(query)
-		       },
-		         success: function(result){
-		             var json = eval('(' + result + ')');
-		             if(json.action=='getTeamMembersList1xj'){
-		                 ConfirmStore = json.RESULT;
-		                 childPanel3();
-		             }
-		         } 
-		     });
-		 }
-	
+
 	var childPanel6 = Ext.create('Ext.Panel', {
-		  height:maxHeight,
-		  width:'20%',
-		        html: '<div></div>'
+		height: maxHeight,
+		width: '20%',
+		html: '<div></div>'
 	});
-//		var childPanel2_fun =function(){
-//			  var query = new Object();
-//			  query.V_LOGINNAME = $("#V_LOGINNAME").val();
-//			  $.ajax({
-//			         type:'POST',
-//			         url: baseUrl+"iot/inspectorsx/getTeamMembersList1xj",
-//			         data: {
-//			          queryJson : Ext.JSON.encode(query)
-//			       },
-//			         success: function(result){
-//			             var json = eval('(' + result + ')');
-//			             if(json.action=='getTeamMembersList1xj'){
-//			                 ConfirmStore = json.RESULT;
-//			                 childPanel2();
-//			             }
-//			         } 
-//			     });
-//			 }
-	
-//		var childPanel3 = Ext.create('Ext.Panel', {
-//			  height:40,
-//			  width:'100%',
-//			        html: '<div id="inspectors_title31_div" class="inspectors_title31_div" onmouseover="mouseon1(this);" onmouseout="mouseoff1(this);" onclick="menu_click(this);"></div><div id="inspectors_title41_div" class="inspectors_title41_div" onmouseover="mouseon1(this);" onmouseout="mouseoff1(this);" onclick="menu_click(this);"></div>'
-//			    });
-	
+	//		var childPanel2_fun =function(){
+	//			  var query = new Object();
+	//			  query.V_LOGINNAME = $("#V_LOGINNAME").val();
+	//			  $.ajax({
+	//			         type:'POST',
+	//			         url: baseUrl+"iot/inspectorsx/getTeamMembersList1xj",
+	//			         data: {
+	//			          queryJson : Ext.JSON.encode(query)
+	//			       },
+	//			         success: function(result){
+	//			             var json = eval('(' + result + ')');
+	//			             if(json.action=='getTeamMembersList1xj'){
+	//			                 ConfirmStore = json.RESULT;
+	//			                 childPanel2();
+	//			             }
+	//			         } 
+	//			     });
+	//			 }
+
+	//		var childPanel3 = Ext.create('Ext.Panel', {
+	//			  height:40,
+	//			  width:'100%',
+	//			        html: '<div id="inspectors_title31_div" class="inspectors_title31_div" onmouseover="mouseon1(this);" onmouseout="mouseoff1(this);" onclick="menu_click(this);"></div><div id="inspectors_title41_div" class="inspectors_title41_div" onmouseover="mouseon1(this);" onmouseout="mouseoff1(this);" onclick="menu_click(this);"></div>'
+	//			    });
+
 	var MaintenancePersonPanel = Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		header: {
+			height: 0,
+			border: '0px solid #000000'
 		},
-	    id: 'InspectorsListPanel',
-	    store: myStore,
-	    selModel: sm,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'id',hidden:true, menuDisabled:true },
-	    	 { header: '职能ID',  dataIndex: 'zn',hidden:true, menuDisabled:true },
-	    	 { header: '序号',  dataIndex: 'xh', width:39, menuDisabled:true },
-		     { header: '姓名', dataIndex: 'name', width:466,align:'center', menuDisabled:true },
-		     { header: '手机号', dataIndex: 'phone', width:466,align:'center', menuDisabled:true },
-		     { header: '职务', dataIndex: 'zn_name', width:466,align:'center', menuDisabled:true },
-		     
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '100%',
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore,  
-            id:'InspectorsListPageToolbar',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-
-        }),
-        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid'
+		id: 'InspectorsListPanel',
+		store: myStore,
+		selModel: sm,
+		columns: [
+			{ header: 'ID', dataIndex: 'id', hidden: true, menuDisabled: true },
+			{ header: '职能ID', dataIndex: 'zn', hidden: true, menuDisabled: true },
+			{ header: '序号', dataIndex: 'xh', width: 39, menuDisabled: true },
+			{ header: '姓名', dataIndex: 'name', width: 466, align: 'center', menuDisabled: true },
+			{ header: '手机号', dataIndex: 'phone', width: 466, align: 'center', menuDisabled: true },
+			{ header: '职务', dataIndex: 'zn_name', width: 466, align: 'center', menuDisabled: true },
+
+		],
+		columnLines: true,
+		height: maxHeight,
+		width: '100%',
+		bbar: new Ext.PagingToolbar({
+			store: myStore,
+			id: 'InspectorsListPageToolbar',
+			displayInfo: true,
+			pageSize: countPerPage,
+			prependButtons: true,
+			displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+			emptyMsg: "没有记录",
+			firstText: '第一页',
+			prevText: '前一页',
+			nextText: '后一页',
+			lastText: '最后一页',
+			refreshText: '刷新',
+
+		}),
+		frame: true,
+		border: false,
+		iconCls: 'icon-grid'
 	});
 	var MaintenancePersonPanel2 = Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		header: {
+			height: 0,
+			border: '0px solid #000000'
 		},
-		bodyStyle:'background:#121E34;',
-	    id: 'InspectorsListPanel2',
-	    store: myStore2,
-	    region:'center',
-	    selModel: sm1,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'id',hidden:true, menuDisabled:true },
-	    	 { header: '责任人ID',  dataIndex: 'person_liable_id',hidden:true, menuDisabled:true },
-	    	 { header: '序号',  dataIndex: 'xh', width:35, menuDisabled:true },
-		     { header: '班组名称', dataIndex: 'team_name', width:340,align:'center', menuDisabled:true },    
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '30%',
-	    listeners: {
-	        select: function(dataview,record,index) {//record被选中时产生的事件
-	         var label = record.get('team_name');
-	         var label1 = record.get('id');
-	         var label2 = record.get('person_liable_id');
-	         var query = new Object();
-	         if(label1.length>0){
-	           query.id = label1;
-	         }
-	         // query.V_LOGINNAME = V_LOGINNAME;
-	         // query.V_PASSWORD =  V_PASSWORD;
-	         var jsonstr = Ext.JSON.encode(query);
-	            myStore1.getProxy().extraParams = {
-	             queryJson : jsonstr
-	            };
-	            Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
-	            document.getElementById('inspectors_title211_input').value = label;
-	            document.getElementById('inspectors_title111_input').value = label2;
-//	         Ext.MessageBox.alert("标题触发了"+label);
-	        }
-//	              itemdblclick: function () {
-//	               Ext.MessageBox.alert("标题离开了");
-//	              }
-	          },
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore2,  
-            id:'InspectorsListPageToolbar2',
-//            displayInfo: true,  
-//            pageSize: countPerPage,  
-//            prependButtons: true,  
-//            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-//            emptyMsg : "没有记录",  
-//            firstText: '第一页',
-//            prevText: '前一页',
-//            nextText: '后一页',
-//            lastText: '最后一页',
-//            refreshText: '刷新',
-
-        }),
-//        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid'
-	});
-	var MaintenancePersonPanel3 = 
-		Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		bodyStyle: 'background:#121E34;',
+		id: 'InspectorsListPanel2',
+		store: myStore2,
+		region: 'center',
+		selModel: sm1,
+		columns: [
+			{ header: 'ID', dataIndex: 'id', hidden: true, menuDisabled: true },
+			{ header: '责任人ID', dataIndex: 'person_liable_id', hidden: true, menuDisabled: true },
+			{ header: '序号', dataIndex: 'xh', width: 35, menuDisabled: true },
+			{ header: '班组名称', dataIndex: 'team_name', width: 340, align: 'center', menuDisabled: true },
+		],
+		columnLines: true,
+		height: maxHeight,
+		width: '30%',
+		listeners: {
+			select: function (dataview, record, index) {//record被选中时产生的事件
+				var label = record.get('team_name');
+				var label1 = record.get('id');
+				var label2 = record.get('person_liable_id');
+				var query = new Object();
+				if (label1.length > 0) {
+					query.id = label1;
+				}
+				// query.V_LOGINNAME = V_LOGINNAME;
+				// query.V_PASSWORD =  V_PASSWORD;
+				var jsonstr = Ext.JSON.encode(query);
+				myStore1.getProxy().extraParams = {
+					queryJson: jsonstr
+				};
+				Ext.getCmp('InspectorsListPageToolbar3').moveFirst();
+				document.getElementById('inspectors_title211_input').value = label;
+				document.getElementById('inspectors_title111_input').value = label2;
+				//	         Ext.MessageBox.alert("标题触发了"+label);
+			}
+			//	              itemdblclick: function () {
+			//	               Ext.MessageBox.alert("标题离开了");
+			//	              }
 		},
-	    id: 'InspectorsListPanel3',
-	    store: myStore1,
-	    region:'center',
-	    selModel: addsm,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'rid',hidden:true, menuDisabled:true },
-	    	 { header: '责任人ID', dataIndex: 'person_liable_id',hidden:true, menuDisabled:true},
-	    	 { header: '班组ID', dataIndex: 'tdid',hidden:true, menuDisabled:true},
-	    	 { header: '默认值', dataIndex: 'pd',hidden:true, menuDisabled:true},
-	    	 { header: '序号',  dataIndex: 'xh', width:35, menuDisabled:true },
-		     { header: '组员', dataIndex: 'name', width:633,align:'center', menuDisabled:true },
-//		     { header: '', dataIndex: 'zrr', width:267,align:'center', menuDisabled:true },
-		     
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '50%',
-	    listeners:{
-	    	
-	         viewready:function(){
-	         var hd_checker = this.getEl().select('div.x-grid3-hd-checker');
-//	         if (hd_checker.hasClass('x-grid3-hd-checker')) {   
-//	                hd_checker.removeClass('x-grid3-hd-checker'); // 去掉全选框 
-//	            } 
-	        }
-	    },
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore1,  
-            id:'InspectorsListPageToolbar3',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-
-        }),
-        border:false,
-        iconCls: 'icon-grid'
+		bbar: new Ext.PagingToolbar({
+			store: myStore2,
+			id: 'InspectorsListPageToolbar2',
+			//            displayInfo: true,  
+			//            pageSize: countPerPage,  
+			//            prependButtons: true,  
+			//            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
+			//            emptyMsg : "没有记录",  
+			//            firstText: '第一页',
+			//            prevText: '前一页',
+			//            nextText: '后一页',
+			//            lastText: '最后一页',
+			//            refreshText: '刷新',
+
+		}),
+		//        frame: true,  
+		border: false,
+		iconCls: 'icon-grid'
 	});
+	var MaintenancePersonPanel3 =
+		Ext.create('Ext.grid.Panel', {
+			header: {
+				height: 0,
+				border: '0px solid #000000'
+			},
+			id: 'InspectorsListPanel3',
+			store: myStore1,
+			region: 'center',
+			selModel: addsm,
+			columns: [
+				{ header: 'ID', dataIndex: 'rid', hidden: true, menuDisabled: true },
+				{ header: '责任人ID', dataIndex: 'person_liable_id', hidden: true, menuDisabled: true },
+				{ header: '班组ID', dataIndex: 'tdid', hidden: true, menuDisabled: true },
+				{ header: '默认值', dataIndex: 'pd', hidden: true, menuDisabled: true },
+				{ header: '序号', dataIndex: 'xh', width: 35, menuDisabled: true },
+				{ header: '组员', dataIndex: 'name', width: 633, align: 'center', menuDisabled: true },
+				//		     { header: '', dataIndex: 'zrr', width:267,align:'center', menuDisabled:true },
 
-	var piebar = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml',
-		width:'100%',
-		height:188,
-		region:'north',
-		layout:'form',
-		defaults:{  
-            border:false
-        }
-//        items: [childPanel1]
+			],
+			columnLines: true,
+			height: maxHeight,
+			width: '50%',
+			listeners: {
+
+				viewready: function () {
+					var hd_checker = this.getEl().select('div.x-grid3-hd-checker');
+					//	         if (hd_checker.hasClass('x-grid3-hd-checker')) {   
+					//	                hd_checker.removeClass('x-grid3-hd-checker'); // 去掉全选框 
+					//	            } 
+				}
+			},
+			bbar: new Ext.PagingToolbar({
+				store: myStore1,
+				id: 'InspectorsListPageToolbar3',
+				displayInfo: true,
+				pageSize: countPerPage,
+				prependButtons: true,
+				displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+				emptyMsg: "没有记录",
+				firstText: '第一页',
+				prevText: '前一页',
+				nextText: '后一页',
+				lastText: '最后一页',
+				refreshText: '刷新',
+
+			}),
+			border: false,
+			iconCls: 'icon-grid'
+		});
+
+	var piebar = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml',
+		width: '100%',
+		height: 188,
+		region: 'north',
+		layout: 'form',
+		defaults: {
+			border: false
+		}
+		//        items: [childPanel1]
 	});
-	var piebar2 = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml2',
-		width:'30%',
-		height:140,
-		bodyStyle:'background:#121E34;',
-		region:'north',
-		layout:'form',
-		defaults:{  
-            border:false
-        }
-//        items: [childPanel2]
+	var piebar2 = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml2',
+		width: '30%',
+		height: 140,
+		bodyStyle: 'background:#121E34;',
+		region: 'north',
+		layout: 'form',
+		defaults: {
+			border: false
+		}
+		//        items: [childPanel2]
 	});
-	var piebar3 = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml3',
-		width:'50%',
-		height:140,
-		region:'north',
-		layout:'form',
-		defaults:{  
-            border:false
-        },
-//        items: [childPanel3]
+	var piebar3 = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml3',
+		width: '50%',
+		height: 140,
+		region: 'north',
+		layout: 'form',
+		defaults: {
+			border: false
+		},
+		//        items: [childPanel3]
 	});
-	panel1 = Ext.create('Ext.panel.Panel',{
-		width:'100%',
+	panel1 = Ext.create('Ext.panel.Panel', {
+		width: '100%',
 		id: 'InspectorsPiebar',
-		layout:'border',
-		items:[
-			piebar,MaintenancePersonPanel
+		layout: 'border',
+		items: [
+			piebar, MaintenancePersonPanel
 		],
-	    
-    });
-	
-	var piebar4 = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml4',
-		width:'30%',
-		region:'west',
-		layout:'border',
-		bodyStyle:'background:#121E34;border-radius:20px;padding:10px;',
-		padding:10,
-		items:[
-			piebar2,MaintenancePersonPanel2
+
+	});
+
+	var piebar4 = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml4',
+		width: '30%',
+		region: 'west',
+		layout: 'border',
+		bodyStyle: 'background:#121E34;border-radius:20px;padding:10px;',
+		padding: 10,
+		items: [
+			piebar2, MaintenancePersonPanel2
 		]
 	});
-	
-	var piebar5 = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml5',
-		width:'50%',
-		region:'center',
-		layout:'border',
-		bodyStyle:'padding:10px;',
-		padding:10,
-		items:[
-			piebar3,MaintenancePersonPanel3
+
+	var piebar5 = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml5',
+		width: '50%',
+		region: 'center',
+		layout: 'border',
+		bodyStyle: 'padding:10px;',
+		padding: 10,
+		items: [
+			piebar3, MaintenancePersonPanel3
 		]
 	});
-	
-	var piebar6 = Ext.create('Ext.panel.Panel',{
-		id:'InspectorsHtml6',
-		width:'20%',
-		region:'east',
-		layout:'form',
-		defaults:{  
-            border:false
-        },
-        items: [childPanel6]
+
+	var piebar6 = Ext.create('Ext.panel.Panel', {
+		id: 'InspectorsHtml6',
+		width: '20%',
+		region: 'east',
+		layout: 'form',
+		defaults: {
+			border: false
+		},
+		items: [childPanel6]
 	});
-	
-	panel2 = Ext.create('Ext.panel.Panel',{
-			width:'100%',
-			id: 'InspectorsPiebar2',
-			layout:'border',
-			items:[
-				piebar4,piebar5,piebar6
-			],
-		    
+
+	panel2 = Ext.create('Ext.panel.Panel', {
+		width: '100%',
+		id: 'InspectorsPiebar2',
+		layout: 'border',
+		items: [
+			piebar4, piebar5, piebar6
+		],
+
 	});
-	
-//	panel2 = Ext.create('Ext.panel.Panel',{
-//			width:'100%',
-//			id: 'InspectorsPiebar2',
-//			layout:'border',
-//			items:[
-//				piebar2,MaintenancePersonPanel2,MaintenancePersonPanel3,piebar3
-//			],
-//		    
-//	});
-	
+
+	//	panel2 = Ext.create('Ext.panel.Panel',{
+	//			width:'100%',
+	//			id: 'InspectorsPiebar2',
+	//			layout:'border',
+	//			items:[
+	//				piebar2,MaintenancePersonPanel2,MaintenancePersonPanel3,piebar3
+	//			],
+	//		    
+	//	});
+
 	Ext.create('Ext.tab.Panel', {
-	     width: '100%',
-	     id: 'InspectorsTab',
-	     activeTab: 0,
-	     items: [
-	         {
-	          itemId:'person',
-	             title: '人员列表',
-	             items : [panel1]
-	         },
-	         {
-	          itemId:'team',
-	             title: '班组详情',
-	             items : [panel2]
-	         }
-	     ],
-	     listeners:{
-	            'tabchange':function (t, n) {
-	             var item = n.itemId;
-	             if(item=='team'){
-	             if(document.getElementById('div26_id_inspectorsPanel3')==undefined)
-	              childPanel2();
-	             if(document.getElementById('div26_id_inspectorsHtml3Panel3')==undefined)
-			      childPanel3_fun();
-	              myStore2.reload();
-	             }
-	            }
-	        },
-	     renderTo : Ext.getBody()
-	     
-	 });
+		width: '100%',
+		id: 'InspectorsTab',
+		activeTab: 0,
+		items: [
+			{
+				itemId: 'person',
+				title: '人员列表',
+				items: [panel1]
+			},
+			{
+				itemId: 'team',
+				title: '班组详情',
+				items: [panel2]
+			}
+		],
+		listeners: {
+			'tabchange': function (t, n) {
+				var item = n.itemId;
+				if (item == 'team') {
+					if (document.getElementById('div26_id_inspectorsPanel3') == undefined)
+						childPanel2();
+					if (document.getElementById('div26_id_inspectorsHtml3Panel3') == undefined)
+						childPanel3_fun();
+					myStore2.reload();
+				}
+			}
+		},
+		renderTo: Ext.getBody()
+
+	});
 	myStore.reload();
 	mystore2_fun(0);
 	childPanel1();
-	$(window).resize(function(){
-    	body_resize();
-    	body_resize1();
-    });
-	body_resize1();	
+	$(window).resize(function () {
+		body_resize();
+		body_resize1();
+	});
+	body_resize1();
 	body_resize();
 });

+ 54 - 4
WebRoot/view/maintenanceperson/scripts/maintenanceperson.js

@@ -335,6 +335,16 @@ Ext.onReady(function(){
 	    }
 	});
 	
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_phone').setValue('');
+				Ext.getCmp('fm_phone').setValue('');
+			});
+			return false;
+		}
+	}
+
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'MaintenancePersonAppendForm',
 		labelWidth: 55,
@@ -347,14 +357,34 @@ Ext.onReady(function(){
 			name:'name',
 			maxLength:20,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
 		},{
 			fieldLabel:'电话号码',
 			id: 'fa_phone',
 			name: 'phone',
 			maxLength: 250,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
 		},{
 		   xtype: 'checkboxgroup',
            fieldLabel: '人员职能',
@@ -543,14 +573,34 @@ Ext.onReady(function(){
 				name:'name',
 				maxLength:20,
 				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
+				anchor:'75%',
+				listeners: {
+					change: function (o, e) {
+						if (e.length > 10) {
+							Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+								Ext.getCmp('fa_name').setValue('');
+							});
+							return false;
+						}
+					}
+				}
 			},{
 				fieldLabel:'电话号码',
 				id: 'fm_phone',
 				name: 'phone',
 				maxLength: 250,
 				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
+				anchor:'75%',
+				listeners: {
+					change: function (o, e) {
+						if (e.length == 11) {
+							public_phone(e);
+						} else {
+							Ext.getCmp('fm_phone').setValue(e.substring(0, 11));
+							e.length == 11 ? public_phone(e) : ''
+						}
+					}
+				}
 			},{
 			    xtype: 'checkboxgroup',
 			    fieldLabel: '人员职能',

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 990 - 1011
WebRoot/view/maintenanceplan/scripts/maintenanceplan.js


+ 81 - 120
WebRoot/view/patrolpoint/scripts/patrolpoint.js

@@ -641,7 +641,7 @@ Ext.onReady(function () {
 						listeners: {
 							change: function (o, e) {
 								if (e.length > 20) {
-									Ext.getCmp('fa_patrol_spot_name').setValue(e.substring(0,20));
+									Ext.getCmp('fa_patrol_spot_name').setValue(e.substring(0, 20));
 								}
 							}
 						}
@@ -685,7 +685,7 @@ Ext.onReady(function () {
 						listeners: {
 							change: function (o, e) {
 								if (e.length > 30) {
-									Ext.getCmp('fa_patrol_spot_address').setValue(e.substring(0,30));
+									Ext.getCmp('fa_patrol_spot_address').setValue(e.substring(0, 30));
 								}
 							}
 						}
@@ -1069,7 +1069,85 @@ Ext.onReady(function () {
 			}]
 	});
 
+	function public_insert() {
+		var fa_patrol_spot_name = Ext.getCmp('fa_patrol_spot_name').getValue();
+		if (fa_patrol_spot_name == "" || fa_patrol_spot_name == null) {
+			Ext.Msg.alert('系统提示', '点位名称不能为空!');
+			return;
+		}
+		var fa_patrol_company_code = Ext.getCmp('fa_patrol_company_code').getValue();
+		if (fa_patrol_company_code == "" || fa_patrol_company_code == null) {
+			Ext.Msg.alert('系统提示', '请选择所属建筑/项目!');
+			return;
+		}
+		var fa_patrol_spot_address = Ext.getCmp('fa_patrol_spot_address').getValue();
+		if (fa_patrol_spot_address == "" || fa_patrol_spot_address == null) {
+			Ext.Msg.alert('系统提示', '点位地址不能为空!');
+			return;
+		}
+		//	        		var fa_patrol_equipment_code=Ext.getCmp('fa_patrol_equipment_code').getValue();
+		var fa_patrol_spot_type = Ext.getCmp('fa_patrol_spot_type').getChecked();
+		var spot_type = '';
+		Ext.Array.each(fa_patrol_spot_type, function (item) {
+			spot_type += item.inputValue + ',';
+		});
+		if (spot_type == null || spot_type == "") {
+			Ext.Msg.alert('系统提示', '至少选择一项设备类型!');
+		}
+		//	        		var fa_patrol_spot_type = patroladdForm.getForm().findField("fa_patrol_spot_type").getGroupValue();
+		var fa_patrol_point_message = Ext.getCmp('fa_patrol_point_message').getValue();
+		var patrol_point_addURL = Ext.getCmp('patrol_point_addURL').getValue();
+		if (patrol_point_addURL == "" || patrol_point_addURL == null) {
+			Ext.Msg.alert('系统提示', '请上传图标' + fa_patrol_spot_type);
+			return;
+		}
+		var query = new Object();
+		query.spot_name = fa_patrol_spot_name;
+		query.company_code = fa_patrol_company_code;
+		query.spot_address = fa_patrol_spot_address;
+		//	        		query.equipment_code = fa_patrol_equipment_code;
+		query.spot_type = spot_type;
+		query.remarks = fa_patrol_point_message;
+		query.picture_route = patrol_point_addURL;
+		if (AllSelectedRecords.length == 1) {
+			query.equipment_code = AllSelectedRecords[0];
+		} else {
+			if (AllSelectedRecords.length > 1) {
+				var spot_id = null;
+				//	                     var selected = sm1.getSelection( );
+				for (var i = 0; i < AllSelectedRecords.length; i++) {
+					if (i == 0)
+						spot_id = AllSelectedRecords[i];
+					else
+						spot_id += "," + AllSelectedRecords[i];
+				}
+				query.equipment_code = spot_id;
+			}else{
+				Ext.Msg.alert('系统提示', '至少选择一条巡检点位,再点击提交!');
+				return;
+			}
+		}
+		query.V_LOGINNAME = V_LOGINNAME;
+		// query.V_PASSWORD =  V_PASSWORD;
+		var jsonstr = Ext.JSON.encode(query);
+		Ext.getCmp('fa_patrol_point_queryJson').setValue(jsonstr);
+		Ext.getCmp('patroladdForm').submit({
+			success: function (form, action) {
+				//	        				addPop.hide();
+				Ext.getCmp('patrol_add_picture').getEl().dom.src = '../../res/img/common/shangchaun.png';
+				Ext.getCmp('patroladdForm').getForm().reset();
+				Ext.getCmp('patroladaddForm').getForm().reset();
+				//	        	       		uploadPanel.getStore().reload();
+				Ext.Msg.alert('系统提示', '保存成功!');
+				clear_append_form();
+			},
+			failure: function (form, action) {
+				Ext.Msg.alert('系统提示', '保存失败!');
+				clear_append_form();
 
+			}
+		});
+	}
 
 	var patroladdWin = Ext.create('Ext.window.Window', {
 		id: 'patroladdWin',
@@ -1086,124 +1164,7 @@ Ext.onReady(function () {
 			{
 				text: '保存',
 				handler: function () {
-					if (AllSelectedRecords.length == 1) {
-						var fa_patrol_spot_name = Ext.getCmp('fa_patrol_spot_name').getValue();
-						if(fa_patrol_spot_name == "" || fa_patrol_spot_name == null){
-							Ext.Msg.alert('系统提示', '点位名称不能为空!');
-							return;
-						}
-						var fa_patrol_company_code = Ext.getCmp('fa_patrol_company_code').getValue();
-						if(fa_patrol_company_code == "" || fa_patrol_company_code == null){
-							Ext.Msg.alert('系统提示', '请选择所属建筑/项目!');
-							return;
-						}
-						var fa_patrol_spot_address = Ext.getCmp('fa_patrol_spot_address').getValue();
-						if(fa_patrol_spot_address == "" || fa_patrol_spot_address == null){
-							Ext.Msg.alert('系统提示', '点位地址不能为空!');
-							return;
-						}
-						//	        		var fa_patrol_equipment_code=Ext.getCmp('fa_patrol_equipment_code').getValue();
-						var fa_patrol_spot_type = Ext.getCmp('fa_patrol_spot_type').getChecked();
-						var spot_type = '';
-						Ext.Array.each(fa_patrol_spot_type, function (item) {
-							spot_type += item.inputValue + ',';
-						});
-						//	        		var fa_patrol_spot_type = patroladdForm.getForm().findField("fa_patrol_spot_type").getGroupValue();
-						var fa_patrol_point_message = Ext.getCmp('fa_patrol_point_message').getValue();
-						var patrol_point_addURL = Ext.getCmp('patrol_point_addURL').getValue();
-						if (patrol_point_addURL == "" || patrol_point_addURL == null) {
-							Ext.Msg.alert('系统提示', '请上传图标' + fa_patrol_spot_type);
-							return;
-						}
-						var query = new Object();
-						query.spot_name = fa_patrol_spot_name;
-						query.company_code = fa_patrol_company_code;
-						query.spot_address = fa_patrol_spot_address;
-						//	        		query.equipment_code = fa_patrol_equipment_code;
-						query.spot_type = spot_type;
-						query.remarks = fa_patrol_point_message;
-						query.picture_route = patrol_point_addURL;
-						query.equipment_code = AllSelectedRecords[0];
-						query.V_LOGINNAME = V_LOGINNAME;
-						// query.V_PASSWORD =  V_PASSWORD;
-						var jsonstr = Ext.JSON.encode(query);
-						Ext.getCmp('fa_patrol_point_queryJson').setValue(jsonstr);
-						Ext.getCmp('patroladdForm').submit({
-							success: function (form, action) {
-								//	        				addPop.hide();
-								Ext.getCmp('patrol_add_picture').getEl().dom.src = '../../res/img/common/shangchaun.png';
-								Ext.getCmp('patroladdForm').getForm().reset();
-								Ext.getCmp('patroladaddForm').getForm().reset();
-								//	        	       		uploadPanel.getStore().reload();
-								Ext.Msg.alert('系统提示', '保存成功!');
-								clear_append_form();
-							},
-							failure: function (form, action) {
-								Ext.Msg.alert('系统提示', '保存失败!');
-								clear_append_form();
-
-							}
-						});
-					} else {
-						if (AllSelectedRecords.length > 1) {
-							var fa_patrol_spot_name = Ext.getCmp('fa_patrol_spot_name').getValue();
-							var fa_patrol_company_code = Ext.getCmp('fa_patrol_company_code').getValue();
-							var fa_patrol_spot_address = Ext.getCmp('fa_patrol_spot_address').getValue();
-							//	  	        		var fa_patrol_equipment_code=Ext.getCmp('fa_patrol_equipment_code').getValue();
-							//	  	        		var fa_patrol_spot_type = patroladdForm.getForm().findField("fa_patrol_spot_type").getGroupValue();
-							var fa_patrol_spot_type = Ext.getCmp('fa_patrol_spot_type').getChecked();
-							var spot_type = '';
-							Ext.Array.each(fa_patrol_spot_type, function (item) {
-								spot_type += item.inputValue + ',';
-							});
-							var fa_patrol_point_message = Ext.getCmp('fa_patrol_point_message').getValue();
-							var patrol_point_addURL = Ext.getCmp('patrol_point_addURL').getValue();
-							if (patrol_point_addURL == "" || patrol_point_addURL == null) {
-								Ext.Msg.alert('系统提示', '请上传图标' + fa_patrol_spot_type);
-								return;
-							}
-							var query = new Object();
-							query.spot_name = fa_patrol_spot_name;
-							query.company_code = fa_patrol_company_code;
-							query.spot_address = fa_patrol_spot_address;
-							//	  	        		query.equipment_code = fa_patrol_equipment_code;
-							query.spot_type = spot_type;
-							query.remarks = fa_patrol_point_message;
-							query.picture_route = patrol_point_addURL;
-							var spot_id = null;
-							//	                     var selected = sm1.getSelection( );
-							for (var i = 0; i < AllSelectedRecords.length; i++) {
-								if (i == 0)
-									spot_id = AllSelectedRecords[i];
-								else
-									spot_id += "," + AllSelectedRecords[i];
-							}
-
-							query.equipment_code = spot_id;
-							query.V_LOGINNAME = V_LOGINNAME;
-							// query.V_PASSWORD =  V_PASSWORD;
-							var jsonstr = Ext.JSON.encode(query);
-							Ext.getCmp('fa_patrol_point_queryJson').setValue(jsonstr);
-							Ext.getCmp('patroladdForm').submit({
-								//	  	        			waitTitle: '系统提示',
-								//	  	        			waitMsg: '保存中......',
-								success: function (form, action) {
-									//	  	        				addPop.hide();
-									Ext.getCmp('patrol_add_picture').getEl().dom.src = '../../res/img/common/shangchaun.png';
-									Ext.getCmp('patroladdForm').getForm().reset();
-									Ext.getCmp('patroladaddForm').getForm().reset();
-									//	  	        	       		uploadPanel.getStore().reload();
-									Ext.Msg.alert('系统提示', '保存成功!');
-									clear_append_form();
-								},
-								failure: function (form, action) {
-									Ext.Msg.alert('系统提示', '保存失败!');
-									clear_append_form();
-
-								}
-							});
-						}
-					}
+					public_insert();
 				}
 			}, {
 				text: '取消',

+ 0 - 5
WebRoot/view/scripts/log.html

@@ -11,7 +11,6 @@
     <script src="https://unpkg.com/element-ui/lib/index.js"></script>
     <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
     <style>
-<<<<<<< HEAD
     .el-table {
         background: transparent !important;
     }
@@ -86,18 +85,14 @@
     .el-table .el-table__body-wrapper::-webkit-scrollbar {
         display: none;
     }
-	html,body,#app{
-=======
         html,
         body,
         #app {
->>>>>>> 6d16855fb9a830c488d691f333de87ec768f6456
             width: 100%;
             height: 100%;
             padding: 0;
             margin: 0;
         }
-        
         .home {
             width: 100%;
             height: 100%;

+ 410 - 349
out/artifacts/YtIoT_Web_exploded/opt/inspectors/scripts/inspectors.js

@@ -6,250 +6,311 @@
  */
 
 Ext.Loader.setConfig({
-    enabled: true
+	enabled: true
 });
 
 Ext.Loader.setPath('Ext.ux', '../../res/extjs/examples/ux');
 
 Ext.require([
-    'Ext.grid.*',
-    'Ext.data.*',
-    'Ext.ux.RowExpander',
-    'Ext.selection.CheckboxModel'
+	'Ext.grid.*',
+	'Ext.data.*',
+	'Ext.ux.RowExpander',
+	'Ext.selection.CheckboxModel'
 ]);
 
 var sm = Ext.create('Ext.selection.CheckboxModel');
 
-Ext.define('Inspectors',{
+Ext.define('Inspectors', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'name',  type:'string'},
-		{name:'phone',  type:'string'},
-		{name:'Job_duties',  type:'string'},
-		{name:'company_code',  type:'string'},
+		{ name: 'id', type: 'string' },
+		{ name: 'name', type: 'string' },
+		{ name: 'phone', type: 'string' },
+		{ name: 'Job_duties', type: 'string' },
+		{ name: 'company_code', type: 'string' },
 	]
 });
 
-Ext.onReady(function(){  
+Ext.onReady(function () {
 	var baseUrl = document.getElementById('basePath').value;
 	var theme = document.getElementById('theme').value;
-	var chkIcon = '<img src="'+baseUrl+'res/img/common/check.gif"/>'
-	var unchkIcon = '<img src="'+baseUrl+'res/img/common/uncheck.gif"/>'
+	var chkIcon = '<img src="' + baseUrl + 'res/img/common/check.gif"/>'
+	var unchkIcon = '<img src="' + baseUrl + 'res/img/common/uncheck.gif"/>'
 	var countPerPage = 20;
 	var maxHeight = 10000;
-	
-	var chkBoolean = function(flag) {
-		if(flag)
+
+	var chkBoolean = function (flag) {
+		if (flag)
 			return chkIcon;
 		return unchkIcon;
 	}
-	
 
-	var clear_append_form = function (){
+
+	var clear_append_form = function () {
 		Ext.getCmp('fa_name').setValue("");
 		Ext.getCmp('fa_phone').setValue("");
 		Ext.getCmp('fa_Job_duties').setValue("");
 		Ext.getCmp('fa_company_code').setValue("");
 		Ext.getCmp('InspectorsListPanel').getStore().reload();
 	}
-		
+
 	var myStore = Ext.create('Ext.data.Store', {
-	    model: 'Inspectors',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        url: baseUrl+'iot/inspectors/getList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        }
-	    },
-	    remoteSort: true
+		model: 'Inspectors',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			url: baseUrl + 'iot/inspectors/getList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			}
+		},
+		remoteSort: true
 	});
-	
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_phone').setValue('');
+				Ext.getCmp('ff_phone').setValue('');
+			});
+			return false;
+		}
+	}
+
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsAppendForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectors/append',
+		url: baseUrl + 'iot/inspectors/append',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'姓名',
+			fieldLabel: '姓名',
 			id: 'fa_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-			fieldLabel:'手机号',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '手机号',
 			id: 'fa_phone',
 			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			fieldLabel:'职务',
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			fieldLabel: '职务',
 			id: 'fa_Job_duties',
-			name:'Job_duties',
+			name: 'Job_duties',
 			maxLength: 30,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			fieldLabel:'单位编号',
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
 			id: 'fa_company_code',
-			name:'company_code',
+			name: 'company_code',
 			maxLength: 30,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'95%'
-		},{
-			id:'fa_queryJson',
-			name:'queryJson',
-			hidden:true
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			id: 'fa_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	query.name = Ext.getCmp('fa_name').getValue();
-		        	query.phone = Ext.getCmp('fa_phone').getValue();
-		        	query.Job_duties = Ext.getCmp('fa_Job_duties').getValue();
-		        	query.company_code = Ext.getCmp('fa_company_code').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fa_queryJson').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-		                	   clear_append_form();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_append_form();
-		                   });
-		                }
-		            });
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					query.name = Ext.getCmp('fa_name').getValue();
+					if(query.name == null || query.name == ""){
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
+					query.phone = Ext.getCmp('fa_phone').getValue();
+					if(query.phone == null || query.phone == ""){
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					}else if (query.phone.length < 11){
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.Job_duties = Ext.getCmp('fa_Job_duties').getValue();
+					query.company_code = Ext.getCmp('fa_company_code').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								clear_append_form();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_append_form();
+							});
+						}
+					});
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var appendwin = function(){
+
+	var appendwin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    width: 400,
-		    layout: 'fit',
-		    items:  AppendForm,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			width: 400,
+			layout: 'fit',
+			items: AppendForm,
+			closeAction: 'hide'
 		}).show();
 	}
-	
+
 	//筛选
-	var clear_filter_form = function(){
+	var clear_filter_form = function () {
 		Ext.getCmp('ff_name').setValue("");
 		Ext.getCmp('ff_phone').setValue("");
 		Ext.getCmp('ff_Job_duties').setValue("");
 		Ext.getCmp('ff_company_code').setValue("");
 	}
-	
+
 	var FilterWin = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsFilterForm',
 		labelWidth: 55,
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'姓名',
+			fieldLabel: '姓名',
 			id: 'ff_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('name').value,
-			anchor:'75%'
-		},{
-			fieldLabel:'手机号',
-			id:'ff_phone',
-			name:'phone',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('name').value,
+			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;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '手机号',
+			id: 'ff_phone',
+			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-	        value : document.getElementById('phone').value,
-	        editable : false 
-		},{
-			fieldLabel:'职务',
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('phone').value,
+			editable: false,
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('ff_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			fieldLabel: '职务',
 			id: 'ff_Job_duties',
 			name: 'Job_duties',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('Job_duties').value,
-			anchor:'95%'
-		},{
-			fieldLabel:'单位编号',
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('Job_duties').value,
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
 			id: 'ff_company_code',
 			name: 'company_code',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			value : document.getElementById('company_code').value,
-			anchor:'95%'
-		},{
-			id:'ff_queryJson',
-			name:'queryJson',
-			hidden:true
+			maxLengthText: '长度不得超出{0}',
+			value: document.getElementById('company_code').value,
+			anchor: '95%'
+		}, {
+			id: 'ff_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	if(Ext.getCmp('ff_name').getValue().length>0)
-		        		query.name = Ext.getCmp('ff_name').getValue();
-		        	if(Ext.getCmp('ff_phone').getValue().length>0)
-		        		query.phone = Ext.getCmp('ff_phone').getValue();	        	
-		        	if(Ext.getCmp('ff_Job_duties').getValue().length>0)
-		        		query.Job_duties = Ext.getCmp('ff_Job_duties').getValue();
-		        		if(Ext.getCmp('ff_company_code').getValue().length>0)
-			        		query.company_code = Ext.getCmp('ff_company_code').getValue();
-		        	
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	myStore.getProxy().extraParams = {
-		        		queryJson : jsonstr
-		        	};	
-		        	Ext.getCmp('InspectorsListPageToolbar').moveFirst();
-		        	Ext.getCmp('name').setValue(query.name);
-		        	Ext.getCmp('phone').setValue(query.phone);
-		        	Ext.getCmp('Job_duties').setValue(query.Job_duties);
-		        	Ext.getCmp('company_code').setValue(query.company_code);
-//		        	myStore.reload();
-		        	clear_filter_form();
-		        	this.up('window').hide();
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					if (Ext.getCmp('ff_name').getValue().length > 0)
+						query.name = Ext.getCmp('ff_name').getValue();
+					if (Ext.getCmp('ff_phone').getValue().length > 0)
+						query.phone = Ext.getCmp('ff_phone').getValue();
+					if (Ext.getCmp('ff_Job_duties').getValue().length > 0)
+						query.Job_duties = Ext.getCmp('ff_Job_duties').getValue();
+					if (Ext.getCmp('ff_company_code').getValue().length > 0)
+						query.company_code = Ext.getCmp('ff_company_code').getValue();
+
+					var jsonstr = Ext.JSON.encode(query);
+					myStore.getProxy().extraParams = {
+						queryJson: jsonstr
+					};
+					Ext.getCmp('InspectorsListPageToolbar').moveFirst();
+					Ext.getCmp('name').setValue(query.name);
+					Ext.getCmp('phone').setValue(query.phone);
+					Ext.getCmp('Job_duties').setValue(query.Job_duties);
+					Ext.getCmp('company_code').setValue(query.company_code);
+					//		        	myStore.reload();
+					clear_filter_form();
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
 
-	
-	
-	
-	var filterwin = function() {
-		Ext.create('Ext.window.Window',{
+
+
+
+	var filterwin = function () {
+		Ext.create('Ext.window.Window', {
 			title: '筛选',
 			height: 300,
 			width: 350,
@@ -258,8 +319,8 @@ Ext.onReady(function(){
 			closeAction: 'hide'
 		}).show();
 	}
-	
-	var clear_modify_form = function (){
+
+	var clear_modify_form = function () {
 		Ext.getCmp('fm_id').setValue("");
 		Ext.getCmp('fm_name').setValue("");
 		Ext.getCmp('fm_phone').setValue("");
@@ -267,228 +328,228 @@ Ext.onReady(function(){
 		Ext.getCmp('fm_company_code').setValue("");
 		Ext.getCmp('InspectorsListPanel').getStore().reload();
 	}
-	
-	
-	
+
+
+
 	var ModifyForm = Ext.create('Ext.form.Panel', {
 		id: 'InspectorsEditForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectors/update',
+		url: baseUrl + 'iot/inspectors/update',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-				fieldLabel:'姓名',
-				id: 'fm_name',
-				name:'name',
-				maxLength:20,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
-			},{
-				fieldLabel:'手机号',
-				id: 'fm_phone',
-				name: 'phone',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
-				fieldLabel:'职务',
-				id: 'fm_Job_duties',
-				name: 'Job_duties',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
-				fieldLabel:'单位编号',
-				id: 'fm_company_code',
-				name: 'company_code',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'95%'
-			},{
+			fieldLabel: '姓名',
+			id: 'fm_name',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%'
+		}, {
+			fieldLabel: '手机号',
+			id: 'fm_phone',
+			name: 'phone',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '职务',
+			id: 'fm_Job_duties',
+			name: 'Job_duties',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
+			fieldLabel: '单位编号',
+			id: 'fm_company_code',
+			name: 'company_code',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '95%'
+		}, {
 			id: 'fm_id',
-			name:'id',
-			hidden:true
-		},{
-			id:'fm_queryJson',
-			name:'queryJson',
-			hidden:true
+			name: 'id',
+			hidden: true
+		}, {
+			id: 'fm_queryJson',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '修改',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		    	var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	query.id = Ext.getCmp('fm_id').getValue();
-		        	query.name = Ext.getCmp('fm_name').getValue();
-		        	query.phone = Ext.getCmp('fm_phone').getValue();
-		        	query.Job_duties = Ext.getCmp('fm_Job_duties').getValue();
-		        	query.company_code = Ext.getCmp('fm_company_code').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fm_queryJson').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_modify_form();
-		                   });
-		                }
-		            });
-		            this.up('window').hide();
-		        }
-		    }
-		},{
+			text: '修改',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					query.id = Ext.getCmp('fm_id').getValue();
+					query.name = Ext.getCmp('fm_name').getValue();
+					query.phone = Ext.getCmp('fm_phone').getValue();
+					query.Job_duties = Ext.getCmp('fm_Job_duties').getValue();
+					query.company_code = Ext.getCmp('fm_company_code').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fm_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+								clear_modify_form();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_modify_form();
+							});
+						}
+					});
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var modifywin = function(){
+
+	var modifywin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '修改',
-		    height: 350,
-		    width: 400,
-		    layout: 'fit',
-		    items:  ModifyForm,
-		    closeAction: 'hide'
+			title: '修改',
+			height: 350,
+			width: 400,
+			layout: 'fit',
+			items: ModifyForm,
+			closeAction: 'hide'
 		}).show();
 	}
-		
-	var chk_sm = function() {
-		if(sm.getCount()==1){
+
+	var chk_sm = function () {
+		if (sm.getCount() == 1) {
 			modifywin();
-			var selected = sm.getSelection( );
+			var selected = sm.getSelection();
 			Ext.getCmp('fm_id').setValue(selected[0].raw.id);
 			Ext.getCmp('fm_name').setValue(selected[0].raw.name);
 			Ext.getCmp('fm_phone').setValue(selected[0].raw.phone);
 			Ext.getCmp('fm_Job_duties').setValue(selected[0].raw.Job_duties);
 			Ext.getCmp('fm_company_code').setValue(selected[0].raw.company_code);
-		}else{
-			Ext.Msg.alert('请先选择','请先选择一条记录,再点击修改');
+		} else {
+			Ext.Msg.alert('请先选择', '请先选择一条记录,再点击修改');
 		}
 	}
-	
-//	
-//	var deletewin = function() {
-//		window.alert("无此功能");
-//		
-//	}
-	
+
+	//	
+	//	var deletewin = function() {
+	//		window.alert("无此功能");
+	//		
+	//	}
+
 	Ext.create('Ext.grid.Panel', {
-	    title: '巡检人管理',
-	    id: 'InspectorsListPanel',
-	    store: myStore,
-	    selModel: sm,
-	    columns: [
-	    	 //{ header: 'ID',  dataIndex: 'UQ_POINT_ID',hidden:true, menuDisabled:true },
-		     { header: 'ID',  dataIndex: 'id', width:40, menuDisabled:true },
-		     { header: '姓名', dataIndex: 'name', width:120,align:'center', menuDisabled:true },
-		     { header: '手机号', dataIndex: 'phone', width:160,align:'center', menuDisabled:true },
-		     { header: '职务', dataIndex: 'Job_duties', width:120,align:'center', menuDisabled:true },
-		     { header: '单位编号', dataIndex: 'company_code', width:120,align:'center', menuDisabled:true },
-//		     { header: '记录版本', dataIndex: 'I_VERSION', width:120, align:'center', menuDisabled:true },
-//		     { 
-//	        	xtype : 'actioncolumn',
-//	        	width:20,
-//	        	sortable:false,
-//	        	
-//	        	
-//	        	//这里
-//	        	align:'center',
-//	        	menuDisabled:true,
-//	        	items:[{
-//	        		icon: '../../res/img/common/forum.gif',
-//	        		tooltip: '版本记录',
-//	        		handler: function(grid, rowIndex, colIndex) {
-//	                    var rec = grid.getStore().getAt(rowIndex);
-//	        			window.location = 'version.jsp?theme='+theme+'&pointId='+rec.get('UQ_POINT_ID');
-//	                }
-//	        	}]
-//    		}
-	    ],
-	    columnLines: true,
-	    tbar: [
-	    	{
-				  xtype: 'button', 
-				  iconCls:'filter_btn',  
-				  text: '筛选',
-				  listeners: {
-				        click: filterwin
-				  }
-	    	},'-',
-	    	{xtype: 'tbfill'},'-',
-			{ 
-				  xtype: 'button', 
-				  iconCls:'append_btn',  
-				  text: '新增',
-				  listeners: {
-				        click: appendwin
-				  }
+		title: '巡检人管理',
+		id: 'InspectorsListPanel',
+		store: myStore,
+		selModel: sm,
+		columns: [
+			//{ header: 'ID',  dataIndex: 'UQ_POINT_ID',hidden:true, menuDisabled:true },
+			{ header: 'ID', dataIndex: 'id', width: 40, menuDisabled: true },
+			{ header: '姓名', dataIndex: 'name', width: 120, align: 'center', menuDisabled: true },
+			{ header: '手机号', dataIndex: 'phone', width: 160, align: 'center', menuDisabled: true },
+			{ header: '职务', dataIndex: 'Job_duties', width: 120, align: 'center', menuDisabled: true },
+			{ header: '单位编号', dataIndex: 'company_code', width: 120, align: 'center', menuDisabled: true },
+			//		     { header: '记录版本', dataIndex: 'I_VERSION', width:120, align:'center', menuDisabled:true },
+			//		     { 
+			//	        	xtype : 'actioncolumn',
+			//	        	width:20,
+			//	        	sortable:false,
+			//	        	
+			//	        	
+			//	        	//这里
+			//	        	align:'center',
+			//	        	menuDisabled:true,
+			//	        	items:[{
+			//	        		icon: '../../res/img/common/forum.gif',
+			//	        		tooltip: '版本记录',
+			//	        		handler: function(grid, rowIndex, colIndex) {
+			//	                    var rec = grid.getStore().getAt(rowIndex);
+			//	        			window.location = 'version.jsp?theme='+theme+'&pointId='+rec.get('UQ_POINT_ID');
+			//	                }
+			//	        	}]
+			//    		}
+		],
+		columnLines: true,
+		tbar: [
+			{
+				xtype: 'button',
+				iconCls: 'filter_btn',
+				text: '筛选',
+				listeners: {
+					click: filterwin
+				}
+			}, '-',
+			{ xtype: 'tbfill' }, '-',
+			{
+				xtype: 'button',
+				iconCls: 'append_btn',
+				text: '新增',
+				listeners: {
+					click: appendwin
+				}
 			},
-			{ 
-				xtype: 'button', 
-				iconCls:'modify_btn', 
+			{
+				xtype: 'button',
+				iconCls: 'modify_btn',
 				text: '修改',
 				listeners: {
 					click: chk_sm
 				}
 			},
-//			{ 
-//				xtype: 'button',
-//				iconCls:'delete_btn',
-//				text: '注销',
-//				listeners: {
-//					click: deletewin
-//				}
-//			}
-//			,{ 
-//				xtype: 'button',
-//				iconCls:'delete_btn',
-//				text: '导出',
-//				listeners: {
-//					click: export_sj
-//				}
-//			}
-			
-    	],
-	    height: maxHeight,
-	    width: '100%',
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore,  
-            id:'InspectorsListPageToolbar',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-//            doRefresh:function(start){  
-//            	alert(start);
-//                relushDataFunction(start); // 调用函数刷新数据  
-//                this.cursor = start; // 更新页签  
-//            }
+			//			{ 
+			//				xtype: 'button',
+			//				iconCls:'delete_btn',
+			//				text: '注销',
+			//				listeners: {
+			//					click: deletewin
+			//				}
+			//			}
+			//			,{ 
+			//				xtype: 'button',
+			//				iconCls:'delete_btn',
+			//				text: '导出',
+			//				listeners: {
+			//					click: export_sj
+			//				}
+			//			}
+
+		],
+		height: maxHeight,
+		width: '100%',
+		bbar: new Ext.PagingToolbar({
+			store: myStore,
+			id: 'InspectorsListPageToolbar',
+			displayInfo: true,
+			pageSize: countPerPage,
+			prependButtons: true,
+			displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+			emptyMsg: "没有记录",
+			firstText: '第一页',
+			prevText: '前一页',
+			nextText: '后一页',
+			lastText: '最后一页',
+			refreshText: '刷新',
+			//            doRefresh:function(start){  
+			//            	alert(start);
+			//                relushDataFunction(start); // 调用函数刷新数据  
+			//                this.cursor = start; // 更新页签  
+			//            }
 
-        }),
-        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid',
-	    renderTo: Ext.getBody()
+		}),
+		frame: true,
+		border: false,
+		iconCls: 'icon-grid',
+		renderTo: Ext.getBody()
 	});
 	myStore.reload();
-	maxHeight =  document.documentElement.clientHeight;
+	maxHeight = document.documentElement.clientHeight;
 	Ext.getCmp('InspectorsListPanel').setHeight(maxHeight);
-	
+
 });

BIN
out/artifacts/YtIoT_Web_exploded/userUpload/46b54756-e0e2-4104-b134-1d08798e2fde.png


BIN
out/artifacts/YtIoT_Web_exploded/userUpload/65f13b7b-4850-4b32-aaac-fd700c913ea0.png


BIN
out/artifacts/YtIoT_Web_exploded/userUpload/6c927dca-f945-4235-b08c-cba1bacae1f6.png


BIN
out/artifacts/YtIoT_Web_exploded/userUpload/f154e3db-cf43-4d60-82b2-3ee550cb1c62.png


+ 54 - 4
out/artifacts/YtIoT_Web_exploded/view/companyxx/scripts/companyxx.js

@@ -186,6 +186,16 @@ Ext.onReady(function(){
 		Ext.getCmp('fa_sbtype').setValue("");
 		Ext.getCmp('PatrolPlanListPageToolbar').getStore().reload();
 	}
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_bjhm').setValue('');
+				Ext.getCmp('fm_bjhm').setValue('');
+			});
+			return false;
+		}
+	}
 	
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'companyxxAppendForm1',
@@ -206,14 +216,34 @@ Ext.onReady(function(){
 			name:'name',
 			maxLength:20,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '责任人姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
 		},{
 			fieldLabel:'责任人手机号',
 			id: 'fa_bjhm',
 			name:'bjhm',
 			maxLength:20,
 			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
+			anchor:'75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_bjhm').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
 		},{
 			fieldLabel:'显号',
 			id:'fa_bjxh',
@@ -768,14 +798,34 @@ Ext.onReady(function(){
 					name:'name',
 					maxLength:20,
 					maxLengthText:'长度不得超出{0}',
-					anchor:'75%'
+					anchor:'75%',
+					listeners: {
+						change: function (o, e) {
+							if (e.length > 10) {
+								Ext.Msg.alert('提示', '责任人姓名长度不可超过10个字!', function (btn, txt) {
+									Ext.getCmp('fm_name').setValue('');
+								});
+								return false;
+							}
+						}
+					}
 				},{
 					fieldLabel:'责任人手机号',
 					id: 'fm_bjhm',
 					name:'bjhm',
 					maxLength:20,
 					maxLengthText:'长度不得超出{0}',
-					anchor:'75%'
+					anchor:'75%',
+					listeners: {
+						change: function (o, e) {
+							if (e.length == 11) {
+								public_phone(e);
+							} else {
+								Ext.getCmp('fm_bjhm').setValue(e.substring(0, 11));
+								e.length == 11 ? public_phone(e) : ''
+							}
+						}
+					}
 				},{
 					fieldLabel:'显号',
 					id:'fm_bjxh',

+ 32 - 2
out/artifacts/YtIoT_Web_exploded/view/inspectors/scripts/inspectors.js

@@ -388,9 +388,24 @@ Ext.onReady(function () {
 					});
 					var query = new Object();
 					// query.V_LOGINNAME = V_LOGINNAME;
-					query.zn = Inspectiontime;
 					query.name = Ext.getCmp('fa_Inspectors_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
 					query.phone = Ext.getCmp('fa_Inspectors_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					}else if (query.phone.length < 11){
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if(query.zn == 0){
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
 					var jsonstr = Ext.JSON.encode(query);
 					Ext.getCmp('fa_Inspectors_queryJson').setValue(jsonstr);
 					form.submit({
@@ -590,10 +605,25 @@ Ext.onReady(function () {
 						Inspectiontime += parseInt(item.inputValue);
 					});
 					var query = new Object();
-					query.zn = Inspectiontime;
 					query.id = Ext.getCmp('fm_inspectors_id').getValue();
 					query.name = Ext.getCmp('fm_inspectors_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
 					query.phone = Ext.getCmp('fm_inspectors_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					}else if (query.phone.length < 11){
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if(query.zn == 0){
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
 					var jsonstr = Ext.JSON.encode(query);
 					Ext.getCmp('fm_inspectors_queryJson').setValue(jsonstr);
 					form.submit({

+ 1412 - 1330
out/artifacts/YtIoT_Web_exploded/view/maintenanceperson/scripts/maintenanceperson.js

@@ -6,23 +6,23 @@
  */
 
 Ext.Loader.setConfig({
-    enabled: true
+	enabled: true
 });
 
 Ext.Loader.setPath('Ext.ux', '../../res/extjs/examples/ux');
 
 Ext.require([
-    'Ext.grid.*',
-    'Ext.data.*',
-    'Ext.ux.RowExpander',
-    'Ext.selection.CheckboxModel'
+	'Ext.grid.*',
+	'Ext.data.*',
+	'Ext.ux.RowExpander',
+	'Ext.selection.CheckboxModel'
 ]);
 
 var company_code;
-var myStore=null;
-var myStore1=null;
-var myStore2=null;
-var V_LOGINNAME='',V_PASSWORD='';
+var myStore = null;
+var myStore1 = null;
+var myStore2 = null;
+var V_LOGINNAME = '', V_PASSWORD = '';
 var menuidx = '';
 var mouseon;
 var mouseoff;
@@ -34,111 +34,111 @@ var panel2;
 var changeon1;
 
 var sm = Ext.create('Ext.selection.CheckboxModel');
-var addsm = Ext.create('Ext.selection.CheckboxModel',{
-	handleMouseDown : Ext.emptyFn,  
-    singleSelect : false 
+var addsm = Ext.create('Ext.selection.CheckboxModel', {
+	handleMouseDown: Ext.emptyFn,
+	singleSelect: false
 });
-var sm1 = Ext.create('Ext.selection.CheckboxModel',{
-	injectCheckbox:1,//checkbox位于哪一列,默认值为0
-	mode:'single',//multi,simple,single;默认为多选multi
-//	checkOnly:true,//如果值为true,则只用点击checkbox列才能选中此条记录
-	allowDeselect:true,//如果值true,并且mode值为单选(single)时,可以通过点击checkbox取消对其的选择
-	enableKeyNav:false,
+var sm1 = Ext.create('Ext.selection.CheckboxModel', {
+	injectCheckbox: 1,//checkbox位于哪一列,默认值为0
+	mode: 'single',//multi,simple,single;默认为多选multi
+	//	checkOnly:true,//如果值为true,则只用点击checkbox列才能选中此条记录
+	allowDeselect: true,//如果值true,并且mode值为单选(single)时,可以通过点击checkbox取消对其的选择
+	enableKeyNav: false,
 	listeners: {
-	 deselect: function(model,record,index) {//取消选中时产生的事件
-	 }
+		deselect: function (model, record, index) {//取消选中时产生的事件
+		}
 	}
 });
 
-Ext.define('MaintenancePerson',{
+Ext.define('MaintenancePerson', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'name',  type:'string'},
-		{name:'phone',  type:'string'},
-		{name:'zn_name',  type:'string'},
-		{name:'xh',  type:'int'},
+		{ name: 'id', type: 'string' },
+		{ name: 'name', type: 'string' },
+		{ name: 'phone', type: 'string' },
+		{ name: 'zn_name', type: 'string' },
+		{ name: 'xh', type: 'int' },
 	]
 });
-Ext.define('MaintenancePerson1',{
+Ext.define('MaintenancePerson1', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'rid',  type:'int'},
-		{name:'xh',  type:'int'},
-		{name:'name',  type:'string'},
-		{name:'tdid',  type:'string'},
-		{name:'pd',  type:'int'},
-//		{name:'zrr',  type:'string'},
+		{ name: 'rid', type: 'int' },
+		{ name: 'xh', type: 'int' },
+		{ name: 'name', type: 'string' },
+		{ name: 'tdid', type: 'string' },
+		{ name: 'pd', type: 'int' },
+		//		{name:'zrr',  type:'string'},
 	]
 });
 
-Ext.define('MaintenancePerson2',{
+Ext.define('MaintenancePerson2', {
 	extend: 'Ext.data.Model',
 	fields: [
-		{name:'id',  type:'string'},
-		{name:'xh',  type:'int'},
-		{name:'team_name',  type:'string'},
-		{name:'person_liable_id',  type:'string'},
-		
+		{ name: 'id', type: 'string' },
+		{ name: 'xh', type: 'int' },
+		{ name: 'team_name', type: 'string' },
+		{ name: 'person_liable_id', type: 'string' },
+
 	]
 });
 
-function exportbtn_click(){
+function exportbtn_click() {
 	baseUrl = document.getElementById('basePath').value;
 	V_LOGINNAME = $("#V_LOGINNAME").val();
 	V_PASSWORD = $("#V_PASSWORD").val();
 	name = document.getElementById('name').value;
 	zn = document.getElementById('zn').value;
-	
-//	zn_name = document.getElementById('zn_name').value;
+
+	//	zn_name = document.getElementById('zn_name').value;
 	var fields = '';
-	var array = ['id','xh','name','phone','zn_name'];
-	var excelname = ['ID','序号','姓名','手机号','职务'];
-	for(var i=0;i<5;i++){
-		if(i>0)
+	var array = ['id', 'xh', 'name', 'phone', 'zn_name'];
+	var excelname = ['ID', '序号', '姓名', '手机号', '职务'];
+	for (var i = 0; i < 5; i++) {
+		if (i > 0)
 			fields += ',';
-	    fields += '{id:"'+array[i]+'",title:"'+excelname[i]+'",shown:"'+true+'"}';
+		fields += '{id:"' + array[i] + '",title:"' + excelname[i] + '",shown:"' + true + '"}';
 	}
-			var query = new Object();
-			// query.V_LOGINNAME = V_LOGINNAME;
-			// query.V_PASSWORD = V_PASSWORD;
-			query.name = name;
-			query.zn = zn;
-			query.EXPORT_FILE = '维保人列表';
-			query.fields = '['+fields+']';
-			$.ajax({
-		        type:'POST',
-		        url: baseUrl+"iot/excel/view/XjInspectorsExcel",
-		        data: {
-		        	queryJson : Ext.JSON.encode(query)
-		    	 },
-		    	 success: function(result){
-		    		
-			            var json = eval('(' + result + ')');
-			            if(json.action=='dormExport'){
-			                ConfirmStore = json.RESULT;
-			               
-			                var elemIF = document.createElement("iframe");
-							elemIF.src = baseUrl+json.filename;
-							elemIF.style.display = "none"; 
-							document.body.appendChild(elemIF);
-			            }
-			    
-			        }
-		    });
-			
+	var query = new Object();
+	// query.V_LOGINNAME = V_LOGINNAME;
+	// query.V_PASSWORD = V_PASSWORD;
+	query.name = name;
+	query.zn = zn;
+	query.EXPORT_FILE = '维保人列表';
+	query.fields = '[' + fields + ']';
+	$.ajax({
+		type: 'POST',
+		url: baseUrl + "iot/excel/view/XjInspectorsExcel",
+		data: {
+			queryJson: Ext.JSON.encode(query)
+		},
+		success: function (result) {
+
+			var json = eval('(' + result + ')');
+			if (json.action == 'dormExport') {
+				ConfirmStore = json.RESULT;
+
+				var elemIF = document.createElement("iframe");
+				elemIF.src = baseUrl + json.filename;
+				elemIF.style.display = "none";
+				document.body.appendChild(elemIF);
+			}
+
+		}
+	});
+
 }
 
-var body_resize = function(){
-	maxHeight =  document.documentElement.clientHeight;
-	maxHeight-=34;
+var body_resize = function () {
+	maxHeight = document.documentElement.clientHeight;
+	maxHeight -= 34;
 	maxWidth = document.documentElement.clientWidth;
 	Ext.getCmp('MaintenancePersonPiebar').setHeight(maxHeight);
 	Ext.getCmp('MaintenancePersonPiebar').setWidth(maxWidth);
 }
-var body_resize1 = function(){
-	maxHeight =  document.documentElement.clientHeight;
-	maxHeight-=34;
+var body_resize1 = function () {
+	maxHeight = document.documentElement.clientHeight;
+	maxHeight -= 34;
 	maxWidth = document.documentElement.clientWidth;
 	Ext.getCmp('MaintenancePersonPiebar2').setHeight(maxHeight);
 	Ext.getCmp('MaintenancePersonPiebar2').setWidth(maxWidth);
@@ -148,1466 +148,1548 @@ var body_resize1 = function(){
 //	Ext.getCmp('MaintenancePersonTab').setHeight(maxHeight1);
 //}
 
-Ext.onReady(function(){  
+Ext.onReady(function () {
 	var baseUrl = document.getElementById('basePath').value;
 	var theme = document.getElementById('theme').value;
-	var chkIcon = '<img src="'+baseUrl+'res/img/common/check.gif"/>'
-	var unchkIcon = '<img src="'+baseUrl+'res/img/common/uncheck.gif"/>'
+	var chkIcon = '<img src="' + baseUrl + 'res/img/common/check.gif"/>'
+	var unchkIcon = '<img src="' + baseUrl + 'res/img/common/uncheck.gif"/>'
 	$("#V_LOGINNAME").val(sessionStorage.getItem('V_LOGINNAME'));
 	$("#V_PASSWORD").val(sessionStorage.getItem('V_PASSWORD'));
 	V_LOGINNAME = $("#V_LOGINNAME").val();
-    V_PASSWORD = $("#V_PASSWORD").val();
+	V_PASSWORD = $("#V_PASSWORD").val();
 	var countPerPage = 15;
 	var maxHeight = 10000;
-//	var maxHeight1 = 10000;
-	
-	var chkBoolean = function(flag) {
-		if(flag)
+	//	var maxHeight1 = 10000;
+
+	var chkBoolean = function (flag) {
+		if (flag)
 			return chkIcon;
 		return unchkIcon;
 	}
-	
+
 	var queryJson = new Object();
 	queryJson.V_LOGINNAME = V_LOGINNAME;
-	queryJson.V_PASSWORD =  V_PASSWORD;
-//	queryJson.COMMSTATUS = 'NO';
-	if((company_code!=null)&&(company_code!='null')&&(company_code.length>0))
-		queryJson.company_code = company_code;	
-	
-	var clear_append_form1 = function (){
+	queryJson.V_PASSWORD = V_PASSWORD;
+	//	queryJson.COMMSTATUS = 'NO';
+	if ((company_code != null) && (company_code != 'null') && (company_code.length > 0))
+		queryJson.company_code = company_code;
+
+	var clear_append_form1 = function () {
 		Ext.getCmp('fa_team_name').setValue("");
 		Ext.getCmp('fa_person_liable_id').setValue("");
 		Ext.getCmp('MaintenancePersonListPageToolbar2').moveFirst();
 	}
-	
+
 	myStore = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-	    remoteSort: true
+		model: 'MaintenancePerson',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		remoteSort: true
 	});
-	
+
 	myStore2 = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson2',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/planteam/getList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-//	    sorters:[{
-//	    	property:'data_time',
-//	    	direction:'DESC'
-//	    }],
-	    remoteSort: true
+		model: 'MaintenancePerson2',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/planteam/getList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		//	    sorters:[{
+		//	    	property:'data_time',
+		//	    	direction:'DESC'
+		//	    }],
+		remoteSort: true
 	});
-	
-	var mystore2_fun = function(id){
-		  if(id== 0){
-		   myStore2.on('load',function(myStore2, record){
-		    for (var i = 0; i < record.length; i++) { 
-		     var records = record[i]; 
-		     if (records.get('xh') == 1) {
-		      Ext.getCmp('MaintenancePersonListPanel2').getSelectionModel().select(records, true);
-		     }
-		    };
-		      });
-		  }else{
-		   myStore2.reload();
-		   myStore2.on('load',function(myStore2, record){
-		    for (var i = 0; i < record.length; i++) { 
-		     var records = record[i]; 
-		     if (records.get('id') == id) {
-		      Ext.getCmp('MaintenancePersonListPanel2').getSelectionModel().select(records, true);
-		     }
-		    };
-		      });
-		  }
-		 }
-	
+
+	var mystore2_fun = function (id) {
+		if (id == 0) {
+			myStore2.on('load', function (myStore2, record) {
+				for (var i = 0; i < record.length; i++) {
+					var records = record[i];
+					if (records.get('xh') == 1) {
+						Ext.getCmp('MaintenancePersonListPanel2').getSelectionModel().select(records, true);
+					}
+				};
+			});
+		} else {
+			myStore2.reload();
+			myStore2.on('load', function (myStore2, record) {
+				for (var i = 0; i < record.length; i++) {
+					var records = record[i];
+					if (records.get('id') == id) {
+						Ext.getCmp('MaintenancePersonListPanel2').getSelectionModel().select(records, true);
+					}
+				};
+			});
+		}
+	}
+
 	myStore1 = Ext.create('Ext.data.Store', {
-	    model: 'MaintenancePerson1',
-	    pageSize: countPerPage, 
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getTeamMembersList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    },
-//	    sorters:[{
-//	    	property:'data_time',
-//	    	direction:'DESC'
-//	    }],
-	    remoteSort: true
+		model: 'MaintenancePerson1',
+		pageSize: countPerPage,
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getTeamMembersList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		},
+		//	    sorters:[{
+		//	    	property:'data_time',
+		//	    	direction:'DESC'
+		//	    }],
+		remoteSort: true
 	});
-	
-	myStore1.on('load',function(myStore1, record){
-//		var index = myStore1.find('pd',1);
-//		Ext.getCmp('MaintenancePersonListPanel3').getSelectionModel().select(index);
-		for (var i = 0; i < record.length; i++) { 
-		    var records = record[i]; 
-		    if (records.get('pd') == 1) {
-		     Ext.getCmp('MaintenancePersonListPanel3').getSelectionModel().select(records, true);
-		     }
-		   };
+
+	myStore1.on('load', function (myStore1, record) {
+		//		var index = myStore1.find('pd',1);
+		//		Ext.getCmp('MaintenancePersonListPanel3').getSelectionModel().select(index);
+		for (var i = 0; i < record.length; i++) {
+			var records = record[i];
+			if (records.get('pd') == 1) {
+				Ext.getCmp('MaintenancePersonListPanel3').getSelectionModel().select(records, true);
+			}
+		};
 	});
-	
-//	myStore1.addListener('load',function(){  
-//		   var records=[];//存放选中记录  
-//		   for(var i=0;i<myStore1.getCount();i++){  
-//		    var record = myStore1.getAt(i);  
-//		    if(record.data.id==7){//根据后台数据判断那些记录默认选中  
-//		     records.push(record);  
-//		    }  
-//		   }  
-//		   sm.selectRecords(records);//执行选中记录  
-//    });
-	
-	Ext.define('getJobDutiesStore1',{
-		extend:'Ext.data.Model',
+
+	//	myStore1.addListener('load',function(){  
+	//		   var records=[];//存放选中记录  
+	//		   for(var i=0;i<myStore1.getCount();i++){  
+	//		    var record = myStore1.getAt(i);  
+	//		    if(record.data.id==7){//根据后台数据判断那些记录默认选中  
+	//		     records.push(record);  
+	//		    }  
+	//		   }  
+	//		   sm.selectRecords(records);//执行选中记录  
+	//    });
+
+	Ext.define('getJobDutiesStore1', {
+		extend: 'Ext.data.Model',
 		fields: [
-			{name:'name',  type:'string'},
-			{name:'rid',type:'int'}
+			{ name: 'name', type: 'string' },
+			{ name: 'rid', type: 'int' }
 		]
 	});
 
-	var getJobDutiesStore1 = Ext.create('Ext.data.Store',{
+	var getJobDutiesStore1 = Ext.create('Ext.data.Store', {
 		model: 'getJobDutiesStore1',
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/inspectorsx/getTeamMembersList1',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    }
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/inspectorsx/getTeamMembersList1',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		}
 	});
-	
+
+	function public_phone(e) {
+		if (!(/^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/.test(e))) {
+			Ext.Msg.alert('提示', '不是完整的11位手机号或者正确的手机号前七位!', function (btn, txt) {
+				Ext.getCmp('fa_phone').setValue('');
+				Ext.getCmp('fm_phone').setValue('');
+			});
+			return false;
+		}
+	}
+
 	var AppendForm = Ext.create('Ext.form.Panel', {
 		id: 'MaintenancePersonAppendForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectorsx/append',
+		url: baseUrl + 'iot/inspectorsx/append',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'人员姓名',
+			fieldLabel: '人员姓名',
 			id: 'fa_name',
-			name:'name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-			fieldLabel:'电话号码',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '电话号码',
 			id: 'fa_phone',
 			name: 'phone',
 			maxLength: 250,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-		   xtype: 'checkboxgroup',
-           fieldLabel: '人员职能',
-           id:"fa_maintenancePerson_inspectiontime",
-           columns: 3,
-           items: [
-              {boxLabel: '维保', name: 'maintenance',inputValue:"1"},
-              {boxLabel: '巡检', name: 'inspection',inputValue:"2"},
-              {boxLabel: '报修', name: 'event_processing',inputValue:"4"}
-            
-       ]},{
-    	   id:'fa_queryJson',
-    	   name:'queryJson',
-    	   hidden:true
-       }],
-       buttons: [{
-        text: '提交',
-        iconCls:'ok_btn',
-        handler: function() {
-        	var form = this.up('form').getForm();
-        	if (form.isValid()) {
-        		var InspectiontimeValue = Ext.getCmp('fa_maintenancePerson_inspectiontime').getChecked();
-        		var Inspectiontime=0;
-        		Ext.Array.each(InspectiontimeValue, function(item){
-        			Inspectiontime +=parseInt(item.inputValue);
-                });
-        		var query = new Object();
-        		// query.V_LOGINNAME = V_LOGINNAME;
-        		query.zn=Inspectiontime;
-        		query.name = Ext.getCmp('fa_name').getValue();
-        		query.phone = Ext.getCmp('fa_phone').getValue();
-            var jsonstr = Ext.JSON.encode(query);
-            Ext.getCmp('fa_queryJson').setValue(jsonstr);
-             form.submit({
-              method:'post',
-                 success: function(form, action) {
-                    Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-                    	Ext.getCmp('MaintenancePersonAppendForm').getForm().reset();
-                    	Ext.getCmp('MaintenancePersonListPageToolbar').moveFirst();
-                    });
-                 },
-                 failure: function(form, action) {
-                    Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-                    });
-                 }
-             });
-           }
-        }
-     },{
-      text: '关闭',
-      iconCls: 'cancel_btn',
-      handler: function() {
-       this.up('window').hide();
-      }
-     }]
-    });
-	
-	var appendwin = function(){
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fa_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			xtype: 'checkboxgroup',
+			fieldLabel: '人员职能',
+			id: "fa_maintenancePerson_inspectiontime",
+			columns: 3,
+			items: [
+				{ boxLabel: '维保', name: 'maintenance', inputValue: "1" },
+				{ boxLabel: '巡检', name: 'inspection', inputValue: "2" },
+				{ boxLabel: '报修', name: 'event_processing', inputValue: "4" }
+
+			]
+		}, {
+			id: 'fa_queryJson',
+			name: 'queryJson',
+			hidden: true
+		}],
+		buttons: [{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var InspectiontimeValue = Ext.getCmp('fa_maintenancePerson_inspectiontime').getChecked();
+					var Inspectiontime = 0;
+					Ext.Array.each(InspectiontimeValue, function (item) {
+						Inspectiontime += parseInt(item.inputValue);
+					});
+					var query = new Object();
+					// query.V_LOGINNAME = V_LOGINNAME;
+					query.name = Ext.getCmp('fa_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
+					query.phone = Ext.getCmp('fa_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					} else if (query.phone.length < 11) {
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if (query.zn == 0) {
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								Ext.getCmp('MaintenancePersonAppendForm').getForm().reset();
+								Ext.getCmp('MaintenancePersonListPageToolbar').moveFirst();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+							});
+						}
+					});
+				}
+			}
+		}, {
+			text: '关闭',
+			iconCls: 'cancel_btn',
+			handler: function () {
+				this.up('window').hide();
+			}
+		}]
+	});
+
+	var appendwin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    width: 400,
-		    modal: true,
-		    layout: 'fit',
-		    items:  AppendForm,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			width: 400,
+			modal: true,
+			layout: 'fit',
+			items: AppendForm,
+			closeAction: 'hide'
 		}).show();
 	}
-	
-	Ext.define('getJobDutiesStore',{
-		extend:'Ext.data.Model',
+
+	Ext.define('getJobDutiesStore', {
+		extend: 'Ext.data.Model',
 		fields: [
-			{name:'owner_name',  type:'string'},
-			{name:'owner_id',type:'string'}
+			{ name: 'owner_name', type: 'string' },
+			{ name: 'owner_id', type: 'string' }
 		]
 	});
 
-	var getJobDutiesStore = Ext.create('Ext.data.Store',{
+	var getJobDutiesStore = Ext.create('Ext.data.Store', {
 		model: 'getJobDutiesStore',
-	    proxy: {
-	        type: 'ajax',
-	        actionMethods: {
-                create : 'POST',
-                read   : 'POST', // by default GET
-                update : 'POST',
-                destroy: 'POST'
-	        },
-	        url: baseUrl+'iot/company/view/getNameList',
-	        reader: {
-	            type: 'json',
-	            root: 'RESULT',
-	            totalProperty: 'totalCount'
-	        },
-	        extraParams:{
-	        	queryJson:Ext.JSON.encode(queryJson)
-	        }
-	    }
+		proxy: {
+			type: 'ajax',
+			actionMethods: {
+				create: 'POST',
+				read: 'POST', // by default GET
+				update: 'POST',
+				destroy: 'POST'
+			},
+			url: baseUrl + 'iot/company/view/getNameList',
+			reader: {
+				type: 'json',
+				root: 'RESULT',
+				totalProperty: 'totalCount'
+			},
+			extraParams: {
+				queryJson: Ext.JSON.encode(queryJson)
+			}
+		}
 	});
-	
+
 	var AppendForm1 = Ext.create('Ext.form.Panel', {
 		id: 'MaintenancePersonAppendForm1',
 		labelWidth: 55,
-		url: baseUrl+'iot/planteam/append',
+		url: baseUrl + 'iot/planteam/append',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-			fieldLabel:'班组名称',
+			fieldLabel: '班组名称',
 			id: 'fa_team_name',
-			name:'team_name',
-			maxLength:20,
-			maxLengthText:'长度不得超出{0}',
-			anchor:'75%'
-		},{
-			fieldLabel:'负责人',
+			name: 'team_name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%'
+		}, {
+			fieldLabel: '负责人',
 			id: 'fa_person_liable_id',
-			name:'person_liable_id',
-			xtype:'combo',
-			store:getJobDutiesStore1,
-			displayField : 'name',  
-	        valueField : 'rid',
-	        editable : false,
-			anchor:'75%'
-		},{
-			id:'fa_queryJson1',
-			name:'queryJson',
-			hidden:true
+			name: 'person_liable_id',
+			xtype: 'combo',
+			store: getJobDutiesStore1,
+			displayField: 'name',
+			valueField: 'rid',
+			editable: false,
+			anchor: '75%'
+		}, {
+			id: 'fa_queryJson1',
+			name: 'queryJson',
+			hidden: true
 		}],
 		buttons: [{
-	        text: '提交',
-	        iconCls:'ok_btn',
-		    handler: function() {
-		        var form = this.up('form').getForm();
-		        if (form.isValid()) {
-		        	var query = new Object();
-		        	// query.V_LOGINNAME = $("#V_LOGINNAME").val();
-		        	query.team_name = Ext.getCmp('fa_team_name').getValue();
-		        	query.person_liable_id = Ext.getCmp('fa_person_liable_id').getValue();
-		        	var jsonstr = Ext.JSON.encode(query);
-		        	Ext.getCmp('fa_queryJson1').setValue(jsonstr);
-		            form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已保存', function(btn,txt){
-		                	   clear_append_form1();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   clear_append_form1();
-		                   });
-		                }
-		            });
-		        }
-		    }
-		},{
+			text: '提交',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var query = new Object();
+					// query.V_LOGINNAME = $("#V_LOGINNAME").val();
+					query.team_name = Ext.getCmp('fa_team_name').getValue();
+					query.person_liable_id = Ext.getCmp('fa_person_liable_id').getValue();
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fa_queryJson1').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已保存', function (btn, txt) {
+								clear_append_form1();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								clear_append_form1();
+							});
+						}
+					});
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 			}
 		}]
 	});
-	
-	var appendwin1 = function(){
+
+	var appendwin1 = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '新增',
-		    height: 350,
-		    modal: true,
-		    width: 400,
-		    layout: 'fit',
-		    items:  AppendForm1,
-		    closeAction: 'hide'
+			title: '新增',
+			height: 350,
+			modal: true,
+			width: 400,
+			layout: 'fit',
+			items: AppendForm1,
+			closeAction: 'hide'
 		}).show();
 	}
-	
-	
+
+
 	var ModifyForm = Ext.create('Ext.form.Panel', {
 		id: 'MaintenancePersonEditForm',
 		labelWidth: 55,
-		url: baseUrl+'iot/inspectorsx/update',
+		url: baseUrl + 'iot/inspectorsx/update',
 		defaultType: 'textfield',
 		bodyPadding: 15,
 		items: [{
-				fieldLabel:'人员姓名',
-				id: 'fm_name',
-				name:'name',
-				maxLength:20,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
-			},{
-				fieldLabel:'电话号码',
-				id: 'fm_phone',
-				name: 'phone',
-				maxLength: 250,
-				maxLengthText:'长度不得超出{0}',
-				anchor:'75%'
-			},{
-			    xtype: 'checkboxgroup',
-			    fieldLabel: '人员职能',
-			    id:"fm_maintenancePerson_inspectiontime",
-			    columns: 3,
-			    items: [
-			            {boxLabel: '维保', name: 'maintenance',inputValue:"1",id:'maintenance'},
-			            {boxLabel: '巡检', name: 'inspection',inputValue:"2",id:'inspection'},
-			            {boxLabel: '报修', name: 'event_processing',inputValue:"4",id:'event_processing'}
-			              
-			]},{
-			   id: 'fm_id',
-			   name:'id',
-			   hidden:true
-			},{
-			   id:'fm_queryJson',
-			   name:'queryJson',
-			   hidden:true
-			  }],
-			  buttons: [{
-			         text: '修改',
-			         iconCls:'ok_btn',
-			      handler: function() {
-			       var form = this.up('form').getForm();
-			          if (form.isValid()) {
-			           var InspectiontimeValue = Ext.getCmp('fm_maintenancePerson_inspectiontime').getChecked();
-			           var Inspectiontime=0;
-			           Ext.Array.each(InspectiontimeValue, function(item){
-			            Inspectiontime +=parseInt(item.inputValue);
-			           });
-			           var query = new Object();
-			           query.zn=Inspectiontime;
-			           query.id = Ext.getCmp('fm_id').getValue();
-			           query.name = Ext.getCmp('fm_name').getValue();
-			           query.phone = Ext.getCmp('fm_phone').getValue();
-			           var jsonstr = Ext.JSON.encode(query);
-			           Ext.getCmp('fm_queryJson').setValue(jsonstr);
-		               form.submit({
-		            	method:'post',
-		                success: function(form, action) {
-		                   Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-		                	   Ext.getCmp('MaintenancePersonEditForm').getForm().reset();
-		                	   Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-		                   });
-		                },
-		                failure: function(form, action) {
-		                   Ext.Msg.alert('操作失败', action.Msg , function(btn,txt){
-		                	   Ext.getCmp('MaintenancePersonEditForm').getForm().reset();
-		                	   Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-		                   });
-		                }
-		               });
-		            this.up('window').hide();
-		        }
-		    }
-		},{
+			fieldLabel: '人员姓名',
+			id: 'fm_name',
+			name: 'name',
+			maxLength: 20,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length > 10) {
+						Ext.Msg.alert('提示', '人员姓名长度不可超过10个字!', function (btn, txt) {
+							Ext.getCmp('fa_name').setValue('');
+						});
+						return false;
+					}
+				}
+			}
+		}, {
+			fieldLabel: '电话号码',
+			id: 'fm_phone',
+			name: 'phone',
+			maxLength: 250,
+			maxLengthText: '长度不得超出{0}',
+			anchor: '75%',
+			listeners: {
+				change: function (o, e) {
+					if (e.length == 11) {
+						public_phone(e);
+					} else {
+						Ext.getCmp('fm_phone').setValue(e.substring(0, 11));
+						e.length == 11 ? public_phone(e) : ''
+					}
+				}
+			}
+		}, {
+			xtype: 'checkboxgroup',
+			fieldLabel: '人员职能',
+			id: "fm_maintenancePerson_inspectiontime",
+			columns: 3,
+			items: [
+				{ boxLabel: '维保', name: 'maintenance', inputValue: "1", id: 'maintenance' },
+				{ boxLabel: '巡检', name: 'inspection', inputValue: "2", id: 'inspection' },
+				{ boxLabel: '报修', name: 'event_processing', inputValue: "4", id: 'event_processing' }
+
+			]
+		}, {
+			id: 'fm_id',
+			name: 'id',
+			hidden: true
+		}, {
+			id: 'fm_queryJson',
+			name: 'queryJson',
+			hidden: true
+		}],
+		buttons: [{
+			text: '修改',
+			iconCls: 'ok_btn',
+			handler: function () {
+				var form = this.up('form').getForm();
+				if (form.isValid()) {
+					var InspectiontimeValue = Ext.getCmp('fm_maintenancePerson_inspectiontime').getChecked();
+					var Inspectiontime = 0;
+					Ext.Array.each(InspectiontimeValue, function (item) {
+						Inspectiontime += parseInt(item.inputValue);
+					});
+					var query = new Object();
+					query.id = Ext.getCmp('fm_id').getValue();
+					query.name = Ext.getCmp('fm_name').getValue();
+					if (query.name == null || query.name == "") {
+						Ext.Msg.alert('系统提示', '人员姓名不能为空!');
+						return;
+					}
+					query.phone = Ext.getCmp('fm_phone').getValue();
+					if (query.phone == null || query.phone == "") {
+						Ext.Msg.alert('系统提示', '电话号码不能为空!');
+						return;
+					} else if (query.phone.length < 11) {
+						Ext.Msg.alert('系统提示', '请输入正确的电话号码!');
+						return;
+					}
+					query.zn = Inspectiontime;
+					if (query.zn == 0) {
+						Ext.Msg.alert('系统提示', '职能至少选择一项!');
+						return
+					}
+					var jsonstr = Ext.JSON.encode(query);
+					Ext.getCmp('fm_queryJson').setValue(jsonstr);
+					form.submit({
+						method: 'post',
+						success: function (form, action) {
+							Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+								Ext.getCmp('MaintenancePersonEditForm').getForm().reset();
+								Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+							});
+						},
+						failure: function (form, action) {
+							Ext.Msg.alert('操作失败', action.Msg, function (btn, txt) {
+								Ext.getCmp('MaintenancePersonEditForm').getForm().reset();
+								Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+							});
+						}
+					});
+					this.up('window').hide();
+				}
+			}
+		}, {
 			text: '关闭',
 			iconCls: 'cancel_btn',
-			handler: function() {
+			handler: function () {
 				this.up('window').hide();
 				Ext.getCmp('MaintenancePersonEditForm').getForm().reset();
 				Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
 			}
 		}]
 	});
-	
-	var modifywin = function(){
+
+	var modifywin = function () {
 		Ext.create('Ext.window.Window', {
-		    title: '修改',
-		    height: 350,
-		    width: 400,
-		    modal: true,
-		    layout: 'fit',
-		    items:  ModifyForm,
-		    closeAction: 'hide'
+			title: '修改',
+			height: 350,
+			width: 400,
+			modal: true,
+			layout: 'fit',
+			items: ModifyForm,
+			closeAction: 'hide'
 		}).show();
 	}
-		
-	var chk_sm = function() {
-		  if(sm.getCount()==1){
-		   modifywin();
-		   var selected = sm.getSelection();
-		   var fm_inspectiontime = selected[0].raw.zn
-		   if(fm_inspectiontime=='1'){
-		    var domainArr = ['1'];
-		   }else if(fm_inspectiontime=='2'){
-		    var domainArr = ['2'];
-		   }else if(fm_inspectiontime=='3'){
-		    var domainArr = ['1','2'];
-		   }else if(fm_inspectiontime=='4'){
-		    var domainArr = ['4'];
-		   }else if(fm_inspectiontime=='5'){
-		    var domainArr = ['1','4'];
-		   }else if(fm_inspectiontime=='6'){
-		    var domainArr = ['2','4'];
-		   }else if(fm_inspectiontime=='7'){
-		    var domainArr = ['1','2','4'];
-		   }
-		   for(var i = 0 ;i < domainArr.length;i++) {
-		    switch(domainArr[i]) {
-		    case "1":
-		     Ext.getCmp('maintenance').setValue(true);
-		     break; 
-		       case "2":
-		        Ext.getCmp('inspection').setValue(true);
-		        break; 
-		       case "4":
-		        Ext.getCmp('event_processing').setValue(true);
-		        break; 
-		    }
-		   }
-		   Ext.getCmp('fm_id').setValue(selected[0].raw.id);
-		   Ext.getCmp('fm_name').setValue(selected[0].raw.name);
-		   Ext.getCmp('fm_phone').setValue(selected[0].raw.phone);
-		  }else{
-		   Ext.Msg.alert('请先选择','请先选择一条记录,再点击修改');
-		  }
-		 }
-	
-	var del_sm = function() {
-		if(sm.getCount()==1){
-			var selected = sm.getSelection( );
+
+	var chk_sm = function () {
+		if (sm.getCount() == 1) {
+			modifywin();
+			var selected = sm.getSelection();
+			var fm_inspectiontime = selected[0].raw.zn
+			if (fm_inspectiontime == '1') {
+				var domainArr = ['1'];
+			} else if (fm_inspectiontime == '2') {
+				var domainArr = ['2'];
+			} else if (fm_inspectiontime == '3') {
+				var domainArr = ['1', '2'];
+			} else if (fm_inspectiontime == '4') {
+				var domainArr = ['4'];
+			} else if (fm_inspectiontime == '5') {
+				var domainArr = ['1', '4'];
+			} else if (fm_inspectiontime == '6') {
+				var domainArr = ['2', '4'];
+			} else if (fm_inspectiontime == '7') {
+				var domainArr = ['1', '2', '4'];
+			}
+			for (var i = 0; i < domainArr.length; i++) {
+				switch (domainArr[i]) {
+					case "1":
+						Ext.getCmp('maintenance').setValue(true);
+						break;
+					case "2":
+						Ext.getCmp('inspection').setValue(true);
+						break;
+					case "4":
+						Ext.getCmp('event_processing').setValue(true);
+						break;
+				}
+			}
+			Ext.getCmp('fm_id').setValue(selected[0].raw.id);
+			Ext.getCmp('fm_name').setValue(selected[0].raw.name);
+			Ext.getCmp('fm_phone').setValue(selected[0].raw.phone);
+		} else {
+			Ext.Msg.alert('请先选择', '请先选择一条记录,再点击修改');
+		}
+	}
+
+	var del_sm = function () {
+		if (sm.getCount() == 1) {
+			var selected = sm.getSelection();
 			var query = new Object();
 			var list = new Array();
 			var o = new Object();
 			o.id = selected[0].raw.id;
 			list.push(o);
 			query.ID_LIST = list;
-			var jsonstr= Ext.JSON.encode(query);
-			Ext.MessageBox.confirm('删除人员信息','是否删除'+selected[0].raw.name+' 维保人员?',function(btn){
-				if(btn=='yes'){
-					
+			var jsonstr = Ext.JSON.encode(query);
+			Ext.MessageBox.confirm('删除人员信息', '是否删除' + selected[0].raw.name + ' 维保人员?', function (btn) {
+				if (btn == 'yes') {
+
 					$.ajax({
-			             type:'POST',
-			             url: baseUrl+"iot/inspectorsx/del",
-			             data: {
-			              queryJson : jsonstr
-			            
-			           },
-			           success: function(result){
-			             
-			             var json = eval('(' + result + ')');
-			                 if(json.action=='deleteInspectors'){
-			         
-			                  if(json.success==true){
-			                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-			                	      Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-			                       }); 
-			                	 }else{
-			                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-				                	      Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-				                      }); 
-			                	 }
-			                 }
-			             
-			            }
-			     });
-				
+						type: 'POST',
+						url: baseUrl + "iot/inspectorsx/del",
+						data: {
+							queryJson: jsonstr
+
+						},
+						success: function (result) {
+
+							var json = eval('(' + result + ')');
+							if (json.action == 'deleteInspectors') {
+
+								if (json.success == true) {
+									Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+										Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+									});
+								} else {
+									Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+										Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+									});
+								}
+							}
+
+						}
+					});
+
 				}
-			},this);
-		}else{
-			if(sm.getCount()>1){
+			}, this);
+		} else {
+			if (sm.getCount() > 1) {
 				var query = new Object();
 				var list = new Array();
-				for(var i=0;i<sm.getCount();i++){
-					var selected = sm.getSelection( );
+				for (var i = 0; i < sm.getCount(); i++) {
+					var selected = sm.getSelection();
 					var o = new Object();
 					o.id = selected[i].raw.id;
 					list.push(o);
 				}
 				query.ID_LIST = list;
-				
-				var jsonstr= Ext.JSON.encode(query);
-				Ext.MessageBox.confirm('删除人员信息','是否删除选中的'+sm.getCount()+' 个维保人员?',function(btn){
-					if(btn=='yes'){
-						
-//					Ext.Ajax.request( { 
-//					        timeout : 3000000, 
-//					        url: baseUrl+'iot/inspectorsx/del',
-//					        params : 'queryJson='+ jsonstr, 
-//					        success: function(resp,opts){
-//					        	myStore.reload();
-//					        }
-//					});
+
+				var jsonstr = Ext.JSON.encode(query);
+				Ext.MessageBox.confirm('删除人员信息', '是否删除选中的' + sm.getCount() + ' 个维保人员?', function (btn) {
+					if (btn == 'yes') {
+
+						//					Ext.Ajax.request( { 
+						//					        timeout : 3000000, 
+						//					        url: baseUrl+'iot/inspectorsx/del',
+						//					        params : 'queryJson='+ jsonstr, 
+						//					        success: function(resp,opts){
+						//					        	myStore.reload();
+						//					        }
+						//					});
 						$.ajax({
-				             type:'POST',
-				             url: baseUrl+"iot/inspectorsx/del",
-				             data: {
-				              queryJson : jsonstr
-				            
-				           },
-				           success: function(result){
-				             
-				             var json = eval('(' + result + ')');
-				                 if(json.action=='deleteInspectors'){
-				                	 if(json.success==true){
-					                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-					                	      Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-					                       }); 
-					                	 }else{
-					                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-						                	      Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
-						                      }); 
-					                	 } 
-				                 }
-				             
-				            }
-				     });
-					
+							type: 'POST',
+							url: baseUrl + "iot/inspectorsx/del",
+							data: {
+								queryJson: jsonstr
+
+							},
+							success: function (result) {
+
+								var json = eval('(' + result + ')');
+								if (json.action == 'deleteInspectors') {
+									if (json.success == true) {
+										Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+											Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+										});
+									} else {
+										Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+											Ext.getCmp('MaintenancePersonListPanel').getStore().reload();
+										});
+									}
+								}
+
+							}
+						});
+
 					}
-				},this);
-			}else{
-			Ext.Msg.alert('请先选择','至少选择一条记录,再点击删除');
-		}
+				}, this);
+			} else {
+				Ext.Msg.alert('请先选择', '至少选择一条记录,再点击删除');
+			}
 		}
 	}
-	
-	var del_sm1 = function() {
-		if(sm1.getCount()==1){
-			var selected = sm1.getSelection( );
+
+	var del_sm1 = function () {
+		if (sm1.getCount() == 1) {
+			var selected = sm1.getSelection();
 			var query = new Object();
 			var list = new Array();
 			var o = new Object();
 			o.id = selected[0].raw.id;
 			list.push(o);
 			query.ID_LIST = list;
-			var jsonstr= Ext.JSON.encode(query);
-			Ext.MessageBox.confirm('删除班组','是否删除'+selected[0].raw.name+' 班组?',function(btn){
-				if(btn=='yes'){
-					
-				 $.ajax({
-			             type:'POST',
-			             url: baseUrl+"iot/planteam/del",
-			             data: {
-			              queryJson : jsonstr
-			            
-			           },
-			           success: function(result){
-			             
-			             var json = eval('(' + result + ')');
-			                 if(json.action=='deletePlanTeam'){
-			                
-			                  if(json.success==true){
-			                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-			                	      Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
-			                       }); 
-			                	 }else{
-			                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-				                	      Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
-				                      }); 
-			                	 }
-			                 }
-			             
-			            }
-			     });
-				
+			var jsonstr = Ext.JSON.encode(query);
+			Ext.MessageBox.confirm('删除班组', '是否删除' + selected[0].raw.name + ' 班组?', function (btn) {
+				if (btn == 'yes') {
+
+					$.ajax({
+						type: 'POST',
+						url: baseUrl + "iot/planteam/del",
+						data: {
+							queryJson: jsonstr
+
+						},
+						success: function (result) {
+
+							var json = eval('(' + result + ')');
+							if (json.action == 'deletePlanTeam') {
+
+								if (json.success == true) {
+									Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+										Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
+									});
+								} else {
+									Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+										Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
+									});
+								}
+							}
+
+						}
+					});
+
 				}
-			},this);
-		}else{
-			if(sm1.getCount()>1){
+			}, this);
+		} else {
+			if (sm1.getCount() > 1) {
 				var query = new Object();
 				var list = new Array();
-				for(var i=0;i<sm.getCount();i++){
-					var selected = sm1.getSelection( );
+				for (var i = 0; i < sm.getCount(); i++) {
+					var selected = sm1.getSelection();
 					var o = new Object();
 					o.id = selected[i].raw.id;
 					list.push(o);
 				}
 				query.ID_LIST = list;
-				
-				var jsonstr= Ext.JSON.encode(query);
-				Ext.MessageBox.confirm('删除班组','是否删除选中的'+sm1.getCount()+' 个班组?',function(btn){
-					if(btn=='yes'){
-						
+
+				var jsonstr = Ext.JSON.encode(query);
+				Ext.MessageBox.confirm('删除班组', '是否删除选中的' + sm1.getCount() + ' 个班组?', function (btn) {
+					if (btn == 'yes') {
+
 						$.ajax({
-				             type:'POST',
-				             url: baseUrl+"iot/planteam/del",
-				             data: {
-				              queryJson : jsonstr
-				            
-				           },
-				           success: function(result){
-				             
-				             var json = eval('(' + result + ')');
-				                 if(json.action=='deletePlanTeam'){
-				                	 if(json.success==true){
-					                       Ext.Msg.alert('操作成功', json.MSG , function(btn,txt){
-					                	      Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
-					                       }); 
-					                	 }else{
-					                		 Ext.Msg.alert('操作失败', json.MSG , function(btn,txt){
-						                	      Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
-						                      }); 
-					                	 }
-				                 }
-				             
-				            }
-				     });
-					
+							type: 'POST',
+							url: baseUrl + "iot/planteam/del",
+							data: {
+								queryJson: jsonstr
+
+							},
+							success: function (result) {
+
+								var json = eval('(' + result + ')');
+								if (json.action == 'deletePlanTeam') {
+									if (json.success == true) {
+										Ext.Msg.alert('操作成功', json.MSG, function (btn, txt) {
+											Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
+										});
+									} else {
+										Ext.Msg.alert('操作失败', json.MSG, function (btn, txt) {
+											Ext.getCmp('MaintenancePersonListPanel2').getStore().reload();
+										});
+									}
+								}
+
+							}
+						});
+
 					}
-				},this);
-			}else{
-			Ext.Msg.alert('请先选择','至少选择一条记录,再点击删除');
-		}
+				}, this);
+			} else {
+				Ext.Msg.alert('请先选择', '至少选择一条记录,再点击删除');
+			}
 		}
 	}
-	
-	var show_page = function(){
+
+	var show_page = function () {
 		var arr = 0;
 		var r = document.getElementsByName("zhineng");
-		if(r.length>1){
-		  for(var i = 0; i < r.length; i++) {
-			  if(r[i].checked) {
-				  arr+=parseInt(r[i].value);
-			  }
-		  }
-		}else if(r.length==1){
+		if (r.length > 1) {
+			for (var i = 0; i < r.length; i++) {
+				if (r[i].checked) {
+					arr += parseInt(r[i].value);
+				}
+			}
+		} else if (r.length == 1) {
 			arr = parseInt(r[0].value);
-		}else{
+		} else {
 			arr = 0;
 		}
 		var maintenancePerson_title3_input = document.getElementById('maintenancePerson_title3_input1').value;
 		var query = new Object();
-		if(arr > 0){
+		if (arr > 0) {
 			query.zn = arr;
 			$("#zn").val(arr);
 		}
-		if(maintenancePerson_title3_input.length>0){
-		query.name = maintenancePerson_title3_input;
-		$("#name").val(maintenancePerson_title3_input);
+		if (maintenancePerson_title3_input.length > 0) {
+			query.name = maintenancePerson_title3_input;
+			$("#name").val(maintenancePerson_title3_input);
 		}
 		// query.V_LOGINNAME = V_LOGINNAME;
 		// query.V_PASSWORD =  V_PASSWORD;
 		var jsonstr = Ext.JSON.encode(query);
-    	myStore.getProxy().extraParams = {
-    		queryJson : jsonstr
-    	};
-    	Ext.getCmp('MaintenancePersonListPageToolbar').moveFirst();
+		myStore.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('MaintenancePersonListPageToolbar').moveFirst();
 	}
-	
-	var show_page1 = function(){
+
+	var show_page1 = function () {
 		var maintenancePerson_title21_input = document.getElementById('maintenancePerson_title21_input').value;
 		var maintenancePerson_title31_input = document.getElementById('maintenancePerson_title31_input1').value;
 		var query = new Object();
-		if(maintenancePerson_title21_input.length>0){
-		  query.spot_name = maintenancePerson_title21_input;
+		if (maintenancePerson_title21_input.length > 0) {
+			query.spot_name = maintenancePerson_title21_input;
 		}
-		if(maintenancePerson_title31_input.length>0){
-		query.name = maintenancePerson_title31_input;
+		if (maintenancePerson_title31_input.length > 0) {
+			query.name = maintenancePerson_title31_input;
 		}
 		// query.V_LOGINNAME = V_LOGINNAME;
 		// query.V_PASSWORD =  V_PASSWORD;
 		var jsonstr = Ext.JSON.encode(query);
-    	myStore.getProxy().extraParams = {
-    		queryJson : jsonstr
-    	};
-    	Ext.getCmp('MaintenancePersonListPageToolbar2').moveFirst();
+		myStore.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('MaintenancePersonListPageToolbar2').moveFirst();
 	}
-	
-	var reset1 = function(){
+
+	var reset1 = function () {
 		var zn = document.getElementsByName("zhineng");
-          for (var i = 0; i < zn.length; i++) {
-        	  zn[i].checked = true;
-          }
+		for (var i = 0; i < zn.length; i++) {
+			zn[i].checked = true;
+		}
 		document.getElementById('maintenancePerson_title3_input1').value = '';
 		$("#zn").val('');
 		$("#name").val('');
 		show_page();
 	}
-	
-	var reset11 = function(){
+
+	var reset11 = function () {
 		document.getElementById('maintenancePerson_title21_input').value = '';
 		document.getElementById('maintenancePerson_title31_input1').value = '';
 	}
-	
-	mouseon = function(obj){
+
+	mouseon = function (obj) {
 		var id = obj.id;
-		$("#"+id).removeClass(id);
-		$("#"+id).addClass(id+'_on');
+		$("#" + id).removeClass(id);
+		$("#" + id).addClass(id + '_on');
 	}
-	
-	mouseon1 = function(obj){
+
+	mouseon1 = function (obj) {
 		var id = obj.id;
-		$("#"+id).removeClass(id);
-		$("#"+id).addClass(id+'_on');
+		$("#" + id).removeClass(id);
+		$("#" + id).addClass(id + '_on');
 	}
-	
-	 mouseoff = function(obj){
+
+	mouseoff = function (obj) {
 		var mid = "maintenancePerson_";
-		for(var i=1;i<7;i++){
-			var id = "maintenancePerson_title"+i+"_div";
-			$("#"+id).removeClass(id+'_on');
-			$("#"+id).addClass(id);
+		for (var i = 1; i < 7; i++) {
+			var id = "maintenancePerson_title" + i + "_div";
+			$("#" + id).removeClass(id + '_on');
+			$("#" + id).addClass(id);
 		}
-		if(menuidx=='m1'){
+		if (menuidx == 'm1') {
 			mid += 'title1_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m2'){
+		else if (menuidx == 'm2') {
 			mid += 'title2_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m3'){
+		else if (menuidx == 'm3') {
 			mid += 'title3_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m4'){
+		else if (menuidx == 'm4') {
 			mid += 'title4_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m5'){
+		else if (menuidx == 'm5') {
 			mid += 'title5_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
-		else if(menuidx=='m6'){
+		else if (menuidx == 'm6') {
 			mid += 'title6_div';
-		$("#"+mid).removeClass(mid);
-		$("#"+mid).addClass(mid+'_on');
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
 		}
 	}
-	
-	 mouseoff1 = function(obj){
-		   var mid = "maintenancePerson_";
-		   for(var i=1;i<5;i++){
-		    var id = "maintenancePerson_title"+i+"1_div";
-		    $("#"+id).removeClass(id+'_on');
-		    $("#"+id).addClass(id);
-		   }
-		      if(menuidx=='m11'){
-		    mid += 'title11_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m21'){
-		    mid += 'title21_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m31'){
-		    mid += 'title31_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		   else if(menuidx=='m41'){
-		    mid += 'title41_div';
-		   $("#"+mid).removeClass(mid);
-		   $("#"+mid).addClass(mid+'_on');
-		   }
-		  }
-	 
-	 menu_click = function(obj){
-		  var id = obj.id;
-		  if(id=='maintenancePerson_title1_div'){
-		   menuidx = 'm1';
-		   show_page();
-		  }
-		  else if(id=='maintenancePerson_title2_div'){
-		   menuidx = 'm2';
-		   reset1();
-		  }
-		  else if(id=='maintenancePerson_title3_div'){
-		   menuidx = 'm3';
-		   exportbtn_click();
-		  }
-		  else if(id=='maintenancePerson_title4_div'){
-		   menuidx = 'm4';
-		   del_sm();
-		  }
-		  else if(id=='maintenancePerson_title5_div'){
-		   menuidx = 'm5';
-		   appendwin();
-		  }
-		  else if(id=='maintenancePerson_title6_div'){
-		   menuidx = 'm6';
-		   chk_sm();
-		  }
-		  else if(id=='maintenancePerson_title11_div'){
-		   menuidx = 'm11';
-		   del_sm1();
-		  }
-		  else if(id=='maintenancePerson_title21_div'){
-		   menuidx = 'm21';
-		   appendwin1();
-		  }
-		  else if(id=='maintenancePerson_title31_div'){
-		   menuidx = 'm31';
-		   Preservation_panel3();
-		  }
-		  else if(id=='maintenancePerson_title41_div'){
-		   menuidx = 'm41';
-		   cancel_panel3();
-		  }
-		 }
-	
-	var Preservation_panel3 = function(){
+
+	mouseoff1 = function (obj) {
+		var mid = "maintenancePerson_";
+		for (var i = 1; i < 5; i++) {
+			var id = "maintenancePerson_title" + i + "1_div";
+			$("#" + id).removeClass(id + '_on');
+			$("#" + id).addClass(id);
+		}
+		if (menuidx == 'm11') {
+			mid += 'title11_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm21') {
+			mid += 'title21_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm31') {
+			mid += 'title31_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+		else if (menuidx == 'm41') {
+			mid += 'title41_div';
+			$("#" + mid).removeClass(mid);
+			$("#" + mid).addClass(mid + '_on');
+		}
+	}
+
+	menu_click = function (obj) {
+		var id = obj.id;
+		if (id == 'maintenancePerson_title1_div') {
+			menuidx = 'm1';
+			show_page();
+		}
+		else if (id == 'maintenancePerson_title2_div') {
+			menuidx = 'm2';
+			reset1();
+		}
+		else if (id == 'maintenancePerson_title3_div') {
+			menuidx = 'm3';
+			exportbtn_click();
+		}
+		else if (id == 'maintenancePerson_title4_div') {
+			menuidx = 'm4';
+			del_sm();
+		}
+		else if (id == 'maintenancePerson_title5_div') {
+			menuidx = 'm5';
+			appendwin();
+		}
+		else if (id == 'maintenancePerson_title6_div') {
+			menuidx = 'm6';
+			chk_sm();
+		}
+		else if (id == 'maintenancePerson_title11_div') {
+			menuidx = 'm11';
+			del_sm1();
+		}
+		else if (id == 'maintenancePerson_title21_div') {
+			menuidx = 'm21';
+			appendwin1();
+		}
+		else if (id == 'maintenancePerson_title31_div') {
+			menuidx = 'm31';
+			Preservation_panel3();
+		}
+		else if (id == 'maintenancePerson_title41_div') {
+			menuidx = 'm41';
+			cancel_panel3();
+		}
+	}
+
+	var Preservation_panel3 = function () {
 		var team_name = document.getElementById('maintenancePerson_title211_input').value;
 		var person_liable_id = document.getElementById('maintenancePerson_title111_input').value;
-		var selected = sm1.getSelection( );
-		
-		var selected1 = addsm.getSelection( );
-		var tid=selected1[0].raw.tdid;
-		for(var i=0;i<addsm.getCount();i++){
-            if(i==0)
-            	people_id_list = selected1[i].raw.rid;
+		var selected = sm1.getSelection();
+
+		var selected1 = addsm.getSelection();
+		var tid = selected1[0].raw.tdid;
+		for (var i = 0; i < addsm.getCount(); i++) {
+			if (i == 0)
+				people_id_list = selected1[i].raw.rid;
 			else
-				people_id_list += ","+selected1[i].raw.rid;
-           }
-		
+				people_id_list += "," + selected1[i].raw.rid;
+		}
+
 		var query = new Object();
-		query.team_name=team_name;
-		query.person_liable_id =person_liable_id ;
-		query.tid = tid ;
-		query.people_id_list = people_id_list ;
-		
+		query.team_name = team_name;
+		query.person_liable_id = person_liable_id;
+		query.tid = tid;
+		query.people_id_list = people_id_list;
+
 		$.ajax({
-	         type:'POST',
-	         url: baseUrl+"iot/planteam/update",
-	         data: {
-	          queryJson : Ext.JSON.encode(query)
-	       },
-	         success: function(result){
-	        	 Ext.Msg.alert('操作成功', '已修改', function(btn,txt){
-	        		  mystore2_fun(tid);
-//					  cancel_panel3();
-                 });
-	         },
-	         failure : function() {
-				  Ext.Msg.alert('操作失败', function(btn,txt){
-					  cancel_panel3();
-                 });
-			  }
-	     });
-
-    	
+			type: 'POST',
+			url: baseUrl + "iot/planteam/update",
+			data: {
+				queryJson: Ext.JSON.encode(query)
+			},
+			success: function (result) {
+				Ext.Msg.alert('操作成功', '已修改', function (btn, txt) {
+					mystore2_fun(tid);
+					//					  cancel_panel3();
+				});
+			},
+			failure: function () {
+				Ext.Msg.alert('操作失败', function (btn, txt) {
+					cancel_panel3();
+				});
+			}
+		});
+
+
+	}
+
+	var cancel_panel3 = function () {
+		var selected = sm1.getSelection();
+		var stor1_id = selected[0].raw.id;
+		var label1 = selected[0].raw.team_name;
+		var label2 = selected[0].raw.person_liable_id;
+		var query = new Object();
+		query.id = stor1_id;
+
+		// query.V_LOGINNAME = V_LOGINNAME;
+		// query.V_PASSWORD =  V_PASSWORD;
+		var jsonstr = Ext.JSON.encode(query);
+		myStore1.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
+		document.getElementById('maintenancePerson_title211_input').value = label1;
+		document.getElementById('maintenancePerson_title111_input').value = label2;
+	}
+
+	//	var childPanel1 = Ext.create('Ext.Panel', {
+	//		height:188,
+	//		width:'100%',
+	//        html: '<div class="title2_div">角色</div><input type="text" class="input_class" id="maintenancePerson_title2_input" value=""><div class="title3_div">姓名</div><input type="text" class="input1_class" id="maintenancePerson_title3_input1" value=""><div id="maintenancePerson_title1_div" class="maintenancePerson_title1_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title2_div" class="maintenancePerson_title2_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title3_div" class="maintenancePerson_title3_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title4_div" class="maintenancePerson_title4_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title5_div" class="maintenancePerson_title5_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title6_div" class="maintenancePerson_title6_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div>'
+	//    });
+	var childPanel1 = function () {
+		var maintenancePersonHtml = document.getElementById('maintenancePersonHtml');
+		var childPanel1_title = document.createElement('div');
+		childPanel1_title.setAttribute('class', 'maintenanceperson_title2_div');
+		childPanel1_title.innerHTML = '职能';
+		maintenancePersonHtml.appendChild(childPanel1_title);
+		var childPanel1_input1 = document.createElement('input');
+		childPanel1_input1.setAttribute('class', 'input4_class');
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input1.setAttribute('type', 'checkbox');
+		childPanel1_input1.setAttribute('name', 'zhineng');
+		childPanel1_input1.setAttribute('value', '1');
+		maintenancePersonHtml.appendChild(childPanel1_input1);
+		var childPanel1_div = document.createElement('div');
+		childPanel1_div.setAttribute('class', 'childPanel1_div');
+		childPanel1_div.innerHTML = '维保';
+		maintenancePersonHtml.appendChild(childPanel1_div);
+		var childPanel1_input2 = document.createElement('input');
+		childPanel1_input2.setAttribute('class', 'input2_class');
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input2.setAttribute('type', 'checkbox');
+		childPanel1_input2.setAttribute('name', 'zhineng');
+		childPanel1_input2.setAttribute('value', '2');
+		maintenancePersonHtml.appendChild(childPanel1_input2);
+		var childPanel1_div1 = document.createElement('div');
+		childPanel1_div1.setAttribute('class', 'childPanel1_div1');
+		childPanel1_div1.innerHTML = '巡检';
+		maintenancePersonHtml.appendChild(childPanel1_div1);
+		var childPanel1_input3 = document.createElement('input');
+		childPanel1_input3.setAttribute('class', 'input3_class');
+		//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
+		childPanel1_input3.setAttribute('type', 'checkbox');
+		childPanel1_input3.setAttribute('name', 'zhineng');
+		childPanel1_input3.setAttribute('value', '4');
+		maintenancePersonHtml.appendChild(childPanel1_input3);
+		var childPanel1_div2 = document.createElement('div');
+		childPanel1_div2.setAttribute('class', 'childPanel1_div2');
+		childPanel1_div2.innerHTML = '报修';
+		maintenancePersonHtml.appendChild(childPanel1_div2);
+		var childPanel1_title1 = document.createElement('div');
+		childPanel1_title1.setAttribute('class', 'title3_div');
+		childPanel1_title1.innerHTML = '姓名';
+		maintenancePersonHtml.appendChild(childPanel1_title1);
+		var childPanel1_input = document.createElement('input');
+		childPanel1_input.setAttribute('class', 'input1_class');
+		childPanel1_input.setAttribute('id', 'maintenancePerson_title3_input1');
+		childPanel1_input.setAttribute('type', 'text');
+		childPanel1_input.setAttribute('value', '');
+		maintenancePersonHtml.appendChild(childPanel1_input);
+		var childPanel1_title2 = document.createElement('div');
+		childPanel1_title2.setAttribute('class', 'maintenancePerson_title1_div');
+		childPanel1_title2.setAttribute('id', 'maintenancePerson_title1_div');
+		childPanel1_title2.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title2.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title2.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title2);
+		var childPanel1_title3 = document.createElement('div');
+		childPanel1_title3.setAttribute('class', 'maintenancePerson_title2_div');
+		childPanel1_title3.setAttribute('id', 'maintenancePerson_title2_div');
+		childPanel1_title3.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title3.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title3.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title3);
+		var childPanel1_title4 = document.createElement('div');
+		childPanel1_title4.setAttribute('class', 'maintenancePerson_title3_div');
+		childPanel1_title4.setAttribute('id', 'maintenancePerson_title3_div');
+		childPanel1_title4.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title4.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title4.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title4);
+		var childPanel1_title5 = document.createElement('div');
+		childPanel1_title5.setAttribute('class', 'maintenancePerson_title4_div');
+		childPanel1_title5.setAttribute('id', 'maintenancePerson_title4_div');
+		childPanel1_title5.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title5.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title5.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title5);
+		var childPanel1_title6 = document.createElement('div');
+		childPanel1_title6.setAttribute('class', 'maintenancePerson_title5_div');
+		childPanel1_title6.setAttribute('id', 'maintenancePerson_title5_div');
+		childPanel1_title6.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title6.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title6.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title6);
+		var childPanel1_title7 = document.createElement('div');
+		childPanel1_title7.setAttribute('class', 'maintenancePerson_title6_div');
+		childPanel1_title7.setAttribute('id', 'maintenancePerson_title6_div');
+		childPanel1_title7.setAttribute('onmouseover', "mouseon(this)");
+		childPanel1_title7.setAttribute('onmouseout', "mouseoff(this)");
+		childPanel1_title7.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml.appendChild(childPanel1_title7);
+		reset1();
 	}
-	
-	var cancel_panel3 = function() {
-		  var selected = sm1.getSelection( );
-		  var stor1_id=selected[0].raw.id;
-		  var label1 = selected[0].raw.team_name;
-		  var label2 = selected[0].raw.person_liable_id;
-		  var query = new Object(); 
-		    query.id = stor1_id;
-		    
-		    // query.V_LOGINNAME = V_LOGINNAME;
-		    // query.V_PASSWORD =  V_PASSWORD;
-		    var jsonstr = Ext.JSON.encode(query);
-		       myStore1.getProxy().extraParams = {
-		        queryJson : jsonstr
-		       };
-		       Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
-		       document.getElementById('maintenancePerson_title211_input').value = label1;
-		     document.getElementById('maintenancePerson_title111_input').value = label2;
-		 }
-	
-//	var childPanel1 = Ext.create('Ext.Panel', {
-//		height:188,
-//		width:'100%',
-//        html: '<div class="title2_div">角色</div><input type="text" class="input_class" id="maintenancePerson_title2_input" value=""><div class="title3_div">姓名</div><input type="text" class="input1_class" id="maintenancePerson_title3_input1" value=""><div id="maintenancePerson_title1_div" class="maintenancePerson_title1_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title2_div" class="maintenancePerson_title2_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title3_div" class="maintenancePerson_title3_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title4_div" class="maintenancePerson_title4_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title5_div" class="maintenancePerson_title5_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div><div id="maintenancePerson_title6_div" class="maintenancePerson_title6_div" onmouseover="mouseon(this);" onmouseout="mouseoff(this);" onclick="menu_click(this);"></div>'
-//    });
-	var childPanel1 = function() {
-		  var maintenancePersonHtml = document.getElementById('maintenancePersonHtml');
-		  var childPanel1_title = document.createElement('div');
-		  childPanel1_title.setAttribute('class','maintenanceperson_title2_div');
-		  childPanel1_title.innerHTML='职能';
-		  maintenancePersonHtml.appendChild(childPanel1_title);
-		  var childPanel1_input1 = document.createElement('input');
-		   childPanel1_input1.setAttribute('class','input4_class');
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input1.setAttribute('type','checkbox');
-		   childPanel1_input1.setAttribute('name','zhineng');
-		   childPanel1_input1.setAttribute('value','1');
-		   maintenancePersonHtml.appendChild(childPanel1_input1);
-		  var childPanel1_div = document.createElement('div');
-		   childPanel1_div.setAttribute('class','childPanel1_div');
-		   childPanel1_div.innerHTML='维保';
-		   maintenancePersonHtml.appendChild(childPanel1_div);
-		  var childPanel1_input2 = document.createElement('input');
-		   childPanel1_input2.setAttribute('class','input2_class');
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input2.setAttribute('type','checkbox');
-		   childPanel1_input2.setAttribute('name','zhineng');
-		   childPanel1_input2.setAttribute('value','2');
-		   maintenancePersonHtml.appendChild(childPanel1_input2);
-		  var childPanel1_div1 = document.createElement('div');
-		   childPanel1_div1.setAttribute('class','childPanel1_div1');
-		   childPanel1_div1.innerHTML='巡检';
-		   maintenancePersonHtml.appendChild(childPanel1_div1);
-		  var childPanel1_input3 = document.createElement('input');
-		   childPanel1_input3.setAttribute('class','input3_class');
-//		   childPanel1_input1.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input3.setAttribute('type','checkbox');
-		   childPanel1_input3.setAttribute('name','zhineng');
-		   childPanel1_input3.setAttribute('value','4');
-		   maintenancePersonHtml.appendChild(childPanel1_input3);
-		  var childPanel1_div2 = document.createElement('div');
-		   childPanel1_div2.setAttribute('class','childPanel1_div2');
-		   childPanel1_div2.innerHTML='报修';
-		   maintenancePersonHtml.appendChild(childPanel1_div2);
-		   var childPanel1_title1 = document.createElement('div');
-		   childPanel1_title1.setAttribute('class','title3_div');
-		   childPanel1_title1.innerHTML='姓名';
-		   maintenancePersonHtml.appendChild(childPanel1_title1);
-		   var childPanel1_input = document.createElement('input');
-		   childPanel1_input.setAttribute('class','input1_class');
-		   childPanel1_input.setAttribute('id','maintenancePerson_title3_input1');
-		   childPanel1_input.setAttribute('type','text');
-		   childPanel1_input.setAttribute('value','');
-		   maintenancePersonHtml.appendChild(childPanel1_input);
-		   var childPanel1_title2 = document.createElement('div');
-		   childPanel1_title2.setAttribute('class','maintenancePerson_title1_div');
-		   childPanel1_title2.setAttribute('id','maintenancePerson_title1_div');
-		   childPanel1_title2.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title2.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title2.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title2);
-		   var childPanel1_title3 = document.createElement('div');
-		   childPanel1_title3.setAttribute('class','maintenancePerson_title2_div');
-		   childPanel1_title3.setAttribute('id','maintenancePerson_title2_div');
-		   childPanel1_title3.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title3.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title3.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title3);
-		   var childPanel1_title4 = document.createElement('div');
-		   childPanel1_title4.setAttribute('class','maintenancePerson_title3_div');
-		   childPanel1_title4.setAttribute('id','maintenancePerson_title3_div');
-		   childPanel1_title4.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title4.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title4.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title4);
-		   var childPanel1_title5 = document.createElement('div');
-		   childPanel1_title5.setAttribute('class','maintenancePerson_title4_div');
-		   childPanel1_title5.setAttribute('id','maintenancePerson_title4_div');
-		   childPanel1_title5.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title5.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title5.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title5);
-		   var childPanel1_title6 = document.createElement('div');
-		   childPanel1_title6.setAttribute('class','maintenancePerson_title5_div');
-		   childPanel1_title6.setAttribute('id','maintenancePerson_title5_div');
-		   childPanel1_title6.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title6.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title6.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title6);
-		   var childPanel1_title7 = document.createElement('div');
-		   childPanel1_title7.setAttribute('class','maintenancePerson_title6_div');
-		   childPanel1_title7.setAttribute('id','maintenancePerson_title6_div');
-		   childPanel1_title7.setAttribute('onmouseover',"mouseon(this)");
-		   childPanel1_title7.setAttribute('onmouseout',"mouseoff(this)");
-		   childPanel1_title7.setAttribute('onclick',"menu_click(this)");
-		   maintenancePersonHtml.appendChild(childPanel1_title7);
-		   reset1();
-		 }
-	
-	changeon1 = function(obj){
-	      var selected = sm1.getSelection();
-	      var id = selected[0].raw.id
-	   var xid = obj.value;
-	   var query = new Object();
-	  if(xid.length>0){
-	    query.xid = xid;
-	  }
-	  query.id = id;
-	  // query.V_LOGINNAME = V_LOGINNAME;
-	  // query.V_PASSWORD =  V_PASSWORD;
-	  var jsonstr = Ext.JSON.encode(query);
-	     myStore1.getProxy().extraParams = {
-	      queryJson : jsonstr
-	     };
-	     Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
-	 }
-	
-	var childPanel2 = function() {
+
+	changeon1 = function (obj) {
+		var selected = sm1.getSelection();
+		var id = selected[0].raw.id
+		var xid = obj.value;
+		var query = new Object();
+		if (xid.length > 0) {
+			query.xid = xid;
+		}
+		query.id = id;
+		// query.V_LOGINNAME = V_LOGINNAME;
+		// query.V_PASSWORD =  V_PASSWORD;
+		var jsonstr = Ext.JSON.encode(query);
+		myStore1.getProxy().extraParams = {
+			queryJson: jsonstr
+		};
+		Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
+	}
+
+	var childPanel2 = function () {
 		var maintenancePersonHtml2 = document.getElementById('maintenancePersonHtml2');
 		var divhiddle = document.createElement('div');
-	    divhiddle.id='div26_id_maintenancePersonPanel3';
-	    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
-	    maintenancePersonHtml2.appendChild(divhiddle);
-	    var title = document.createElement('div');
-		   title.setAttribute('class','MaintenancePersonTitle123');
-		   title.innerHTML='班组列表';
-		   maintenancePersonHtml2.appendChild(title);			
- 		var childPanel2_title2 = document.createElement('div');
- 		childPanel2_title2.setAttribute('class','maintenancePerson_title11_div');
- 		childPanel2_title2.setAttribute('id','maintenancePerson_title11_div');
- 		childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
- 		childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
- 		childPanel2_title2.setAttribute('onclick',"menu_click(this)");
- 		maintenancePersonHtml2.appendChild(childPanel2_title2);
- 		var childPanel2_title3 = document.createElement('div');
- 		childPanel2_title3.setAttribute('class','maintenancePerson_title21_div');
- 		childPanel2_title3.setAttribute('id','maintenancePerson_title21_div');
- 		childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
- 		childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
- 		childPanel2_title3.setAttribute('onclick',"menu_click(this)");
- 		maintenancePersonHtml2.appendChild(childPanel2_title3);
-    }
-
-var childPanel3 = function(){
-	var maintenancePersonHtml3 = document.getElementById('maintenancePersonHtml3');
-	var divhiddle = document.createElement('div');
-    divhiddle.id='div26_id_maintenancePersonHtml3Panel3';
-    divhiddle.setAttribute('class','SpringHandleHtml3DivHiddle');
-    maintenancePersonHtml3.appendChild(divhiddle);
-    var title1 = document.createElement('div');
-	   title1.setAttribute('class','MaintenancePersonTitle123');
-	   title1.innerHTML='班组详情';
-	   maintenancePersonHtml3.appendChild(title1);
-	var childPanel2_title = document.createElement('div');
-	childPanel2_title.setAttribute('class','maintenancePerson_title211_div');
-	childPanel2_title.innerHTML='班组名称';
-	maintenancePersonHtml3.appendChild(childPanel2_title);
+		divhiddle.id = 'div26_id_maintenancePersonPanel3';
+		divhiddle.setAttribute('class', 'SpringHandleHtml3DivHiddle');
+		maintenancePersonHtml2.appendChild(divhiddle);
+		var title = document.createElement('div');
+		title.setAttribute('class', 'MaintenancePersonTitle123');
+		title.innerHTML = '班组列表';
+		maintenancePersonHtml2.appendChild(title);
+		var childPanel2_title2 = document.createElement('div');
+		childPanel2_title2.setAttribute('class', 'maintenancePerson_title11_div');
+		childPanel2_title2.setAttribute('id', 'maintenancePerson_title11_div');
+		childPanel2_title2.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title2.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title2.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml2.appendChild(childPanel2_title2);
+		var childPanel2_title3 = document.createElement('div');
+		childPanel2_title3.setAttribute('class', 'maintenancePerson_title21_div');
+		childPanel2_title3.setAttribute('id', 'maintenancePerson_title21_div');
+		childPanel2_title3.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title3.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title3.setAttribute('onclick', "menu_click(this)");
+		maintenancePersonHtml2.appendChild(childPanel2_title3);
+	}
+
+	var childPanel3 = function () {
+		var maintenancePersonHtml3 = document.getElementById('maintenancePersonHtml3');
+		var divhiddle = document.createElement('div');
+		divhiddle.id = 'div26_id_maintenancePersonHtml3Panel3';
+		divhiddle.setAttribute('class', 'SpringHandleHtml3DivHiddle');
+		maintenancePersonHtml3.appendChild(divhiddle);
+		var title1 = document.createElement('div');
+		title1.setAttribute('class', 'MaintenancePersonTitle123');
+		title1.innerHTML = '班组详情';
+		maintenancePersonHtml3.appendChild(title1);
+		var childPanel2_title = document.createElement('div');
+		childPanel2_title.setAttribute('class', 'maintenancePerson_title211_div');
+		childPanel2_title.innerHTML = '班组名称';
+		maintenancePersonHtml3.appendChild(childPanel2_title);
 		var childPanel2_input = document.createElement('input');
-		childPanel2_input.setAttribute('class','maintenancePerson_input211_class');
-		childPanel2_input.setAttribute('id','maintenancePerson_title211_input');
-		childPanel2_input.setAttribute('type','text');
-		childPanel2_input.setAttribute('value','');
+		childPanel2_input.setAttribute('class', 'maintenancePerson_input211_class');
+		childPanel2_input.setAttribute('id', 'maintenancePerson_title211_input');
+		childPanel2_input.setAttribute('type', 'text');
+		childPanel2_input.setAttribute('value', '');
 		maintenancePersonHtml3.appendChild(childPanel2_input);
 		var childPanel2_title1 = document.createElement('div');
-		childPanel2_title1.setAttribute('class','maintenancePerson_title111_div');
-		childPanel2_title1.innerHTML='负责人';
+		childPanel2_title1.setAttribute('class', 'maintenancePerson_title111_div');
+		childPanel2_title1.innerHTML = '负责人';
 		maintenancePersonHtml3.appendChild(childPanel2_title1);
-	var select = document.createElement('select');
-	   select.setAttribute('class','maintenancePerson_input111_class');
-	   select.setAttribute('onchange',"changeon1(this)");
-	   select.setAttribute('id','maintenancePerson_title111_input');
-	   maintenancePersonHtml3.appendChild(select);
-	   for(var i=0;i<ConfirmStore.length;i++){
-	    var option3 = document.createElement('option');
-	    option3.innerHTML=ConfirmStore[i].name;
-	    option3.setAttribute('value',ConfirmStore[i].rid);
-	    select.appendChild(option3); 
-	   }
-   var childPanel2_title2 = document.createElement('div');
-		childPanel2_title2.setAttribute('class','maintenancePerson_title31_div');
-		childPanel2_title2.setAttribute('id','maintenancePerson_title31_div');
-		childPanel2_title2.setAttribute('onmouseover',"mouseon1(this)");
-		childPanel2_title2.setAttribute('onmouseout',"mouseoff1(this)");
-		childPanel2_title2.setAttribute('onclick',"menu_click(this)");
+		var select = document.createElement('select');
+		select.setAttribute('class', 'maintenancePerson_input111_class');
+		select.setAttribute('onchange', "changeon1(this)");
+		select.setAttribute('id', 'maintenancePerson_title111_input');
+		maintenancePersonHtml3.appendChild(select);
+		for (var i = 0; i < ConfirmStore.length; i++) {
+			var option3 = document.createElement('option');
+			option3.innerHTML = ConfirmStore[i].name;
+			option3.setAttribute('value', ConfirmStore[i].rid);
+			select.appendChild(option3);
+		}
+		var childPanel2_title2 = document.createElement('div');
+		childPanel2_title2.setAttribute('class', 'maintenancePerson_title31_div');
+		childPanel2_title2.setAttribute('id', 'maintenancePerson_title31_div');
+		childPanel2_title2.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title2.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title2.setAttribute('onclick', "menu_click(this)");
 		maintenancePersonHtml3.appendChild(childPanel2_title2);
-	   var childPanel2_title3 = document.createElement('div');
-		childPanel2_title3.setAttribute('class','maintenancePerson_title41_div');
-		childPanel2_title3.setAttribute('id','maintenancePerson_title41_div');
-		childPanel2_title3.setAttribute('onmouseover',"mouseon1(this)");
-		childPanel2_title3.setAttribute('onmouseout',"mouseoff1(this)");
-		childPanel2_title3.setAttribute('onclick',"menu_click(this)");
+		var childPanel2_title3 = document.createElement('div');
+		childPanel2_title3.setAttribute('class', 'maintenancePerson_title41_div');
+		childPanel2_title3.setAttribute('id', 'maintenancePerson_title41_div');
+		childPanel2_title3.setAttribute('onmouseover', "mouseon1(this)");
+		childPanel2_title3.setAttribute('onmouseout', "mouseoff1(this)");
+		childPanel2_title3.setAttribute('onclick', "menu_click(this)");
 		maintenancePersonHtml3.appendChild(childPanel2_title3);
-}
+	}
 
-var childPanel3_fun =function(){
-	  var query = new Object();
-	  query.V_LOGINNAME = $("#V_LOGINNAME").val();
-	  $.ajax({
-	         type:'POST',
-	         url: baseUrl+"iot/inspectorsx/getTeamMembersList1",
-	         data: {
-	          queryJson : Ext.JSON.encode(query)
-	       },
-	         success: function(result){
-	             var json = eval('(' + result + ')');
-	             if(json.action=='getTeamMembersList'){
-	                 ConfirmStore = json.RESULT;
-	                 childPanel3();
-	             }
-	         } 
-	     });
-	 }
-	
-		var childPanel6 = Ext.create('Ext.Panel', {
-			  height:maxHeight,
-			  width:'20%',
-			        html: '<div></div>'
+	var childPanel3_fun = function () {
+		var query = new Object();
+		query.V_LOGINNAME = $("#V_LOGINNAME").val();
+		$.ajax({
+			type: 'POST',
+			url: baseUrl + "iot/inspectorsx/getTeamMembersList1",
+			data: {
+				queryJson: Ext.JSON.encode(query)
+			},
+			success: function (result) {
+				var json = eval('(' + result + ')');
+				if (json.action == 'getTeamMembersList') {
+					ConfirmStore = json.RESULT;
+					childPanel3();
+				}
+			}
 		});
-	
+	}
+
+	var childPanel6 = Ext.create('Ext.Panel', {
+		height: maxHeight,
+		width: '20%',
+		html: '<div></div>'
+	});
+
 	var MaintenancePersonPanel = Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		header: {
+			height: 0,
+			border: '0px solid #000000'
 		},
-	    id: 'MaintenancePersonListPanel',
-	    store: myStore,
-	    selModel: sm,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'id',hidden:true, menuDisabled:true },
-	    	 { header: '职能ID',  dataIndex: 'zn',hidden:true, menuDisabled:true },
-	    	 { header: '序号',  dataIndex: 'xh', width:39, menuDisabled:true },
-		     { header: '姓名', dataIndex: 'name', width:466,align:'center', menuDisabled:true },
-		     { header: '手机号', dataIndex: 'phone', width:466,align:'center', menuDisabled:true },
-		     { header: '职务', dataIndex: 'zn_name', width:466,align:'center', menuDisabled:true },
-		     
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '100%',
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore,  
-            id:'MaintenancePersonListPageToolbar',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-
-        }),
-        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid'
+		id: 'MaintenancePersonListPanel',
+		store: myStore,
+		selModel: sm,
+		columns: [
+			{ header: 'ID', dataIndex: 'id', hidden: true, menuDisabled: true },
+			{ header: '职能ID', dataIndex: 'zn', hidden: true, menuDisabled: true },
+			{ header: '序号', dataIndex: 'xh', width: 39, menuDisabled: true },
+			{ header: '姓名', dataIndex: 'name', width: 466, align: 'center', menuDisabled: true },
+			{ header: '手机号', dataIndex: 'phone', width: 466, align: 'center', menuDisabled: true },
+			{ header: '职务', dataIndex: 'zn_name', width: 466, align: 'center', menuDisabled: true },
+
+		],
+		columnLines: true,
+		height: maxHeight,
+		width: '100%',
+		bbar: new Ext.PagingToolbar({
+			store: myStore,
+			id: 'MaintenancePersonListPageToolbar',
+			displayInfo: true,
+			pageSize: countPerPage,
+			prependButtons: true,
+			displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+			emptyMsg: "没有记录",
+			firstText: '第一页',
+			prevText: '前一页',
+			nextText: '后一页',
+			lastText: '最后一页',
+			refreshText: '刷新',
+
+		}),
+		frame: true,
+		border: false,
+		iconCls: 'icon-grid'
 	});
 	var MaintenancePersonPanel2 = Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		header: {
+			height: 0,
+			border: '0px solid #000000'
 		},
-		bodyStyle:'background:#121E34;',
-	    id: 'MaintenancePersonListPanel2',
-	    store: myStore2,
-	    region:'center',
-	    selModel: sm1,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'id',hidden:true, menuDisabled:true },
-	    	 { header: '责任人ID',  dataIndex: 'person_liable_id',hidden:true, menuDisabled:true },
-	    	 { header: '序号',  dataIndex: 'xh', width:35, menuDisabled:true },
-		     { header: '班组名称', dataIndex: 'team_name', width:340,align:'center', menuDisabled:true },    
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '30%',
-	    listeners: {
-	        select: function(dataview,record,index) {//record被选中时产生的事件
-	         var label = record.get('team_name');
-	         var label1 = record.get('id');
-	         var label2 = record.get('person_liable_id');
-	         var query = new Object();
-	         if(label1.length>0){
-	           query.id = label1;
-	         }
-	         // query.V_LOGINNAME = V_LOGINNAME;
-	         // query.V_PASSWORD =  V_PASSWORD;
-	         var jsonstr = Ext.JSON.encode(query);
-	            myStore1.getProxy().extraParams = {
-	             queryJson : jsonstr
-	            };
-	            Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
-	            document.getElementById('maintenancePerson_title211_input').value = label;
-	            document.getElementById('maintenancePerson_title111_input').value = label2;
-//	         Ext.MessageBox.alert("标题触发了"+label);
-	        }
-//	              itemdblclick: function () {
-//	               Ext.MessageBox.alert("标题离开了");
-//	              }
-	          },
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore2,
-            id:'MaintenancePersonListPageToolbar2',
-//            displayInfo: true,  
-//            pageSize: countPerPage,  
-//            prependButtons: true,  
-//            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-//            emptyMsg : "没有记录",  
-//            firstText: '第一页',
-//            prevText: '前一页',
-//            nextText: '后一页',
-//            lastText: '最后一页',
-//            refreshText: '刷新',
-
-        }),
-//        frame: true,  
-        border:false,  
-        iconCls: 'icon-grid'
-	});
-	var MaintenancePersonPanel3 = 
-		Ext.create('Ext.grid.Panel', {
-		header :{
-			height:0,
-			border:'0px solid #000000'
+		bodyStyle: 'background:#121E34;',
+		id: 'MaintenancePersonListPanel2',
+		store: myStore2,
+		region: 'center',
+		selModel: sm1,
+		columns: [
+			{ header: 'ID', dataIndex: 'id', hidden: true, menuDisabled: true },
+			{ header: '责任人ID', dataIndex: 'person_liable_id', hidden: true, menuDisabled: true },
+			{ header: '序号', dataIndex: 'xh', width: 35, menuDisabled: true },
+			{ header: '班组名称', dataIndex: 'team_name', width: 340, align: 'center', menuDisabled: true },
+		],
+		columnLines: true,
+		height: maxHeight,
+		width: '30%',
+		listeners: {
+			select: function (dataview, record, index) {//record被选中时产生的事件
+				var label = record.get('team_name');
+				var label1 = record.get('id');
+				var label2 = record.get('person_liable_id');
+				var query = new Object();
+				if (label1.length > 0) {
+					query.id = label1;
+				}
+				// query.V_LOGINNAME = V_LOGINNAME;
+				// query.V_PASSWORD =  V_PASSWORD;
+				var jsonstr = Ext.JSON.encode(query);
+				myStore1.getProxy().extraParams = {
+					queryJson: jsonstr
+				};
+				Ext.getCmp('MaintenancePersonListPageToolbar3').moveFirst();
+				document.getElementById('maintenancePerson_title211_input').value = label;
+				document.getElementById('maintenancePerson_title111_input').value = label2;
+				//	         Ext.MessageBox.alert("标题触发了"+label);
+			}
+			//	              itemdblclick: function () {
+			//	               Ext.MessageBox.alert("标题离开了");
+			//	              }
 		},
-	    id: 'MaintenancePersonListPanel3',
-	    store: myStore1,
-	    region:'center',
-	    selModel: addsm,
-	    columns: [
-	    	 { header: 'ID',  dataIndex: 'rid',hidden:true, menuDisabled:true },
-	    	 { header: '责任人ID', dataIndex: 'person_liable_id',hidden:true, menuDisabled:true},
-	    	 { header: '班组ID', dataIndex: 'tdid',hidden:true, menuDisabled:true},
-	    	 { header: '默认值', dataIndex: 'pd',hidden:true, menuDisabled:true},
-	    	 { header: '序号',  dataIndex: 'xh', width:35, menuDisabled:true },
-		     { header: '组员', dataIndex: 'name', width:633,align:'center', menuDisabled:true },
-//		     { header: '', dataIndex: 'zrr', width:267,align:'center', menuDisabled:true },
-		     
-	    ],
-	    columnLines: true,
-	    height: maxHeight,
-	    width: '50%',
-	    listeners:{
-	    	
-	         viewready:function(){
-	         var hd_checker = this.getEl().select('div.x-grid3-hd-checker');
-//	         if (hd_checker.hasClass('x-grid3-hd-checker')) {   
-//	                hd_checker.removeClass('x-grid3-hd-checker'); // 去掉全选框 
-//	            } 
-	        }
-	    },
-	    bbar: new Ext.PagingToolbar({  
-            store: myStore1,  
-            id:'MaintenancePersonListPageToolbar3',
-            displayInfo: true,  
-            pageSize: countPerPage,  
-            prependButtons: true,  
-            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
-            emptyMsg : "没有记录",  
-            firstText: '第一页',
-            prevText: '前一页',
-            nextText: '后一页',
-            lastText: '最后一页',
-            refreshText: '刷新',
-
-        }),
-        border:false,
-        iconCls: 'icon-grid'
+		bbar: new Ext.PagingToolbar({
+			store: myStore2,
+			id: 'MaintenancePersonListPageToolbar2',
+			//            displayInfo: true,  
+			//            pageSize: countPerPage,  
+			//            prependButtons: true,  
+			//            displayMsg : '显示第 {0}条到 {1}条记录,总共 {2}条',     
+			//            emptyMsg : "没有记录",  
+			//            firstText: '第一页',
+			//            prevText: '前一页',
+			//            nextText: '后一页',
+			//            lastText: '最后一页',
+			//            refreshText: '刷新',
+
+		}),
+		//        frame: true,  
+		border: false,
+		iconCls: 'icon-grid'
 	});
+	var MaintenancePersonPanel3 =
+		Ext.create('Ext.grid.Panel', {
+			header: {
+				height: 0,
+				border: '0px solid #000000'
+			},
+			id: 'MaintenancePersonListPanel3',
+			store: myStore1,
+			region: 'center',
+			selModel: addsm,
+			columns: [
+				{ header: 'ID', dataIndex: 'rid', hidden: true, menuDisabled: true },
+				{ header: '责任人ID', dataIndex: 'person_liable_id', hidden: true, menuDisabled: true },
+				{ header: '班组ID', dataIndex: 'tdid', hidden: true, menuDisabled: true },
+				{ header: '默认值', dataIndex: 'pd', hidden: true, menuDisabled: true },
+				{ header: '序号', dataIndex: 'xh', width: 35, menuDisabled: true },
+				{ header: '组员', dataIndex: 'name', width: 633, align: 'center', menuDisabled: true },
+				//		     { header: '', dataIndex: 'zrr', width:267,align:'center', menuDisabled:true },
+
+			],
+			columnLines: true,
+			height: maxHeight,
+			width: '50%',
+			listeners: {
+
+				viewready: function () {
+					var hd_checker = this.getEl().select('div.x-grid3-hd-checker');
+					//	         if (hd_checker.hasClass('x-grid3-hd-checker')) {   
+					//	                hd_checker.removeClass('x-grid3-hd-checker'); // 去掉全选框 
+					//	            } 
+				}
+			},
+			bbar: new Ext.PagingToolbar({
+				store: myStore1,
+				id: 'MaintenancePersonListPageToolbar3',
+				displayInfo: true,
+				pageSize: countPerPage,
+				prependButtons: true,
+				displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
+				emptyMsg: "没有记录",
+				firstText: '第一页',
+				prevText: '前一页',
+				nextText: '后一页',
+				lastText: '最后一页',
+				refreshText: '刷新',
+
+			}),
+			border: false,
+			iconCls: 'icon-grid'
+		});
 
-	var piebar = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml',
-		width:'100%',
-		height:188,
-		region:'north',
-		layout:'form',
-		defaults:{  
-            border:false
-        }
-//        items: [childPanel1]
+	var piebar = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml',
+		width: '100%',
+		height: 188,
+		region: 'north',
+		layout: 'form',
+		defaults: {
+			border: false
+		}
+		//        items: [childPanel1]
 	});
-	var piebar2 = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml2',
-		width:'30%',
-		height:140,
-		region:'north',
-		layout:'form',
-		bodyStyle:'background:#121E34;',
-		defaults:{  
-            border:false
-        }
-//        items: [childPanel2]
+	var piebar2 = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml2',
+		width: '30%',
+		height: 140,
+		region: 'north',
+		layout: 'form',
+		bodyStyle: 'background:#121E34;',
+		defaults: {
+			border: false
+		}
+		//        items: [childPanel2]
 	});
-	var piebar3 = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml3',
-		width:'50%',
-		height:140,
-		region:'north',
-		layout:'form',
-		defaults:{  
-            border:false
-        }
+	var piebar3 = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml3',
+		width: '50%',
+		height: 140,
+		region: 'north',
+		layout: 'form',
+		defaults: {
+			border: false
+		}
 	});
-	panel1 = Ext.create('Ext.panel.Panel',{
-		width:'100%',
+	panel1 = Ext.create('Ext.panel.Panel', {
+		width: '100%',
 		id: 'MaintenancePersonPiebar',
-		layout:'border',
-		items:[
-			piebar,MaintenancePersonPanel
+		layout: 'border',
+		items: [
+			piebar, MaintenancePersonPanel
 		],
-	    
-    });
-	
-	var piebar4 = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml4',
-		width:'30%',
-		region:'west',
-		layout:'border',
-		bodyStyle:'background:#121E34;border-radius:20px;padding:10px;',
-		padding:10,
-		items:[
-			piebar2,MaintenancePersonPanel2
+
+	});
+
+	var piebar4 = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml4',
+		width: '30%',
+		region: 'west',
+		layout: 'border',
+		bodyStyle: 'background:#121E34;border-radius:20px;padding:10px;',
+		padding: 10,
+		items: [
+			piebar2, MaintenancePersonPanel2
 		]
 	});
-	
-	var piebar5 = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml5',
-		width:'50%',
-		region:'center',
-		layout:'border',
-		bodyStyle:'padding:10px;',
-		padding:10,
-		items:[
-			piebar3,MaintenancePersonPanel3
+
+	var piebar5 = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml5',
+		width: '50%',
+		region: 'center',
+		layout: 'border',
+		bodyStyle: 'padding:10px;',
+		padding: 10,
+		items: [
+			piebar3, MaintenancePersonPanel3
 		]
 	});
-	
-	var piebar6 = Ext.create('Ext.panel.Panel',{
-		id:'maintenancePersonHtml6',
-		width:'20%',
-		region:'east',
-		layout:'form',
-		defaults:{  
-            border:false
-        },
-        items: [childPanel6]
+
+	var piebar6 = Ext.create('Ext.panel.Panel', {
+		id: 'maintenancePersonHtml6',
+		width: '20%',
+		region: 'east',
+		layout: 'form',
+		defaults: {
+			border: false
+		},
+		items: [childPanel6]
 	});
-	
-	panel2 = Ext.create('Ext.panel.Panel',{
-			width:'100%',
-			id: 'MaintenancePersonPiebar2',
-			layout:'border',
-			items:[
-				piebar4,piebar5,piebar6
-			],
-		    
+
+	panel2 = Ext.create('Ext.panel.Panel', {
+		width: '100%',
+		id: 'MaintenancePersonPiebar2',
+		layout: 'border',
+		items: [
+			piebar4, piebar5, piebar6
+		],
+
 	});
-	
+
 	Ext.create('Ext.tab.Panel', {
-	     width: '100%',
-	     id: 'MaintenancePersonTab',
-	     activeTab: 0,
-	     items: [
-	         {
-	          itemId:'person',
-	             title: '人员列表',
-	             items : [panel1]
-	         },
-	         {
-	          itemId:'team',
-	             title: '班组详情',
-	             items : [panel2]
-	         }
-	     ],
-	     listeners:{
-	            'tabchange':function (t, n) {
-	             var item = n.itemId;
-	             if(item=='team'){
-	              if(document.getElementById('div26_id_maintenancePersonPanel3')==undefined)
-	              childPanel2();
-	              if(document.getElementById('div26_id_maintenancePersonHtml3Panel3')==undefined)
-		          childPanel3_fun();	              
-	              myStore2.reload();
-	             }
-	            }
-	        },
-	     renderTo : Ext.getBody()
-	     
-	 });
+		width: '100%',
+		id: 'MaintenancePersonTab',
+		activeTab: 0,
+		items: [
+			{
+				itemId: 'person',
+				title: '人员列表',
+				items: [panel1]
+			},
+			{
+				itemId: 'team',
+				title: '班组详情',
+				items: [panel2]
+			}
+		],
+		listeners: {
+			'tabchange': function (t, n) {
+				var item = n.itemId;
+				if (item == 'team') {
+					if (document.getElementById('div26_id_maintenancePersonPanel3') == undefined)
+						childPanel2();
+					if (document.getElementById('div26_id_maintenancePersonHtml3Panel3') == undefined)
+						childPanel3_fun();
+					myStore2.reload();
+				}
+			}
+		},
+		renderTo: Ext.getBody()
+
+	});
 	myStore.reload();
 	mystore2_fun(0);
 	childPanel1();
-	$(window).resize(function(){
-    	body_resize();
-    	body_resize1();
-    });
-	body_resize1();	
+	$(window).resize(function () {
+		body_resize();
+		body_resize1();
+	});
+	body_resize1();
 	body_resize();
 });

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 990 - 1011
out/artifacts/YtIoT_Web_exploded/view/maintenanceplan/scripts/maintenanceplan.js


+ 33 - 5
out/artifacts/YtIoT_Web_exploded/view/patrolpoint/scripts/patrolpoint.js

@@ -943,19 +943,35 @@ Ext.onReady(function () {
 	function public_update() {
 		var patrol_point_uploadURL = Ext.getCmp('patrol_point_uploadURL').getValue();
 		var fm_patrol_spot_name = Ext.getCmp('fm_patrol_spot_name').getValue();
+		if (fm_patrol_spot_name == "" || fm_patrol_spot_name == null) {
+			Ext.Msg.alert('系统提示', '点位名称不能为空!');
+			return;
+		}
 		var fm_patrol_company_code = Ext.getCmp('fm_patrol_company_code').getValue();
+		if (fm_patrol_company_code == "" || fm_patrol_company_code == null) {
+			Ext.Msg.alert('系统提示', '请选择所属建筑/项目!');
+			return;
+		}
 		var fm_patrol_spot_address = Ext.getCmp('fm_patrol_spot_address').getValue();
+		if (fm_patrol_spot_address == "" || fm_patrol_spot_address == null) {
+			Ext.Msg.alert('系统提示', '点位地址不能为空!');
+			return;
+		}
+		//	        		var fm_patrol_equipment_code=Ext.getCmp('fm_patrol_equipment_code').getValue();
+		//	        		var fm_patrol_spot_type=patrolUploadForm.form.findField("fm_patrol_spot_type").getGroupValue();
 		var fm_patrol_spot_type = Ext.getCmp('fm_patrol_spot_type').getChecked();
 		var spot_type = '';
 		Ext.Array.each(fm_patrol_spot_type, function (item) {
 			spot_type += item.inputValue + ',';
 		});
+		if (spot_type == null || spot_type == "") {
+			Ext.Msg.alert('系统提示', '至少选择一项设备类型!');
+		}
 		var fm_patrol_point_message = Ext.getCmp('fm_patrol_point_message').getValue();
 		var fm_patrol_point_id = Ext.getCmp('fm_patrol_point_id').getValue();
 		var query = new Object();
 		if (AllSelectedRecords1.length == 1) {
 			query.equipment_code = AllSelectedRecords1[0];
-
 		} else {
 			if (AllSelectedRecords1.length > 1) {
 				var spot_id = null;
@@ -967,6 +983,9 @@ Ext.onReady(function () {
 						spot_id += "," + AllSelectedRecords1[i];
 				}
 				query.equipment_code = spot_id;
+			} else {
+				Ext.Msg.alert('系统提示', '至少选择一条巡检点位,再点击提交!');
+				return;
 			}
 		}
 		query.id = fm_patrol_point_id;
@@ -1028,7 +1047,7 @@ Ext.onReady(function () {
 			}]
 	});
 
-	function pulic_instrt() {
+	function public_insert() {
 		var fa_patrol_spot_name = Ext.getCmp('fa_patrol_spot_name').getValue();
 		if (fa_patrol_spot_name == "" || fa_patrol_spot_name == null) {
 			Ext.Msg.alert('系统提示', '点位名称不能为空!');
@@ -1044,11 +1063,16 @@ Ext.onReady(function () {
 			Ext.Msg.alert('系统提示', '点位地址不能为空!');
 			return;
 		}
+		//	        		var fa_patrol_equipment_code=Ext.getCmp('fa_patrol_equipment_code').getValue();
 		var fa_patrol_spot_type = Ext.getCmp('fa_patrol_spot_type').getChecked();
 		var spot_type = '';
 		Ext.Array.each(fa_patrol_spot_type, function (item) {
 			spot_type += item.inputValue + ',';
 		});
+		if (spot_type == null || spot_type == "") {
+			Ext.Msg.alert('系统提示', '至少选择一项设备类型!');
+		}
+		//	        		var fa_patrol_spot_type = patroladdForm.getForm().findField("fa_patrol_spot_type").getGroupValue();
 		var fa_patrol_point_message = Ext.getCmp('fa_patrol_point_message').getValue();
 		var patrol_point_addURL = Ext.getCmp('patrol_point_addURL').getValue();
 		if (patrol_point_addURL == "" || patrol_point_addURL == null) {
@@ -1059,15 +1083,16 @@ Ext.onReady(function () {
 		query.spot_name = fa_patrol_spot_name;
 		query.company_code = fa_patrol_company_code;
 		query.spot_address = fa_patrol_spot_address;
+		//	        		query.equipment_code = fa_patrol_equipment_code;
 		query.spot_type = spot_type;
 		query.remarks = fa_patrol_point_message;
 		query.picture_route = patrol_point_addURL;
-
 		if (AllSelectedRecords.length == 1) {
 			query.equipment_code = AllSelectedRecords[0];
 		} else {
 			if (AllSelectedRecords.length > 1) {
 				var spot_id = null;
+				//	                     var selected = sm1.getSelection( );
 				for (var i = 0; i < AllSelectedRecords.length; i++) {
 					if (i == 0)
 						spot_id = AllSelectedRecords[i];
@@ -1075,9 +1100,11 @@ Ext.onReady(function () {
 						spot_id += "," + AllSelectedRecords[i];
 				}
 				query.equipment_code = spot_id;
+			} else {
+				Ext.Msg.alert('系统提示', '至少选择一条巡检点位,再点击提交!');
+				return;
 			}
 		}
-
 		query.V_LOGINNAME = V_LOGINNAME;
 		// query.V_PASSWORD =  V_PASSWORD;
 		var jsonstr = Ext.JSON.encode(query);
@@ -1095,6 +1122,7 @@ Ext.onReady(function () {
 			failure: function (form, action) {
 				Ext.Msg.alert('系统提示', '保存失败!');
 				clear_append_form();
+
 			}
 		});
 	}
@@ -1114,7 +1142,7 @@ Ext.onReady(function () {
 			{
 				text: '保存',
 				handler: function () {
-					pulic_instrt();
+					public_insert();
 				}
 			}, {
 				text: '取消',

+ 0 - 5
out/artifacts/YtIoT_Web_exploded/view/scripts/log.html

@@ -11,7 +11,6 @@
     <script src="https://unpkg.com/element-ui/lib/index.js"></script>
     <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
     <style>
-<<<<<<< HEAD
     .el-table {
         background: transparent !important;
     }
@@ -86,18 +85,14 @@
     .el-table .el-table__body-wrapper::-webkit-scrollbar {
         display: none;
     }
-	html,body,#app{
-=======
         html,
         body,
         #app {
->>>>>>> 6d16855fb9a830c488d691f333de87ec768f6456
             width: 100%;
             height: 100%;
             padding: 0;
             margin: 0;
         }
-        
         .home {
             width: 100%;
             height: 100%;

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels