mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 01:12:56 +03:00
parent
c87940ae42
commit
b24456788c
@ -183,9 +183,7 @@ const ColumnEditor = ({
|
||||
<div className="col-xs-6">
|
||||
<select
|
||||
className="input-sm form-control"
|
||||
value={
|
||||
selectedProperties[colName].uniqueConstraint ? 'true' : 'false'
|
||||
}
|
||||
value={selectedProperties[colName].isUnique}
|
||||
onChange={toggleColumnUnique}
|
||||
disabled={columnProperties.pkConstraint}
|
||||
data-test="edit-col-unique"
|
||||
|
@ -50,7 +50,8 @@ const ColumnEditorList = ({
|
||||
type: col.data_type !== 'USER-DEFINED' ? col.data_type : col.udt_name,
|
||||
isNullable: col.is_nullable === 'YES',
|
||||
pkConstraint: columnPKConstraints[colName],
|
||||
uniqueConstraint: columnUniqueConstraints[colName],
|
||||
isUnique: columnUniqueConstraints[colName] ? true : false,
|
||||
// uniqueConstraint: columnUniqueConstraints[colName],
|
||||
default: col.column_default || '',
|
||||
};
|
||||
|
||||
@ -85,7 +86,7 @@ const ColumnEditorList = ({
|
||||
propertiesList.push('primary key');
|
||||
}
|
||||
|
||||
if (columnProperties.uniqueConstraint) {
|
||||
if (columnProperties.isUnique) {
|
||||
propertiesList.push('unique');
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user