From b8d72cdbc571c8050c0fefd6be0ba10f6c9a9181 Mon Sep 17 00:00:00 2001 From: "Karl O. Pinc" Date: Tue, 16 Jul 2024 17:16:51 -0500 Subject: [PATCH] Move core utility functions into a separate module --- .../TEMPLATE/src/pgwui_TEMPLATE/views/TEMPLATE.py.mak | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/pgwui_develop/TEMPLATE/src/pgwui_TEMPLATE/views/TEMPLATE.py.mak b/src/pgwui_develop/TEMPLATE/src/pgwui_TEMPLATE/views/TEMPLATE.py.mak index c6ef577..4ace228 100644 --- a/src/pgwui_develop/TEMPLATE/src/pgwui_TEMPLATE/views/TEMPLATE.py.mak +++ b/src/pgwui_develop/TEMPLATE/src/pgwui_TEMPLATE/views/TEMPLATE.py.mak @@ -22,6 +22,7 @@ from pyramid.view import view_config import logging import pgwui_core.core +import pgwui_core.utils from pgwui_common.view import auth_base_view from ${component.lower()} import exceptions as ${short_name}_ex @@ -48,7 +49,7 @@ def ${short_name}_view(request): response['pgwui']['${component.lower()}'] = settings['pgwui']['${component.lower()}'] if response['report_success']: - if pgwui_core.core.is_checked(response['csv_checked']): + if pgwui_core.utils.is_checked(response['csv_checked']): upload_fmt = 'CSV' else: upload_fmt = 'TAB' @@ -59,11 +60,11 @@ def ${short_name}_view(request): .format(filename=response['filename'], lines=response['lines'], format=upload_fmt, - null=pgwui_core.core.is_checked( + null=pgwui_core.utils.is_checked( response['upload_null']), - null_rep=pgwui_core.core.escape_eol( + null_rep=pgwui_core.utils.escape_eol( response['null_rep']), - trim=pgwui_core.core.is_checked( + trim=pgwui_core.utils.is_checked( response['trim_upload']), db=response['db'], table=response['table'], -- 2.34.1