mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Security label providers are an optional parameter. Fixes #1478.
This commit is contained in:
committed by
Dave Page
parent
f4f8273994
commit
b6e8d195dc
@@ -1,6 +1,6 @@
|
||||
{% macro APPLY(conn, type, schema_name, parent_object, child_object, provider, label) -%}
|
||||
SECURITY LABEL FOR {{ conn|qtIdent(provider) }} ON {{ type }} {{ conn|qtIdent(schema_name, parent_object, child_object) }} IS {{ label|qtLiteral }};
|
||||
SECURITY LABEL{% if provider and provider != '' %} FOR {{ conn|qtIdent(provider) }}{% endif %} ON {{ type }} {{ conn|qtIdent(schema_name, parent_object, child_object) }} IS {{ label|qtLiteral }};
|
||||
{%- endmacro %}
|
||||
{% macro DROP(conn, type, schema_name, parent_object, child_object, provider) -%}
|
||||
SECURITY LABEL FOR {{ conn|qtIdent(provider) }} ON {{ type }} {{ conn|qtIdent(schema_name, parent_object, child_object) }} IS NULL;
|
||||
SECURITY LABEL{% if provider and provider != '' %} FOR {{ conn|qtIdent(provider) }}{% endif %} ON {{ type }} {{ conn|qtIdent(schema_name, parent_object, child_object) }} IS NULL;
|
||||
{%- endmacro %}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{# Macros for Security Labels (functions module) #}
|
||||
{#################################################}
|
||||
{% macro SET(conn, type, name, provider, label, schema, func_args) -%}
|
||||
SECURITY LABEL FOR {{ provider }} ON {{ type }} {{ conn|qtIdent(schema, name) }}({{func_args}}) IS {{ label|qtLiteral }};
|
||||
SECURITY LABEL{% if provider and provider != '' %} FOR {{ conn|qtIdent(provider) }}{% endif %} ON {{ type }} {{ conn|qtIdent(schema, name) }}({{func_args}}) IS {{ label|qtLiteral }};
|
||||
{%- endmacro %}
|
||||
{% macro UNSET(conn, type, name, provider, schema, func_args) -%}
|
||||
SECURITY LABEL FOR {{ provider }} ON {{ type }} {{ conn|qtIdent(schema, name) }}({{func_args}}) IS NULL;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{# Macros for schema and its child nodes #}
|
||||
{##########################################}
|
||||
{% macro SET(conn, type, name, provider, label, schema) -%}
|
||||
SECURITY LABEL FOR {{ provider }} ON {{ type }} {{ conn|qtIdent(schema, name) }} IS {{ label|qtLiteral }};
|
||||
SECURITY LABEL FOR{% if provider and provider != '' %} FOR {{ conn|qtIdent(provider) }}{% endif %} ON {{ type }} {{ conn|qtIdent(schema, name) }} IS {{ label|qtLiteral }};
|
||||
{%- endmacro %}
|
||||
{% macro UNSET(conn, type, name, provider, schema) -%}
|
||||
SECURITY LABEL FOR {{ provider }} ON {{ type }} {{ conn|qtIdent(schema, name) }} IS NULL;
|
||||
|
||||
Reference in New Issue
Block a user