Feat(SQL, UI): Button Icons page, Command Button Links page created with get and set functionality.

This commit is contained in:
2025-07-17 18:58:06 +01:00
parent e0805ec2ed
commit 4e214c3bde
151 changed files with 12224 additions and 463 deletions

View File

@@ -0,0 +1,5 @@
{% set value_previous = '0' if is_blank_row else button_shape.id_button_shape %}
{% set text_previous = '' if is_blank_row else button_shape.name %}
<div class="{{ model.FLAG_BUTTON_SHAPE }}" {{ model.ATTR_VALUE_PREVIOUS }}="{{ value_previous }}" {{ model.ATTR_VALUE_CURRENT }}="{{ value_previous }}">{{ text_previous }}</div>

View File

@@ -0,0 +1,5 @@
{% set value_previous = '0' if is_blank_row else colour.id_colour %}
{% set text_previous = '' if is_blank_row else colour.name %}
<div class="{{ model.FLAG_COLOUR }}" {{ model.ATTR_VALUE_PREVIOUS }}="{{ value_previous }}" {{ model.ATTR_VALUE_CURRENT }}="{{ value_previous }}">{{ text_previous }}</div>

View File

@@ -0,0 +1,7 @@
{% with _attribute_text = '' if (attribute_text is not defined or attribute_text is none) else attribute_text %}
{% set value_previous = '0' if (is_blank_row or (image is not defined) or (image is none) or (image.id_image is none)) else image.id_image %}
{% set text_previous = '' if (is_blank_row or (image is not defined) or (image is none)) else model.format_null_string_as_blank(image.name) %}
<div class="{{ model.FLAG_IMAGE }} {{ _attribute_text }}" {{ model.ATTR_VALUE_PREVIOUS }}="{{ value_previous }}" {{ model.ATTR_VALUE_CURRENT }}="{{ value_previous }}">{{ text_previous }}</div>
{% endwith %}

View File

@@ -1,7 +1,7 @@
{% with _attribute_text = '' if (attribute_text is not defined or attribute_text is none) else attribute_text %}
{% set value_previous = '0' if is_blank_row else location_preview.id_location %}
{% set text_previous = '' if is_blank_row else location_preview.name %}
{% set value_previous = '0' if (is_blank_row or (location_preview is not defined) or (location_preview is none) or (location_preview.id_location is none)) else location_preview.id_location %}
{% set text_previous = '' if (is_blank_row or (location_preview is not defined) or (location_preview is none)) else model.format_null_string_as_blank(location_preview.name) %}
<div class="{{ model.FLAG_LOCATION }}" {{ model.ATTR_VALUE_PREVIOUS }}="{{ value_previous }}" {{ model.ATTR_VALUE_CURRENT }}="{{ value_previous }}">{{ text_previous }}</div>
<div class="{{ model.FLAG_LOCATION }} {{ _attribute_text }}" {{ model.ATTR_VALUE_PREVIOUS }}="{{ value_previous }}" {{ model.ATTR_VALUE_CURRENT }}="{{ value_previous }}">{{ text_previous }}</div>
{% endwith %}

View File

@@ -0,0 +1,32 @@
{% if is_blank_row %}
<tr class="{{ model.FLAG_ROW_NEW }} {{ model.FLAG_BUTTON_ICON }}" {{ model.ATTR_ID_BUTTON_ICON }}>
<td class="{{ model.FLAG_IMAGE }} {{ model.FLAG_DDL_PREVIEW }}">
{% set image = none %}
{% include 'components/dog/_preview_DDL_image.html' %}
</td>
<td class="{{ model.FLAG_NAME }}">
<input type="text"
class="{{ model.FLAG_NAME }}"
{{ model.ATTR_VALUE_CURRENT }} {{ model.ATTR_VALUE_PREVIOUS }} />
</td>
{% set active = True %}
{% include 'components/dog/_td_active.html' %}
</tr>
{% else %}
<tr class="{{ model.FLAG_BUTTON_ICON }}" {{ model.ATTR_ID_BUTTON_ICON }}="{{ button_icon.id_button_icon }}">
{% set image = button_icon.image %}
<td class="{{ model.FLAG_IMAGE }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_image.html' %}
</td>
<td class="{{ model.FLAG_NAME }}">
<input type="text"
class="{{ model.FLAG_NAME }}"
{{ model.ATTR_VALUE_CURRENT }}="{{ model.format_null_string_as_blank(button_icon.name)|escape }}"
{{ model.ATTR_VALUE_PREVIOUS }}="{{ model.format_null_string_as_blank(button_icon.name)|escape }}"
value="{{ model.format_null_string_as_blank(button_icon.name) }}" />
</td>
{% set active = button_icon.active %}
{% include 'components/dog/_td_active.html' %}
</tr>
{% endif %}

View File

@@ -0,0 +1,54 @@
{% if is_blank_row %}
<tr class="{{ model.FLAG_ROW_NEW }} {{ model.FLAG_COMMAND_BUTTON_LINK }}" {{ model.ATTR_ID_COMMAND_BUTTON_LINK }}>
<td class="{{ model.FLAG_COMMAND_CATEGORY }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command_category.html' %}
</td>
<td class="{{ model.FLAG_COMMAND }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command.html' %}
</td>
<td class="{{ model.FLAG_BUTTON_SHAPE }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_button_shape.html' %}
</td>
<td class="{{ model.FLAG_COLOUR }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_colour.html' %}
</td>
<td class="{{ model.FLAG_BUTTON_ICON }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_image.html' %}
</td>
<td class="{{ model.FLAG_LOCATION }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_location.html' %}
</td>
{% set active = True %}
{% include 'components/dog/_td_active.html' %}
</tr>
{% else %}
<tr class="{{ model.FLAG_COMMAND_BUTTON_LINK }}" {{ model.ATTR_ID_COMMAND_BUTTON_LINK }}="{{ link.id_link }}">
{% set command = link.command %}
{% set command_category = command.command_category %}
<td class="{{ model.FLAG_COMMAND_CATEGORY }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command_category.html' %}
</td>
<td class="{{ model.FLAG_COMMAND }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command.html' %}
</td>
{% set button_shape = link.button_shape %}
<td class="{{ model.FLAG_BUTTON_SHAPE }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_button_shape.html' %}
</td>
{% set colour = link.colour %}
<td class="{{ model.FLAG_COLOUR }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_colour.html' %}
</td>
{% set image = link.button_icon.image %}
<td class="{{ model.FLAG_BUTTON_ICON }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_image.html' %}
</td>
{% set location_preview = link.location %}
<td class="{{ model.FLAG_LOCATION }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_location.html' %}
</td>
{% set active = link.active %}
{% include 'components/dog/_td_active.html' %}
</tr>
{% endif %}

View File

@@ -29,11 +29,11 @@
<td class="{{ model.FLAG_DOG }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_dog.html' %}
</td>
{% set command_category = link.command.command_category %}
{% set command = link.command %}
{% set command_category = command.command_category %}
<td class="{{ model.FLAG_COMMAND_CATEGORY }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command_category.html' %}
</td>
{% set command = link.command %}
<td class="{{ model.FLAG_COMMAND }} {{ model.FLAG_DDL_PREVIEW }}">
{% include 'components/dog/_preview_DDL_command.html' %}
</td>

View File

@@ -2,6 +2,7 @@
{% if is_blank_row %}
<tr class="{{ model.FLAG_ROW_NEW }} {{ model.FLAG_LOCATION }}" {{ model.ATTR_ID_LOCATION }}>
<td class="{{ model.FLAG_LOCATION_PARENT }} {{ model.FLAG_DDL_PREVIEW }}">
{% set location_preview = none %}
{% set attribute_text = model.FLAG_LOCATION_PARENT %}
{% include 'components/dog/_preview_DDL_location.html' %}
</td>