U
    h]                     @   sJ   d dl Zd dlZd dlZd dlmZ d dlmZmZ G dd dej	Z	dS )    N)settings)
migrationsmodelsc                ,   @   s  e Zd ZdZeejgZej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jddddfde
jddddd fd!e
jd"dd#dfd$e
jd%d&d'd(d)d*gd+d,dd-d.fd/e
jd0d1d2d3gd4d5dd6d.fd7e
jdd8dd9d:d;fd<e
jdd=d>d?fd@e
jddAdBd?fdCe
jddDdEdFdGfdHe
jddIdEdJdGfdKe
jddLdMdNdGfdOe
jddPdQdfdRe
jddSddTdfdUe
jddVdWdfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgddedfd!dgdgdhej	dide
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jdjdMdkdfdle
jdmdndodfdpe
jdqdndrdfdse
jddtddudGfdve
jdwdxdyfdze
jdd{d|d}dd~dfde
jdedddfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgddddgdgdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jddddfde
jddddd fd<e
jdddd?fde
jdddnddfde
jddddfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgddddgdgdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jdddd?fde
jdddd?fde
jdddddGfde
jdddMddGfde
jdddddGfde
jddddfde
jddddddfde
jddddfde
jddddgddddd.fde
jdddddGfde
jdddMddGfde
jdddddGfde
jddddfde
jddddfde
jdejj
jjddddԍfde
jdddejj
jjdddd\fdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fde
jdejj
jjddddԍfgddddddgdgdhejdde
jdddfdddddej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jddddfd<e
jdddd?fde
jdddddddddg	ddddd.fde
jdddyfde
jdd dyfde
jdddyfde
jdddddfde
jdddd	dfd
e
j dddddfde
jdddddGfdCe
jdddnddGfde
jddddfde
jddddfde
jde!dddfde
jdejj
jjddddԍfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgdddddgdgdhej	d de
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfd!e
jdd"d#dfd$e
jd%d&dyfd'e
jd(d)ej"j#j$d*d+d,gd-d.fd/e
jd0d)ej"j#j$d1d+d,gd2d.fd3e
jd4d5d6d7gd8d9dd:d.fd;e
jd<d=d>d?d@gdAdBddCd.fdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fdDe
j%dEejj
jjdFdGdHdԍfgdIdJdKdLdhej	dMde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jdNddOdfdPe
jdQdRdSdTdUgdVddWdXfdYe
jdZd[d\d]d^d_d`dagdbdcdddd.fdee
j&dfdgdhdifde
jdjddyfdke
jddldmd?fdne
jddodpd?fde
jddqddfde
jd͐drddfdse
j ddtddudfdve
j ddwddxdfdye
jde!dzd{dfd|e
jd}d~ddfde
jdddddfde
jdejj
jjddddԍfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgdMdddddgdgdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jddddfde
jdddyfde
jdd dyfde
jddd}ddfde
jddddgdkddndd.fde
jdddyfd/e
jdddgddddd.fde
jdedddfde
jdejj
jjddddԍfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fde
jdejj
jjdddMdԍfdae
jddbdejj
jjdcejddd\fgddddgdgdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfd!e
jdd"d#dfde
j&dddddd;fde
jdddd?fde
jdddd?fde
jdddd?fde
jdddgddddd.fde
jdŐdƐdǐdȐdgdʐdːd̐dd.fdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fdDe
j%dEejj
jjdFdGdHdԍfgdΐdϐdАdLdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfd!e
jdd"d#dfde
jdӐddyfde
jdd֐dd?fde
jdِddyfde
jddddfde
jdߐdddfde
jddddfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fdDe
j%dEejj
jjdFdGdHdԍfgddddLdhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
j dddyfde
j'dddddfde
j'dddddfde
j(dddddfde
jddddgdddfde
jdddddgdddfde
jddddd dfde
jddddddfde
jddddfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fde
jddejj
jjdӐdfgd	d
e
j)dgdde
j)dgddgddhej	dde
jddddfde
jddd	d
fde
jejdddddfde
jddddfde
jdddddfde
jddddfde
jddd2dddgddddd.fde
jdddyfde
jdd dyfd<e
jdddd?fde
jddd d?fd!e
jdd"d#d?fd$e
jdd%d&dfd'e
jd(d)d*dfde
jdd+d,dfde
jd͐d-ddfd.e
jd̐d/d0dfde
jd1ejj
jjd2dddԍfdXe
jddYdejj
jjdZejd[d\fd]e
jdd^dejj
jjd_ejd`d\fdae
jddbdejj
jjdcejddd\fgd3d4d5dddge
j)ddgd6de
j)dgd7de
j)ddgd8dge
j*e
+d9e
,dfd:d;e
j*e
+d<d=d;gd>dhej-d?e
j)ddgd@ddAej-d?e
j)ddgdBddAej-d?e
j)dddgdCddAej.d?dDhdEej-de
j)d/dUgdFddAej-de
j)d$dHgdGddAej-de
j)dRgdHddAej-dIe
j)ddgdJddAej-dIe
j)ddgdKddAej-dIe
j)dgdLddAej/dIe
j*e
+d9e
,dfdMd;dNej/dIe
j*e
+dOdPd;dNej-de
j)ddgdQddAej-de
j)dYdgdRddAej-de
j)ddgdSddAej-dTe
j)dАdgdUddAej-dTe
j)ddgdVddAej-dTe
j)ddgdWddAej-dTe
j)d/dgdXddAej-dTe
j)dgdYddAg!Z0dZS ([  	MigrationTChannel
created_atz&Timestamp when this object was createdz
Created At)auto_now_add	help_textverbose_name
updated_atz,Timestamp when this object was last modifiedz
Updated At)auto_nowr	   r
   idFz!Unique identifier for this object)defaulteditabler	   primary_key	serialize
is_deletedz)Whether this object has been soft-deletedz
Is Deleted)r   r	   r
   
deleted_atz+Timestamp when this object was soft-deletedz
Deleted At)blankr	   nullr
   namez,Full official name of the television channel   zChannel Name)r	   
max_lengthr
   display_namez@Official call sign or short identifier (e.g., "WABC-TV", "ESPN")   z	Call Sign)r	   r   uniquer
   channel_numberz@Channel number in cable/satellite listings (e.g., "7.1", "ESPN")zChannel Numberchannel_type)terrestrialzTerrestrial/Over-the-Air)cablezCable Channel)	satellitezSatellite Channel)iptvzIPTV Channel)	streamingzStreaming Channel)radiozRadio Stationr    z/Broadcasting technology and distribution methodzChannel Type)choicesr   r	   r   r
   status)activeActive)inactiveInactive)maintenanceMaintenance)testingTestingr&   z)Current operational status of the channelzChannel StatuslogozChannel logo or branding imagezchannels/logos/zChannel Logo)r   r	   r   	upload_tor
   descriptionz0Brief description of the channel and its contentzChannel Description)r   r	   r
   websitezChannel's official website URLzOfficial Websitelanguagez%Primary language of broadcast content   zPrimary Language)r   r	   r   r
   categoryz<Primary content category (News, Sports, Entertainment, etc.)zContent Categorytarget_audiencez<Primary target demographic (Children, Adults, Seniors, etc.)d   zTarget Audiencesupports_daiz1Whether the channel supports Dynamic Ad InsertionzSupports DAIlast_health_checkz4Timestamp of the most recent health monitoring checkzLast Health Check	is_onlinez,Current online/offline status of the channelz	Is Online
created_byzUser who created this objectz%(class)s_createdz
Created By)r   r	   r   	on_deleterelated_nametor
   
deleted_byz!User who soft-deleted this objectz%(class)s_deletedz
Deleted By
updated_byz"User who last modified this objectz%(class)s_updatedz
Updated ByChannelschannels)r
   verbose_name_pluraldb_tableordering)r   fieldsoptionsChannelCodecz0Human-readable name for this codec configurationz
Codec Namevideo_codecz.Video codec identifier (h264, h265, vp9, etc.)2   zVideo Codecaudio_codecz-Audio codec identifier (aac, mp3, opus, etc.)zAudio Codec
resolutionz9Video resolution in WIDTHxHEIGHT format (e.g., 1920x1080)
ResolutionbitratezTarget bitrate in kbpsBitrate)r	   r
   
frame_rate   z-Target frame rate in fps (e.g., 29.97, 25.00)   z
Frame Rate)r   decimal_placesr	   
max_digitsr   r
   ffmpeg_optionsz1Additional FFmpeg encoding options as JSON objectzFFmpeg Options)r   r   r	   r
   zChannel CodeczChannel Codecschannel_codecsChannelZonez*Human-readable name of the geographic zone   z	Zone Namecodez8Unique identifier code for the zone (e.g., "NAE", "EUR")
   z	Zone Codez2Optional detailed description of the zone coverageDescriptiontimezoneUTCz?Timezone identifier (e.g., "America/New_York", "Europe/London")Timezone)r   r	   r   r
   	is_activez3Whether this zone is currently accepting broadcastsz	Is ActivezChannel ZonezChannel Zoneschannel_zonesChannelZoneRelation
stream_urlz"Custom streaming URL for this zonezZone-specific Stream URLbackup_stream_urlz$Secondary URL for failover streamingzZone-specific Backup Stream URLftp_hostz6FTP server hostname or IP address for content deliveryzFTP Hostftp_usernamezUsername for FTP authenticationzFTP Usernameftp_passwordzPassword for FTP authenticationzFTP Passwordftp_port   z$FTP server port number (default: 21)zFTP Portftp_root_directory/z%Root directory path on the FTP serveri  zFTP Root Directory)r   r   r	   r   r
   ftp_use_passivez/Whether to use passive mode for FTP connectionszUse FTP Passive Modevpn_type)nonezNo VPN)ipseczIPSec Tunnel)openvpnOpenVPN)	wireguard	WireGuardrl   z+Type of VPN connection for secure streamingzVPN Typevpn_server_addressz!VPN server IP address or hostnamezVPN Server Addressvpn_usernamezUsername for VPN authenticationzVPN Usernamevpn_passwordzPassword for VPN authenticationzVPN Passwordz+Whether this channel is active in this zonezActive in Zonepriority   z>Priority level for this zone (higher number = higher priority)Prioritychannelz)The channel this configuration applies tozone_relationszchannels.channel)r	   r;   r<   r=   r
   codecz*Override codec configuration for this zonezchannels.channelcodeczZone-specific Codeczonez-The geographic zone this configuration is forchannel_relationszchannels.channelzoneZonezChannel Zone RelationzChannel Zone Relationschannel_zone_relationsz	-priorityzonesz0Geographic zones where this channel is availablezchannels.ChannelZoneRelationzBroadcasting Zones)r   r	   r<   throughr=   r
   )
model_namer   field
EPGProgramtitlezFull title of the programzProgram Titlez+Detailed description of the program contentzProgram Descriptionprogram_type)movieMovie)seriesz	TV Series)newsNews)sportsSports)documentaryDocumentary)entertainmentEntertainment)kidsKids)musicMusic)otherOtherr   z&Category classification of the programzProgram Type
start_timez$When the program starts broadcastingz
Start Timeend_timez"When the program ends broadcastingzEnd TimedurationzProgram duration in minutesDurationseason_numberz Season number for series contentzSeason Numberepisode_numberz Episode number within the seasonzEpisode Numberoriginal_air_datez'Original broadcast date of this contentzOriginal Air Datecontent_ratingz*Age/content rating (G, PG, PG-13, R, etc.)zContent RatingzPrimary language of the programLanguagesubtitles_availablez/Whether closed captions/subtitles are availablezSubtitles Availablehas_ad_breaksz/Whether this program supports commercial breakszHas Ad Breaksad_break_positionsz9List of timestamps (in seconds) where ads can be insertedzAd Break Positionsz!Channel broadcasting this programprogramszEPG ProgramzEPG Programsepg_programsIPSecConfiguration
is_enabledz3Whether this VPN configuration is currently enabledz
Is Enabledpreshared_keyz'IPSec pre-shared key for authenticationzPre-shared Keylocal_subnetz<Local network subnet in CIDR notation (e.g., 192.168.1.0/24)   z0Enter a valid CIDR subnet (e.g., 192.168.1.0/24)z^(\d{1,3}\.){3}\d{1,3}/\d{1,2}$)messageregexzLocal Subnet)r	   r   
validatorsr
   remote_subnetz:Remote network subnet in CIDR notation (e.g., 10.0.0.0/24)z-Enter a valid CIDR subnet (e.g., 10.0.0.0/24)zRemote Subnetencryption_algorithm)aes128zAES-128)aes192zAES-192)aes256zAES-256)3des3DESr   z%Encryption algorithm for IPSec tunnelzEncryption Algorithmhash_algorithm)sha1zSHA-1)sha256zSHA-256)sha384zSHA-384)sha512zSHA-512)md5MD5r   z)Hash algorithm for integrity verificationzHash Algorithmzone_relationz3The zone relation this VPN configuration applies toz%(class)s_configzchannels.channelzonerelationzZone RelationzIPSec ConfigurationzIPSec Configurationsipsec_configurations)r
   rB   rC   Jinglez#Human-readable name for this jinglezJingle Namejingle_type)
station_idz
Station ID)bumperBumper)promoPromo)
transition
Transition)commercial_breakzCommercial BreakzType of jingle contentzJingle Type)r$   r	   r   r
   placement_type)startzStart of Show)endzEnd of Show)commercial_startzStart of Commercial Break)commercial_endzEnd of Commercial Break)program_transitionzProgram Transition)hourlyHourly)half_hourlyzHalf Hourly)randomzRandom Placementr   z2When this jingle should be played in the broadcastzPlacement TypefilezAudio file for this jinglezjingles/z
Audio File)r	   r/   r
   z!Duration of the jingle in secondsaudio_fingerprintz9Audio fingerprint data for automatic detection in streamsAudio Fingerprintvideo_fingerprintz9Video fingerprint data for automatic detection in streamsVideo Fingerprintz'Whether this jingle is currently activezEPriority level for jingle selection (higher number = higher priority)
start_datez7Optional start date for when this jingle becomes activez
Start Dateend_datez7Optional end date for when this jingle becomes inactivezEnd Date
time_slotsz2JSON list of time ranges when this jingle can playz
Time Slots
play_countr   z+Number of times this jingle has been playedz
Play Countlast_playedz-Timestamp of when this jingle was last playedzLast PlayedzChannel this jingle belongs tojinglesJinglesJingleDetectiondetected_atz-When the detection was recorded in the systemzDetected Atstart_timestampz-When the jingle started playing in the streamend_timestampz+When the jingle ended playing in the streamconfidence_score   z*Detection confidence score from 0.0 to 1.0zConfidence Score)rR   r	   rS   r
   detection_method)r   r   )r   r   )combinedzCombined Audio/Video)manualzManual DetectionzMethod used for detectionzDetection Methodstream_positionzAPosition in stream where jingle was detected (seconds from start)zStream Position)detectedDetected)	confirmed	Confirmed)false_positivezFalse Positiver   z#Validation status of this detectionStatusmetadataz,Additional detection metadata and parametersMetadataz%Channel where the jingle was detectedjingle_detectionsjinglezThe jingle that was detected
detectionszchannels.jinglezJingle DetectionzJingle Detectionsz-detected_atOpenVPNConfigurationconfig_filez"OpenVPN configuration file (.ovpn)zvpn_configs/openvpn/zOpenVPN Config Fileca_certz/Certificate Authority certificate in PEM formatzCA Certificateclient_certz Client certificate in PEM formatzClient Certificate
client_keyz Client private key in PEM formatzClient Private Keycompression)rl   zNo Compression)lzozLZO Compression)lz4zLZ4 Compressionr   z(Compression algorithm for OpenVPN tunnelCompressioncipher)aes-256-cbczAES-256-CBC)zaes-192-cbczAES-192-CBC)zaes-128-cbczAES-128-CBC)zaes-256-gcmzAES-256-GCM)zchacha20-poly1305zChaCha20-Poly1305r   z$Encryption cipher for OpenVPN tunnel   CipherzOpenVPN ConfigurationzOpenVPN Configurationsopenvpn_configurationsWireGuardConfigurationprivate_keyz%WireGuard private key for this clientzPrivate Key
public_keyzFWireGuard public key for this client (auto-generated from private key)z
Public Keypeer_public_keyz&WireGuard public key of the VPN serverzPeer Public KeyendpointzBWireGuard server endpoint (host:port, e.g., vpn.example.com:51820)Endpointallowed_ipsz	0.0.0.0/0z9Comma-separated list of allowed IP ranges (CIDR notation)zAllowed IPspersistent_keepalive   z,Keepalive interval in seconds (0 to disable)zPersistent KeepalivezWireGuard ConfigurationzWireGuard Configurationswireguard_configurationsAdbreakdatezThe date of the ad-break.Datestart_atzThe start time of the ad break.zAd Break Start Timeend_atzThe end time of the ad break.zAd Break End TimezThe duration of the ad break.adbreak_type)Prer  )Postr  )Midr  )r   r$   r   r   adbreak_category)Historyr  )	Predictedr  )RealTimeZRealtime)	Conductorr  show_beforezThe show before the ad break.zShow Before)r   r	   r   r   r
   
show_afterzThe show after the ad break.z
Show Afterif_show_duringz:Boolean indicating if the ad break is shown during a show.zShow During)r   r   r;   r=   zConductor DataAdbreaksidx_start_at)rE   r   
idx_end_at)rB   rC   indexesChannelSchedulez%Title or name for this schedule entryzSchedule Titleschedule_type)regularzRegular Programming)specialzSpecial Event)testzTest Broadcast)	emergencyzEmergency Broadcast)replayzReplay/Rerunr!  z"Type of scheduled content or eventzSchedule TypezWhen this schedule entry beginszWhen this schedule entry endsz-Detailed description of the scheduled contentcontent_urlz,Primary URL for the scheduled content streamzContent URLbackup_content_urlz Backup URL for content streamingzBackup Content URL	allow_adsz0Whether ads can be inserted during this schedulezAllow Advertisementsad_break_durationx   z+Duration of advertisement breaks in secondszAd Break Durationz/Whether this schedule entry is currently activer'   z3Schedule priority (higher number = higher priority)notify_before_minutesz/Minutes before start time to send notificationszNotification Lead TimezChannel for this schedule entry	scheduleszChannel SchedulezChannel Scheduleschannel_schedulesschedule_channel_start_idxschedule_type_idxschedule_active_start_idxend_time__gtschedule_valid_time_range)checkr   )priority__gterv   schedule_positive_priority)r
   rB   rC   rD   r  constraintsZchannelzonerelationZchannel_zon_channel_35e2ee_idx)r   indexZchannel_zon_zone_id_c83795_idxZchannel_zon_channel_01b275_idx)rx   r{   )r   unique_togetherZchannels_status_9488f5_idxZchannels_channel_b7eea9_idxZchannels_last_he_da88f4_idxZ
epgprogramepg_channel_start_idxepg_time_range_idxepg_type_idxepg_valid_time_range)r   
constraint)duration__gtr   epg_positive_durationZjingles_channel_d7c7d8_idxZjingles_placeme_150487_idxZjingles_priorit_65aa69_idxZjingledetectionZjingle_dete_channel_18fbef_idxZjingle_dete_jingle__5ec887_idxZjingle_dete_start_t_8492c4_idxZjingle_dete_status_a1756a_idxZjingle_dete_confide_879f92_idxN)1__name__
__module____qualname__initialr   swappable_dependencyr   AUTH_USER_MODELdependenciesCreateModelr   DateTimeField	UUIDFielduuiduuid4BooleanField	CharField
ImageField	TextFieldURLField
ForeignKeydjangodbdeletionSET_NULLPositiveIntegerFieldDecimalField	JSONFielddictCASCADEAddFieldManyToManyField	DateFieldlistcorer   RegexValidatorOneToOneField	FileField	TimeFieldDurationFieldIndexCheckConstraintQFAddIndexAlterUniqueTogetherAddConstraint
operations rm  rm  @/var/www/html/Focus/src/apps/channels/migrations/0001_initial.pyr   
   sN  
"$$$!$$$$$$"$$$$("$$$"44.2$$$(0>"$$$".("$$($*4$$$($$$($($$$*4"$$$><""   r   )
Zdjango.core.validatorsrR  django.db.models.deletionrJ  django.confr   	django.dbr   r   r   rm  rm  rm  rn  <module>   s
   