Selaa lähdekoodia

Closes #22239: Rename apply button for table configs

Jeremy Stretch 1 päivä sitten
vanhempi
commit
36caa81d7d

+ 2 - 1
netbox/templates/htmx/table.html

@@ -1,5 +1,6 @@
 {# Render an HTMX-enabled table with paginator #}
 {# Render an HTMX-enabled table with paginator #}
 {% load helpers %}
 {% load helpers %}
+{% load i18n %}
 {% load buttons %}
 {% load buttons %}
 {% load render_table from django_tables2 %}
 {% load render_table from django_tables2 %}
 
 
@@ -23,7 +24,7 @@
 
 
   {# Include the updated "save" link for the table configuration #}
   {# Include the updated "save" link for the table configuration #}
   {% if table.config_params and not table.embedded %}
   {% if table.config_params and not table.embedded %}
-    <a class="dropdown-item" hx-swap-oob="outerHTML:#table_save_link" href="{% url 'extras:tableconfig_add' %}?{{ table.config_params }}&return_url={{ request.path }}" id="table_save_link">Save</a>
+    <a class="dropdown-item" hx-swap-oob="outerHTML:#table_save_link" href="{% url 'extras:tableconfig_add' %}?{{ table.config_params }}&return_url={{ request.path }}" id="table_save_link">{% trans "Save" %}</a>
   {% endif %}
   {% endif %}
 
 
   {# Update the bulk action buttons with new query parameters #}
   {# Update the bulk action buttons with new query parameters #}

+ 1 - 1
netbox/templates/inc/table_controls_htmx.html

@@ -38,7 +38,7 @@
           </button>
           </button>
           <div class="dropdown-menu">
           <div class="dropdown-menu">
             {% if table.config_params %}
             {% if table.config_params %}
-              <a class="dropdown-item" href="{% url 'extras:tableconfig_add' %}?{{ table.config_params }}&return_url={{ request.path }}" id="table_save_link">Save</a>
+              <a class="dropdown-item" href="{% url 'extras:tableconfig_add' %}?{{ table.config_params }}&return_url={{ request.path }}" id="table_save_link">{% trans "Save" %}</a>
             {% endif %}
             {% endif %}
             {% if table.config_params and table_configs %}
             {% if table.config_params and table_configs %}
               <hr class="dropdown-divider">
               <hr class="dropdown-divider">

+ 2 - 2
netbox/utilities/templates/helpers/table_config_form.html

@@ -36,8 +36,8 @@
           </div>
           </div>
         </div>
         </div>
         <div class="modal-footer">
         <div class="modal-footer">
-            <button type="submit" class="btn btn-outline-danger" id="reset_tableconfig" value="Reset">{% trans "Reset" %}</button>
-            <button type="submit" class="btn btn-primary" id="save_tableconfig" value="Save">{% trans "Save" %}</button>
+          <button type="submit" class="btn btn-outline-danger" id="reset_tableconfig" value="Reset">{% trans "Reset" %}</button>
+          <button type="submit" class="btn btn-primary" id="apply_tableconfig" value="Apply">{% trans "Apply" %}</button>
         </div>
         </div>
       </form>
       </form>
     </div>
     </div>