Merge branch 'main' into avm99963-monorail

Merged commit 34d8229ae2b51fb1a15bd208e6fe6185c94f6266

GitOrigin-RevId: 7ee0917f93a577e475f8e09526dd144d245593f4
diff --git a/templates/tracker/admin-components-page.ezt b/templates/tracker/admin-components-page.ezt
index 0c9d2d1..9dd2a6e 100644
--- a/templates/tracker/admin-components-page.ezt
+++ b/templates/tracker/admin-components-page.ezt
@@ -5,10 +5,10 @@
 [else]
 
 <form action="adminComponents.do" id="adminComponents" method="POST">
- <input type="hidden" name="token" value="form_token]">
+ <input type="hidden" name="token" value="[form_token]">
 
  <h4>Issue components</h4>
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <span style="margin:0 .7em">Show:
     <select id="rowfilter">
      <option label="All components" value="all">
@@ -26,7 +26,7 @@
  [end]
 
  <div class="list-foot"></div>
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <form action="adminComponents.do" method="POST">
      <a href="/p/[projectname]/components/create" class="buttonify primary">Create component</a>
      <input type="hidden" name="delete_components">
@@ -53,7 +53,7 @@
    <table cellspacing="0" cellpadding="2" border="0" class="comptable results striped vt active" id="resultstable" width="100%">
    <tbody>
      <tr>
-       [if-any perms.EditProject]<th></th>[end]
+       [if-any can_edit_project]<th></th>[end]
        <th>ID</th>
        <th>Name</th>
        <th>Administrators</th>
@@ -73,7 +73,7 @@
      [for component_defs]
        [define detail_url]/p/[projectname]/components/detail?component=[format "url"][component_defs.path][end][end]
        <tr data-url="[detail_url]" class="comprow [component_defs.classes]">
-         [if-any perms.EditProject]
+         [if-any can_edit_project]
            <td class="cb rowwidgets">
              <input type="checkbox" data-path="[component_defs.path]" class="checkRangeSelect">
            </td>
@@ -109,7 +109,7 @@
  </div>[# section]
 
  <div class="list-foot"></div>
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <form action="adminComponents.do" method="POST">
      <a href="/p/[projectname]/components/create" class="buttonify primary">Create component</a>
      <input type="hidden" name="delete_components">
diff --git a/templates/tracker/admin-labels-page.ezt b/templates/tracker/admin-labels-page.ezt
index e8cb7ae..0acd465 100644
--- a/templates/tracker/admin-labels-page.ezt
+++ b/templates/tracker/admin-labels-page.ezt
@@ -10,7 +10,7 @@
 
  <h4>Predefined issue labels</h4>
  <div class="section">
-  [if-any perms.EditProject]
+  [if-any can_edit_project]
     <table class="vt">
      <tr><td>
        <textarea name="predefinedlabels" rows="12" cols="75" style="tab-size:18">[labels_text]</textarea>
@@ -47,7 +47,7 @@
   [end]
  </div>
 
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <input type="submit" id="savechanges" name="btn" value="Save changes" class="submit">
  [end]
 
@@ -111,7 +111,7 @@
   </tbody>
   </table>
   <div class="list-foot"></div>
-  [if-any perms.EditProject]
+  [if-any can_edit_project]
     <p><a href="/p/[projectname]/fields/create" class="buttonify primary">Add field</a></p>
   [end]
  </div>
diff --git a/templates/tracker/admin-statuses-page.ezt b/templates/tracker/admin-statuses-page.ezt
index 2d2d936..425667d 100644
--- a/templates/tracker/admin-statuses-page.ezt
+++ b/templates/tracker/admin-statuses-page.ezt
@@ -7,7 +7,7 @@
 <form action="adminStatuses.do" id="adminStatuses" method="POST">
  <input type="hidden" name="token" value="[form_token]">
 
-  [if-any perms.EditProject]
+  [if-any can_edit_project]
     <table class="vt">
      <tr><td>
        <h4>Open Issue Status Values</h4>
@@ -72,7 +72,7 @@
   [end]
 
 
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <input type="submit" id="savechanges" name="btn" value="Save changes" class="submit">
  [end]
 </form>
diff --git a/templates/tracker/admin-templates-page.ezt b/templates/tracker/admin-templates-page.ezt
index 2ef36f3..a78bdfa 100644
--- a/templates/tracker/admin-templates-page.ezt
+++ b/templates/tracker/admin-templates-page.ezt
@@ -4,7 +4,7 @@
 [if-any read_only][include "../framework/read-only-rejection.ezt"]
 [else]
 
-[if-any perms.EditProject]
+[if-any can_edit_project]
   <h4>Default templates</h4>
   <div class="section" style="padding-top:0">
     <form action="adminTemplates.do" id="adminTemplates" method="POST">
@@ -54,7 +54,7 @@
         </tr>
       [end]
       [for config.templates]
-        [if-any config.templates.can_view perms.EditProject]
+        [if-any config.templates.can_view can_edit_project]
           [define detail_url]/p/[projectname]/templates/detail?template=[format "url"][config.templates.name][end][end]
             <tr data-url="detail_url">
               <td style="white-space:nowrap" class="id">
@@ -66,7 +66,7 @@
     </tbody>
   </table>
 
-  [if-any perms.EditProject]
+  [if-any can_edit_project]
     <p><a href="/p/[projectname]/templates/create" class="buttonify primary">Add template</a></p>
   [end]
 </div>
diff --git a/templates/tracker/admin-views-page.ezt b/templates/tracker/admin-views-page.ezt
index 5ec5d15..db0e83b 100644
--- a/templates/tracker/admin-views-page.ezt
+++ b/templates/tracker/admin-views-page.ezt
@@ -27,7 +27,7 @@
   </div>
   <br>
 
-  [if-any perms.EditProject]
+  [if-any can_edit_project]
     [include "../framework/saved-queries-admin-part.ezt" "project"]
   [else]
     <table cellspacing="0" cellpadding="2" border="0" class="results striped">
@@ -60,7 +60,7 @@
  </div>
 </div>
 
- [if-any perms.EditProject]
+ [if-any can_edit_project]
    <input type="submit" id="savechanges" name="btn" value="Save changes" class="submit">
  [end]
 </form>
diff --git a/templates/tracker/issue-bulk-edit-page.ezt b/templates/tracker/issue-bulk-edit-page.ezt
index d57c0ae..ec3cf74 100644
--- a/templates/tracker/issue-bulk-edit-page.ezt
+++ b/templates/tracker/issue-bulk-edit-page.ezt
@@ -208,6 +208,9 @@
          <input type="text" class="labelinput" id="label23" size="20" autocomplete="off"
                 name="label" value="[label23]">
         </div>
+        [if-any errors.labels]
+          <div class="fielderror">[errors.labels]</div>
+        [end]
       </td>
    </tr>
 
diff --git a/templates/tracker/issue-entry-page.ezt b/templates/tracker/issue-entry-page.ezt
index b9889d6..f3b69db 100644
--- a/templates/tracker/issue-entry-page.ezt
+++ b/templates/tracker/issue-entry-page.ezt
@@ -176,6 +176,9 @@
       <tr [if-any page_perms.EditIssue][else]style="display:none;"[end]><th>Labels:</th>[# aria-labels added in label-fields.ezt]
        <td colspan="2" class="labelediting">
         [include "label-fields.ezt" "just-two" ""]
+        [if-any errors.labels]
+          <div class="fielderror">[errors.labels]</div>
+        [end]
        </td>
       </tr>
 
diff --git a/templates/tracker/web-components-page.ezt b/templates/tracker/web-components-page.ezt
index 88a42e4..87c3bed 100644
--- a/templates/tracker/web-components-page.ezt
+++ b/templates/tracker/web-components-page.ezt
@@ -14,6 +14,7 @@
   loginUrl="[login_url]"
   logoutUrl="[logout_url]"
   versionBase="[version_base]"
+  projectAlert="[project_alert]"
 ></mr-app>
 
 [include "../framework/polymer-footer.ezt"]