Make name property required when creating templates, dal connections, workflows, auth clients and sensitivity levelsE
This commit is contained in:
parent
424ee1c1fc
commit
4ccafb19da
@ -17,6 +17,7 @@
|
||||
v-model="authClient.meta.name"
|
||||
data-test-id="input-name"
|
||||
required
|
||||
:state="nameState"
|
||||
/>
|
||||
</b-form-group>
|
||||
|
||||
@ -634,6 +635,10 @@ export default {
|
||||
return this.secret.length > 0
|
||||
},
|
||||
|
||||
nameState () {
|
||||
return this.authClient.meta.name ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.authClient.handle)
|
||||
},
|
||||
@ -647,7 +652,7 @@ export default {
|
||||
},
|
||||
|
||||
saveDisabled () {
|
||||
return !this.editable || [this.handleState].includes(false)
|
||||
return !this.editable || [this.nameState, this.handleState].includes(false)
|
||||
},
|
||||
},
|
||||
|
||||
|
||||
@ -15,8 +15,10 @@
|
||||
>
|
||||
<b-form-input
|
||||
v-model="connection.meta.name"
|
||||
required
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('form.name.placeholder')"
|
||||
:state="nameState"
|
||||
/>
|
||||
</b-form-group>
|
||||
</b-col>
|
||||
@ -165,6 +167,10 @@ export default {
|
||||
},
|
||||
|
||||
computed: {
|
||||
nameState () {
|
||||
return this.connection.meta.name ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.connection.handle)
|
||||
},
|
||||
|
||||
@ -17,6 +17,8 @@
|
||||
>
|
||||
<b-form-input
|
||||
v-model="sensitivityLevel.meta.name"
|
||||
required
|
||||
:state="nameState"
|
||||
/>
|
||||
</b-form-group>
|
||||
</b-col>
|
||||
@ -183,12 +185,16 @@ export default {
|
||||
return this.fresh ? this.canCreate : true
|
||||
},
|
||||
|
||||
nameState () {
|
||||
return this.sensitivityLevel.meta.name ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.sensitivityLevel.handle)
|
||||
},
|
||||
|
||||
saveDisabled () {
|
||||
return !this.editable || [this.handleState].includes(false)
|
||||
return !this.editable || [this.nameState, this.handleState].includes(false)
|
||||
},
|
||||
|
||||
getDeleteStatus () {
|
||||
|
||||
@ -15,6 +15,8 @@
|
||||
<b-form-input
|
||||
v-model="template.meta.short"
|
||||
data-test-id="input-short-name"
|
||||
required
|
||||
:state="shortState"
|
||||
/>
|
||||
</b-form-group>
|
||||
|
||||
@ -200,12 +202,16 @@ export default {
|
||||
return this.fresh ? this.canCreate : true // this.template.canUpdateRole
|
||||
},
|
||||
|
||||
shortState () {
|
||||
return this.template.meta.short ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.template.handle)
|
||||
},
|
||||
|
||||
saveDisabled () {
|
||||
return !this.editable || [this.handleState].includes(false)
|
||||
return !this.editable || [this.shortState, this.handleState].includes(false)
|
||||
},
|
||||
|
||||
getDeleteStatus () {
|
||||
|
||||
@ -27,6 +27,7 @@
|
||||
<b-form-input
|
||||
v-model="workflow.meta.name"
|
||||
required
|
||||
:state="nameState"
|
||||
/>
|
||||
</b-form-group>
|
||||
|
||||
@ -187,6 +188,10 @@ export default {
|
||||
return (!this.workflow.workflowID || this.workflow.workflowID === NoID) || this.workflow.canUpdateWorkflow
|
||||
},
|
||||
|
||||
nameState () {
|
||||
return this.workflow.meta.name ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.workflow.handle)
|
||||
},
|
||||
|
||||
@ -132,12 +132,16 @@ export default {
|
||||
return this.fresh ? this.canCreate : true // this.user.canUpdateUser
|
||||
},
|
||||
|
||||
nameState () {
|
||||
return this.connection.meta.name ? null : false
|
||||
},
|
||||
|
||||
handleState () {
|
||||
return handle.handleState(this.connection.handle)
|
||||
},
|
||||
|
||||
saveDisabled () {
|
||||
return !this.editable || [this.handleState].includes(false)
|
||||
return !this.editable || [this.nameState, this.handleState].includes(false)
|
||||
},
|
||||
|
||||
},
|
||||
|
||||
@ -1559,9 +1559,6 @@ export default class System {
|
||||
level,
|
||||
meta,
|
||||
} = (a as KV) || {}
|
||||
if (!handle) {
|
||||
throw Error('field handle is empty')
|
||||
}
|
||||
if (!level) {
|
||||
throw Error('field level is empty')
|
||||
}
|
||||
@ -1596,9 +1593,6 @@ export default class System {
|
||||
if (!sensitivityLevelID) {
|
||||
throw Error('field sensitivityLevelID is empty')
|
||||
}
|
||||
if (!handle) {
|
||||
throw Error('field handle is empty')
|
||||
}
|
||||
if (!level) {
|
||||
throw Error('field level is empty')
|
||||
}
|
||||
|
||||
@ -7,7 +7,7 @@ editor:
|
||||
handle: Handle
|
||||
invalid-handle-characters: Should be at least 2 characters long and start with a letter. Can contain only letters, numbers, dashes, underscores and dots
|
||||
id: ID
|
||||
name: Name
|
||||
name: Name *
|
||||
openBuilder: Open builder
|
||||
title: Basic information
|
||||
undelete: Undelete
|
||||
|
||||
@ -20,7 +20,7 @@ editor:
|
||||
label: Handle
|
||||
placeholder-handle: handle (a - z, 0 - 9, underscore, dash)
|
||||
invalid-handle-characters: Should be at least 2 characters long and start with a letter. Can contain only letters, numbers, dashes, underscores and dots
|
||||
name: Name
|
||||
name: Name *
|
||||
no-time: No time selected
|
||||
profile: Allow client access to user's profile
|
||||
redirectURI: Redirect URI's
|
||||
|
||||
@ -33,7 +33,7 @@ editor:
|
||||
title: Basic settings
|
||||
form:
|
||||
name:
|
||||
label: Name
|
||||
label: Name *
|
||||
placeholder: Data lake
|
||||
description: ''
|
||||
handle:
|
||||
|
||||
@ -9,7 +9,7 @@ editor:
|
||||
label: Handle
|
||||
placeholder: handle (a - z, 0 - 9, underscore, dash)
|
||||
invalid-characters: Should be at least 2 characters long and start with a letter. Can contain only letters, numbers, dashes, underscores and dots
|
||||
name: Name
|
||||
name: Name *
|
||||
description: Description
|
||||
level: Level {{level}}
|
||||
createdAt: Created at
|
||||
|
||||
@ -31,7 +31,7 @@ editor:
|
||||
invalid-handle-characters: Should be at least 2 characters long and start with a letter. Can contain only letters, numbers, dashes, underscores and dots
|
||||
meta:
|
||||
description: Description
|
||||
short: Short name
|
||||
short: Short name *
|
||||
partial: Partial template
|
||||
partialDescription: Partial templates may be used inside other templates such as headers and footers. Partial templates may not be used on their own.
|
||||
title: Basic information
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user