mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 23:40:13 +01:00
- Fix Import from Trello error 400.
Thanks to xet7 !
This commit is contained in:
parent
be25e372a3
commit
2f557ae3a5
2 changed files with 26 additions and 0 deletions
4
config/models.js
Normal file
4
config/models.js
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
module.exports.models = {
|
||||||
|
connection: 'mongodb',
|
||||||
|
migrate: 'safe'
|
||||||
|
}
|
||||||
|
|
@ -6,6 +6,8 @@ Cards = new Mongo.Collection('cards');
|
||||||
Cards.attachSchema(new SimpleSchema({
|
Cards.attachSchema(new SimpleSchema({
|
||||||
title: {
|
title: {
|
||||||
type: String,
|
type: String,
|
||||||
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
archived: {
|
archived: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -22,6 +24,8 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
},
|
},
|
||||||
listId: {
|
listId: {
|
||||||
type: String,
|
type: String,
|
||||||
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
swimlaneId: {
|
swimlaneId: {
|
||||||
type: String,
|
type: String,
|
||||||
|
|
@ -31,10 +35,14 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
// difficult to manage and less efficient.
|
// difficult to manage and less efficient.
|
||||||
boardId: {
|
boardId: {
|
||||||
type: String,
|
type: String,
|
||||||
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
coverId: {
|
coverId: {
|
||||||
type: String,
|
type: String,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
|
|
||||||
},
|
},
|
||||||
createdAt: {
|
createdAt: {
|
||||||
type: Date,
|
type: Date,
|
||||||
|
|
@ -49,15 +57,19 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
customFields: {
|
customFields: {
|
||||||
type: [Object],
|
type: [Object],
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: [],
|
||||||
},
|
},
|
||||||
'customFields.$': {
|
'customFields.$': {
|
||||||
type: new SimpleSchema({
|
type: new SimpleSchema({
|
||||||
_id: {
|
_id: {
|
||||||
type: String,
|
type: String,
|
||||||
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
value: {
|
value: {
|
||||||
type: Match.OneOf(String, Number, Boolean, Date),
|
type: Match.OneOf(String, Number, Boolean, Date),
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
},
|
},
|
||||||
|
|
@ -70,22 +82,28 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
description: {
|
description: {
|
||||||
type: String,
|
type: String,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: ''
|
||||||
},
|
},
|
||||||
requestedBy: {
|
requestedBy: {
|
||||||
type: String,
|
type: String,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
|
|
||||||
},
|
},
|
||||||
assignedBy: {
|
assignedBy: {
|
||||||
type: String,
|
type: String,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
labelIds: {
|
labelIds: {
|
||||||
type: [String],
|
type: [String],
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
members: {
|
members: {
|
||||||
type: [String],
|
type: [String],
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: [],
|
||||||
},
|
},
|
||||||
receivedAt: {
|
receivedAt: {
|
||||||
type: Date,
|
type: Date,
|
||||||
|
|
@ -107,6 +125,7 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
type: Number,
|
type: Number,
|
||||||
decimal: true,
|
decimal: true,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: 0,
|
||||||
},
|
},
|
||||||
isOvertime: {
|
isOvertime: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
|
|
@ -126,6 +145,7 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
sort: {
|
sort: {
|
||||||
type: Number,
|
type: Number,
|
||||||
decimal: true,
|
decimal: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
subtaskSort: {
|
subtaskSort: {
|
||||||
type: Number,
|
type: Number,
|
||||||
|
|
@ -135,10 +155,12 @@ Cards.attachSchema(new SimpleSchema({
|
||||||
},
|
},
|
||||||
type: {
|
type: {
|
||||||
type: String,
|
type: String,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
linkedId: {
|
linkedId: {
|
||||||
type: String,
|
type: String,
|
||||||
optional: true,
|
optional: true,
|
||||||
|
defaultValue: '',
|
||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue