You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							50 lines
						
					
					
						
							1.3 KiB
						
					
					
				
			
		
		
		
			
			
			
				
					
				
				
					
				
			
		
		
	
	
							50 lines
						
					
					
						
							1.3 KiB
						
					
					
				
								<?php
							 | 
						|
								
							 | 
						|
								use App\Enumerators\SessionElement;
							 | 
						|
								use App\Wrappers\DatabaseInteractions;
							 | 
						|
								use App\Wrappers\SessionWrapper;
							 | 
						|
								use App\Wrappers\SQLQueryBuilderWrapper;
							 | 
						|
								use App\Wrappers\TwigWrapper;
							 | 
						|
								
							 | 
						|
								require_once __DIR__ . "/../../vendor/autoload.php";
							 | 
						|
								
							 | 
						|
								$db = new DatabaseInteractions();
							 | 
						|
								
							 | 
						|
								
							 | 
						|
								$tuneSetDetails = $db->RunOneSelect(
							 | 
						|
								    queryBuilder: SQLQueryBuilderWrapper::SELECT_ONE(
							 | 
						|
								        table: 'TuneSets',
							 | 
						|
								        id: $_GET["tune-set-id"]
							 | 
						|
								    )
							 | 
						|
								);
							 | 
						|
								
							 | 
						|
								$tunesInSet = $db->RunSelect(
							 | 
						|
								    queryBuilder: SQLQueryBuilderWrapper::SELECT(
							 | 
						|
								        table: 'TuneSetTunes'
							 | 
						|
								    )
							 | 
						|
								        ->cols(cols: [
							 | 
						|
								            'T_T.ID AS TuneID',
							 | 
						|
								            'T_T.CreatedAt AS TuneCreatedAT',
							 | 
						|
								            'T_T.CreatedBy AS TuneCreatedBy',
							 | 
						|
								            'T_T.Title AS TuneTitle',
							 | 
						|
								            'T_T.Copyright AS TuneCopyright',
							 | 
						|
								        ])
							 | 
						|
								        ->join(
							 | 
						|
								            join: 'INNER',
							 | 
						|
								            spec: 'Tunes AS T_T',
							 | 
						|
								            cond: 'T.TuneID=T_T.ID',
							 | 
						|
								        )
							 | 
						|
								        ->where(cond: 'T.TuneSetID LIKE :__tune_set_id__')
							 | 
						|
								        ->orderBy(spec: [
							 | 
						|
								            'T.Order ASC',
							 | 
						|
								        ])
							 | 
						|
								        ->bindValue(name: '__tune_set_id__', value: $_GET["tune-set-id"])
							 | 
						|
								);
							 | 
						|
								
							 | 
						|
								TwigWrapper::RenderTwig(
							 | 
						|
								    target: "Pages/tune-set/uuid.html.twig",
							 | 
						|
								    arguments: [
							 | 
						|
								        "TuneSetDetails"=>$tuneSetDetails,
							 | 
						|
								        "TunesInSet"=>$tunesInSet,
							 | 
						|
								    ]
							 | 
						|
								);
							 | 
						|
								
							 |