Allow creating label without name
This commit is contained in:
@@ -12,12 +12,13 @@ module.exports = {
|
||||
},
|
||||
name: {
|
||||
type: 'string',
|
||||
required: true
|
||||
isNotEmptyString: true,
|
||||
allowNull: true
|
||||
},
|
||||
color: {
|
||||
type: 'string',
|
||||
isIn: Label.COLORS,
|
||||
allowNull: true
|
||||
required: true
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -12,12 +12,13 @@ module.exports = {
|
||||
},
|
||||
name: {
|
||||
type: 'string',
|
||||
isNotEmptyString: true
|
||||
isNotEmptyString: true,
|
||||
allowNull: true
|
||||
},
|
||||
color: {
|
||||
type: 'string',
|
||||
isIn: Label.COLORS,
|
||||
allowNull: true
|
||||
required: true
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -28,12 +28,13 @@ module.exports = {
|
||||
|
||||
name: {
|
||||
type: 'string',
|
||||
required: true
|
||||
isNotEmptyString: true,
|
||||
allowNull: true
|
||||
},
|
||||
color: {
|
||||
type: 'string',
|
||||
isIn: COLORS,
|
||||
allowNull: true
|
||||
required: true
|
||||
},
|
||||
|
||||
// ╔═╗╔╦╗╔╗ ╔═╗╔╦╗╔═╗
|
||||
|
||||
@@ -6,8 +6,8 @@ module.exports.up = knex =>
|
||||
|
||||
table.integer('board_id').notNullable();
|
||||
|
||||
table.text('name').notNullable();
|
||||
table.text('color');
|
||||
table.text('name');
|
||||
table.text('color').notNullable();
|
||||
|
||||
table.timestamp('created_at', true);
|
||||
table.timestamp('updated_at', true);
|
||||
|
||||
Reference in New Issue
Block a user