⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fiberdialog.js

📁 javascript ext1.X源码,主要用于界面
💻 JS
📖 第 1 页 / 共 2 页
字号:
			}	
			*/
			
			if(!modifyFiberDialog)
			{
				modifyFiberDialog = new Ext.BasicDialog("modifyFiberDlg", {
	            	width:600,
	            	height:400,
					modal:false,
					resizable:false
	            }); /*
	            modifyFiberForm = new Ext.form.Form({
	            	id: 'modifyfiberform',
	        		labelAlign: 'left',
	        		labelWidth: 60,
	        		waitMsgTarget: 'modifyFiberDlg',
	        		reader: new Ext.data.JsonReader({
			            root: 'fibers',
			            id: 'id'
			        	}, [
							{name: 'midf', mapping:'id'},
							{name: 'mcodef', mapping: 'code'},
							{name: 'mnamef', mapping: 'name'},
							{name: 'maroomf', mapping: 'aroom'},
							{name: 'maportf', mapping: 'aport'},
							{name: 'mbroomf', mapping: 'broom'},
							{name: 'mbportf', mapping: 'bport'},
							{name: 'misTrunkf', mapping: 'isTrunk'},
							{name: 'misMainf', mapping: 'isMain'},
							{name: 'mbusinessTypef', mapping: 'businessType'},
							{name: 'mvelocityf', mapping: 'velocity'},
							{name: 'mamountf', mapping: 'amount'},
							{name: 'mtransSystemf', mapping: 'transSystem'}
			        ])
				});  

				fsf0 = modifyFiberForm.fieldset(
					{labelWidth:0,labelSeparator:''},
					mff0 = new Ext.form.TextField({name: 'midf'}));	
					
				mfieldset1 = modifyFiberForm.fieldset({legend:'基本信息', style:'width:550px'});
				mleftColumn1 = new Ext.form.Column();
				modifyFiberForm.start(mleftColumn1);
				modifyFiberForm.add(
					mff1 = new Ext.form.TextField({
			            fieldLabel: '光路代码',
			            name: 'mcodef',
			            width:175
			        }),
			        mff2 = new Ext.form.TextField({
			            fieldLabel: '光路名称',
			            name: 'mnamea',
			            width:175
			        }),
			        mff3 = new Ext.form.ClearableComboBox({
				        fieldLabel: '速率',
			            name: 'mvelocityf',
				        store: new Ext.data.SimpleStore({
				        	fields: ['ov', 'ot'],
				            data: velocityDS
				        }),
				        valueField:'ov',
				        displayField:'ot',
				        mode: 'local',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,
				        width:175
			        }),
			        mff4 = new Ext.form.ClearableComboBox({
				        fieldLabel: '业务类型',
			            name: 'mbusinessTypeaf',
				        store: new Ext.data.SimpleStore({
				        	fields: ['ov', 'ot'],
				            data: businessTypeDS
				        }),
				        valueField:'ov',
				        displayField:'ot',
				        mode: 'local',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,
				        width:175
			        }));
			    modifyFiberForm.end(mleftColumn1);
			    mrightColumn1 = new Ext.form.Column();
			    modifyFiberForm.start(mrightColumn1);
			    modifyFiberForm.add(
					mautoCreatBtn = new Ext.Button('modifyCreateBtn', {text:'自动生成'}),
			        mff5 = new Ext.form.ClearableComboBox({
				        fieldLabel: '主光路',
			            name: 'misMainf',
				        store: new Ext.data.SimpleStore({
				        	fields: ['ov', 'ot'],
				            data: ysDS
				        }),
				        valueField:'ov',
				        displayField:'ot',
				        mode: 'local',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,
				        width:175
			        }),
			        mff6 = new Ext.form.TextField({
			            fieldLabel: '数量',
			            name: 'mamountf',
			            value: '1',
			            width:175
			        }),
			        mff7 = new Ext.form.ClearableComboBox({
				        fieldLabel: '传输系统',
			            name: 'mtransSystemf',
				        store: transSystemCBDS,
				        valueField:'id',
				        displayField:'name',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
			        }));
			    modifyFiberForm.end(mrightColumn1);
			    modifyFiberForm.end(mfieldset1);
			    
			    mfieldset2 = modifyFiberForm.fieldset({legend:'A端信息', style:'width:550px'});
				mleftColumn2 = new Ext.form.Column();
				modifyFiberForm.start(mleftColumn2);
				modifyFiberForm.add(
					mff8 = new Ext.form.ClearableComboBox({
				        fieldLabel: '省干',
				        name: 'maisTrunkf',
				        store: new Ext.data.SimpleStore({
				        	fields: ['ov', 'ot'],
				            data: ysDS
				        }),
				        valueField:'ov',
				        displayField:'ot',
				        mode: 'local',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,
				        width:175
				    }),
				    mff9 = new Ext.form.ClearableComboBox({
				        fieldLabel: '机房',
				        name: 'maroomf',
				        store: roomCBDS,
				        valueField:'id',
				        displayField:'name',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }));
			    modifyFiberForm.end(mleftColumn2);
			    mrightColumn2 = new Ext.form.Column();
			    modifyFiberForm.start(mrightColumn2);
			    modifyFiberForm.add(
					mff10 = new Ext.form.ClearableComboBox({
				        fieldLabel: '波分通道',
				        name: 'machannelf',
				        store: channelCBDS,
				        valueField:'id',
				        displayField:'channel',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }),
				    mff11 = new Ext.form.ClearableComboBox({
				        fieldLabel: '端口',
				        name: 'maportf',
				        store: portCBDS,
				        valueField:'id',
				        displayField:'name',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }));
			    modifyFiberForm.end(mrightColumn2);
			    modifyFiberForm.end(mfieldset2);
			    
			    mfieldset3 = modifyFiberForm.fieldset({legend:'B端信息', style:'width:550px'});
				mleftColumn3 = new Ext.form.Column();
				modifyFiberForm.start(mleftColumn3);
				modifyFiberForm.add(
					mff12 = new Ext.form.ClearableComboBox({
				        fieldLabel: '省干',
				        name: 'mbisTrunkf',
				        store: new Ext.data.SimpleStore({
				        	fields: ['ov', 'ot'],
				            data: ysDS
				        }),
				        valueField:'ov',
				        displayField:'ot',
				        mode: 'local',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,
				        width:175
				    }),
				    mff13 = new Ext.form.ClearableComboBox({
				        fieldLabel: '机房',
				        name: 'mbroomf',
				        store: roomCBDS,
				        valueField:'id',
				        displayField:'name',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }));
			    modifyFiberForm.end(mleftColumn3);
			    mrightColumn3 = new Ext.form.Column();
			    modifyFiberForm.start(mrightColumn3);
			    modifyFiberForm.add(
					mff14 = new Ext.form.ClearableComboBox({
				        fieldLabel: '波分通道',
				        name: 'mbchannelf',
				        store: channelCBDS,
				        valueField:'id',
				        displayField:'channel',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }),
				    mff15 = new Ext.form.ClearableComboBox({
				        fieldLabel: '端口',
				        name: 'mbportf',
				        store: portCBDS,
				        valueField:'id',
				        displayField:'name',
				        typeAhead: true,
				        mode: 'remote',
				        triggerAction: 'all',
				        selectOnFocus:true,
				        editable: false,	
				        width:175
				    }));
			    modifyFiberForm.end(mrightColumn3);
			    modifyFiberForm.end(mfieldset3);				
    			
				function modifyFiberSubmit(){
					modifyFiberForm.submit({
						url:FiberSchedulerPath+'fiberapply/modifyFiber.do', 
						waitMsg:'正在操作,请稍候......', 
						success:function(){
							modifyFiberDialog.hide();
							fiberDS.load({params:{start:0, limit:pgSize}});
							Ext.MessageBox.alert('提示','增加光路,操作成功');
						},
						failure:function(){
							Ext.MessageBox.alert('提示ʾ','增加光路,操作失败');
						}});
				}
				
	   			modifyFiberForm.addButton('提交', modifyFiberSubmit, modifyFiberForm );
	   			modifyFiberForm.addButton('重置', modifyFiberForm.reset, modifyFiberForm);
			    modifyFiberForm.addButton('取消', modifyFiberDialog.hide, modifyFiberDialog);
				modifyFiberForm.render('modifyFiberForm');  
				fsf0.hide();	*/			
			}
			
			/*
			modifyFiberForm.load({
				url:FiberSchedulerPath+'fiberapply/findFiber.do'+'&Id='+selectFiber.get('id'), 
				waitMsg:'正在操作,请稍候......'
			});
			*/
			
			modifyFiberDialog.show(modifyFiberBtn.dom);
		},
		deleteFiberClick: function(){
			var selectFiber = gridFiber.getSelectionModel().getSelected();
			/*
			if(!selectFiber)
			{
				Ext.MessageBox.alert('提示','请先选择一条记录');
				return;
			}	
			*/
			
			Ext.MessageBox.confirm('提示','您确认要删除吗?',function(btn){
				if(btn == 'no') 
					return;
				modifyApplyForm.submit({
						url:FiberSchedulerPath+'fiberapply/deleteFiber.do&Id='+selectFiber.get('id'), 
						success: function(){									
							Ext.MessageBox.alert('提示','删除光路,操作成功');
							fiberDS.reload();
						},
						failure: function(){
							Ext.MessageBox.alert('提示','删除光路,操作失败');
						}
					});
			});
		},
		relayManageClick: function(){
			alert('未完成');
		},
		constructUnitManageClick: function(){
			alert('未完成');
		}
	}
}();

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -