Hello Guest, if you are reading this it means you have not registered yet. Please take a second, Click here to register, and in a few simple steps you will be able to enjoy our community and use our OpenViX support section.
Results 1 to 15 of 130

Thread: Cable and FTA Sky UK CustomMix

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #24
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,630
    Thanks
    2,006
    Thanked 4,953 Times in 3,274 Posts
    Quote Originally Posted by dsayers View Post
    For my region 113 named ITV HD
    Ok, so what is happening is 113 is getting saved to "move_dict" but we continue searching and then it finds another match at 179 and overwrites the first match. So we need to avoid that happening.

    Code:
    source = "sat_282_sky_uk"
    dest = "cable_uk_virgin"
    
    move_dict = {
    	'bbc one': {"source": None, "dest": None}, 
    	'bbc two': {"source": None, "dest": None},
    	'itv': {"source": None, "dest": None},
    	'channel 4': {"source": None, "dest": None},
    }
    
    if source in services and dest in services:
    	for key in move_dict.keys():
    		for service in range(101, 201) + range(801, 900):
    			if move_dict[key]["source"] is None and \
    				service in services[source]["video"] and \
    				services[source]["video"][service]["service_type"] in DvbScanner.HD_ALLOWED_TYPES and \
    				services[source]["video"][service]["service_name"].lower().startswith(key) :
    				move_dict[key]["source"] = service
    			if move_dict[key]["dest"] is None and \
    				service in services[dest]["video"] and \
    				services[dest]["video"][service]["service_type"] in DvbScanner.HD_ALLOWED_TYPES and \
    				services[dest]["video"][service]["service_name"].lower().startswith(key):
    				move_dict[key]["dest"] = service
    			if move_dict[key]["source"] and move_dict[key]["dest"]:
    				break
    
    for key in move_dict.keys():
    	if move_dict[key]["source"] and move_dict[key]["dest"]:
    		customised["video"][move_dict[key]["dest"]] = services[source]["video"][move_dict[key]["source"]]
    Last edited by Huevos; 24-06-19 at 23:42.
    Help keep OpenViX servers online.Please donate!

  2. The Following User Says Thank You to Huevos For This Useful Post:

    dsayers (25-06-19)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.