mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-10 00:50:09 -04:00
Update nowplayer.now.com
This commit is contained in:
parent
6a7b667e61
commit
410eb9a77f
2 changed files with 1 additions and 12 deletions
|
@ -19,11 +19,6 @@ module.exports = {
|
|||
}
|
||||
}
|
||||
},
|
||||
logo({ channel }) {
|
||||
const channelId = channel.site_id.replace(/^0/, '')
|
||||
|
||||
return `https://images.now-tv.com/shares/channelPreview/img/en_hk/color/ch${channelId}_160_115`
|
||||
},
|
||||
parser: function ({ content }) {
|
||||
let programs = []
|
||||
const items = parseItems(content)
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
// npx epg-grabber --config=sites/nowplayer.now.com/nowplayer.now.com.config.js --channels=sites/nowplayer.now.com/nowplayer.now.com_hk-zh.channels.xml --output=.gh-pages/guides/hk-zh/nowplayer.now.com.epg.xml --days=2
|
||||
// npx epg-grabber --config=sites/nowplayer.now.com/nowplayer.now.com.config.js --channels=sites/nowplayer.now.com/nowplayer.now.com_hk-en.channels.xml --output=.gh-pages/guides/hk-en/nowplayer.now.com.epg.xml --days=2
|
||||
|
||||
const { parser, url, request, logo } = require('./nowplayer.now.com.config.js')
|
||||
const { parser, url, request } = require('./nowplayer.now.com.config.js')
|
||||
const dayjs = require('dayjs')
|
||||
const utc = require('dayjs/plugin/utc')
|
||||
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
||||
|
@ -36,12 +36,6 @@ it('can generate valid request headers', () => {
|
|||
})
|
||||
})
|
||||
|
||||
it('can get logo url', () => {
|
||||
expect(logo({ channel })).toBe(
|
||||
'https://images.now-tv.com/shares/channelPreview/img/en_hk/color/ch96_160_115'
|
||||
)
|
||||
})
|
||||
|
||||
it('can parse response', () => {
|
||||
const content = `[[{"key":"key_202111174524739","vimProgramId":"202111174524739","name":"ViuTVsix Station Closing","start":1637690400000,"end":1637715600000,"date":"20211124","startTime":"02:00AM","endTime":"09:00AM","duration":420,"recordable":false,"restartTv":false,"npvrProg":false,"npvrStartTime":0,"npvrEndTime":0,"cid":"viutvsix station closing","cc":"","isInWatchlist":false}]]`
|
||||
const result = parser({ content }).map(p => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue