Skip to content

Commit

Permalink
set business lookup visible
Browse files Browse the repository at this point in the history
  • Loading branch information
kzdev420 committed Aug 3, 2023
1 parent 1df5453 commit 6697735
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 7 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "name-request",
"version": "5.0.13",
"version": "5.0.14",
"private": true,
"appName": "Name Request UI",
"sbcName": "SBC Common Components",
Expand Down
16 changes: 12 additions & 4 deletions src/components/new-request/search.vue
Original file line number Diff line number Diff line change
Expand Up @@ -182,10 +182,8 @@
<v-row no-gutters>
<v-col cols="12">
<template>
<!-- Search for business identifier or name -->
<BusinessLookup
@business="businessName = $event.name; businessIdentifier = $event.identifier"
/>
<!-- Search for business identifier or name if NR request action is one of [CHG, AML, CNV, REH] -->
<BusinessLookup v-if="isBusinessLookup" />

<template v-if="businessIdentifier">
<dl>
Expand Down Expand Up @@ -554,6 +552,16 @@ export default class Search extends Mixins(CommonMixin) {
return this.getEntityTextFromValue || 'specified business type'
}
get isBusinessLookup () {
// show BusinessLookup when NR request actions are following these
return [
NrRequestActionCodes.AMALGAMATE,
NrRequestActionCodes.CHANGE_NAME,
NrRequestActionCodes.CONVERSION,
NrRequestActionCodes.RESTORE
].includes(this.getRequestActionCd)
}
async handleSubmit (doNameCheck = true) {
this.setDoNameCheck(doNameCheck)
if (this.getIsXproMras) this.$root.$emit('showSpinner', true)
Expand Down

0 comments on commit 6697735

Please sign in to comment.