fix: readonly does not exists
fix: validate after setting timezone to the new value
This commit is contained in:
		| @@ -40,7 +40,7 @@ class BackupEdit extends Component | ||||
|     #[Validate(['required', 'string'])]
 | ||||
|     public string $frequency = ''; | ||||
| 
 | ||||
|     #[Validate(['readonly', 'string'])]
 | ||||
|     #[Validate(['string'])]
 | ||||
|     public string $timezone = ''; | ||||
| 
 | ||||
|     #[Validate(['required', 'integer', 'min:1'])]
 | ||||
| @@ -71,7 +71,6 @@ class BackupEdit extends Component | ||||
|     public function syncData(bool $toModel = false) | ||||
|     { | ||||
|         if ($toModel) { | ||||
|             $this->customValidate(); | ||||
|             $this->backup->enabled = $this->backupEnabled; | ||||
|             $this->backup->frequency = $this->frequency; | ||||
|             $this->backup->number_of_backups_locally = $this->numberOfBackupsLocally; | ||||
| @@ -79,6 +78,7 @@ class BackupEdit extends Component | ||||
|             $this->backup->s3_storage_id = $this->s3StorageId; | ||||
|             $this->backup->databases_to_backup = $this->databasesToBackup; | ||||
|             $this->backup->dump_all = $this->dumpAll; | ||||
|             $this->customValidate(); | ||||
|             $this->backup->save(); | ||||
|         } else { | ||||
|             $this->backupEnabled = $this->backup->enabled; | ||||
| @@ -187,12 +187,12 @@ class BackupEdit extends Component | ||||
| 
 | ||||
|     private function deleteAssociatedBackupsS3() | ||||
|     { | ||||
|         //Add function to delete backups from S3
 | ||||
|         // Add function to delete backups from S3
 | ||||
|     } | ||||
| 
 | ||||
|     private function deleteAssociatedBackupsSftp() | ||||
|     { | ||||
|         //Add function to delete backups from SFTP
 | ||||
|         // Add function to delete backups from SFTP
 | ||||
|     } | ||||
| 
 | ||||
|     private function deleteEmptyBackupFolder($folderPath, $server) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Andras Bacsai
					Andras Bacsai