feat: simplification of default-value specification in FieldMetadata (#4592)
* feat: wip refactor default-value * feat: health check to migrate default value * fix: tests * fix: refactor defaultValue to make it more clean * fix: unit tests * fix: front-end default value
This commit is contained in:
@ -40,7 +40,7 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
color: 'orange',
|
||||
},
|
||||
],
|
||||
defaultValue: { value: 'share_everything' },
|
||||
defaultValue: "'share_everything'",
|
||||
})
|
||||
visibility: string;
|
||||
|
||||
@ -73,7 +73,7 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
{ value: 'email', label: 'Email', position: 0, color: 'green' },
|
||||
{ value: 'sms', label: 'SMS', position: 1, color: 'blue' },
|
||||
],
|
||||
defaultValue: { value: 'email' },
|
||||
defaultValue: "'email'",
|
||||
})
|
||||
type: string;
|
||||
|
||||
@ -83,7 +83,7 @@ export class MessageChannelObjectMetadata extends BaseObjectMetadata {
|
||||
label: 'Is Contact Auto Creation Enabled',
|
||||
description: 'Is Contact Auto Creation Enabled',
|
||||
icon: 'IconUserCircle',
|
||||
defaultValue: { value: true },
|
||||
defaultValue: true,
|
||||
})
|
||||
isContactAutoCreationEnabled: boolean;
|
||||
|
||||
|
||||
@ -42,7 +42,7 @@ export class MessageParticipantObjectMetadata extends BaseObjectMetadata {
|
||||
{ value: 'cc', label: 'Cc', position: 2, color: 'orange' },
|
||||
{ value: 'bcc', label: 'Bcc', position: 3, color: 'red' },
|
||||
],
|
||||
defaultValue: { value: 'from' },
|
||||
defaultValue: "'from'",
|
||||
})
|
||||
role: string;
|
||||
|
||||
|
||||
@ -55,7 +55,7 @@ export class MessageObjectMetadata extends BaseObjectMetadata {
|
||||
{ value: 'incoming', label: 'Incoming', position: 0, color: 'green' },
|
||||
{ value: 'outgoing', label: 'Outgoing', position: 1, color: 'blue' },
|
||||
],
|
||||
defaultValue: { value: 'incoming' },
|
||||
defaultValue: "'incoming'",
|
||||
})
|
||||
direction: string;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user