1515from ietf .doc .models import Document , DocumentAuthor , DocAlias , DocRelationshipName , RelatedDocument , State
1616from ietf .doc .models import DocEvent , NewRevisionDocEvent
1717from ietf .doc .models import save_document_in_history
18+ from ietf .ietfauth .utils import role_required
1819from ietf .meeting .models import Meeting
1920from ietf .meeting .helpers import get_meeting
2021from ietf .name .models import StreamName
@@ -484,6 +485,7 @@ def report_progress_report(start_date,end_date):
484485# -------------------------------------------------
485486# Standard View Functions
486487# -------------------------------------------------
488+ @role_required ('Secretariat' )
487489def abstract (request , id ):
488490 '''
489491 View Internet Draft Abstract
@@ -503,6 +505,7 @@ def abstract(request, id):
503505 RequestContext (request , {}),
504506 )
505507
508+ @role_required ('Secretariat' )
506509def add (request ):
507510 '''
508511 Add Internet Draft
@@ -594,6 +597,7 @@ def add(request):
594597 RequestContext (request , {}),
595598 )
596599
600+ @role_required ('Secretariat' )
597601def announce (request , id ):
598602 '''
599603 Schedule announcement of new Internet-Draft to I-D Announce list
@@ -618,6 +622,7 @@ def announce(request, id):
618622 messages .success (request , 'Announcement scheduled successfully!' )
619623 return redirect ('drafts_view' , id = id )
620624
625+ @role_required ('Secretariat' )
621626def approvals (request ):
622627 '''
623628 This view handles setting Initial Approval for drafts
@@ -632,6 +637,7 @@ def approvals(request):
632637 RequestContext (request , {}),
633638 )
634639
640+ @role_required ('Secretariat' )
635641def author_delete (request , id , oid ):
636642 '''
637643 This view deletes the specified author(email) from the draft
@@ -640,6 +646,7 @@ def author_delete(request, id, oid):
640646 messages .success (request , 'The author was deleted successfully' )
641647 return redirect ('drafts_authors' , id = id )
642648
649+ @role_required ('Secretariat' )
643650def authors (request , id ):
644651 '''
645652 Edit Internet Draft Authors
@@ -687,6 +694,7 @@ def authors(request, id):
687694 RequestContext (request , {}),
688695 )
689696
697+ @role_required ('Secretariat' )
690698def confirm (request , id ):
691699 '''
692700 This view displays changes that will be made and calls appropriate
@@ -737,6 +745,7 @@ def confirm(request, id):
737745 RequestContext (request , {}),
738746 )
739747
748+ @role_required ('Secretariat' )
740749def dates (request ):
741750 '''
742751 Manage ID Submission Dates
@@ -756,6 +765,7 @@ def dates(request):
756765 RequestContext (request , {}),
757766 )
758767
768+ @role_required ('Secretariat' )
759769def edit (request , id ):
760770 '''
761771 Since there's a lot going on in this function we are summarizing in the docstring.
@@ -804,6 +814,7 @@ def edit(request, id):
804814 'draft' : draft },
805815 )
806816
817+ @role_required ('Secretariat' )
807818def email (request , id ):
808819 '''
809820 This function displays the notification message and allows the
@@ -849,6 +860,7 @@ def email(request, id):
849860 RequestContext (request , {}),
850861 )
851862
863+ @role_required ('Secretariat' )
852864def extend (request , id ):
853865 '''
854866 This view handles extending the expiration date for an Internet-Draft
@@ -880,6 +892,7 @@ def extend(request, id):
880892 RequestContext (request , {}),
881893 )
882894
895+ @role_required ('Secretariat' )
883896def makerfc (request , id ):
884897 '''
885898 Make RFC out of Internet Draft
@@ -954,6 +967,7 @@ def makerfc(request, id):
954967 RequestContext (request , {}),
955968 )
956969
970+ @role_required ('Secretariat' )
957971def nudge_report (request ):
958972 '''
959973 This view produces the Nudge Report, basically a list of documents that are in the IESG
@@ -967,6 +981,7 @@ def nudge_report(request):
967981 RequestContext (request , {}),
968982 )
969983
984+ @role_required ('Secretariat' )
970985def replace (request , id ):
971986 '''
972987 This view handles replacing one Internet-Draft with another
@@ -998,6 +1013,7 @@ def replace(request, id):
9981013 RequestContext (request , {}),
9991014 )
10001015
1016+ @role_required ('Secretariat' )
10011017def resurrect (request , id ):
10021018 '''
10031019 This view handles resurrection of an Internet-Draft
@@ -1008,6 +1024,7 @@ def resurrect(request, id):
10081024 request .session ['action' ] = 'resurrect'
10091025 return redirect ('drafts_email' , id = id )
10101026
1027+ @role_required ('Secretariat' )
10111028def revision (request , id ):
10121029 '''
10131030 This function presents the input form for the New Revision action. If submitted
@@ -1047,6 +1064,7 @@ def revision(request, id):
10471064 RequestContext (request , {}),
10481065 )
10491066
1067+ @role_required ('Secretariat' )
10501068def search (request ):
10511069 '''
10521070 Search Internet Drafts
@@ -1118,6 +1136,7 @@ def search(request):
11181136 RequestContext (request , {}),
11191137 )
11201138
1139+ @role_required ('Secretariat' )
11211140def update (request , id ):
11221141 '''
11231142 This view handles the Update action for an Internet-Draft
@@ -1159,6 +1178,7 @@ def update(request, id):
11591178 RequestContext (request , {}),
11601179 )
11611180
1181+ @role_required ('Secretariat' )
11621182def view (request , id ):
11631183 '''
11641184 View Internet Draft
@@ -1219,6 +1239,7 @@ def view(request, id):
12191239 RequestContext (request , {}),
12201240 )
12211241
1242+ @role_required ('Secretariat' )
12221243def withdraw (request , id ):
12231244 '''
12241245 This view handles withdrawing an Internet-Draft
0 commit comments