diff --git a/ietf/doc/templatetags/active_groups_menu.py b/ietf/doc/templatetags/active_groups_menu.py index af8f268eb..c60d6dcd1 100644 --- a/ietf/doc/templatetags/active_groups_menu.py +++ b/ietf/doc/templatetags/active_groups_menu.py @@ -11,7 +11,7 @@ register = template.Library() @register.simple_tag def active_groups_menu(flavor): - parents = GroupTypeName.objects.filter(slug__in=["ag", "area", "rag", "team", "dir", "program"]) + parents = GroupTypeName.objects.filter(slug__in=["ag", "area", "rag", "team", "dir", "program", "iabworkshop"]) others = [] for group in Group.objects.filter(acronym__in=("rsoc",), state_id="active"): group.menu_url = reverse("ietf.group.views.group_home", kwargs=dict(acronym=group.acronym)) # type: ignore @@ -23,4 +23,4 @@ def active_groups_menu(flavor): return render_to_string( "base/menu_active_groups.html", {"parents": parents, "others": others, "flavor": flavor}, - ) \ No newline at end of file + ) diff --git a/ietf/group/migrations/0003_iabworkshops.py b/ietf/group/migrations/0003_iabworkshops.py new file mode 100644 index 000000000..c8d175a10 --- /dev/null +++ b/ietf/group/migrations/0003_iabworkshops.py @@ -0,0 +1,34 @@ +# Copyright The IETF Trust 2023, All Rights Reserved + +from django.db import migrations + +def forward(apps, schema_editor): + GroupFeatures = apps.get_model("group", "GroupFeatures") + GroupTypeName = apps.get_model("name", "GroupTypeName") + + iabworkshop = GroupFeatures.objects.create( + type_id="iabworkshop", + need_parent=True, + default_parent="iab", + has_documents=True, + has_session_materials=True, + has_meetings=True, + has_default_chat=True, + session_purposes='["regular"]', + ) + iabworkshop.parent_types.add(GroupTypeName.objects.get(slug="ietf")) + + +def reverse(apps, schema_editor): + GroupFeatures = apps.get_model("group", "GroupFeatures") + GroupFeatures.objects.filter(type="iabworkshop").delete() + +class Migration(migrations.Migration): + dependencies = [ + ("group", "0002_appeal"), + ("name", "0009_iabworkshops"), + ] + + operations = [ + migrations.RunPython(forward, reverse) + ] diff --git a/ietf/group/tests_info.py b/ietf/group/tests_info.py index 136e19549..39a1e69e2 100644 --- a/ietf/group/tests_info.py +++ b/ietf/group/tests_info.py @@ -71,7 +71,7 @@ class GroupPagesTests(TestCase): self.assertContains(r, group.name) self.assertContains(r, escape(group.ad_role().person.name)) - for t in ('rg','area','ag', 'rag', 'dir','review','team','program','iabasg','adm','rfcedtyp'): # See issue 5120 + for t in ('rg','area','ag', 'rag', 'dir','review','team','program','iabasg','iabworkshop','adm','rfcedtyp'): # See issue 5120 g = GroupFactory.create(type_id=t,state_id='active') if t in ['dir','review']: g.parent = GroupFactory.create(type_id='area',state_id='active') @@ -87,7 +87,7 @@ class GroupPagesTests(TestCase): self.assertContains(r, "Directorate") self.assertContains(r, "AG") - for slug in GroupTypeName.objects.exclude(slug__in=['wg','rg','ag','rag','area','dir','review','team','program','adhoc','ise','adm','iabasg','rfcedtyp', 'edwg', 'edappr']).values_list('slug',flat=True): + for slug in GroupTypeName.objects.exclude(slug__in=['wg','rg','ag','rag','area','dir','review','team','program','adhoc','ise','adm','iabasg','iabworkshop','rfcedtyp', 'edwg', 'edappr']).values_list('slug',flat=True): with self.assertRaises(NoReverseMatch): url=urlreverse('ietf.group.views.active_groups', kwargs=dict(group_type=slug)) diff --git a/ietf/group/views.py b/ietf/group/views.py index 593c649bb..129247455 100644 --- a/ietf/group/views.py +++ b/ietf/group/views.py @@ -291,7 +291,7 @@ def active_groups(request, group_type=None): return active_dirs(request) elif group_type == "review": return active_review_dirs(request) - elif group_type in ("program", "iabasg"): + elif group_type in ("program", "iabasg","iabworkshop"): return active_iab(request) elif group_type == "adm": return active_adm(request) @@ -314,6 +314,7 @@ def active_group_types(request): "area", "program", "iabasg", + "iabworkshop" "adm", ] ) @@ -344,7 +345,7 @@ def active_teams(request): return render(request, 'group/active_teams.html', {'teams' : teams }) def active_iab(request): - iabgroups = Group.objects.filter(type__in=("program","iabasg"), state="active").order_by("-type_id","name") + iabgroups = Group.objects.filter(type__in=("program","iabasg","iabworkshop"), state="active").order_by("-type_id","name") for group in iabgroups: group.leads = sorted(roles(group, "lead"), key=extract_last_name) return render(request, 'group/active_iabgroups.html', {'iabgroups' : iabgroups }) @@ -1335,7 +1336,7 @@ def stream_edit(request, acronym): @cache_control(public=True, max_age=30*60) @cache_page(30 * 60) def group_menu_data(request): - groups = Group.objects.filter(state="active", parent__state="active").filter(Q(type__features__acts_like_wg=True)|Q(type_id__in=['program','iabasg'])|Q(parent__acronym='ietfadminllc')|Q(parent__acronym='rfceditor')).order_by("-type_id","acronym") + groups = Group.objects.filter(state="active", parent__state="active").filter(Q(type__features__acts_like_wg=True)|Q(type_id__in=['program','iabasg','iabworkshop'])|Q(parent__acronym='ietfadminllc')|Q(parent__acronym='rfceditor')).order_by("-type_id","acronym") groups_by_parent = defaultdict(list) for g in groups: diff --git a/ietf/name/fixtures/names.json b/ietf/name/fixtures/names.json index 4dfe1574a..a039af3c4 100644 --- a/ietf/name/fixtures/names.json +++ b/ietf/name/fixtures/names.json @@ -3123,6 +3123,45 @@ "model": "group.groupfeatures", "pk": "iabasg" }, + { + "fields": { + "about_page": "ietf.group.views.group_about", + "acts_like_wg": false, + "admin_roles": "[\n \"chair\"\n]", + "agenda_filter_type": "none", + "agenda_type": "ietf", + "create_wiki": false, + "custom_group_roles": false, + "customize_workflow": false, + "default_parent": "iab", + "default_tab": "ietf.group.views.group_about", + "default_used_roles": "[]", + "docman_roles": "[\n \"ad\",\n \"chair\",\n \"delegate\",\n \"secr\"\n]", + "groupman_authroles": "[\n \"Secretariat\"\n]", + "groupman_roles": "[\n \"ad\",\n \"chair\"\n]", + "has_chartering_process": false, + "has_default_chat": true, + "has_documents": true, + "has_meetings": true, + "has_milestones": false, + "has_nonsession_materials": false, + "has_reviews": false, + "has_session_materials": true, + "is_schedulable": false, + "material_types": "[\n \"slides\"\n]", + "matman_roles": "[\n \"ad\",\n \"chair\",\n \"delegate\",\n \"secr\"\n]", + "need_parent": true, + "parent_types": [ + "ietf" + ], + "req_subm_approval": false, + "role_order": "[\n \"chair\",\n \"secr\",\n \"member\"\n]", + "session_purposes": "\"[\\\"regular\\\"]\"", + "show_on_agenda": false + }, + "model": "group.groupfeatures", + "pk": "iabworkshop" + }, { "fields": { "about_page": "ietf.group.views.group_about", @@ -5054,6 +5093,21 @@ "model": "mailtrigger.mailtrigger", "pk": "review_completed_httpdir_early" }, + { + "fields": { + "cc": [ + "ietf_last_call", + "review_doc_all_parties", + "review_doc_group_mail_list" + ], + "desc": "Recipients when a httpdir Last Call review is completed", + "to": [ + "review_team_mail_list" + ] + }, + "model": "mailtrigger.mailtrigger", + "pk": "review_completed_httpdir_lc" + }, { "fields": { "cc": [ @@ -11530,6 +11584,17 @@ "model": "name.grouptypename", "pk": "iabasg" }, + { + "fields": { + "desc": "IAB Workshop", + "name": "IAB Workshop", + "order": 0, + "used": true, + "verbose_name": "IAB Workshop" + }, + "model": "name.grouptypename", + "pk": "iabworkshop" + }, { "fields": { "desc": "", @@ -16562,7 +16627,7 @@ "fields": { "command": "xym", "switch": "--version", - "time": "2023-08-22T07:09:39.542Z", + "time": "2023-11-21T08:09:45.989Z", "used": true, "version": "xym 0.7.0" }, @@ -16573,9 +16638,9 @@ "fields": { "command": "pyang", "switch": "--version", - "time": "2023-08-22T07:09:39.881Z", + "time": "2023-11-21T08:09:46.322Z", "used": true, - "version": "pyang 2.5.3" + "version": "pyang 2.6.0" }, "model": "utils.versioninfo", "pk": 2 @@ -16584,7 +16649,7 @@ "fields": { "command": "yanglint", "switch": "--version", - "time": "2023-08-22T07:09:39.899Z", + "time": "2023-11-21T08:09:46.338Z", "used": true, "version": "yanglint SO 1.9.2" }, @@ -16595,9 +16660,9 @@ "fields": { "command": "xml2rfc", "switch": "--version", - "time": "2023-08-22T07:09:40.791Z", + "time": "2023-11-21T08:09:47.251Z", "used": true, - "version": "xml2rfc 3.18.0" + "version": "xml2rfc 3.18.2" }, "model": "utils.versioninfo", "pk": 4 diff --git a/ietf/name/migrations/0009_iabworkshops.py b/ietf/name/migrations/0009_iabworkshops.py new file mode 100644 index 000000000..181981586 --- /dev/null +++ b/ietf/name/migrations/0009_iabworkshops.py @@ -0,0 +1,29 @@ +# Copyright The IETF Trust 2023, All Rights Reserved + +from django.db import migrations + +def forward(apps, schema_editor): + GroupTypeName = apps.get_model("name", "GroupTypeName") + GroupTypeName.objects.create( + slug = "iabworkshop", + name = "IAB Workshop", + desc = "IAB Workshop", + used = True, + order = 0, + verbose_name = "IAB Workshop", + + ) + +def reverse(apps, schema_editor): + GroupTypeName = apps.get_model("name", "GroupTypeName") + GroupTypeName.objects.filter(slug="iabworkshop").delete() + + +class Migration(migrations.Migration): + dependencies = [ + ("name", "0008_removed_objfalse"), + ] + + operations = [ + migrations.RunPython(forward, reverse) + ] diff --git a/ietf/urls.py b/ietf/urls.py index 58179fbd0..78dbb861b 100644 --- a/ietf/urls.py +++ b/ietf/urls.py @@ -65,7 +65,7 @@ urlpatterns = [ url(r'^submit/', include('ietf.submit.urls')), url(r'^sync/', include('ietf.sync.urls')), url(r'^templates/', include('ietf.dbtemplate.urls')), - url(r'^(?P(wg|rg|ag|rag|team|dir|review|area|program|iabasg|adhoc|ise|adm|rfcedtyp|edwg|edappr))/', include(grouptype_urls)), + url(r'^(?P(wg|rg|ag|rag|team|dir|review|area|program|iabasg|iabworkshop|adhoc|ise|adm|rfcedtyp|edwg|edappr))/', include(grouptype_urls)), # Redirects url(r'^(?Ppublic)/', include('ietf.redirects.urls')),