Merge pull request #761 from iptv-org/add-owner-field

Patch 2022.10
This commit is contained in:
Aleksandr Statciuk 2022-10-17 16:39:04 +03:00 committed by GitHub
commit 1474da8b44
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 30523 additions and 30506 deletions

View file

@ -26,9 +26,15 @@ body:
- type: input
attributes:
label: Network (optional)
description: Network of which this channel is a part.
description: Network of which this channel is a part. May contain any characters except `,` and `"`.
placeholder: 'Anhui'
- type: input
attributes:
label: Owners (optional)
description: List of channel owners separated by `;`. May contain any characters except `,` and `"`.
placeholder: 'China Central Television'
- type: input
attributes:
label: Country

View file

@ -32,9 +32,15 @@ body:
- type: input
attributes:
label: Network
description: Network of which this channel is a part.
description: Network of which this channel is a part. May contain any characters except `,` and `"`.
placeholder: 'Anhui'
- type: input
attributes:
label: Owners
description: List of channel owners separated by `;`. May contain any characters except `,` and `"`.
placeholder: 'China Central Television'
- type: input
attributes:
label: Country

View file

@ -24,7 +24,8 @@
| id | Unique channel ID derived from the `name` and `country` separated by dot. May only contain Latin letters, numbers and dot. | Required | `AnhuiTV.cn` |
| name | Official channel name in English. May include: `a-z`, `à-ÿ`, `0-9`, `space`, `-`, `!`, `:`, `&`, `.`, `+`, `'`, `/`, `»`, `#`, `%`, `°`, `$`, `@`, `?`, `(`, `)`. | Required | `Anhui TV` |
| native_name | Channel name in the original language. Used when different from `name`. May contain any characters except `,` and `"`. | Optional | `安徽卫视` |
| network | Network of which this channel is a part. | Optional | `Anhui` |
| network | Network of which this channel is a part. May contain any characters except `,` and `"`. | Optional | `Anhui` |
| owners | List of channel owners separated by `;`. May contain any characters except `,` and `"`. | Optional | `China Central Television` |
| country | Country code from which the channel is transmitted. A list of all supported countries and their codes can be found in [data/countries.csv](data/countries.csv) | Required | `CN` |
| subdivision | Code of the subdivision (e.g., provinces or states) from which the broadcast is transmitted. A list of all supported subdivisions and their codes can be found in [data/subdivisions.csv](data/subdivisions.csv). | Optional | `CN-AH` |
| city | Name of the city from which the channel is transmitted. May only contain `a-z`, `à-ÿ`, `0-9`, `space`, `-`, `'`. | Optional | `Hefei` |

File diff suppressed because it is too large Load diff

View file

@ -23,6 +23,7 @@ const csv2jsonOptions = {
subdivision: nullable,
city: nullable,
network: nullable,
owners: listParser,
launched: nullable,
closed: nullable,
website: nullable,

View file

@ -12,7 +12,10 @@ module.exports = {
.regex(/^[^",]+$/)
.invalid(Joi.ref('name'))
.allow(null),
network: Joi.string().allow(null),
network: Joi.string()
.regex(/^[^",]+$/)
.allow(null),
owners: Joi.array().items(Joi.string().regex(/^[^",]+$/)),
country: Joi.string()
.regex(/^[A-Z]{2}$/)
.required(),