mirror of
				https://github.com/LaQuay/TDTChannels.git
				synced 2025-10-31 10:12:15 +01:00 
			
		
		
		
	fix change channel with options
This commit is contained in:
		
							parent
							
								
									63f86be304
								
							
						
					
					
						commit
						dfb7ea4779
					
				
					 1 changed files with 11 additions and 9 deletions
				
			
		|  | @ -178,18 +178,20 @@ function filterChannelsList() { | |||
| } | ||||
| 
 | ||||
| function reproduceChannel(channel_options) { | ||||
|     options = channel_options; | ||||
| 
 | ||||
|     document.getElementById("option-buttons").innerHTML = "" | ||||
|     if (options.length == 1) { | ||||
|         reproduceVideo(channel['options'][0]['url']) | ||||
|     } else if (options.length > 1) { | ||||
|         for (i = 0; i < options.length; ++i) { | ||||
|             var url = options[i]['url']; | ||||
|     if (channel_options.length > 0) { | ||||
|         reproduceVideo(channel_options[0]['url']) | ||||
| 
 | ||||
|         if (channel_options.length > 1) { | ||||
|             for (i = 0; i < channel_options.length; ++i) { | ||||
|                 var url = channel_options[i]['url']; | ||||
|                 document.getElementById("option-buttons").innerHTML += | ||||
|                     "<a href='javascript:reproduceVideo(\"" + url + "\")' class='btn btn-secondary btn-sm' style='margin-right: 10px'>Opción " + (i+1) + "</a>"; | ||||
|             } | ||||
|         } | ||||
|     } else { | ||||
|         reproduceVideo("no_video_found.m3u8") | ||||
|     } | ||||
| } | ||||
| 
 | ||||
| function onChannelClick(channel) { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 LaQuay
						LaQuay