(xepg)
| 913 | } |
| 914 | |
| 915 | function saveChannelStatus(xepg) { |
| 916 | var thisChannel = xEPG["epgMapping"][xepg]; |
| 917 | var xXmltvFile = thisChannel["x-xmltv-file"]; |
| 918 | |
| 919 | var key = "x-active"; |
| 920 | var value = JSON.parse(document.getElementById("x-active").lastChild.checked); |
| 921 | |
| 922 | if (xEPG["xmltvMap"].hasOwnProperty(xXmltvFile) == true) { |
| 923 | if (thisChannel["x-mapping"] != "-" && thisChannel["x-mapping"] != undefined) { |
| 924 | thisChannel["x-active"] = !thisChannel["x-active"]; |
| 925 | var tr = document.getElementById(xepg); |
| 926 | switch (thisChannel["x-active"]) { |
| 927 | case true: tr.className = "activeEPG"; break; |
| 928 | case false: tr.className = "notActiveEPG"; break; |
| 929 | } |
| 930 | |
| 931 | } else { |
| 932 | var err = "XMLTV Channel is not selected" |
| 933 | alert(err) |
| 934 | value = false |
| 935 | } |
| 936 | |
| 937 | } else { |
| 938 | if (value == true) { |
| 939 | var err = "XMLTV File is not selecte" |
| 940 | alert(err) |
| 941 | value = false |
| 942 | } |
| 943 | } |
| 944 | |
| 945 | |
| 946 | |
| 947 | if (bulk == false) { |
| 948 | var thisChannel = xEPG["epgMapping"][xepg]; |
| 949 | thisChannel[key] = value |
| 950 | mappingDetail(xepg); |
| 951 | searchInMapping(); |
| 952 | |
| 953 | var tr = document.getElementById(xepg); |
| 954 | switch (thisChannel["x-active"]) { |
| 955 | case true: tr.className = "activeEPG"; break; |
| 956 | case false: tr.className = "notActiveEPG"; break; |
| 957 | } |
| 958 | |
| 959 | return |
| 960 | } |
| 961 | |
| 962 | if (bulk == true) { |
| 963 | saveBulk(key, value); |
| 964 | mappingDetail(xepg); |
| 965 | return |
| 966 | } |
| 967 | |
| 968 | } |
| 969 | |
| 970 | function saveGroupTitle(xepg) { |
| 971 | var key = "x-group-title"; |
nothing calls this directly
no test coverage detected