diff --git a/aircox/forms.py b/aircox/forms.py index ed43a04..93ce9d9 100644 --- a/aircox/forms.py +++ b/aircox/forms.py @@ -63,8 +63,8 @@ class SoundCreateForm(forms.ModelForm): TrackFormSet = modelformset_factory( models.Track, fields=[ - "episode", "position", + "episode", "artist", "title", "tags", @@ -79,15 +79,15 @@ TrackFormSet = modelformset_factory( EpisodeSoundFormSet = modelformset_factory( models.EpisodeSound, fields=( + "position", "episode", "sound", - "position", "broadcast", ), widgets={ "broadcast": forms.CheckboxInput(), "episode": forms.HiddenInput(), - "sound": forms.HiddenInput(), + # "sound": forms.HiddenInput(), "position": forms.HiddenInput(), }, can_delete=True, diff --git a/aircox/migrations/0023_station_legal_label_alter_schedule_timezone.py b/aircox/migrations/0023_station_legal_label_alter_schedule_timezone.py new file mode 100644 index 0000000..6a9b7ad --- /dev/null +++ b/aircox/migrations/0023_station_legal_label_alter_schedule_timezone.py @@ -0,0 +1,633 @@ +# Generated by Django 4.2.9 on 2024-03-15 19:56 + +import aircox.models.schedule +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("aircox", "0022_set_group_ownership"), + ] + + operations = [ + migrations.AddField( + model_name="station", + name="legal_label", + field=models.CharField( + blank=True, + default="", + help_text="Displayed at the bottom of pages.", + max_length=64, + verbose_name="Legal label", + ), + ), + migrations.AlterField( + model_name="schedule", + name="timezone", + field=models.CharField( + choices=[ + ("Africa/Abidjan", "Africa/Abidjan"), + ("Africa/Accra", "Africa/Accra"), + ("Africa/Addis_Ababa", "Africa/Addis_Ababa"), + ("Africa/Algiers", "Africa/Algiers"), + ("Africa/Asmara", "Africa/Asmara"), + ("Africa/Asmera", "Africa/Asmera"), + ("Africa/Bamako", "Africa/Bamako"), + ("Africa/Bangui", "Africa/Bangui"), + ("Africa/Banjul", "Africa/Banjul"), + ("Africa/Bissau", "Africa/Bissau"), + ("Africa/Blantyre", "Africa/Blantyre"), + ("Africa/Brazzaville", "Africa/Brazzaville"), + ("Africa/Bujumbura", "Africa/Bujumbura"), + ("Africa/Cairo", "Africa/Cairo"), + ("Africa/Casablanca", "Africa/Casablanca"), + ("Africa/Ceuta", "Africa/Ceuta"), + ("Africa/Conakry", "Africa/Conakry"), + ("Africa/Dakar", "Africa/Dakar"), + ("Africa/Dar_es_Salaam", "Africa/Dar_es_Salaam"), + ("Africa/Djibouti", "Africa/Djibouti"), + ("Africa/Douala", "Africa/Douala"), + ("Africa/El_Aaiun", "Africa/El_Aaiun"), + ("Africa/Freetown", "Africa/Freetown"), + ("Africa/Gaborone", "Africa/Gaborone"), + ("Africa/Harare", "Africa/Harare"), + ("Africa/Johannesburg", "Africa/Johannesburg"), + ("Africa/Juba", "Africa/Juba"), + ("Africa/Kampala", "Africa/Kampala"), + ("Africa/Khartoum", "Africa/Khartoum"), + ("Africa/Kigali", "Africa/Kigali"), + ("Africa/Kinshasa", "Africa/Kinshasa"), + ("Africa/Lagos", "Africa/Lagos"), + ("Africa/Libreville", "Africa/Libreville"), + ("Africa/Lome", "Africa/Lome"), + ("Africa/Luanda", "Africa/Luanda"), + ("Africa/Lubumbashi", "Africa/Lubumbashi"), + ("Africa/Lusaka", "Africa/Lusaka"), + ("Africa/Malabo", "Africa/Malabo"), + ("Africa/Maputo", "Africa/Maputo"), + ("Africa/Maseru", "Africa/Maseru"), + ("Africa/Mbabane", "Africa/Mbabane"), + ("Africa/Mogadishu", "Africa/Mogadishu"), + ("Africa/Monrovia", "Africa/Monrovia"), + ("Africa/Nairobi", "Africa/Nairobi"), + ("Africa/Ndjamena", "Africa/Ndjamena"), + ("Africa/Niamey", "Africa/Niamey"), + ("Africa/Nouakchott", "Africa/Nouakchott"), + ("Africa/Ouagadougou", "Africa/Ouagadougou"), + ("Africa/Porto-Novo", "Africa/Porto-Novo"), + ("Africa/Sao_Tome", "Africa/Sao_Tome"), + ("Africa/Timbuktu", "Africa/Timbuktu"), + ("Africa/Tripoli", "Africa/Tripoli"), + ("Africa/Tunis", "Africa/Tunis"), + ("Africa/Windhoek", "Africa/Windhoek"), + ("America/Adak", "America/Adak"), + ("America/Anchorage", "America/Anchorage"), + ("America/Anguilla", "America/Anguilla"), + ("America/Antigua", "America/Antigua"), + ("America/Araguaina", "America/Araguaina"), + ("America/Argentina/Buenos_Aires", "America/Argentina/Buenos_Aires"), + ("America/Argentina/Catamarca", "America/Argentina/Catamarca"), + ("America/Argentina/ComodRivadavia", "America/Argentina/ComodRivadavia"), + ("America/Argentina/Cordoba", "America/Argentina/Cordoba"), + ("America/Argentina/Jujuy", "America/Argentina/Jujuy"), + ("America/Argentina/La_Rioja", "America/Argentina/La_Rioja"), + ("America/Argentina/Mendoza", "America/Argentina/Mendoza"), + ("America/Argentina/Rio_Gallegos", "America/Argentina/Rio_Gallegos"), + ("America/Argentina/Salta", "America/Argentina/Salta"), + ("America/Argentina/San_Juan", "America/Argentina/San_Juan"), + ("America/Argentina/San_Luis", "America/Argentina/San_Luis"), + ("America/Argentina/Tucuman", "America/Argentina/Tucuman"), + ("America/Argentina/Ushuaia", "America/Argentina/Ushuaia"), + ("America/Aruba", "America/Aruba"), + ("America/Asuncion", "America/Asuncion"), + ("America/Atikokan", "America/Atikokan"), + ("America/Atka", "America/Atka"), + ("America/Bahia", "America/Bahia"), + ("America/Bahia_Banderas", "America/Bahia_Banderas"), + ("America/Barbados", "America/Barbados"), + ("America/Belem", "America/Belem"), + ("America/Belize", "America/Belize"), + ("America/Blanc-Sablon", "America/Blanc-Sablon"), + ("America/Boa_Vista", "America/Boa_Vista"), + ("America/Bogota", "America/Bogota"), + ("America/Boise", "America/Boise"), + ("America/Buenos_Aires", "America/Buenos_Aires"), + ("America/Cambridge_Bay", "America/Cambridge_Bay"), + ("America/Campo_Grande", "America/Campo_Grande"), + ("America/Cancun", "America/Cancun"), + ("America/Caracas", "America/Caracas"), + ("America/Catamarca", "America/Catamarca"), + ("America/Cayenne", "America/Cayenne"), + ("America/Cayman", "America/Cayman"), + ("America/Chicago", "America/Chicago"), + ("America/Chihuahua", "America/Chihuahua"), + ("America/Ciudad_Juarez", "America/Ciudad_Juarez"), + ("America/Coral_Harbour", "America/Coral_Harbour"), + ("America/Cordoba", "America/Cordoba"), + ("America/Costa_Rica", "America/Costa_Rica"), + ("America/Creston", "America/Creston"), + ("America/Cuiaba", "America/Cuiaba"), + ("America/Curacao", "America/Curacao"), + ("America/Danmarkshavn", "America/Danmarkshavn"), + ("America/Dawson", "America/Dawson"), + ("America/Dawson_Creek", "America/Dawson_Creek"), + ("America/Denver", "America/Denver"), + ("America/Detroit", "America/Detroit"), + ("America/Dominica", "America/Dominica"), + ("America/Edmonton", "America/Edmonton"), + ("America/Eirunepe", "America/Eirunepe"), + ("America/El_Salvador", "America/El_Salvador"), + ("America/Ensenada", "America/Ensenada"), + ("America/Fort_Nelson", "America/Fort_Nelson"), + ("America/Fort_Wayne", "America/Fort_Wayne"), + ("America/Fortaleza", "America/Fortaleza"), + ("America/Glace_Bay", "America/Glace_Bay"), + ("America/Godthab", "America/Godthab"), + ("America/Goose_Bay", "America/Goose_Bay"), + ("America/Grand_Turk", "America/Grand_Turk"), + ("America/Grenada", "America/Grenada"), + ("America/Guadeloupe", "America/Guadeloupe"), + ("America/Guatemala", "America/Guatemala"), + ("America/Guayaquil", "America/Guayaquil"), + ("America/Guyana", "America/Guyana"), + ("America/Halifax", "America/Halifax"), + ("America/Havana", "America/Havana"), + ("America/Hermosillo", "America/Hermosillo"), + ("America/Indiana/Indianapolis", "America/Indiana/Indianapolis"), + ("America/Indiana/Knox", "America/Indiana/Knox"), + ("America/Indiana/Marengo", "America/Indiana/Marengo"), + ("America/Indiana/Petersburg", "America/Indiana/Petersburg"), + ("America/Indiana/Tell_City", "America/Indiana/Tell_City"), + ("America/Indiana/Vevay", "America/Indiana/Vevay"), + ("America/Indiana/Vincennes", "America/Indiana/Vincennes"), + ("America/Indiana/Winamac", "America/Indiana/Winamac"), + ("America/Indianapolis", "America/Indianapolis"), + ("America/Inuvik", "America/Inuvik"), + ("America/Iqaluit", "America/Iqaluit"), + ("America/Jamaica", "America/Jamaica"), + ("America/Jujuy", "America/Jujuy"), + ("America/Juneau", "America/Juneau"), + ("America/Kentucky/Louisville", "America/Kentucky/Louisville"), + ("America/Kentucky/Monticello", "America/Kentucky/Monticello"), + ("America/Knox_IN", "America/Knox_IN"), + ("America/Kralendijk", "America/Kralendijk"), + ("America/La_Paz", "America/La_Paz"), + ("America/Lima", "America/Lima"), + ("America/Los_Angeles", "America/Los_Angeles"), + ("America/Louisville", "America/Louisville"), + ("America/Lower_Princes", "America/Lower_Princes"), + ("America/Maceio", "America/Maceio"), + ("America/Managua", "America/Managua"), + ("America/Manaus", "America/Manaus"), + ("America/Marigot", "America/Marigot"), + ("America/Martinique", "America/Martinique"), + ("America/Matamoros", "America/Matamoros"), + ("America/Mazatlan", "America/Mazatlan"), + ("America/Mendoza", "America/Mendoza"), + ("America/Menominee", "America/Menominee"), + ("America/Merida", "America/Merida"), + ("America/Metlakatla", "America/Metlakatla"), + ("America/Mexico_City", "America/Mexico_City"), + ("America/Miquelon", "America/Miquelon"), + ("America/Moncton", "America/Moncton"), + ("America/Monterrey", "America/Monterrey"), + ("America/Montevideo", "America/Montevideo"), + ("America/Montreal", "America/Montreal"), + ("America/Montserrat", "America/Montserrat"), + ("America/Nassau", "America/Nassau"), + ("America/New_York", "America/New_York"), + ("America/Nipigon", "America/Nipigon"), + ("America/Nome", "America/Nome"), + ("America/Noronha", "America/Noronha"), + ("America/North_Dakota/Beulah", "America/North_Dakota/Beulah"), + ("America/North_Dakota/Center", "America/North_Dakota/Center"), + ("America/North_Dakota/New_Salem", "America/North_Dakota/New_Salem"), + ("America/Nuuk", "America/Nuuk"), + ("America/Ojinaga", "America/Ojinaga"), + ("America/Panama", "America/Panama"), + ("America/Pangnirtung", "America/Pangnirtung"), + ("America/Paramaribo", "America/Paramaribo"), + ("America/Phoenix", "America/Phoenix"), + ("America/Port-au-Prince", "America/Port-au-Prince"), + ("America/Port_of_Spain", "America/Port_of_Spain"), + ("America/Porto_Acre", "America/Porto_Acre"), + ("America/Porto_Velho", "America/Porto_Velho"), + ("America/Puerto_Rico", "America/Puerto_Rico"), + ("America/Punta_Arenas", "America/Punta_Arenas"), + ("America/Rainy_River", "America/Rainy_River"), + ("America/Rankin_Inlet", "America/Rankin_Inlet"), + ("America/Recife", "America/Recife"), + ("America/Regina", "America/Regina"), + ("America/Resolute", "America/Resolute"), + ("America/Rio_Branco", "America/Rio_Branco"), + ("America/Rosario", "America/Rosario"), + ("America/Santa_Isabel", "America/Santa_Isabel"), + ("America/Santarem", "America/Santarem"), + ("America/Santiago", "America/Santiago"), + ("America/Santo_Domingo", "America/Santo_Domingo"), + ("America/Sao_Paulo", "America/Sao_Paulo"), + ("America/Scoresbysund", "America/Scoresbysund"), + ("America/Shiprock", "America/Shiprock"), + ("America/Sitka", "America/Sitka"), + ("America/St_Barthelemy", "America/St_Barthelemy"), + ("America/St_Johns", "America/St_Johns"), + ("America/St_Kitts", "America/St_Kitts"), + ("America/St_Lucia", "America/St_Lucia"), + ("America/St_Thomas", "America/St_Thomas"), + ("America/St_Vincent", "America/St_Vincent"), + ("America/Swift_Current", "America/Swift_Current"), + ("America/Tegucigalpa", "America/Tegucigalpa"), + ("America/Thule", "America/Thule"), + ("America/Thunder_Bay", "America/Thunder_Bay"), + ("America/Tijuana", "America/Tijuana"), + ("America/Toronto", "America/Toronto"), + ("America/Tortola", "America/Tortola"), + ("America/Vancouver", "America/Vancouver"), + ("America/Virgin", "America/Virgin"), + ("America/Whitehorse", "America/Whitehorse"), + ("America/Winnipeg", "America/Winnipeg"), + ("America/Yakutat", "America/Yakutat"), + ("America/Yellowknife", "America/Yellowknife"), + ("Antarctica/Casey", "Antarctica/Casey"), + ("Antarctica/Davis", "Antarctica/Davis"), + ("Antarctica/DumontDUrville", "Antarctica/DumontDUrville"), + ("Antarctica/Macquarie", "Antarctica/Macquarie"), + ("Antarctica/Mawson", "Antarctica/Mawson"), + ("Antarctica/McMurdo", "Antarctica/McMurdo"), + ("Antarctica/Palmer", "Antarctica/Palmer"), + ("Antarctica/Rothera", "Antarctica/Rothera"), + ("Antarctica/South_Pole", "Antarctica/South_Pole"), + ("Antarctica/Syowa", "Antarctica/Syowa"), + ("Antarctica/Troll", "Antarctica/Troll"), + ("Antarctica/Vostok", "Antarctica/Vostok"), + ("Arctic/Longyearbyen", "Arctic/Longyearbyen"), + ("Asia/Aden", "Asia/Aden"), + ("Asia/Almaty", "Asia/Almaty"), + ("Asia/Amman", "Asia/Amman"), + ("Asia/Anadyr", "Asia/Anadyr"), + ("Asia/Aqtau", "Asia/Aqtau"), + ("Asia/Aqtobe", "Asia/Aqtobe"), + ("Asia/Ashgabat", "Asia/Ashgabat"), + ("Asia/Ashkhabad", "Asia/Ashkhabad"), + ("Asia/Atyrau", "Asia/Atyrau"), + ("Asia/Baghdad", "Asia/Baghdad"), + ("Asia/Bahrain", "Asia/Bahrain"), + ("Asia/Baku", "Asia/Baku"), + ("Asia/Bangkok", "Asia/Bangkok"), + ("Asia/Barnaul", "Asia/Barnaul"), + ("Asia/Beirut", "Asia/Beirut"), + ("Asia/Bishkek", "Asia/Bishkek"), + ("Asia/Brunei", "Asia/Brunei"), + ("Asia/Calcutta", "Asia/Calcutta"), + ("Asia/Chita", "Asia/Chita"), + ("Asia/Choibalsan", "Asia/Choibalsan"), + ("Asia/Chongqing", "Asia/Chongqing"), + ("Asia/Chungking", "Asia/Chungking"), + ("Asia/Colombo", "Asia/Colombo"), + ("Asia/Dacca", "Asia/Dacca"), + ("Asia/Damascus", "Asia/Damascus"), + ("Asia/Dhaka", "Asia/Dhaka"), + ("Asia/Dili", "Asia/Dili"), + ("Asia/Dubai", "Asia/Dubai"), + ("Asia/Dushanbe", "Asia/Dushanbe"), + ("Asia/Famagusta", "Asia/Famagusta"), + ("Asia/Gaza", "Asia/Gaza"), + ("Asia/Harbin", "Asia/Harbin"), + ("Asia/Hebron", "Asia/Hebron"), + ("Asia/Ho_Chi_Minh", "Asia/Ho_Chi_Minh"), + ("Asia/Hong_Kong", "Asia/Hong_Kong"), + ("Asia/Hovd", "Asia/Hovd"), + ("Asia/Irkutsk", "Asia/Irkutsk"), + ("Asia/Istanbul", "Asia/Istanbul"), + ("Asia/Jakarta", "Asia/Jakarta"), + ("Asia/Jayapura", "Asia/Jayapura"), + ("Asia/Jerusalem", "Asia/Jerusalem"), + ("Asia/Kabul", "Asia/Kabul"), + ("Asia/Kamchatka", "Asia/Kamchatka"), + ("Asia/Karachi", "Asia/Karachi"), + ("Asia/Kashgar", "Asia/Kashgar"), + ("Asia/Kathmandu", "Asia/Kathmandu"), + ("Asia/Katmandu", "Asia/Katmandu"), + ("Asia/Khandyga", "Asia/Khandyga"), + ("Asia/Kolkata", "Asia/Kolkata"), + ("Asia/Krasnoyarsk", "Asia/Krasnoyarsk"), + ("Asia/Kuala_Lumpur", "Asia/Kuala_Lumpur"), + ("Asia/Kuching", "Asia/Kuching"), + ("Asia/Kuwait", "Asia/Kuwait"), + ("Asia/Macao", "Asia/Macao"), + ("Asia/Macau", "Asia/Macau"), + ("Asia/Magadan", "Asia/Magadan"), + ("Asia/Makassar", "Asia/Makassar"), + ("Asia/Manila", "Asia/Manila"), + ("Asia/Muscat", "Asia/Muscat"), + ("Asia/Nicosia", "Asia/Nicosia"), + ("Asia/Novokuznetsk", "Asia/Novokuznetsk"), + ("Asia/Novosibirsk", "Asia/Novosibirsk"), + ("Asia/Omsk", "Asia/Omsk"), + ("Asia/Oral", "Asia/Oral"), + ("Asia/Phnom_Penh", "Asia/Phnom_Penh"), + ("Asia/Pontianak", "Asia/Pontianak"), + ("Asia/Pyongyang", "Asia/Pyongyang"), + ("Asia/Qatar", "Asia/Qatar"), + ("Asia/Qostanay", "Asia/Qostanay"), + ("Asia/Qyzylorda", "Asia/Qyzylorda"), + ("Asia/Rangoon", "Asia/Rangoon"), + ("Asia/Riyadh", "Asia/Riyadh"), + ("Asia/Saigon", "Asia/Saigon"), + ("Asia/Sakhalin", "Asia/Sakhalin"), + ("Asia/Samarkand", "Asia/Samarkand"), + ("Asia/Seoul", "Asia/Seoul"), + ("Asia/Shanghai", "Asia/Shanghai"), + ("Asia/Singapore", "Asia/Singapore"), + ("Asia/Srednekolymsk", "Asia/Srednekolymsk"), + ("Asia/Taipei", "Asia/Taipei"), + ("Asia/Tashkent", "Asia/Tashkent"), + ("Asia/Tbilisi", "Asia/Tbilisi"), + ("Asia/Tehran", "Asia/Tehran"), + ("Asia/Tel_Aviv", "Asia/Tel_Aviv"), + ("Asia/Thimbu", "Asia/Thimbu"), + ("Asia/Thimphu", "Asia/Thimphu"), + ("Asia/Tokyo", "Asia/Tokyo"), + ("Asia/Tomsk", "Asia/Tomsk"), + ("Asia/Ujung_Pandang", "Asia/Ujung_Pandang"), + ("Asia/Ulaanbaatar", "Asia/Ulaanbaatar"), + ("Asia/Ulan_Bator", "Asia/Ulan_Bator"), + ("Asia/Urumqi", "Asia/Urumqi"), + ("Asia/Ust-Nera", "Asia/Ust-Nera"), + ("Asia/Vientiane", "Asia/Vientiane"), + ("Asia/Vladivostok", "Asia/Vladivostok"), + ("Asia/Yakutsk", "Asia/Yakutsk"), + ("Asia/Yangon", "Asia/Yangon"), + ("Asia/Yekaterinburg", "Asia/Yekaterinburg"), + ("Asia/Yerevan", "Asia/Yerevan"), + ("Atlantic/Azores", "Atlantic/Azores"), + ("Atlantic/Bermuda", "Atlantic/Bermuda"), + ("Atlantic/Canary", "Atlantic/Canary"), + ("Atlantic/Cape_Verde", "Atlantic/Cape_Verde"), + ("Atlantic/Faeroe", "Atlantic/Faeroe"), + ("Atlantic/Faroe", "Atlantic/Faroe"), + ("Atlantic/Jan_Mayen", "Atlantic/Jan_Mayen"), + ("Atlantic/Madeira", "Atlantic/Madeira"), + ("Atlantic/Reykjavik", "Atlantic/Reykjavik"), + ("Atlantic/South_Georgia", "Atlantic/South_Georgia"), + ("Atlantic/St_Helena", "Atlantic/St_Helena"), + ("Atlantic/Stanley", "Atlantic/Stanley"), + ("Australia/ACT", "Australia/ACT"), + ("Australia/Adelaide", "Australia/Adelaide"), + ("Australia/Brisbane", "Australia/Brisbane"), + ("Australia/Broken_Hill", "Australia/Broken_Hill"), + ("Australia/Canberra", "Australia/Canberra"), + ("Australia/Currie", "Australia/Currie"), + ("Australia/Darwin", "Australia/Darwin"), + ("Australia/Eucla", "Australia/Eucla"), + ("Australia/Hobart", "Australia/Hobart"), + ("Australia/LHI", "Australia/LHI"), + ("Australia/Lindeman", "Australia/Lindeman"), + ("Australia/Lord_Howe", "Australia/Lord_Howe"), + ("Australia/Melbourne", "Australia/Melbourne"), + ("Australia/NSW", "Australia/NSW"), + ("Australia/North", "Australia/North"), + ("Australia/Perth", "Australia/Perth"), + ("Australia/Queensland", "Australia/Queensland"), + ("Australia/South", "Australia/South"), + ("Australia/Sydney", "Australia/Sydney"), + ("Australia/Tasmania", "Australia/Tasmania"), + ("Australia/Victoria", "Australia/Victoria"), + ("Australia/West", "Australia/West"), + ("Australia/Yancowinna", "Australia/Yancowinna"), + ("Brazil/Acre", "Brazil/Acre"), + ("Brazil/DeNoronha", "Brazil/DeNoronha"), + ("Brazil/East", "Brazil/East"), + ("Brazil/West", "Brazil/West"), + ("CET", "CET"), + ("CST6CDT", "CST6CDT"), + ("Canada/Atlantic", "Canada/Atlantic"), + ("Canada/Central", "Canada/Central"), + ("Canada/Eastern", "Canada/Eastern"), + ("Canada/Mountain", "Canada/Mountain"), + ("Canada/Newfoundland", "Canada/Newfoundland"), + ("Canada/Pacific", "Canada/Pacific"), + ("Canada/Saskatchewan", "Canada/Saskatchewan"), + ("Canada/Yukon", "Canada/Yukon"), + ("Chile/Continental", "Chile/Continental"), + ("Chile/EasterIsland", "Chile/EasterIsland"), + ("Cuba", "Cuba"), + ("EET", "EET"), + ("EST", "EST"), + ("EST5EDT", "EST5EDT"), + ("Egypt", "Egypt"), + ("Eire", "Eire"), + ("Etc/GMT", "Etc/GMT"), + ("Etc/GMT+0", "Etc/GMT+0"), + ("Etc/GMT+1", "Etc/GMT+1"), + ("Etc/GMT+10", "Etc/GMT+10"), + ("Etc/GMT+11", "Etc/GMT+11"), + ("Etc/GMT+12", "Etc/GMT+12"), + ("Etc/GMT+2", "Etc/GMT+2"), + ("Etc/GMT+3", "Etc/GMT+3"), + ("Etc/GMT+4", "Etc/GMT+4"), + ("Etc/GMT+5", "Etc/GMT+5"), + ("Etc/GMT+6", "Etc/GMT+6"), + ("Etc/GMT+7", "Etc/GMT+7"), + ("Etc/GMT+8", "Etc/GMT+8"), + ("Etc/GMT+9", "Etc/GMT+9"), + ("Etc/GMT-0", "Etc/GMT-0"), + ("Etc/GMT-1", "Etc/GMT-1"), + ("Etc/GMT-10", "Etc/GMT-10"), + ("Etc/GMT-11", "Etc/GMT-11"), + ("Etc/GMT-12", "Etc/GMT-12"), + ("Etc/GMT-13", "Etc/GMT-13"), + ("Etc/GMT-14", "Etc/GMT-14"), + ("Etc/GMT-2", "Etc/GMT-2"), + ("Etc/GMT-3", "Etc/GMT-3"), + ("Etc/GMT-4", "Etc/GMT-4"), + ("Etc/GMT-5", "Etc/GMT-5"), + ("Etc/GMT-6", "Etc/GMT-6"), + ("Etc/GMT-7", "Etc/GMT-7"), + ("Etc/GMT-8", "Etc/GMT-8"), + ("Etc/GMT-9", "Etc/GMT-9"), + ("Etc/GMT0", "Etc/GMT0"), + ("Etc/Greenwich", "Etc/Greenwich"), + ("Etc/UCT", "Etc/UCT"), + ("Etc/UTC", "Etc/UTC"), + ("Etc/Universal", "Etc/Universal"), + ("Etc/Zulu", "Etc/Zulu"), + ("Europe/Amsterdam", "Europe/Amsterdam"), + ("Europe/Andorra", "Europe/Andorra"), + ("Europe/Astrakhan", "Europe/Astrakhan"), + ("Europe/Athens", "Europe/Athens"), + ("Europe/Belfast", "Europe/Belfast"), + ("Europe/Belgrade", "Europe/Belgrade"), + ("Europe/Berlin", "Europe/Berlin"), + ("Europe/Bratislava", "Europe/Bratislava"), + ("Europe/Brussels", "Europe/Brussels"), + ("Europe/Bucharest", "Europe/Bucharest"), + ("Europe/Budapest", "Europe/Budapest"), + ("Europe/Busingen", "Europe/Busingen"), + ("Europe/Chisinau", "Europe/Chisinau"), + ("Europe/Copenhagen", "Europe/Copenhagen"), + ("Europe/Dublin", "Europe/Dublin"), + ("Europe/Gibraltar", "Europe/Gibraltar"), + ("Europe/Guernsey", "Europe/Guernsey"), + ("Europe/Helsinki", "Europe/Helsinki"), + ("Europe/Isle_of_Man", "Europe/Isle_of_Man"), + ("Europe/Istanbul", "Europe/Istanbul"), + ("Europe/Jersey", "Europe/Jersey"), + ("Europe/Kaliningrad", "Europe/Kaliningrad"), + ("Europe/Kiev", "Europe/Kiev"), + ("Europe/Kirov", "Europe/Kirov"), + ("Europe/Kyiv", "Europe/Kyiv"), + ("Europe/Lisbon", "Europe/Lisbon"), + ("Europe/Ljubljana", "Europe/Ljubljana"), + ("Europe/London", "Europe/London"), + ("Europe/Luxembourg", "Europe/Luxembourg"), + ("Europe/Madrid", "Europe/Madrid"), + ("Europe/Malta", "Europe/Malta"), + ("Europe/Mariehamn", "Europe/Mariehamn"), + ("Europe/Minsk", "Europe/Minsk"), + ("Europe/Monaco", "Europe/Monaco"), + ("Europe/Moscow", "Europe/Moscow"), + ("Europe/Nicosia", "Europe/Nicosia"), + ("Europe/Oslo", "Europe/Oslo"), + ("Europe/Paris", "Europe/Paris"), + ("Europe/Podgorica", "Europe/Podgorica"), + ("Europe/Prague", "Europe/Prague"), + ("Europe/Riga", "Europe/Riga"), + ("Europe/Rome", "Europe/Rome"), + ("Europe/Samara", "Europe/Samara"), + ("Europe/San_Marino", "Europe/San_Marino"), + ("Europe/Sarajevo", "Europe/Sarajevo"), + ("Europe/Saratov", "Europe/Saratov"), + ("Europe/Simferopol", "Europe/Simferopol"), + ("Europe/Skopje", "Europe/Skopje"), + ("Europe/Sofia", "Europe/Sofia"), + ("Europe/Stockholm", "Europe/Stockholm"), + ("Europe/Tallinn", "Europe/Tallinn"), + ("Europe/Tirane", "Europe/Tirane"), + ("Europe/Tiraspol", "Europe/Tiraspol"), + ("Europe/Ulyanovsk", "Europe/Ulyanovsk"), + ("Europe/Uzhgorod", "Europe/Uzhgorod"), + ("Europe/Vaduz", "Europe/Vaduz"), + ("Europe/Vatican", "Europe/Vatican"), + ("Europe/Vienna", "Europe/Vienna"), + ("Europe/Vilnius", "Europe/Vilnius"), + ("Europe/Volgograd", "Europe/Volgograd"), + ("Europe/Warsaw", "Europe/Warsaw"), + ("Europe/Zagreb", "Europe/Zagreb"), + ("Europe/Zaporozhye", "Europe/Zaporozhye"), + ("Europe/Zurich", "Europe/Zurich"), + ("Factory", "Factory"), + ("GB", "GB"), + ("GB-Eire", "GB-Eire"), + ("GMT", "GMT"), + ("GMT+0", "GMT+0"), + ("GMT-0", "GMT-0"), + ("GMT0", "GMT0"), + ("Greenwich", "Greenwich"), + ("HST", "HST"), + ("Hongkong", "Hongkong"), + ("Iceland", "Iceland"), + ("Indian/Antananarivo", "Indian/Antananarivo"), + ("Indian/Chagos", "Indian/Chagos"), + ("Indian/Christmas", "Indian/Christmas"), + ("Indian/Cocos", "Indian/Cocos"), + ("Indian/Comoro", "Indian/Comoro"), + ("Indian/Kerguelen", "Indian/Kerguelen"), + ("Indian/Mahe", "Indian/Mahe"), + ("Indian/Maldives", "Indian/Maldives"), + ("Indian/Mauritius", "Indian/Mauritius"), + ("Indian/Mayotte", "Indian/Mayotte"), + ("Indian/Reunion", "Indian/Reunion"), + ("Iran", "Iran"), + ("Israel", "Israel"), + ("Jamaica", "Jamaica"), + ("Japan", "Japan"), + ("Kwajalein", "Kwajalein"), + ("Libya", "Libya"), + ("MET", "MET"), + ("MST", "MST"), + ("MST7MDT", "MST7MDT"), + ("Mexico/BajaNorte", "Mexico/BajaNorte"), + ("Mexico/BajaSur", "Mexico/BajaSur"), + ("Mexico/General", "Mexico/General"), + ("NZ", "NZ"), + ("NZ-CHAT", "NZ-CHAT"), + ("Navajo", "Navajo"), + ("PRC", "PRC"), + ("PST8PDT", "PST8PDT"), + ("Pacific/Apia", "Pacific/Apia"), + ("Pacific/Auckland", "Pacific/Auckland"), + ("Pacific/Bougainville", "Pacific/Bougainville"), + ("Pacific/Chatham", "Pacific/Chatham"), + ("Pacific/Chuuk", "Pacific/Chuuk"), + ("Pacific/Easter", "Pacific/Easter"), + ("Pacific/Efate", "Pacific/Efate"), + ("Pacific/Enderbury", "Pacific/Enderbury"), + ("Pacific/Fakaofo", "Pacific/Fakaofo"), + ("Pacific/Fiji", "Pacific/Fiji"), + ("Pacific/Funafuti", "Pacific/Funafuti"), + ("Pacific/Galapagos", "Pacific/Galapagos"), + ("Pacific/Gambier", "Pacific/Gambier"), + ("Pacific/Guadalcanal", "Pacific/Guadalcanal"), + ("Pacific/Guam", "Pacific/Guam"), + ("Pacific/Honolulu", "Pacific/Honolulu"), + ("Pacific/Johnston", "Pacific/Johnston"), + ("Pacific/Kanton", "Pacific/Kanton"), + ("Pacific/Kiritimati", "Pacific/Kiritimati"), + ("Pacific/Kosrae", "Pacific/Kosrae"), + ("Pacific/Kwajalein", "Pacific/Kwajalein"), + ("Pacific/Majuro", "Pacific/Majuro"), + ("Pacific/Marquesas", "Pacific/Marquesas"), + ("Pacific/Midway", "Pacific/Midway"), + ("Pacific/Nauru", "Pacific/Nauru"), + ("Pacific/Niue", "Pacific/Niue"), + ("Pacific/Norfolk", "Pacific/Norfolk"), + ("Pacific/Noumea", "Pacific/Noumea"), + ("Pacific/Pago_Pago", "Pacific/Pago_Pago"), + ("Pacific/Palau", "Pacific/Palau"), + ("Pacific/Pitcairn", "Pacific/Pitcairn"), + ("Pacific/Pohnpei", "Pacific/Pohnpei"), + ("Pacific/Ponape", "Pacific/Ponape"), + ("Pacific/Port_Moresby", "Pacific/Port_Moresby"), + ("Pacific/Rarotonga", "Pacific/Rarotonga"), + ("Pacific/Saipan", "Pacific/Saipan"), + ("Pacific/Samoa", "Pacific/Samoa"), + ("Pacific/Tahiti", "Pacific/Tahiti"), + ("Pacific/Tarawa", "Pacific/Tarawa"), + ("Pacific/Tongatapu", "Pacific/Tongatapu"), + ("Pacific/Truk", "Pacific/Truk"), + ("Pacific/Wake", "Pacific/Wake"), + ("Pacific/Wallis", "Pacific/Wallis"), + ("Pacific/Yap", "Pacific/Yap"), + ("Poland", "Poland"), + ("Portugal", "Portugal"), + ("ROC", "ROC"), + ("ROK", "ROK"), + ("Singapore", "Singapore"), + ("Turkey", "Turkey"), + ("UCT", "UCT"), + ("US/Alaska", "US/Alaska"), + ("US/Aleutian", "US/Aleutian"), + ("US/Arizona", "US/Arizona"), + ("US/Central", "US/Central"), + ("US/East-Indiana", "US/East-Indiana"), + ("US/Eastern", "US/Eastern"), + ("US/Hawaii", "US/Hawaii"), + ("US/Indiana-Starke", "US/Indiana-Starke"), + ("US/Michigan", "US/Michigan"), + ("US/Mountain", "US/Mountain"), + ("US/Pacific", "US/Pacific"), + ("US/Samoa", "US/Samoa"), + ("UTC", "UTC"), + ("Universal", "Universal"), + ("W-SU", "W-SU"), + ("WET", "WET"), + ("Zulu", "Zulu"), + ], + default=aircox.models.schedule.current_timezone_key, + help_text="timezone used for the date", + max_length=100, + verbose_name="timezone", + ), + ), + ] diff --git a/aircox/migrations/0024_rename_playlist_editor_columns_usersettings_tracklist_editor_columns_and_more.py b/aircox/migrations/0024_rename_playlist_editor_columns_usersettings_tracklist_editor_columns_and_more.py new file mode 100644 index 0000000..99e65e9 --- /dev/null +++ b/aircox/migrations/0024_rename_playlist_editor_columns_usersettings_tracklist_editor_columns_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 4.2.9 on 2024-03-19 22:38 + +from django.db import migrations + + +class Migration(migrations.Migration): + dependencies = [ + ("aircox", "0023_station_legal_label_alter_schedule_timezone"), + ] + + operations = [ + migrations.RenameField( + model_name="usersettings", + old_name="playlist_editor_columns", + new_name="tracklist_editor_columns", + ), + migrations.RenameField( + model_name="usersettings", + old_name="playlist_editor_sep", + new_name="tracklist_editor_sep", + ), + ] diff --git a/aircox/migrations/0025_sound_is_removed_alter_sound_is_downloadable_and_more.py b/aircox/migrations/0025_sound_is_removed_alter_sound_is_downloadable_and_more.py new file mode 100644 index 0000000..474fa8c --- /dev/null +++ b/aircox/migrations/0025_sound_is_removed_alter_sound_is_downloadable_and_more.py @@ -0,0 +1,36 @@ +# Generated by Django 4.2.9 on 2024-03-25 20:23 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("aircox", "0024_rename_playlist_editor_columns_usersettings_tracklist_editor_columns_and_more"), + ] + + operations = [ + migrations.AddField( + model_name="sound", + name="is_removed", + field=models.BooleanField(default=False, help_text="file has been removed", verbose_name="removed"), + ), + migrations.AlterField( + model_name="sound", + name="is_downloadable", + field=models.BooleanField( + default=False, + help_text="sound can be downloaded by visitors (sound must be public)", + verbose_name="downloadable", + ), + ), + migrations.AlterField( + model_name="sound", + name="is_public", + field=models.BooleanField(default=False, help_text="sound is available as podcast", verbose_name="public"), + ), + migrations.AlterField( + model_name="sound", + name="type", + field=models.SmallIntegerField(choices=[(0, "other"), (1, "archive"), (2, "excerpt")], verbose_name="type"), + ), + ] diff --git a/aircox/migrations/0026_alter_sound_options_remove_sound_episode_and_more.py b/aircox/migrations/0026_alter_sound_options_remove_sound_episode_and_more.py new file mode 100644 index 0000000..b4dacf3 --- /dev/null +++ b/aircox/migrations/0026_alter_sound_options_remove_sound_episode_and_more.py @@ -0,0 +1,108 @@ +# Generated by Django 4.2.9 on 2024-03-26 02:53 + +import aircox.models.file +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + dependencies = [ + ("aircox", "0025_sound_is_removed_alter_sound_is_downloadable_and_more"), + ] + + operations = [ + migrations.AlterModelOptions( + name="sound", + options={"verbose_name": "Sound file", "verbose_name_plural": "Sound files"}, + ), + migrations.RemoveField( + model_name="sound", + name="episode", + ), + migrations.RemoveField( + model_name="sound", + name="position", + ), + migrations.RemoveField( + model_name="sound", + name="type", + ), + migrations.AddField( + model_name="sound", + name="broadcast", + field=models.BooleanField( + default=False, help_text="The sound is broadcasted on air", verbose_name="Broadcast" + ), + ), + migrations.AddField( + model_name="sound", + name="description", + field=models.TextField(blank=True, default="", max_length=256, verbose_name="description"), + ), + migrations.AlterField( + model_name="sound", + name="file", + field=models.FileField( + db_index=True, max_length=256, upload_to=aircox.models.file.File._upload_to, verbose_name="file" + ), + ), + migrations.AlterField( + model_name="sound", + name="is_downloadable", + field=models.BooleanField( + default=False, help_text="sound can be downloaded by visitors", verbose_name="downloadable" + ), + ), + migrations.AlterField( + model_name="sound", + name="is_public", + field=models.BooleanField(default=False, help_text="file is publicly accessible", verbose_name="public"), + ), + migrations.AlterField( + model_name="sound", + name="is_removed", + field=models.BooleanField( + db_index=True, default=False, help_text="file has been removed from server", verbose_name="removed" + ), + ), + migrations.AlterField( + model_name="sound", + name="name", + field=models.CharField(db_index=True, max_length=64, verbose_name="name"), + ), + migrations.AlterField( + model_name="sound", + name="program", + field=models.ForeignKey( + blank=True, + null=True, + on_delete=django.db.models.deletion.SET_NULL, + to="aircox.program", + verbose_name="Program", + ), + ), + migrations.CreateModel( + name="EpisodeSound", + fields=[ + ("id", models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")), + ( + "position", + models.PositiveSmallIntegerField( + default=0, help_text="position in the playlist", verbose_name="order" + ), + ), + ( + "broadcast", + models.BooleanField( + blank=None, help_text="The sound is broadcasted on air", verbose_name="Broadcast" + ), + ), + ("episode", models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to="aircox.episode")), + ("sound", models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to="aircox.sound")), + ], + options={ + "verbose_name": "Episode Sound", + "verbose_name_plural": "Episode Sounds", + }, + ), + ] diff --git a/aircox/static/aircox/js/chunk-common.js b/aircox/static/aircox/js/chunk-common.js index 74a5b84..4e0abc7 100644 --- a/aircox/static/aircox/js/chunk-common.js +++ b/aircox/static/aircox/js/chunk-common.js @@ -69,6 +69,16 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _mod /***/ }), +/***/ "./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=script&lang=js": +/*!******************************************************************************************************************************************************************************************!*\ + !*** ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=script&lang=js ***! + \******************************************************************************************************************************************************************************************/ +/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { + +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\");\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../model */ \"./src/model.js\");\n/* harmony import */ var _ARows__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./ARows */ \"./src/components/ARows.vue\");\n\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n emit: ['cell', 'move', 'colmove', 'load'],\n components: {\n ARows: _ARows__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n },\n props: {\n labels: Object,\n //! If provided call this function instead of adding an item to rows on \"+\" button click.\n actionAdd: Function,\n //! If True, columns can be reordered\n columnsOrderable: Boolean,\n //! Field name used for ordering\n orderBy: String,\n //! Formset data as returned by get_formset_data\n formData: Object,\n //! Model class used for item's set\n model: {\n type: Function,\n default: _model__WEBPACK_IMPORTED_MODULE_2__[\"default\"]\n },\n //! initial data set load at mount\n initials: Array\n },\n data() {\n return {\n set: new _model__WEBPACK_IMPORTED_MODULE_2__.Set(_model__WEBPACK_IMPORTED_MODULE_2__[\"default\"])\n };\n },\n computed: {\n // ---- fields\n _prefix() {\n return this.formData.prefix ? this.formData.prefix + '-' : '';\n },\n fields() {\n return this.formData.fields;\n },\n orderField() {\n return this.orderBy && this.fields.find(f => f.name == this.orderBy);\n },\n orderable() {\n return !!this.orderField;\n },\n hiddenFields() {\n return this.fields.filter(f => f.hidden && !(this.orderable && f == this.orderField));\n },\n visibleFields() {\n return this.fields.filter(f => !f.hidden);\n },\n fieldSlots() {\n return this.visibleFields.reduce((slots, f) => ({\n ...slots,\n ['row-' + f.name]: f\n }), {});\n },\n items() {\n return this.set.items;\n },\n rows() {\n return this.$refs.rows;\n }\n },\n methods: {\n onCellEvent(event) {\n this.$emit('cell', event);\n },\n onMoveColumn(event) {\n this.$emit('colmove', event);\n },\n onActionAdd() {\n if (this.actionAdd) return this.actionAdd(this);\n this.set.push();\n },\n moveItem(event) {\n const {\n from,\n to\n } = event;\n const set_ = event.set || this.set;\n set_.move(from, to);\n this.$emit('move', {\n ...event,\n seŧ: set_\n });\n },\n removeItem(row) {\n const item = this.items[row];\n if (item.id) {\n // TODO\n } else {\n this.items.splice(row, 1);\n }\n },\n //! Load items into set\n load(items = [], reset = false) {\n if (reset) this.set.items = [];\n for (var item of items) this.set.push((0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(item));\n this.$emit('load', items);\n },\n //! Reset forms to initials\n reset() {\n this.load(this.initials || [], true);\n }\n },\n mounted() {\n this.reset();\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/AFormSet.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); + +/***/ }), + /***/ "./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AList.vue?vue&type=script&lang=js": /*!***************************************************************************************************************************************************************************************!*\ !*** ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AList.vue?vue&type=script&lang=js ***! @@ -135,7 +145,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony default export */ \**************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n/* harmony import */ var _model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../model */ \"./src/model.js\");\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n emit: ['move', 'cell'],\n props: {\n //! Item to display in row\n item: Object,\n //! Columns to display, as items' attributes\n columns: Array,\n //! Default cell's info\n cell: {\n type: Object,\n default() {\n return {\n row: 0\n };\n }\n },\n //! Cell component tag\n cellTag: {\n type: String,\n default: 'td'\n },\n //! If true, can reorder cell by drag & drop\n orderable: {\n type: Boolean,\n default: false\n }\n },\n computed: {\n /**\n * Row index\n */\n row() {\n return this.cell && this.cell.row || 0;\n },\n /**\n * Item's data if model instance, otherwise item\n */\n itemData() {\n return this.item instanceof _model__WEBPACK_IMPORTED_MODULE_2__[\"default\"] ? this.item.data : this.item;\n },\n /**\n * Computed cell infos\n */\n cells() {\n const cell = (0,vue__WEBPACK_IMPORTED_MODULE_1__.isReactive)(this.cell) && (0,vue__WEBPACK_IMPORTED_MODULE_1__.toRefs)(this.cell) || this.cell || {};\n const cells = [];\n for (var col in this.columns) cells.push({\n ...cell,\n col: Number(col)\n });\n return cells;\n }\n },\n methods: {\n /**\n * Emit a 'cell' event.\n * Event data: `{name, cell, data, item}`\n * @param {Number} col: cell column's index\n * @param {String} name: cell's event name\n * @param {} data: cell's event data\n */\n cellEmit(name, cell, data) {\n this.$emit('cell', {\n name,\n cell,\n data,\n item: this.item\n });\n },\n onDragStart(ev) {\n const dataset = ev.target.dataset;\n const data = `cell:${dataset.col}`;\n ev.dataTransfer.setData(\"text/cell\", data);\n ev.dataTransfer.dropEffect = 'move';\n },\n onDragOver(ev) {\n ev.preventDefault();\n ev.dataTransfer.dropEffect = 'move';\n },\n /**\n * Handle drop event, emit `'move': { from, to }`.\n */\n onDrop(ev) {\n const data = ev.dataTransfer.getData(\"text/cell\");\n if (!data || !data.startsWith('cell:')) return;\n ev.preventDefault();\n this.$emit('move', {\n from: Number(data.slice(5)),\n to: Number(ev.target.dataset.col)\n });\n },\n /**\n * Return DOM node for cells at provided position `col`\n */\n getCellEl(col) {\n const els = this.$el.querySelectorAll(this.cellTag);\n for (var el of els) if (col == Number(el.dataset.col)) return el;\n return null;\n },\n /**\n * Focus cell's form input. If from is provided, related focus\n */\n focus(col, from) {\n if (from) col += from.col;\n const target = this.getCellEl(col);\n if (!target) return;\n const control = target.querySelector('input:not([type=\"hidden\"])') || target.querySelector('button') || target.querySelector('select') || target.querySelector('a');\n control && control.focus();\n }\n },\n mounted() {\n this.$el.__row = this;\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARow.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n/* harmony import */ var _model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../model */ \"./src/model.js\");\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n emits: ['move', 'cell'],\n props: {\n //! Item to display in row\n item: {\n type: Object,\n default: () => ({})\n },\n //! Columns to display, as items' attributes\n //! - name: field name / item attribute value\n //! - label: display label\n //! - help: help text\n columns: Array,\n //! Default cell's info\n cell: {\n type: Object,\n default() {\n return {\n row: 0\n };\n }\n },\n //! Cell component tag\n cellTag: {\n type: String,\n default: 'td'\n },\n //! If true, can reorder cell by drag & drop\n orderable: {\n type: Boolean,\n default: false\n }\n },\n computed: {\n /**\n * Row index\n */\n row() {\n return this.cell && this.cell.row || 0;\n },\n /**\n * Item's data if model instance, otherwise item\n */\n itemData() {\n return this.item instanceof _model__WEBPACK_IMPORTED_MODULE_2__[\"default\"] ? this.item.data : this.item;\n },\n /**\n * Computed cell infos\n */\n cells() {\n const cell = (0,vue__WEBPACK_IMPORTED_MODULE_1__.isReactive)(this.cell) && (0,vue__WEBPACK_IMPORTED_MODULE_1__.toRefs)(this.cell) || this.cell || {};\n const cells = [];\n for (var col in this.columns) cells.push({\n ...cell,\n col: Number(col)\n });\n return cells;\n }\n },\n methods: {\n /**\n * Emit a 'cell' event.\n * Event data: `{name, cell, data, item}`\n * @param {Number} col: cell column's index\n * @param {String} name: cell's event name\n * @param {} data: cell's event data\n */\n cellEmit(name, cell, data) {\n this.$emit('cell', {\n name,\n cell,\n data,\n item: this.item\n });\n },\n onDragStart(ev) {\n const dataset = ev.target.dataset;\n const data = `cell:${dataset.col}`;\n ev.dataTransfer.setData(\"text/cell\", data);\n ev.dataTransfer.dropEffect = 'move';\n },\n onDragOver(ev) {\n ev.preventDefault();\n ev.dataTransfer.dropEffect = 'move';\n },\n /**\n * Handle drop event, emit `'move': { from, to }`.\n */\n onDrop(ev) {\n const data = ev.dataTransfer.getData(\"text/cell\");\n if (!data || !data.startsWith('cell:')) return;\n ev.preventDefault();\n this.$emit('move', {\n from: Number(data.slice(5)),\n to: Number(ev.target.dataset.col)\n });\n },\n /**\n * Return DOM node for cells at provided position `col`\n */\n getCellEl(col) {\n const els = this.$el.querySelectorAll(this.cellTag);\n for (var el of els) if (col == Number(el.dataset.col)) return el;\n return null;\n },\n /**\n * Focus cell's form input. If from is provided, related focus\n */\n focus(col, from) {\n if (from) col += from.col;\n const target = this.getCellEl(col);\n if (!target) return;\n const control = target.querySelector('input:not([type=\"hidden\"])') || target.querySelector('button') || target.querySelector('select') || target.querySelector('a');\n control && control.focus();\n }\n },\n mounted() {\n this.$el.__row = this;\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARow.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -145,7 +155,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core \***************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _AList_vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AList.vue */ \"./src/components/AList.vue\");\n/* harmony import */ var _ARow_vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./ARow.vue */ \"./src/components/ARow.vue\");\n\n\n\nconst Component = {\n extends: _AList_vue__WEBPACK_IMPORTED_MODULE_1__[\"default\"],\n components: {\n ARow: _ARow_vue__WEBPACK_IMPORTED_MODULE_2__[\"default\"]\n },\n emit: ['cell', 'colmove'],\n props: {\n ..._AList_vue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].props,\n columns: Array,\n labels: Object\n },\n data() {\n return {\n ...super.data,\n extraItem: new this.set.model()\n };\n },\n computed: {\n rowCells() {\n const cells = [];\n for (var row in this.items) cells.push({\n row\n });\n },\n rowSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-')).map(x => [x, x.slice(4)]);\n }\n },\n methods: {\n /**\n * React on 'cell' event, re-emitting it with additional values:\n * - `set`: data set\n * - `row`: row index\n *\n * @param {Number} row: row index\n * @param {} data: cell's event data\n */\n onCellEvent(row, event) {\n if (event.name == 'focus') this.focus(event.data, event.cell);\n this.$emit('cell', {\n ...event,\n row,\n set: this.set\n });\n },\n /**\n * Return row component at provided index\n */\n getRow(row) {\n const els = this.$el.querySelectorAll('tr');\n for (var el of els) if (el.__row && row == Number(el.dataset.row)) return el.__row;\n },\n /**\n * Focus on a cell\n */\n focus(row, col, from = null) {\n if (from) row += from.row;\n row = this.getRow(row);\n row && row.focus(col, from);\n }\n }\n};\nComponent.props.itemTag.default = 'tr';\nComponent.props.listTag.default = 'tbody';\n/* harmony default export */ __webpack_exports__[\"default\"] = (Component);\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARows.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _AList_vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AList.vue */ \"./src/components/AList.vue\");\n/* harmony import */ var _ARow_vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ARow.vue */ \"./src/components/ARow.vue\");\n\n\nconst Component = {\n extends: _AList_vue__WEBPACK_IMPORTED_MODULE_0__[\"default\"],\n components: {\n ARow: _ARow_vue__WEBPACK_IMPORTED_MODULE_1__[\"default\"]\n },\n emits: ['cell', 'colmove'],\n props: {\n ..._AList_vue__WEBPACK_IMPORTED_MODULE_0__[\"default\"].props,\n //! Ordered list of columns, as objects with:\n //! - name: item attribute value\n //! - label: display label\n //! - help: help text\n //! - hidden: if true, field is hidden\n columns: Array,\n //! If True, columns are orderable\n columnsOrderable: Boolean\n },\n data() {\n return {\n ...super.data,\n // TODO: add observer\n columns_: [...this.columns],\n extraItem: new this.set.model()\n };\n },\n computed: {\n columnNames() {\n return this.columns_.map(c => c.name);\n },\n columnLabels() {\n return this.columns_.map(c => c.label);\n },\n rowSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-')).map(x => [x, x.slice(4)]);\n }\n },\n methods: {\n /**\n * Move column using provided event object (as `{from, to}`)\n */\n moveColumn(event) {\n const {\n from,\n to\n } = event;\n const value = this.columns_[from];\n this.columns_.splice(from, 1);\n this.columns_.splice(to, 0, value);\n this.$emit('colmove', event);\n },\n /**\n * React on 'cell' event, re-emitting it with additional values:\n * - `set`: data set\n * - `row`: row index\n *\n * @param {Number} row: row index\n * @param {} data: cell's event data\n */\n onCellEvent(row, event) {\n if (event.name == 'focus') this.focus(event.data, event.cell);\n this.$emit('cell', {\n ...event,\n row,\n set: this.set\n });\n },\n /**\n * Return row component at provided index\n */\n getRow(row) {\n const els = this.$el.querySelectorAll('tr');\n for (var el of els) if (el.__row && row == Number(el.dataset.row)) return el.__row;\n },\n /**\n * Focus on a cell\n */\n focus(row, col, from = null) {\n if (from) row += from.row;\n row = this.getRow(row);\n row && row.focus(col, from);\n }\n }\n};\nComponent.props.itemTag.default = 'tr';\nComponent.props.listTag.default = 'tbody';\n/* harmony default export */ __webpack_exports__[\"default\"] = (Component);\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARows.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -175,7 +185,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _mod \**************************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\");\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../model */ \"./src/model.js\");\n/* harmony import */ var _ARows__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./ARows */ \"./src/components/ARows.vue\");\n/* harmony import */ var _ASelectFile__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./ASelectFile */ \"./src/components/ASelectFile.vue\");\n\n// import {dropRightWhile, cloneDeep, isEqual} from 'lodash'\n\n\n\n//import AFileUpload from \"./AFileUpload\"\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n components: {\n ARows: _ARows__WEBPACK_IMPORTED_MODULE_3__[\"default\"],\n ASelectFile: _ASelectFile__WEBPACK_IMPORTED_MODULE_4__[\"default\"]\n },\n props: {\n // default values of items\n itemDefaults: Object,\n // initial datas\n initData: Object,\n labels: Object,\n soundListUrl: String,\n soundUploadUrl: String,\n soundDeleteUrl: String,\n columns: {\n type: Array,\n default: () => ['name', \"broadcast\"]\n }\n },\n data() {\n return {\n set: new _model__WEBPACK_IMPORTED_MODULE_2__.Set(_model__WEBPACK_IMPORTED_MODULE_2__[\"default\"])\n };\n },\n computed: {\n player_() {\n return this.player || window.aircox.player;\n },\n allColumns() {\n return [\"sound\", ...this.columns, \"delete\"];\n },\n allColumnsLabels() {\n return {\n ...this.labels,\n ...this.initData.fields\n };\n },\n items() {\n return this.set.items;\n },\n rowsSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-') || x.startsWith('rows-')).map(x => [x, x.startsWith('rows-') ? x.slice(5) : x]);\n }\n },\n methods: {\n listItemMove({\n from,\n to,\n set\n }) {\n set.move(from, to);\n },\n /**\n * Load initial data\n */\n loadData({\n items = [] /*, settings=null*/\n }, reset = false) {\n if (reset) {\n this.set.items = [];\n }\n for (var index in items) this.set.push((0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(items[index]));\n // if(settings)\n // this.settingsSaved(settings)\n },\n\n selected(item) {\n const data = {\n ...this.itemDefaults,\n \"sound\": item.id,\n \"name\": item.name,\n \"url\": item.url,\n \"broadcast\": item.broadcast\n };\n this.set.push(data);\n }\n },\n watch: {\n initData(val) {\n this.loadData(val);\n }\n },\n mounted() {\n this.initData && this.loadData(this.initData);\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ASoundListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _AFormSet__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AFormSet */ \"./src/components/AFormSet.vue\");\n/* harmony import */ var _ASelectFile__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./ASelectFile */ \"./src/components/ASelectFile.vue\");\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n components: {\n AFormSet: _AFormSet__WEBPACK_IMPORTED_MODULE_1__[\"default\"],\n ASelectFile: _ASelectFile__WEBPACK_IMPORTED_MODULE_2__[\"default\"]\n },\n props: {\n formData: Object,\n labels: Object,\n // initial datas\n initData: Object,\n soundListUrl: String,\n soundUploadUrl: String,\n soundDeleteUrl: String\n },\n computed: {\n rowsSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-') || x.startsWith('rows-') || x.startsWith('control-')).map(x => [x, x.startsWith('rows-') ? x.slice(5) : x]);\n }\n },\n methods: {\n actionAdd() {\n this.$refs['select-file'].open();\n },\n selected(item) {\n const data = {\n \"sound\": item.id,\n \"name\": item.name,\n \"url\": item.url,\n \"broadcast\": item.broadcast\n };\n this.$refs.formset.set.push(data);\n }\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ASoundListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -215,7 +225,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony default export */ \**************************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Page: function() { return /* binding */ Page; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\");\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../model */ \"./src/model.js\");\n/* harmony import */ var _AActionButton__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./AActionButton */ \"./src/components/AActionButton.vue\");\n/* harmony import */ var _ARow__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./ARow */ \"./src/components/ARow.vue\");\n/* harmony import */ var _ARows__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./ARows */ \"./src/components/ARows.vue\");\n/* harmony import */ var _AModal__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./AModal */ \"./src/components/AModal.vue\");\n\n\n\n\n\n\n\n\n/// Page display\nconst Page = {\n Text: 0,\n List: 1,\n Settings: 2\n};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n components: {\n AActionButton: _AActionButton__WEBPACK_IMPORTED_MODULE_3__[\"default\"],\n ARow: _ARow__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n ARows: _ARows__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n AModal: _AModal__WEBPACK_IMPORTED_MODULE_6__[\"default\"]\n },\n props: {\n ///! initial data as: {items: [], fields: {column_name: label, settings: {}}\n initData: Object,\n dataPrefix: String,\n labels: Object,\n settingsUrl: String,\n defaultColumns: {\n type: Array,\n default: () => ['artist', 'title', 'tags', 'album', 'year', 'timestamp']\n }\n },\n data() {\n const settings = {\n tracklist_editor_columns: this.columns,\n tracklist_editor_sep: ' -- '\n };\n return {\n Page: Page,\n page: Page.Text,\n set: new _model__WEBPACK_IMPORTED_MODULE_2__.Set(_model__WEBPACK_IMPORTED_MODULE_2__[\"default\"]),\n extraData: {},\n settings,\n savedSettings: (0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(settings)\n };\n },\n computed: {\n settingsChanged() {\n var k = Object.keys(this.savedSettings).findIndex(k => !(0,lodash__WEBPACK_IMPORTED_MODULE_1__.isEqual)(this.settings[k], this.savedSettings[k]));\n return k != -1;\n },\n separator: {\n set(value) {\n this.settings.tracklist_editor_sep = value;\n if (this.page == Page.List) this.updateInput();\n },\n get() {\n return this.settings.tracklist_editor_sep;\n }\n },\n allColumns: {\n set(value) {\n var cols = value.filter(x => x in this.defaultColumns);\n var left = this.defaultColumns.filter(x => !(x in cols));\n value = cols.concat(left);\n this.settings.tracklist_editor_columns = value;\n },\n get() {\n return this.settings.tracklist_editor_columns;\n }\n },\n items() {\n return this.set.items;\n },\n rowsSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-') || x.startsWith('rows-')).map(x => [x, x.startsWith('rows-') ? x.slice(5) : x]);\n }\n },\n methods: {\n onCellEvent(event) {\n switch (event.name) {\n case 'change':\n this.updateInput();\n break;\n }\n },\n formatMove({\n from,\n to\n }) {\n const value = this.allColumns[from];\n this.settings.tracklist_editor_columns.splice(from, 1);\n this.settings.tracklist_editor_columns.splice(to, 0, value);\n if (this.page == Page.Text) this.updateList();else this.updateInput();\n },\n columnMove({\n from,\n to\n }) {\n const value = this.allColumns[from];\n this.allColumns.splice(from, 1);\n this.allColumns.splice(to, 0, value);\n this.updateInput();\n },\n listItemMove({\n from,\n to,\n set\n }) {\n set.move(from, to);\n this.updateInput();\n },\n updateList() {\n const items = this.toList(this.$refs.textarea.value);\n this.set.reset(items);\n },\n updateInput() {\n const input = this.toText(this.items);\n this.$refs.textarea.value = input;\n },\n /**\n * From input and separator, return list of items.\n */\n toList(input) {\n var lines = input.split('\\n');\n var items = [];\n for (let line of lines) {\n line = line.trimLeft();\n if (!line) continue;\n var lineBits = line.split(this.separator);\n var item = {};\n for (var col in this.allColumns) {\n if (col >= lineBits.length) break;\n const attr = this.allColumns[col];\n item[attr] = lineBits[col].trim();\n }\n item && items.push(item);\n }\n return items;\n },\n /**\n * From items and separator return a string\n */\n toText(items) {\n const sep = ` ${this.separator.trim()} `;\n const lines = [];\n for (let item of items) {\n if (!item) continue;\n var line = [];\n for (var col of this.allColumns) line.push(item.data[col] || '');\n line = (0,lodash__WEBPACK_IMPORTED_MODULE_1__.dropRightWhile)(line, x => !x || !('' + x).trim());\n line = line.join(sep).trimRight();\n lines.push(line);\n }\n return lines.join('\\n');\n },\n _data_key(key) {\n key = key.slice(this.dataPrefix.length);\n try {\n var [index, attr] = key.split('-', 1);\n return [Number(index), attr];\n } catch (err) {\n return [null, key];\n }\n },\n //! Update saved settings from this.settings\n settingsSaved(settings = null) {\n if (settings !== null) this.settings = settings;\n if (this.$refs.settings) this.$refs.settings.close();\n this.savedSettings = (0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(this.settings);\n },\n /**\n * Load initial data\n */\n loadData({\n items = [],\n settings = null\n }, reset = false) {\n if (reset) {\n this.set.items = [];\n }\n for (var index in items) this.set.push((0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(items[index]));\n if (settings) this.settingsSaved(settings);\n this.updateInput();\n }\n },\n watch: {\n initData(val) {\n this.loadData(val);\n }\n },\n mounted() {\n this.initData && this.loadData(this.initData);\n this.page = this.items.length ? Page.List : Page.Text;\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ATrackListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Page: function() { return /* binding */ Page; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash */ \"./node_modules/lodash/lodash.js\");\n/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _AActionButton__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./AActionButton */ \"./src/components/AActionButton.vue\");\n/* harmony import */ var _AFormSet__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./AFormSet */ \"./src/components/AFormSet.vue\");\n/* harmony import */ var _ARow__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./ARow */ \"./src/components/ARow.vue\");\n/* harmony import */ var _AModal__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./AModal */ \"./src/components/AModal.vue\");\n\n\n\n\n\n\n\n/// Page display\nconst Page = {\n Text: 0,\n List: 1,\n Settings: 2\n};\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n components: {\n AActionButton: _AActionButton__WEBPACK_IMPORTED_MODULE_2__[\"default\"],\n AFormSet: _AFormSet__WEBPACK_IMPORTED_MODULE_3__[\"default\"],\n ARow: _ARow__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n AModal: _AModal__WEBPACK_IMPORTED_MODULE_5__[\"default\"]\n },\n props: {\n formData: Object,\n labels: Object,\n ///! initial data as: {items: [], fields: {column_name: label, settings: {}}\n initData: Object,\n dataPrefix: String,\n settingsUrl: String,\n defaultColumns: {\n type: Array,\n default: () => ['artist', 'title', 'tags', 'album', 'year', 'timestamp']\n }\n },\n data() {\n const settings = {\n // tracklist_editor_columns: this.columns,\n tracklist_editor_sep: ' -- '\n };\n return {\n Page: Page,\n page: Page.Text,\n extraData: {},\n settings,\n savedSettings: (0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(settings)\n };\n },\n computed: {\n rows() {\n return this.$refs.formset && this.$refs.formset.rows;\n },\n columns() {\n return this.rows && this.rows.columns_ || [];\n },\n settingsChanged() {\n var k = Object.keys(this.savedSettings).findIndex(k => !(0,lodash__WEBPACK_IMPORTED_MODULE_1__.isEqual)(this.settings[k], this.savedSettings[k]));\n return k != -1;\n },\n separator: {\n set(value) {\n this.settings.tracklist_editor_sep = value;\n if (this.page == Page.List) this.updateInput();\n },\n get() {\n return this.settings.tracklist_editor_sep;\n }\n },\n rowsSlots() {\n return Object.keys(this.$slots).filter(x => x.startsWith('row-') || x.startsWith('rows-') || x.startsWith('control-')).map(x => [x, x.startsWith('rows-') ? x.slice(5) : x]);\n }\n },\n methods: {\n onCellEvent(event) {\n switch (event.name) {\n case 'change':\n this.updateInput();\n break;\n }\n },\n formatMove({\n from,\n to\n }) {\n this.$refs.formset.rows.columnMove({\n from,\n to\n });\n /*this.settings.tracklist_editor_columns.splice(from, 1)\n this.settings.tracklist_editor_columns.splice(to, 0, value)*/\n },\n\n moveItem({\n from,\n to,\n set\n }) {\n set.move(from, to);\n this.updateInput();\n },\n onColumnMove() {\n if (this.page == this.Page.List) this.updateInput();else this.updateList();\n },\n updateList() {\n const items = this.toList(this.$refs.textarea.value);\n this.$refs.formset.set.reset(items);\n },\n updateInput() {\n const input = this.toText(this.$refs.formset.items);\n this.$refs.textarea.value = input;\n },\n /**\n * From input and separator, return list of items.\n */\n toList(input) {\n const columns = this.$refs.formset.rows.columns_;\n var lines = input.split('\\n');\n var items = [];\n for (let line of lines) {\n line = line.trimLeft();\n if (!line) continue;\n var lineBits = line.split(this.separator);\n var item = {};\n for (var col in columns) {\n if (col >= lineBits.length) break;\n const column = columns[col];\n item[column.name] = lineBits[col].trim();\n }\n item && items.push(item);\n }\n return items;\n },\n /**\n * From items and separator return a string\n */\n toText(items) {\n const columns = this.$refs.formset.rows.columns_;\n const sep = ` ${this.separator.trim()} `;\n const lines = [];\n for (let item of items) {\n if (!item) continue;\n var line = [];\n for (var col of columns) line.push(item.data[col.name] || '');\n line = (0,lodash__WEBPACK_IMPORTED_MODULE_1__.dropRightWhile)(line, x => !x || !('' + x).trim());\n line = line.join(sep).trimRight();\n lines.push(line);\n }\n return lines.join('\\n');\n },\n _data_key(key) {\n key = key.slice(this.dataPrefix.length);\n try {\n var [index, attr] = key.split('-', 1);\n return [Number(index), attr];\n } catch (err) {\n return [null, key];\n }\n },\n //! Update saved settings from this.settings\n settingsSaved(settings = null) {\n if (settings !== null) this.settings = settings;\n if (this.$refs.settings) this.$refs.settings.close();\n this.savedSettings = (0,lodash__WEBPACK_IMPORTED_MODULE_1__.cloneDeep)(this.settings);\n }\n\n /**\n * Load initial data\n */\n /*loadData({items=[], settings=null}, reset=false) {\n if(settings)\n this.settingsSaved(settings)\n this.updateInput()\n },*/\n },\n\n mounted() {\n //this.initData && this.initData.settings &&\n //this.initData && this.loadData(this.initData)\n this.page = this.initData.items.length ? Page.List : Page.Text;\n }\n});\n\n//# sourceURL=webpack://aircox-assets/./src/components/ATrackListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -279,6 +289,16 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac /***/ }), +/***/ "./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=template&id=6138d9e6": +/*!**********************************************************************************************************************************************************************************************************************************************************************!*\ + !*** ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=template&id=6138d9e6 ***! + \**********************************************************************************************************************************************************************************************************************************************************************/ +/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { + +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = [\"name\", \"value\"];\nconst _hoisted_2 = [\"name\", \"value\"];\nconst _hoisted_3 = [\"title\", \"aria-label\", \"aria-description\"];\nconst _hoisted_4 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-arrow-down-1-9\"\n})], -1 /* HOISTED */);\nconst _hoisted_5 = [_hoisted_4];\nconst _hoisted_6 = [\"name\", \"value\"];\nconst _hoisted_7 = [\"name\", \"value\"];\nconst _hoisted_8 = [\"name\", \"value\"];\nconst _hoisted_9 = {\n key: 0\n};\nconst _hoisted_10 = {\n class: \"field\"\n};\nconst _hoisted_11 = {\n class: \"control\"\n};\nconst _hoisted_12 = {\n class: \"align-right pr-0\"\n};\nconst _hoisted_13 = [\"onClick\", \"title\", \"aria-label\"];\nconst _hoisted_14 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-trash\"\n})], -1 /* HOISTED */);\nconst _hoisted_15 = [_hoisted_14];\nconst _hoisted_16 = {\n class: \"a-formset-footer flex-row\"\n};\nconst _hoisted_17 = {\n class: \"flex-grow-1 flex-row\"\n};\nconst _hoisted_18 = {\n class: \"flex-grow-1 align-right\"\n};\nconst _hoisted_19 = [\"title\", \"aria-label\"];\nconst _hoisted_20 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-rotate\"\n})], -1 /* HOISTED */);\nconst _hoisted_21 = [_hoisted_20];\nconst _hoisted_22 = [\"title\", \"aria-label\"];\nconst _hoisted_23 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-plus\"\n})], -1 /* HOISTED */);\nconst _hoisted_24 = [_hoisted_23];\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_rows = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-rows\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"div\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"input\", {\n type: \"hidden\",\n name: $options._prefix + 'TOTAL_FORMS',\n value: $options.items.length || 0\n }, null, 8 /* PROPS */, _hoisted_1), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($props.formData.management, (value, name) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"input\", {\n key: name,\n type: \"hidden\",\n name: $options._prefix + name.toUpperCase(),\n value: value\n }, null, 8 /* PROPS */, _hoisted_2);\n }), 128 /* KEYED_FRAGMENT */)), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_rows, {\n ref: \"rows\",\n set: $data.set,\n columns: $options.visibleFields,\n columnsOrderable: $props.columnsOrderable,\n orderable: $options.orderable,\n onMove: $options.moveItem,\n onColmove: $options.onMoveColumn,\n onCell: _cache[0] || (_cache[0] = e => _ctx.$emit('cell', e))\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n \"header-head\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [$options.orderable ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, {\n key: 0\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"th\", {\n style: {\n \"max-width\": \"2em\"\n },\n title: $options.orderField.label,\n \"aria-label\": $options.orderField.label,\n \"aria-description\": $options.orderField.help || ''\n }, _hoisted_5, 8 /* PROPS */, _hoisted_3), (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"rows-header-head\")], 64 /* STABLE_FRAGMENT */)) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)]),\n \"row-head\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [$options.orderable ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"input\", {\n key: 0,\n type: \"hidden\",\n name: $options._prefix + data.row + '-' + $props.orderBy,\n value: data.row\n }, null, 8 /* PROPS */, _hoisted_6)) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"input\", {\n type: \"hidden\",\n name: $options._prefix + data.row + '-id',\n value: data.item ? data.item.id : ''\n }, null, 8 /* PROPS */, _hoisted_7), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($options.hiddenFields, field => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, {\n key: field.name\n }, [!(field.name in ['id', $props.orderBy]) ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"input\", {\n key: 0,\n type: \"hidden\",\n name: $options._prefix + data.row + '-' + field.name,\n value: field.value in [null, undefined] ? data.item.data[_ctx.name] : field.value\n }, null, 8 /* PROPS */, _hoisted_8)) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)], 64 /* STABLE_FRAGMENT */);\n }), 128 /* KEYED_FRAGMENT */)), (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"row-head\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)), () => [$options.orderable ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"td\", _hoisted_9, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(data.row + 1), 1 /* TEXT */)) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])]),\n \"row-tail\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [_ctx.$slots['row-tail'] ? (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"row-tail\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"td\", _hoisted_12, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square\",\n onClick: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withModifiers)($event => $options.removeItem(data.row, data.item), [\"stop\"]),\n title: $props.labels.remove_item,\n \"aria-label\": $props.labels.remove_item\n }, _hoisted_15, 8 /* PROPS */, _hoisted_13)])]),\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($options.fieldSlots, (field, slot) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, slot, (0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)(data, {\n field: field,\n inputName: $options._prefix + data.cell.row + '-' + field.name\n }), () => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_10, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_11, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, 'control-' + field.name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)(data, {\n field: field,\n inputName: $options._prefix + data.cell.row + '-' + field.name\n }))]), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(data.item.error(field.name), ([error, index]) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"p\", {\n class: \"help is-danger\",\n key: index\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(error), 1 /* TEXT */);\n }), 128 /* KEYED_FRAGMENT */))])])])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"set\", \"columns\", \"columnsOrderable\", \"orderable\", \"onMove\", \"onColmove\"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_16, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_17, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"footer\")]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_18, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square is-warning p-2\",\n onClick: _cache[1] || (_cache[1] = $event => $options.reset()),\n title: $props.labels.discard_changes,\n \"aria-label\": $props.labels.discard_changes\n }, _hoisted_21, 8 /* PROPS */, _hoisted_19), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square is-primary p-2\",\n onClick: _cache[2] || (_cache[2] = (...args) => $options.onActionAdd && $options.onActionAdd(...args)),\n title: $props.labels.add_item,\n \"aria-label\": $props.labels.add_item\n }, _hoisted_24, 8 /* PROPS */, _hoisted_22)])])]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/AFormSet.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); + +/***/ }), + /***/ "./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AList.vue?vue&type=template&id=70c3911f": /*!*******************************************************************************************************************************************************************************************************************************************************************!*\ !*** ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AList.vue?vue&type=template&id=70c3911f ***! @@ -355,7 +375,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac \*******************************************************************************************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = {\n class: \"table is-stripped is-fullwidth\"\n};\nconst _hoisted_2 = {\n key: 1\n};\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_row = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-row\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"table\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"thead\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_row, {\n item: _ctx.labels,\n columns: _ctx.columns,\n orderable: _ctx.orderable,\n onMove: _cache[0] || (_cache[0] = $event => _ctx.$emit('colmove', $event))\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n _: 2 /* DYNAMIC */\n }, [_ctx.$slots['header-head'] ? {\n name: \"head\",\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"header-head\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))]),\n key: \"0\"\n } : undefined, _ctx.$slots['header-tail'] ? {\n name: \"tail\",\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"header-tail\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))]),\n key: \"1\"\n } : undefined]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"item\", \"columns\", \"orderable\"])]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"tbody\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"head\"), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(_ctx.items, (item, row) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, {\n key: row\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\" data-index comes from AList component drag & drop \"), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_row, {\n item: item,\n cell: {\n row\n },\n columns: _ctx.columns,\n \"data-index\": row,\n \"data-row\": row,\n draggable: _ctx.orderable,\n onDragstart: _ctx.onDragStart,\n onDragover: _ctx.onDragOver,\n onDrop: _ctx.onDrop,\n onCell: $event => _ctx.onCellEvent(row, $event)\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(_ctx.rowSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [slot == 'head' || slot == 'tail' ? (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)({\n key: 0\n }, data))) : ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"div\", _hoisted_2, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))]))])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"item\", \"cell\", \"columns\", \"data-index\", \"data-row\", \"draggable\", \"onDragstart\", \"onDragover\", \"onDrop\", \"onCell\"])], 64 /* STABLE_FRAGMENT */);\n }), 128 /* KEYED_FRAGMENT */)), (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"tail\")])]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARows.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = {\n class: \"table is-stripped is-fullwidth\"\n};\nconst _hoisted_2 = [\"title\"];\nconst _hoisted_3 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-circle-question\"\n}, null, -1 /* HOISTED */);\nconst _hoisted_4 = [_hoisted_3];\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_row = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-row\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"table\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"thead\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_row, {\n columns: _ctx.columnNames,\n orderable: _ctx.columnsOrderable,\n cellTag: \"th\",\n onMove: _ctx.moveColumn\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n _: 2 /* DYNAMIC */\n }, [_ctx.$slots['header-head'] ? {\n name: \"head\",\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"header-head\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))]),\n key: \"0\"\n } : undefined, _ctx.$slots['header-tail'] ? {\n name: \"tail\",\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"header-tail\", (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))]),\n key: \"1\"\n } : undefined, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(_ctx.columns, column => {\n return {\n name: column.name,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, 'header-' + column.name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)), () => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createTextVNode)((0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(column.label) + \" \", 1 /* TEXT */), column.help ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"span\", {\n key: 0,\n class: \"icon small\",\n title: column.help\n }, _hoisted_4, 8 /* PROPS */, _hoisted_2)) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"columns\", \"orderable\", \"onMove\"])]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"tbody\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"head\"), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(_ctx.items, (item, row) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, {\n key: row\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\" data-index comes from AList component drag & drop \"), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_row, {\n item: item,\n cell: {\n row\n },\n columns: _ctx.columnNames,\n \"data-index\": row,\n \"data-row\": row,\n draggable: _ctx.orderable,\n onDragstart: _ctx.onDragStart,\n onDragover: _ctx.onDragOver,\n onDrop: _ctx.onDrop,\n onCell: $event => _ctx.onCellEvent(row, $event)\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)(_ctx.rowSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.guardReactiveProps)(data)))])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"item\", \"cell\", \"columns\", \"data-index\", \"data-row\", \"draggable\", \"onDragstart\", \"onDragover\", \"onDrop\", \"onCell\"])], 64 /* STABLE_FRAGMENT */);\n }), 128 /* KEYED_FRAGMENT */)), (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"tail\")])]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ARows.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -385,7 +405,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac \******************************************************************************************************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = {\n class: \"a-playlist-editor\"\n};\nconst _hoisted_2 = [\"src\"];\nconst _hoisted_3 = {\n class: \"label small flex-grow-1\"\n};\nconst _hoisted_4 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"br\", null, null, -1 /* HOISTED */);\nconst _hoisted_5 = [\"src\"];\nconst _hoisted_6 = {\n class: \"flex-row\"\n};\nconst _hoisted_7 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", {\n class: \"flex-grow-1 flex-row\"\n}, null, -1 /* HOISTED */);\nconst _hoisted_8 = {\n class: \"flex-grow-1 align-right\"\n};\nconst _hoisted_9 = [\"title\", \"aria-label\"];\nconst _hoisted_10 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-rotate\"\n})], -1 /* HOISTED */);\nconst _hoisted_11 = [_hoisted_10];\nconst _hoisted_12 = [\"title\", \"aria-label\"];\nconst _hoisted_13 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-plus\"\n})], -1 /* HOISTED */);\nconst _hoisted_14 = [_hoisted_13];\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_select_file = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-select-file\");\n const _component_a_rows = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-rows\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_select_file, {\n ref: \"select-file\",\n title: $props.labels && $props.labels.add_sound,\n labels: $props.labels,\n \"list-url\": $props.soundListUrl,\n deleteUrl: $props.soundDeleteUrl,\n uploadUrl: $props.soundUploadUrl,\n uploadLabel: $props.labels.select_file,\n onSelect: $options.selected\n }, {\n \"upload-preview\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n upload\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"upload-preview\", {\n upload: upload\n })]),\n \"upload-form\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"upload-form\")]),\n default: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n item\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"audio\", {\n controls: \"\",\n src: item.url\n }, null, 8 /* PROPS */, _hoisted_2), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", _hoisted_3, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(item.name), 1 /* TEXT */)]),\n\n _: 3 /* FORWARDED */\n }, 8 /* PROPS */, [\"title\", \"labels\", \"list-url\", \"deleteUrl\", \"uploadUrl\", \"uploadLabel\", \"onSelect\"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"top\", {\n set: $data.set,\n items: $data.set.items\n }), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_rows, {\n set: $data.set,\n columns: $options.allColumns,\n labels: $options.allColumnsLabels,\n \"allow-create\": true,\n orderable: true,\n onMove: $options.listItemMove\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n \"row-sound\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n item\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(item.data.name), 1 /* TEXT */), _hoisted_4, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"audio\", {\n controls: \"\",\n src: item.data.url\n }, null, 8 /* PROPS */, _hoisted_5)]),\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($options.rowsSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [name != 'row-tail' ? (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"set\", \"columns\", \"labels\", \"onMove\"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_6, [_hoisted_7, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_8, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square is-warning p-2\",\n onClick: _cache[0] || (_cache[0] = $event => $options.loadData({\n items: this.initData.items\n }, true)),\n title: $props.labels.discard_changes,\n \"aria-label\": $props.labels.discard_changes\n }, _hoisted_11, 8 /* PROPS */, _hoisted_9), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square is-primary p-2\",\n onClick: _cache[1] || (_cache[1] = $event => _ctx.$refs['select-file'].open()),\n title: $props.labels.add_sound,\n \"aria-label\": $props.labels.add_sound\n }, _hoisted_14, 8 /* PROPS */, _hoisted_12)])])]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ASoundListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = {\n class: \"a-playlist-editor\"\n};\nconst _hoisted_2 = [\"src\"];\nconst _hoisted_3 = {\n class: \"label small flex-grow-1\"\n};\nconst _hoisted_4 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"br\", null, null, -1 /* HOISTED */);\nconst _hoisted_5 = [\"src\"];\nconst _hoisted_6 = [\"name\", \"value\"];\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_select_file = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-select-file\");\n const _component_a_form_set = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-form-set\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_select_file, {\n ref: \"select-file\",\n title: $props.labels && $props.labels.add_sound,\n labels: $props.labels,\n \"list-url\": $props.soundListUrl,\n deleteUrl: $props.soundDeleteUrl,\n uploadUrl: $props.soundUploadUrl,\n uploadLabel: $props.labels.select_file,\n onSelect: $options.selected\n }, {\n \"upload-preview\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n upload\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"upload-preview\", {\n upload: upload\n })]),\n \"upload-form\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"upload-form\")]),\n default: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n item\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"audio\", {\n controls: \"\",\n src: item.url\n }, null, 8 /* PROPS */, _hoisted_2), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", _hoisted_3, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(item.name), 1 /* TEXT */)]),\n\n _: 3 /* FORWARDED */\n }, 8 /* PROPS */, [\"title\", \"labels\", \"list-url\", \"deleteUrl\", \"uploadUrl\", \"uploadLabel\", \"onSelect\"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_form_set, {\n ref: \"formset\",\n \"form-data\": $props.formData,\n labels: $props.labels,\n initials: $props.initData.items,\n \"order-by\": \"position\",\n \"action-add\": $options.actionAdd\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n \"row-sound\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n item,\n inputName\n }) => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)(item.data.name), 1 /* TEXT */), _hoisted_4, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"audio\", {\n controls: \"\",\n src: item.data.url\n }, null, 8 /* PROPS */, _hoisted_5), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"input\", {\n type: \"hidden\",\n name: inputName,\n value: item.data.sound\n }, null, 8 /* PROPS */, _hoisted_6)]),\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($options.rowsSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [name != 'row-tail' ? (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"form-data\", \"labels\", \"initials\", \"action-add\"])]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ASoundListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -425,7 +445,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac \******************************************************************************************************************************************************************************************************************************************************************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\n\nconst _hoisted_1 = {\n class: \"a-tracklist-editor\"\n};\nconst _hoisted_2 = {\n class: \"flex-row\"\n};\nconst _hoisted_3 = {\n class: \"flex-grow-1\"\n};\nconst _hoisted_4 = {\n class: \"flex-row align-right\"\n};\nconst _hoisted_5 = {\n class: \"field has-addons\"\n};\nconst _hoisted_6 = {\n class: \"control\"\n};\nconst _hoisted_7 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-pencil\"\n})], -1 /* HOISTED */);\nconst _hoisted_8 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", null, \"Texte\", -1 /* HOISTED */);\nconst _hoisted_9 = [_hoisted_7, _hoisted_8];\nconst _hoisted_10 = {\n class: \"control\"\n};\nconst _hoisted_11 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-list\"\n})], -1 /* HOISTED */);\nconst _hoisted_12 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", null, \"Liste\", -1 /* HOISTED */);\nconst _hoisted_13 = [_hoisted_11, _hoisted_12];\nconst _hoisted_14 = {\n class: \"panel\"\n};\nconst _hoisted_15 = {\n class: \"panel\"\n};\nconst _hoisted_16 = {\n class: \"align-right pr-0\"\n};\nconst _hoisted_17 = [\"onClick\", \"title\", \"aria-label\"];\nconst _hoisted_18 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-trash\"\n})], -1 /* HOISTED */);\nconst _hoisted_19 = [_hoisted_18];\nconst _hoisted_20 = {\n class: \"flex-row\"\n};\nconst _hoisted_21 = {\n class: \"flex-grow-1 flex-row\"\n};\nconst _hoisted_22 = {\n class: \"field\"\n};\nconst _hoisted_23 = {\n class: \"control\"\n};\nconst _hoisted_24 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-cog\"\n})], -1 /* HOISTED */);\nconst _hoisted_25 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", null, \"Options\", -1 /* HOISTED */);\nconst _hoisted_26 = [_hoisted_24, _hoisted_25];\nconst _hoisted_27 = {\n class: \"flex-grow-1 align-right\"\n};\nconst _hoisted_28 = [\"title\", \"aria-label\"];\nconst _hoisted_29 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-rotate\"\n})], -1 /* HOISTED */);\nconst _hoisted_30 = [_hoisted_29];\nconst _hoisted_31 = [\"title\", \"aria-label\"];\nconst _hoisted_32 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-plus\"\n})], -1 /* HOISTED */);\nconst _hoisted_33 = [_hoisted_32];\nconst _hoisted_34 = {\n class: \"field\"\n};\nconst _hoisted_35 = {\n class: \"label\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_36 = {\n class: \"table is-bordered\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_37 = {\n key: 0,\n style: {\n \"cursor\": \"pointer\"\n }\n};\nconst _hoisted_38 = [\"onClick\"];\nconst _hoisted_39 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"i\", {\n class: \"fa fa-left-right\"\n}, null, -1 /* HOISTED */);\nconst _hoisted_40 = [_hoisted_39];\nconst _hoisted_41 = {\n class: \"flex-row\"\n};\nconst _hoisted_42 = {\n class: \"field is-inline-block is-vcentered flex-grow-1\"\n};\nconst _hoisted_43 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"label\", {\n class: \"label is-inline mr-2\",\n style: {\n \"vertical-align\": \"middle\"\n }\n}, \" Séparateur\", -1 /* HOISTED */);\nconst _hoisted_44 = {\n class: \"control is-inline-block\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_45 = {\n class: \"flex-row align-right\"\n};\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_rows = (0,vue__WEBPACK_IMPORTED_MODULE_1__.resolveComponent)(\"a-rows\");\n const _component_a_row = (0,vue__WEBPACK_IMPORTED_MODULE_1__.resolveComponent)(\"a-row\");\n const _component_a_action_button = (0,vue__WEBPACK_IMPORTED_MODULE_1__.resolveComponent)(\"a-action-button\");\n const _component_a_modal = (0,vue__WEBPACK_IMPORTED_MODULE_1__.resolveComponent)(\"a-modal\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_1__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementBlock)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_2, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_3, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.renderSlot)(_ctx.$slots, \"title\")]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_4, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_5, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"p\", _hoisted_6, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n type: \"button\",\n class: (0,vue__WEBPACK_IMPORTED_MODULE_1__.normalizeClass)(['button', 'p-2', $data.page == $data.Page.Text ? 'is-primary' : 'is-light']),\n onClick: _cache[0] || (_cache[0] = $event => $data.page = $data.Page.Text)\n }, _hoisted_9, 2 /* CLASS */)]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"p\", _hoisted_10, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n type: \"button\",\n class: (0,vue__WEBPACK_IMPORTED_MODULE_1__.normalizeClass)(['button', 'p-2', $data.page == $data.Page.List ? 'is-primary' : 'is-light']),\n onClick: _cache[1] || (_cache[1] = $event => $data.page = $data.Page.List)\n }, _hoisted_13, 2 /* CLASS */)])])])]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.renderSlot)(_ctx.$slots, \"top\", {\n set: $data.set,\n columns: $options.allColumns,\n items: $options.items\n }), (0,vue__WEBPACK_IMPORTED_MODULE_1__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"section\", _hoisted_14, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"textarea\", {\n ref: \"textarea\",\n class: \"is-fullwidth is-size-6\",\n rows: \"20\",\n onChange: _cache[2] || (_cache[2] = (...args) => $options.updateList && $options.updateList(...args))\n }, null, 544 /* HYDRATE_EVENTS, NEED_PATCH */)], 512 /* NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_1__.vShow, $data.page == $data.Page.Text]]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"section\", _hoisted_15, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createVNode)(_component_a_rows, {\n set: $data.set,\n columns: $options.allColumns,\n labels: $props.initData.fields,\n orderable: true,\n onMove: $options.listItemMove,\n onColmove: $options.columnMove,\n onCell: $options.onCellEvent\n }, (0,vue__WEBPACK_IMPORTED_MODULE_1__.createSlots)({\n \"row-tail\": (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(data => [_ctx.$slots['row-tail'] ? (0,vue__WEBPACK_IMPORTED_MODULE_1__.renderSlot)(_ctx.$slots, _ctx.row - _ctx.tail, (0,vue__WEBPACK_IMPORTED_MODULE_1__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_1__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_1__.createCommentVNode)(\"v-if\", true), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"td\", _hoisted_16, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square\",\n onClick: (0,vue__WEBPACK_IMPORTED_MODULE_1__.withModifiers)($event => $options.items.splice(data.row, 1), [\"stop\"]),\n title: $props.labels.remove_item,\n \"aria-label\": $props.labels.remove_item\n }, _hoisted_19, 8 /* PROPS */, _hoisted_17)])]),\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.renderList)($options.rowsSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(data => [name != 'row-tail' ? (0,vue__WEBPACK_IMPORTED_MODULE_1__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_1__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_1__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_1__.createCommentVNode)(\"v-if\", true)])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"set\", \"columns\", \"labels\", \"onMove\", \"onColmove\", \"onCell\"])], 512 /* NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_1__.vShow, $data.page == $data.Page.List]]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_20, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_21, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_22, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"p\", _hoisted_23, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button is-info\",\n onClick: _cache[3] || (_cache[3] = $event => _ctx.$refs.settings.open())\n }, _hoisted_26)])])]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_27, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button square is-warning p-2\",\n onClick: _cache[4] || (_cache[4] = $event => $options.loadData({\n items: this.initData.items\n }, true)),\n title: $props.labels.discard_changes,\n \"aria-label\": $props.labels.discard_changes\n }, _hoisted_30, 8 /* PROPS */, _hoisted_28), $data.page == $data.Page.List ? ((0,vue__WEBPACK_IMPORTED_MODULE_1__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementBlock)(\"button\", {\n key: 0,\n type: \"button\",\n class: \"button square is-primary p-2\",\n onClick: _cache[5] || (_cache[5] = $event => this.set.push(new this.set.model())),\n title: $props.labels.add_item,\n \"aria-label\": $props.labels.add_item\n }, _hoisted_33, 8 /* PROPS */, _hoisted_31)) : (0,vue__WEBPACK_IMPORTED_MODULE_1__.createCommentVNode)(\"v-if\", true)])]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createVNode)(_component_a_modal, {\n ref: \"settings\",\n title: \"Options\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_34, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"label\", _hoisted_35, (0,vue__WEBPACK_IMPORTED_MODULE_1__.toDisplayString)($props.labels.columns), 1 /* TEXT */), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"table\", _hoisted_36, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"tr\", null, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createVNode)(_component_a_row, {\n columns: $options.allColumns,\n item: $props.initData.fields,\n onMove: $options.formatMove,\n orderable: true\n }, {\n \"cell-after\": (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(({\n cell\n }) => [cell.col < $options.allColumns.length - 1 ? ((0,vue__WEBPACK_IMPORTED_MODULE_1__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementBlock)(\"td\", _hoisted_37, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"span\", {\n class: \"icon\",\n onClick: $event => $options.formatMove({\n from: cell.col,\n to: cell.col + 1\n })\n }, _hoisted_40, 8 /* PROPS */, _hoisted_38)])) : (0,vue__WEBPACK_IMPORTED_MODULE_1__.createCommentVNode)(\"v-if\", true)]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"columns\", \"item\", \"onMove\"])])])]), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_41, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_42, [_hoisted_43, (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_44, [(0,vue__WEBPACK_IMPORTED_MODULE_1__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"input\", {\n type: \"text\",\n ref: \"sep\",\n class: \"input is-inline is-text-centered is-small\",\n style: {\n \"max-width\": \"5em\"\n },\n \"onUpdate:modelValue\": _cache[6] || (_cache[6] = $event => $options.separator = $event),\n onChange: _cache[7] || (_cache[7] = $event => $options.updateList())\n }, null, 544 /* HYDRATE_EVENTS, NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_1__.vModelText, $options.separator]])])])])]),\n footer: (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"div\", _hoisted_45, [$options.settingsChanged ? ((0,vue__WEBPACK_IMPORTED_MODULE_1__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createBlock)(_component_a_action_button, {\n key: 0,\n icon: \"fa fa-floppy-disk\",\n class: \"button control p-2 mr-3 is-secondary\",\n \"run-class\": \"blink\",\n url: $props.settingsUrl,\n method: \"POST\",\n data: $data.settings,\n \"aria-label\": $props.labels.save_settings,\n onDone: _cache[8] || (_cache[8] = $event => $options.settingsSaved())\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_1__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_1__.createTextVNode)((0,vue__WEBPACK_IMPORTED_MODULE_1__.toDisplayString)($props.labels.save_settings), 1 /* TEXT */)]),\n\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"url\", \"data\", \"aria-label\"])) : (0,vue__WEBPACK_IMPORTED_MODULE_1__.createCommentVNode)(\"v-if\", true), (0,vue__WEBPACK_IMPORTED_MODULE_1__.createElementVNode)(\"button\", {\n class: \"button\",\n type: \"button\",\n onClick: _cache[9] || (_cache[9] = $event => _ctx.$refs.settings.close())\n }, \" Fermer \")])]),\n _: 1 /* STABLE */\n }, 512 /* NEED_PATCH */), (0,vue__WEBPACK_IMPORTED_MODULE_1__.renderSlot)(_ctx.$slots, \"bottom\", {\n set: $data.set,\n columns: $options.allColumns,\n items: $options.items\n })]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ATrackListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vue */ \"./node_modules/vue/dist/vue.esm-bundler.js\");\n\nconst _hoisted_1 = {\n class: \"a-tracklist-editor\"\n};\nconst _hoisted_2 = {\n class: \"flex-row\"\n};\nconst _hoisted_3 = {\n class: \"flex-grow-1\"\n};\nconst _hoisted_4 = {\n class: \"flex-row align-right\"\n};\nconst _hoisted_5 = {\n class: \"field has-addons\"\n};\nconst _hoisted_6 = {\n class: \"control\"\n};\nconst _hoisted_7 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-pencil\"\n})], -1 /* HOISTED */);\nconst _hoisted_8 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", null, \"Texte\", -1 /* HOISTED */);\nconst _hoisted_9 = [_hoisted_7, _hoisted_8];\nconst _hoisted_10 = {\n class: \"control\"\n};\nconst _hoisted_11 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-list\"\n})], -1 /* HOISTED */);\nconst _hoisted_12 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", null, \"Liste\", -1 /* HOISTED */);\nconst _hoisted_13 = [_hoisted_11, _hoisted_12];\nconst _hoisted_14 = {\n class: \"panel\"\n};\nconst _hoisted_15 = {\n class: \"panel\"\n};\nconst _hoisted_16 = {\n class: \"field\"\n};\nconst _hoisted_17 = {\n class: \"control\"\n};\nconst _hoisted_18 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon is-small\"\n}, [/*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-cog\"\n})], -1 /* HOISTED */);\nconst _hoisted_19 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", null, \"Options\", -1 /* HOISTED */);\nconst _hoisted_20 = [_hoisted_18, _hoisted_19];\nconst _hoisted_21 = {\n class: \"field\"\n};\nconst _hoisted_22 = {\n class: \"label\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_23 = {\n class: \"table is-bordered\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_24 = {\n key: 0\n};\nconst _hoisted_25 = {\n key: 0,\n style: {\n \"cursor\": \"pointer\"\n }\n};\nconst _hoisted_26 = [\"onClick\"];\nconst _hoisted_27 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"i\", {\n class: \"fa fa-left-right\"\n}, null, -1 /* HOISTED */);\nconst _hoisted_28 = [_hoisted_27];\nconst _hoisted_29 = {\n class: \"flex-row\"\n};\nconst _hoisted_30 = {\n class: \"field is-inline-block is-vcentered flex-grow-1\"\n};\nconst _hoisted_31 = /*#__PURE__*/(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", {\n class: \"label is-inline mr-2\",\n style: {\n \"vertical-align\": \"middle\"\n }\n}, \" Séparateur\", -1 /* HOISTED */);\nconst _hoisted_32 = {\n class: \"control is-inline-block\",\n style: {\n \"vertical-align\": \"middle\"\n }\n};\nconst _hoisted_33 = {\n class: \"flex-row align-right\"\n};\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_a_form_set = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-form-set\");\n const _component_a_row = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-row\");\n const _component_a_action_button = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-action-button\");\n const _component_a_modal = (0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveComponent)(\"a-modal\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_2, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_3, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, \"title\")]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_4, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_5, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"p\", _hoisted_6, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeClass)(['button', 'p-2', $data.page == $data.Page.Text ? 'is-primary' : 'is-light']),\n onClick: _cache[0] || (_cache[0] = $event => $data.page = $data.Page.Text)\n }, _hoisted_9, 2 /* CLASS */)]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"p\", _hoisted_10, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeClass)(['button', 'p-2', $data.page == $data.Page.List ? 'is-primary' : 'is-light']),\n onClick: _cache[1] || (_cache[1] = $event => $data.page = $data.Page.List)\n }, _hoisted_13, 2 /* CLASS */)])])])]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"section\", _hoisted_14, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"textarea\", {\n ref: \"textarea\",\n class: \"is-fullwidth is-size-6\",\n rows: \"20\",\n onChange: _cache[2] || (_cache[2] = (...args) => $options.updateList && $options.updateList(...args))\n }, null, 544 /* HYDRATE_EVENTS, NEED_PATCH */)], 512 /* NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_0__.vShow, $data.page == $data.Page.Text]]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"section\", _hoisted_15, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_form_set, {\n ref: \"formset\",\n \"form-data\": $props.formData,\n initials: $props.initData.items,\n columnsOrderable: true,\n labels: $props.labels,\n \"order-by\": \"position\",\n onLoad: $options.updateInput,\n onColmove: $options.updateInput,\n onMove: $options.updateInput,\n onCell: $options.onCellEvent\n }, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createSlots)({\n footer: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_16, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"p\", _hoisted_17, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n type: \"button\",\n class: \"button is-info\",\n onClick: _cache[3] || (_cache[3] = $event => _ctx.$refs.settings.open())\n }, _hoisted_20)])])]),\n _: 2 /* DYNAMIC */\n }, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($options.rowsSlots, ([name, slot]) => {\n return {\n name: slot,\n fn: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(data => [name != 'row-tail' ? (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderSlot)(_ctx.$slots, name, (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeProps)((0,vue__WEBPACK_IMPORTED_MODULE_0__.mergeProps)({\n key: 0\n }, data))) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])\n };\n })]), 1032 /* PROPS, DYNAMIC_SLOTS */, [\"form-data\", \"initials\", \"labels\", \"onLoad\", \"onColmove\", \"onMove\", \"onCell\"])], 512 /* NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_0__.vShow, $data.page == $data.Page.List]]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_modal, {\n ref: \"settings\",\n title: \"Options\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_21, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"label\", _hoisted_22, (0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)($props.labels.columns), 1 /* TEXT */), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"table\", _hoisted_23, [_ctx.$refs.formset ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"tr\", _hoisted_24, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_a_row, {\n columns: _ctx.$refs.formset.rows.columnNames,\n item: _ctx.$refs.formset.rows.columnLabels,\n onMove: _ctx.$refs.formset.rows.moveColumn\n }, {\n \"cell-after\": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(({\n cell\n }) => [cell.col < _ctx.$refs.formset.rows.columns_.length - 1 ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(\"td\", _hoisted_25, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"span\", {\n class: \"icon\",\n onClick: $event => _ctx.$refs.formset.rows.moveColumn({\n from: cell.col,\n to: cell.col + 1\n })\n }, _hoisted_28, 8 /* PROPS */, _hoisted_26)])) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"columns\", \"item\", \"onMove\"])])) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true)])]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_29, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_30, [_hoisted_31, (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_32, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.withDirectives)((0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"input\", {\n type: \"text\",\n ref: \"sep\",\n class: \"input is-inline is-text-centered is-small\",\n style: {\n \"max-width\": \"5em\"\n },\n \"onUpdate:modelValue\": _cache[4] || (_cache[4] = $event => $options.separator = $event),\n onChange: _cache[5] || (_cache[5] = $event => $options.updateList())\n }, null, 544 /* HYDRATE_EVENTS, NEED_PATCH */), [[vue__WEBPACK_IMPORTED_MODULE_0__.vModelText, $options.separator]])])])])]),\n footer: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"div\", _hoisted_33, [$options.settingsChanged ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createBlock)(_component_a_action_button, {\n key: 0,\n icon: \"fa fa-floppy-disk\",\n class: \"button control p-2 mr-3 is-secondary\",\n \"run-class\": \"blink\",\n url: $props.settingsUrl,\n method: \"POST\",\n data: $data.settings,\n \"aria-label\": $props.labels.save_settings,\n onDone: _cache[6] || (_cache[6] = $event => $options.settingsSaved())\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createTextVNode)((0,vue__WEBPACK_IMPORTED_MODULE_0__.toDisplayString)($props.labels.save_settings), 1 /* TEXT */)]),\n\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"url\", \"data\", \"aria-label\"])) : (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(\"v-if\", true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)(\"button\", {\n class: \"button\",\n type: \"button\",\n onClick: _cache[7] || (_cache[7] = $event => _ctx.$refs.settings.close())\n }, \" Fermer \")])]),\n _: 1 /* STABLE */\n }, 512 /* NEED_PATCH */)]);\n}\n\n//# sourceURL=webpack://aircox-assets/./src/components/ATrackListEditor.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D"); /***/ }), @@ -445,7 +465,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac \*********************************/ /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { -eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ admin: function() { return /* binding */ admin; },\n/* harmony export */ base: function() { return /* binding */ base; },\n/* harmony export */ dashboard: function() { return /* binding */ dashboard; }\n/* harmony export */ });\n/* harmony import */ var _AActionButton__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AActionButton */ \"./src/components/AActionButton.vue\");\n/* harmony import */ var _AAutocomplete__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AAutocomplete */ \"./src/components/AAutocomplete.vue\");\n/* harmony import */ var _ACarousel__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./ACarousel */ \"./src/components/ACarousel.vue\");\n/* harmony import */ var _ADropdown__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./ADropdown */ \"./src/components/ADropdown.vue\");\n/* harmony import */ var _AEpisode__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./AEpisode */ \"./src/components/AEpisode.vue\");\n/* harmony import */ var _AList__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./AList */ \"./src/components/AList.vue\");\n/* harmony import */ var _APage__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./APage */ \"./src/components/APage.vue\");\n/* harmony import */ var _APlayer__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./APlayer */ \"./src/components/APlayer.vue\");\n/* harmony import */ var _APlaylist__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./APlaylist */ \"./src/components/APlaylist.vue\");\n/* harmony import */ var _AProgress__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./AProgress */ \"./src/components/AProgress.vue\");\n/* harmony import */ var _ASoundItem__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./ASoundItem */ \"./src/components/ASoundItem.vue\");\n/* harmony import */ var _ASwitch__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./ASwitch */ \"./src/components/ASwitch.vue\");\n/* harmony import */ var _AModal__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./AModal */ \"./src/components/AModal.vue\");\n/* harmony import */ var _AFileUpload__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./AFileUpload */ \"./src/components/AFileUpload.vue\");\n/* harmony import */ var _ASelectFile__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./ASelectFile */ \"./src/components/ASelectFile.vue\");\n/* harmony import */ var _AStatistics__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./AStatistics */ \"./src/components/AStatistics.vue\");\n/* harmony import */ var _AStreamer__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./AStreamer */ \"./src/components/AStreamer.vue\");\n/* harmony import */ var _ATrackListEditor__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./ATrackListEditor */ \"./src/components/ATrackListEditor.vue\");\n/* harmony import */ var _ASoundListEditor__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./ASoundListEditor */ \"./src/components/ASoundListEditor.vue\");\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n/**\n * Core components\n */\nconst base = {\n AAutocomplete: _AAutocomplete__WEBPACK_IMPORTED_MODULE_1__[\"default\"],\n ACarousel: _ACarousel__WEBPACK_IMPORTED_MODULE_2__[\"default\"],\n ADropdown: _ADropdown__WEBPACK_IMPORTED_MODULE_3__[\"default\"],\n AEpisode: _AEpisode__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n AList: _AList__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n APage: _APage__WEBPACK_IMPORTED_MODULE_6__[\"default\"],\n APlayer: _APlayer__WEBPACK_IMPORTED_MODULE_7__[\"default\"],\n APlaylist: _APlaylist__WEBPACK_IMPORTED_MODULE_8__[\"default\"],\n AProgress: _AProgress__WEBPACK_IMPORTED_MODULE_9__[\"default\"],\n ASoundItem: _ASoundItem__WEBPACK_IMPORTED_MODULE_10__[\"default\"],\n ASwitch: _ASwitch__WEBPACK_IMPORTED_MODULE_11__[\"default\"]\n};\n/* harmony default export */ __webpack_exports__[\"default\"] = (base);\nconst admin = {\n ...base,\n AStatistics: _AStatistics__WEBPACK_IMPORTED_MODULE_15__[\"default\"],\n AStreamer: _AStreamer__WEBPACK_IMPORTED_MODULE_16__[\"default\"],\n ATrackListEditor: _ATrackListEditor__WEBPACK_IMPORTED_MODULE_17__[\"default\"]\n};\nconst dashboard = {\n ...base,\n AActionButton: _AActionButton__WEBPACK_IMPORTED_MODULE_0__[\"default\"],\n AFileUpload: _AFileUpload__WEBPACK_IMPORTED_MODULE_13__[\"default\"],\n ASelectFile: _ASelectFile__WEBPACK_IMPORTED_MODULE_14__[\"default\"],\n AModal: _AModal__WEBPACK_IMPORTED_MODULE_12__[\"default\"],\n ATrackListEditor: _ATrackListEditor__WEBPACK_IMPORTED_MODULE_17__[\"default\"],\n ASoundListEditor: _ASoundListEditor__WEBPACK_IMPORTED_MODULE_18__[\"default\"]\n};\n\n//# sourceURL=webpack://aircox-assets/./src/components/index.js?"); +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ admin: function() { return /* binding */ admin; },\n/* harmony export */ base: function() { return /* binding */ base; },\n/* harmony export */ dashboard: function() { return /* binding */ dashboard; }\n/* harmony export */ });\n/* harmony import */ var _AActionButton__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AActionButton */ \"./src/components/AActionButton.vue\");\n/* harmony import */ var _AAutocomplete__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AAutocomplete */ \"./src/components/AAutocomplete.vue\");\n/* harmony import */ var _ACarousel__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./ACarousel */ \"./src/components/ACarousel.vue\");\n/* harmony import */ var _ADropdown__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./ADropdown */ \"./src/components/ADropdown.vue\");\n/* harmony import */ var _AEpisode__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./AEpisode */ \"./src/components/AEpisode.vue\");\n/* harmony import */ var _AList__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./AList */ \"./src/components/AList.vue\");\n/* harmony import */ var _APage__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./APage */ \"./src/components/APage.vue\");\n/* harmony import */ var _APlayer__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./APlayer */ \"./src/components/APlayer.vue\");\n/* harmony import */ var _APlaylist__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./APlaylist */ \"./src/components/APlaylist.vue\");\n/* harmony import */ var _AProgress__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./AProgress */ \"./src/components/AProgress.vue\");\n/* harmony import */ var _ASoundItem__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./ASoundItem */ \"./src/components/ASoundItem.vue\");\n/* harmony import */ var _ASwitch__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./ASwitch */ \"./src/components/ASwitch.vue\");\n/* harmony import */ var _AModal__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./AModal */ \"./src/components/AModal.vue\");\n/* harmony import */ var _AFileUpload__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./AFileUpload */ \"./src/components/AFileUpload.vue\");\n/* harmony import */ var _ASelectFile__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./ASelectFile */ \"./src/components/ASelectFile.vue\");\n/* harmony import */ var _AStatistics__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./AStatistics */ \"./src/components/AStatistics.vue\");\n/* harmony import */ var _AStreamer__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./AStreamer */ \"./src/components/AStreamer.vue\");\n/* harmony import */ var _AFormSet__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./AFormSet */ \"./src/components/AFormSet.vue\");\n/* harmony import */ var _ATrackListEditor__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./ATrackListEditor */ \"./src/components/ATrackListEditor.vue\");\n/* harmony import */ var _ASoundListEditor__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./ASoundListEditor */ \"./src/components/ASoundListEditor.vue\");\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n/**\n * Core components\n */\nconst base = {\n AAutocomplete: _AAutocomplete__WEBPACK_IMPORTED_MODULE_1__[\"default\"],\n ACarousel: _ACarousel__WEBPACK_IMPORTED_MODULE_2__[\"default\"],\n ADropdown: _ADropdown__WEBPACK_IMPORTED_MODULE_3__[\"default\"],\n AEpisode: _AEpisode__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n AList: _AList__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n APage: _APage__WEBPACK_IMPORTED_MODULE_6__[\"default\"],\n APlayer: _APlayer__WEBPACK_IMPORTED_MODULE_7__[\"default\"],\n APlaylist: _APlaylist__WEBPACK_IMPORTED_MODULE_8__[\"default\"],\n AProgress: _AProgress__WEBPACK_IMPORTED_MODULE_9__[\"default\"],\n ASoundItem: _ASoundItem__WEBPACK_IMPORTED_MODULE_10__[\"default\"],\n ASwitch: _ASwitch__WEBPACK_IMPORTED_MODULE_11__[\"default\"]\n};\n/* harmony default export */ __webpack_exports__[\"default\"] = (base);\nconst admin = {\n ...base,\n AStatistics: _AStatistics__WEBPACK_IMPORTED_MODULE_15__[\"default\"],\n AStreamer: _AStreamer__WEBPACK_IMPORTED_MODULE_16__[\"default\"],\n ATrackListEditor: _ATrackListEditor__WEBPACK_IMPORTED_MODULE_18__[\"default\"]\n};\nconst dashboard = {\n ...base,\n AActionButton: _AActionButton__WEBPACK_IMPORTED_MODULE_0__[\"default\"],\n AFileUpload: _AFileUpload__WEBPACK_IMPORTED_MODULE_13__[\"default\"],\n ASelectFile: _ASelectFile__WEBPACK_IMPORTED_MODULE_14__[\"default\"],\n AModal: _AModal__WEBPACK_IMPORTED_MODULE_12__[\"default\"],\n AFormSet: _AFormSet__WEBPACK_IMPORTED_MODULE_17__[\"default\"],\n ATrackListEditor: _ATrackListEditor__WEBPACK_IMPORTED_MODULE_18__[\"default\"],\n ASoundListEditor: _ASoundListEditor__WEBPACK_IMPORTED_MODULE_19__[\"default\"]\n};\n\n//# sourceURL=webpack://aircox-assets/./src/components/index.js?"); /***/ }), @@ -619,6 +639,16 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _AFi /***/ }), +/***/ "./src/components/AFormSet.vue": +/*!*************************************!*\ + !*** ./src/components/AFormSet.vue ***! + \*************************************/ +/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { + +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _AFormSet_vue_vue_type_template_id_6138d9e6__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AFormSet.vue?vue&type=template&id=6138d9e6 */ \"./src/components/AFormSet.vue?vue&type=template&id=6138d9e6\");\n/* harmony import */ var _AFormSet_vue_vue_type_script_lang_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AFormSet.vue?vue&type=script&lang=js */ \"./src/components/AFormSet.vue?vue&type=script&lang=js\");\n/* harmony import */ var _home_data_code_projets_aircox_assets_node_modules_vue_loader_dist_exportHelper_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./node_modules/vue-loader/dist/exportHelper.js */ \"./node_modules/vue-loader/dist/exportHelper.js\");\n\n\n\n\n;\nconst __exports__ = /*#__PURE__*/(0,_home_data_code_projets_aircox_assets_node_modules_vue_loader_dist_exportHelper_js__WEBPACK_IMPORTED_MODULE_2__[\"default\"])(_AFormSet_vue_vue_type_script_lang_js__WEBPACK_IMPORTED_MODULE_1__[\"default\"], [['render',_AFormSet_vue_vue_type_template_id_6138d9e6__WEBPACK_IMPORTED_MODULE_0__.render],['__file',\"src/components/AFormSet.vue\"]])\n/* hot reload */\nif (false) {}\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = (__exports__);\n\n//# sourceURL=webpack://aircox-assets/./src/components/AFormSet.vue?"); + +/***/ }), + /***/ "./src/components/AList.vue": /*!**********************************!*\ !*** ./src/components/AList.vue ***! @@ -829,6 +859,16 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac /***/ }), +/***/ "./src/components/AFormSet.vue?vue&type=script&lang=js": +/*!*************************************************************!*\ + !*** ./src/components/AFormSet.vue?vue&type=script&lang=js ***! + \*************************************************************/ +/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { + +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": function() { return /* reexport safe */ _node_modules_babel_loader_lib_index_js_clonedRuleSet_40_use_0_node_modules_vue_loader_dist_index_js_ruleSet_0_use_0_AFormSet_vue_vue_type_script_lang_js__WEBPACK_IMPORTED_MODULE_0__[\"default\"]; }\n/* harmony export */ });\n/* harmony import */ var _node_modules_babel_loader_lib_index_js_clonedRuleSet_40_use_0_node_modules_vue_loader_dist_index_js_ruleSet_0_use_0_AFormSet_vue_vue_type_script_lang_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./AFormSet.vue?vue&type=script&lang=js */ \"./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=script&lang=js\");\n \n\n//# sourceURL=webpack://aircox-assets/./src/components/AFormSet.vue?"); + +/***/ }), + /***/ "./src/components/AList.vue?vue&type=script&lang=js": /*!**********************************************************!*\ !*** ./src/components/AList.vue?vue&type=script&lang=js ***! @@ -1039,6 +1079,16 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac /***/ }), +/***/ "./src/components/AFormSet.vue?vue&type=template&id=6138d9e6": +/*!*******************************************************************!*\ + !*** ./src/components/AFormSet.vue?vue&type=template&id=6138d9e6 ***! + \*******************************************************************/ +/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) { + +eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* reexport safe */ _node_modules_babel_loader_lib_index_js_clonedRuleSet_40_use_0_node_modules_vue_loader_dist_templateLoader_js_ruleSet_1_rules_3_node_modules_vue_loader_dist_index_js_ruleSet_0_use_0_AFormSet_vue_vue_type_template_id_6138d9e6__WEBPACK_IMPORTED_MODULE_0__.render; }\n/* harmony export */ });\n/* harmony import */ var _node_modules_babel_loader_lib_index_js_clonedRuleSet_40_use_0_node_modules_vue_loader_dist_templateLoader_js_ruleSet_1_rules_3_node_modules_vue_loader_dist_index_js_ruleSet_0_use_0_AFormSet_vue_vue_type_template_id_6138d9e6__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!../../node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./AFormSet.vue?vue&type=template&id=6138d9e6 */ \"./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/AFormSet.vue?vue&type=template&id=6138d9e6\");\n\n\n//# sourceURL=webpack://aircox-assets/./src/components/AFormSet.vue?"); + +/***/ }), + /***/ "./src/components/AList.vue?vue&type=template&id=70c3911f": /*!****************************************************************!*\ !*** ./src/components/AList.vue?vue&type=template&id=70c3911f ***! diff --git a/aircox/templates/aircox/dashboard/list_editor.html b/aircox/templates/aircox/dashboard/list_editor.html index 7ec60f5..d64e4b4 100644 --- a/aircox/templates/aircox/dashboard/list_editor.html +++ b/aircox/templates/aircox/dashboard/list_editor.html @@ -7,6 +7,7 @@ Context: - related_field: field name that target object - object: related object - formset: formset used to render the list editor +- formset_data: formset data {% endcomment %} {% load aircox aircox_admin static i18n %} @@ -19,6 +20,7 @@ Context: <{{ tag }} {% block tag-attrs %} + :form-data="{{ formset_data|json }}" :labels="window.aircox.labels" :init-data="{% formset_inline_data formset=formset %}" :columns="[{% for n, f in fields.items %}{% if not f.widget.is_hidden %}'{{ n }}',{% endif %}{% endfor %} ]" @@ -26,19 +28,6 @@ Context: data-prefix="{{ formset.prefix }}-" {% endblock %}> {% block inner %} - - {% for name, field in fields.items %} - {% if name != related_field and not field.widget.is_hidden and not field.is_readonly %} -