mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-03 12:10:55 -06:00
Fixed issues reported while testing feature #6378
This commit is contained in:
parent
aa973fc8ae
commit
d69b4282c8
@ -81,16 +81,17 @@ CACHE {{c.seqcache|int}} {% endif %}
|
||||
{% if data.like_relation or data.coll_inherits or data.columns|length > 0 or data.primary_key|length > 0 or data.unique_constraint|length > 0 or data.foreign_key|length > 0 or data.check_constraint|length > 0 or data.exclude_constraint|length > 0 %}
|
||||
|
||||
){% endif %}{% if data.relkind is defined and data.relkind == 'p' %} PARTITION BY {{ data.partition_scheme }}{% endif %}
|
||||
{% if not data.coll_inherits and not data.spcname and not with_clause %};{% endif %}
|
||||
{% if not data.coll_inherits and not data.spcname and not with_clause and not data.amname %};{% endif %}
|
||||
|
||||
{### If we are inheriting it from another table(s) ###}
|
||||
{% if data.coll_inherits %}
|
||||
INHERITS ({% for val in data.coll_inherits %}{% if loop.index != 1 %}, {% endif %}{{val}}{% endfor %}){% if not data.spcname and not with_clause %};{% endif %}
|
||||
INHERITS ({% for val in data.coll_inherits %}{% if loop.index != 1 %}, {% endif %}{{val}}{% endfor %}){% if not data.spcname and not with_clause and not data.amname %};{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if data.default_amname and data.default_amname != data.amname and data.amname is not none %}
|
||||
USING {{data.amname}}
|
||||
{% elif not data.default_amname and data.amname %}
|
||||
USING {{data.amname}}
|
||||
USING {{data.amname}}{% if not data.spcname and not with_clause %};{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if with_clause %}
|
||||
|
@ -83,16 +83,17 @@ CACHE {{c.seqcache|int}} {% endif %}
|
||||
{% if data.like_relation or data.coll_inherits or data.columns|length > 0 or data.primary_key|length > 0 or data.unique_constraint|length > 0 or data.foreign_key|length > 0 or data.check_constraint|length > 0 or data.exclude_constraint|length > 0 %}
|
||||
|
||||
){% endif %}{% if data.relkind is defined and data.relkind == 'p' %} PARTITION BY {{ data.partition_scheme }}{% endif %}
|
||||
{% if not data.coll_inherits and not data.spcname and not with_clause %};{% endif %}
|
||||
{% if not data.coll_inherits and not data.spcname and not with_clause and not data.amname %};{% endif %}
|
||||
|
||||
{### If we are inheriting it from another table(s) ###}
|
||||
{% if data.coll_inherits %}
|
||||
INHERITS ({% for val in data.coll_inherits %}{% if loop.index != 1 %}, {% endif %}{{val}}{% endfor %}){% if not data.spcname and not with_clause %};{% endif %}
|
||||
INHERITS ({% for val in data.coll_inherits %}{% if loop.index != 1 %}, {% endif %}{{val}}{% endfor %}){% if not data.spcname and not with_clause and not data.amname %};{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if data.default_amname and data.default_amname != data.amname and data.amname is not none %}
|
||||
USING {{data.amname}}
|
||||
{% elif data.amname and not data.default_amname %}
|
||||
USING {{data.amname}}
|
||||
USING {{data.amname}}{% if not data.spcname and not with_clause %};{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if with_clause %}
|
||||
|
@ -87,8 +87,14 @@ export default class MViewSchema extends BaseUISchema {
|
||||
},
|
||||
}, {
|
||||
id: 'amname', label: gettext('Access Method'), group: gettext('Definition'),
|
||||
type: 'select', mode: ['create', 'properties', 'edit'], min_version: 120000,
|
||||
options: obj.fieldOptions.table_amname_list,
|
||||
type: (state)=>{
|
||||
return {
|
||||
type: 'select', options: obj.fieldOptions.table_amname_list,
|
||||
controlProps: {
|
||||
allowClear: obj.isNew(state) ? true : false,
|
||||
}
|
||||
};
|
||||
}, mode: ['create', 'properties', 'edit'], min_version: 120000,
|
||||
disabled: (state) => {
|
||||
if (obj.getServerVersion() < 150000 && !obj.isNew(state)) {
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user