mirror of
				https://github.com/optim-enterprises-bv/control-pane.git
				synced 2025-10-31 01:47:52 +00:00 
			
		
		
		
	WIP: upgrade button
This commit is contained in:
		| @@ -158,6 +158,8 @@ class ClonOS { | ||||
| 				} | ||||
| 				echo json_encode($new_array); | ||||
| 				return; | ||||
| 			}else{ | ||||
| 				echo json_encode(array('error'=>true,'error_message'=>'PHP Method is not exists: '.$this->mode)); | ||||
| 			} | ||||
|  | ||||
| 			$included_result_array=''; | ||||
| @@ -2161,6 +2163,16 @@ class ClonOS { | ||||
| 		} | ||||
| 	} | ||||
| 	 | ||||
| 	function ccmd_settingsUpdateCheck() | ||||
| 	{ | ||||
| 		return array('error'=>true,'error_message'=>'Ещё не реализовано...'); | ||||
| 	} | ||||
| 	 | ||||
| 	 | ||||
| 	 | ||||
| 	 | ||||
| 	 | ||||
|  | ||||
| 	function postCurl($url,$vars=false) | ||||
| 	{ | ||||
| 		if($vars===false) return array('error'=>true,'errorMessage'=>'something wrong...'); | ||||
|   | ||||
| @@ -1009,7 +1009,7 @@ td.error { | ||||
| 	width:60%; | ||||
| 	max-width:60%; | ||||
| 	/*margin-left:-30% !important;*/ | ||||
| 	left:50%; | ||||
| 	/*left:50%;*/ | ||||
| } | ||||
| .tasklog .window-content { | ||||
| 	user-select:auto; | ||||
|   | ||||
							
								
								
									
										9
									
								
								public/dialogs/settings-update.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								public/dialogs/settings-update.php
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| <dialog id="settings-update" class="window-box tasklog"> | ||||
| 	<h1><?php echo $this->translate('Settings update');?></h1> | ||||
| 	<div class="window-content"> | ||||
| 		Check for updates… | ||||
| 	</div> | ||||
| 	<div class="buttons"> | ||||
| 		<input type="button" value="<?php echo $this->translate('Close');?>" class="button red cancel-but" /> | ||||
| 	</div> | ||||
| </dialog> | ||||
| @@ -232,6 +232,10 @@ var clonos={ | ||||
| 				this.getFreeCname();	// Берём с сервера свободное имя kubernetes | ||||
| 				//this.trids=this.getTrIdsForCheck('jailslist'); | ||||
| 			} | ||||
| 			if(id='settings-update') | ||||
| 			{ | ||||
| 				this.settingsUpdateCheck(); | ||||
| 			} | ||||
| 			this.dialogShow1(id); | ||||
| 		} | ||||
| 	}, | ||||
| @@ -872,6 +876,14 @@ var clonos={ | ||||
| 		$('dialog#k8s-new input[name="cname"]').val(data.freejname); | ||||
| 		//$('dialog#jail-settings input[name="host_hostname"]').val(data.freecname+'.my.domain'); | ||||
| 	}, | ||||
| 	settingsUpdateCheck:function() | ||||
| 	{ | ||||
| 		this.loadData('settingsUpdateCheck',$.proxy(this.onSettingsUpdateCheck,this)); | ||||
| 	}, | ||||
| 	onSettingsUpdateCheck:function(data) | ||||
| 	{ | ||||
| 		 | ||||
| 	}, | ||||
| 	 | ||||
| 	onUsersAdd:function(data) | ||||
| 	{ | ||||
|   | ||||
| @@ -2,7 +2,7 @@ | ||||
|  | ||||
| /* hardcode API ip. Change it later */ | ||||
| //$api_ip='https://bitclouds.convectix.com:1443'; | ||||
| $api_ip = 'http://144.76.225.238'; | ||||
| $api_ip = 'http://127.0.0.1:65531'; | ||||
|  | ||||
| function getSslPage($url) { | ||||
| 	$ch = curl_init(); | ||||
|   | ||||
| @@ -1,4 +1,21 @@ | ||||
| <h1>ClonOS Settings</h1> | ||||
| <?php | ||||
| $clonos->useDialogs(['users-new']); | ||||
| ?> | ||||
|  | ||||
| echo (new Forms('cbsd-settings'))->generate(); | ||||
| <h1>User management</h1> | ||||
| <p><span class="top-button icon-plus id:users-new">Add users</span></p> | ||||
|  | ||||
| <table class="tsimple" id="userslist" width="100%"> | ||||
| 	<thead> | ||||
| 		<tr> | ||||
| 			<th class="txtleft">Login</th> | ||||
| 			<th class="txtleft">First Name</th> | ||||
| 			<th class="txtleft">Last Name</th> | ||||
| 			<th class="txtleft">Registration</th> | ||||
| 			<th class="txtleft">Last login</th> | ||||
| 			<th class="txtcenter">Active</th> | ||||
| 			<th class="txtcenter wd-100">Action</th> | ||||
| 		</tr> | ||||
| 	</thead> | ||||
| 	<tbody></tbody> | ||||
| </table> | ||||
| @@ -1,4 +1,17 @@ | ||||
| <h1>Настройки ClonOS</h1> | ||||
| <?php | ||||
| $clonos->useDialogs(['settings-update']); | ||||
| ?> | ||||
|  | ||||
| echo (new Forms('cbsd-settings'))->generate(); | ||||
| <h1>Настройки</h1> | ||||
| <p><span class="top-button icon-plus id:settings-update">Проверить обновления</span></p> | ||||
|  | ||||
|  | ||||
| <table class="tsimple" id="update_files" width="100%"> | ||||
| 	<thead> | ||||
| 		<tr> | ||||
| 			<th class="txtleft">Компонент</th> | ||||
| 			<th class="txtleft">Версия</th> | ||||
| 		</tr> | ||||
| 	</thead> | ||||
| 	<tbody></tbody> | ||||
| </table> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 olevole
					olevole