mirror of
				https://github.com/Ysurac/openmptcprouter-feeds.git
				synced 2025-03-09 15:40:03 +00:00 
			
		
		
		
	Fix add interface in luci-omr-tracker
This commit is contained in:
		
							parent
							
								
									c149ea35dc
								
							
						
					
					
						commit
						a4a0cad8ad
					
				
					 1 changed files with 9 additions and 2 deletions
				
			
		| 
						 | 
					@ -35,6 +35,13 @@ return view.extend({
 | 
				
			||||||
				.map(function(s) { return s['.name']; });
 | 
									.map(function(s) { return s['.name']; });
 | 
				
			||||||
		};
 | 
							};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
							s.handleAdd = function(ev) {
 | 
				
			||||||
 | 
								this.sectiontype = 'interface';
 | 
				
			||||||
 | 
								var promise = form.GridSection.prototype.handleAdd.apply(this, arguments);
 | 
				
			||||||
 | 
								this.sectiontype = undefined;
 | 
				
			||||||
 | 
								return promise;
 | 
				
			||||||
 | 
							};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		o = s.option(form.Flag, 'enabled', _('Enabled'));
 | 
							o = s.option(form.Flag, 'enabled', _('Enabled'));
 | 
				
			||||||
		o.default = false;
 | 
							o.default = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -54,13 +61,13 @@ return view.extend({
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		o = s.option(form.DynamicList, 'hosts', _('Tracking hostname or IP address'),
 | 
							o = s.option(form.DynamicList, 'hosts', _('Tracking hostname or IP address'),
 | 
				
			||||||
			_('This hostname or IP address will be pinged to determine if the link is up or down. Leave blank to use defaults settings.'));
 | 
								_('This hostname or IP address will be pinged to determine if the link is up or down. Leave blank to use defaults settings.'));
 | 
				
			||||||
		o.datatype = 'hosts';
 | 
							//o.datatype = 'hosts';
 | 
				
			||||||
		o.modalonly = true;
 | 
							o.modalonly = true;
 | 
				
			||||||
		o.rmempty = false;
 | 
							o.rmempty = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		o = s.option(form.DynamicList, 'hosts6', _('Tracking hostname or IP address for IPv6'),
 | 
							o = s.option(form.DynamicList, 'hosts6', _('Tracking hostname or IP address for IPv6'),
 | 
				
			||||||
			_('This hostname or IP address will be pinged to determine if the link is up or down. Leave blank to use defaults settings.'));
 | 
								_('This hostname or IP address will be pinged to determine if the link is up or down. Leave blank to use defaults settings.'));
 | 
				
			||||||
		o.datatype = 'hosts';
 | 
							//o.datatype = 'hosts';
 | 
				
			||||||
		o.modalonly = true;
 | 
							o.modalonly = true;
 | 
				
			||||||
		o.depends('family', 'ipv4ipv6');
 | 
							o.depends('family', 'ipv4ipv6');
 | 
				
			||||||
		o.depends('family', 'ipv6');
 | 
							o.depends('family', 'ipv6');
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue