From 65f23ffcdaec8231d0be6861bbd05c7e17822665 Mon Sep 17 00:00:00 2001 From: "Karl O. Pinc" Date: Tue, 30 Jul 2024 12:27:53 -0500 Subject: [PATCH] Make consistent use of TabIndex --- src/pgwui_common/templates/auth_base.mak | 5 ++--- src/pgwui_common/templates/auth_parts.mak | 10 ++++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/pgwui_common/templates/auth_base.mak b/src/pgwui_common/templates/auth_base.mak index 1856ce8..daf1fa7 100644 --- a/src/pgwui_common/templates/auth_base.mak +++ b/src/pgwui_common/templates/auth_base.mak @@ -199,9 +199,8 @@ <% tab_index = TabIndex() database_row(tab_index) - self.auth_parts.user_row(tab_index.val + 1, havecreds, user) - self.auth_parts.password_row(tab_index.val + 2, havecreds) - tab_index.inc(2) + self.auth_parts.user_row(tab_index, havecreds, user) + self.auth_parts.password_row(tab_index, havecreds) caller.body(tab_index) diff --git a/src/pgwui_common/templates/auth_parts.mak b/src/pgwui_common/templates/auth_parts.mak index 00dc4b1..ca20d4e 100644 --- a/src/pgwui_common/templates/auth_parts.mak +++ b/src/pgwui_common/templates/auth_parts.mak @@ -48,7 +48,7 @@ % endif -<%def name="user_row(tabindex, havecreds, user)"> +<%def name="user_row(tab_index, havecreds, user)"> @@ -58,18 +58,19 @@ ${user} % else: % endif + <% tab_index.inc() %> -<%def name="password_row(tabindex, havecreds)"> +<%def name="password_row(tab_index, havecreds)"> % if not havecreds: @@ -77,12 +78,13 @@ + <% tab_index.inc() %> % endif -- 2.34.1