change update interval checking method
This commit is contained in:
		
							parent
							
								
									a0f8a7b0b3
								
							
						
					
					
						commit
						c2f5daac98
					
				
					 3 changed files with 16 additions and 22 deletions
				
			
		|  | @ -165,6 +165,9 @@ | ||||||
| 	"settings_filters_content": { | 	"settings_filters_content": { | ||||||
| 		"message": "Filter" | 		"message": "Filter" | ||||||
| 	}, | 	}, | ||||||
|  | 	"settings_update_duration_description": { | ||||||
|  | 		"message": "Update Check" | ||||||
|  | 	}, | ||||||
| 
 | 
 | ||||||
| 	"JSON_parse_error": { | 	"JSON_parse_error": { | ||||||
| 		"message": "There is a mistake in your JSON formatting. Please correct the error before saving." | 		"message": "There is a mistake in your JSON formatting. Please correct the error before saving." | ||||||
|  |  | ||||||
|  | @ -103,22 +103,9 @@ | ||||||
| 							</side> | 							</side> | ||||||
| 						</section> | 						</section> | ||||||
| 						<section class="input-group"> | 						<section class="input-group"> | ||||||
| 							<label class="input-description"> |  | ||||||
| 								<legend |  | ||||||
| 									for="duration" |  | ||||||
| 									class="flow-text" |  | ||||||
| 								></legend> |  | ||||||
| 								<label |  | ||||||
| 									for="settings_update_duration_description" |  | ||||||
| 								></label> |  | ||||||
| 							</label> |  | ||||||
| 							<div class="input-field"> | 							<div class="input-field"> | ||||||
| 								<input | 								<input type="number" data-store="settings,sync,duration" data-store-location="1" placeholder=" " min=".25" step=".25" /> | ||||||
| 									type="number" | 								<label for="settings_update_duration_description"></label> | ||||||
| 									data-store="settings,sync,duration" |  | ||||||
| 									data-store-location="1" |  | ||||||
| 								/> |  | ||||||
| 								<label for="settings_update_duration_prompt"></label> |  | ||||||
| 							</div> | 							</div> | ||||||
| 						</section> | 						</section> | ||||||
| 						<section class="input-group"> | 						<section class="input-group"> | ||||||
|  | @ -132,12 +119,7 @@ | ||||||
| 								></label> | 								></label> | ||||||
| 							</label> | 							</label> | ||||||
| 							<div class="input-field"> | 							<div class="input-field"> | ||||||
| 								<input | 								<input type="password" data-store="settings,analysis,api,key" data-store-location="1" placeholder=" " class="validate" required /> | ||||||
| 									type="password" |  | ||||||
| 									data-store="settings,analysis,api,key" |  | ||||||
| 									data-store-location="1" |  | ||||||
| 									placeholder=" " |  | ||||||
| 								/> |  | ||||||
| 								<label for="API_Key"></label> | 								<label for="API_Key"></label> | ||||||
| 							</div> | 							</div> | ||||||
| 						</section> | 						</section> | ||||||
|  |  | ||||||
|  | @ -350,8 +350,17 @@ export default class windowman { | ||||||
| 						element[`event`] = function () { | 						element[`event`] = function () { | ||||||
| 							let UI_item = {}; | 							let UI_item = {}; | ||||||
| 							UI_item[`source`] = this.getAttribute(`data-store`); | 							UI_item[`source`] = this.getAttribute(`data-store`); | ||||||
|  | 
 | ||||||
|  | 							if (element[`type`].includes(`num`) || element[`type`].includes(`range`)) { | ||||||
|  | 								if ((this.hasAttribute(`min`)) ? this.value < parseFloat(this.getAttribute(`min`)) : false) { | ||||||
|  | 									this.value = this.getAttribute(`min`); | ||||||
|  | 								} else if((this.hasAttribute(`max`)) ? this.value > parseFloat(this.getAttribute(`max`)) : false) { | ||||||
|  | 									this.value = this.getAttribute(`max`); | ||||||
|  | 								}; | ||||||
|  | 							}; | ||||||
|  | 
 | ||||||
| 							UI_item[`value`] = element[`type`].includes(`num`) | 							UI_item[`value`] = element[`type`].includes(`num`) | ||||||
| 								? parseFloat(this.value) % 1 != 0 | 								? this.value % parseInt(this.value) != 0 | ||||||
| 									? parseFloat(this.value) | 									? parseFloat(this.value) | ||||||
| 									: parseInt(this.value) | 									: parseInt(this.value) | ||||||
| 								: this.value; | 								: this.value; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue