Настроил скрытие формы после успешного добавления

master
Sipachev Igor 3 years ago
parent 6bb6835145
commit 20d89cbb0e
  1. 3
      popup/src/components/mocks/script.ts
  2. 2
      popup/src/components/mocks/template.html

@ -20,6 +20,7 @@ export default class Mocks extends Vue {
mode!: Mode mode!: Mode
showLoader = false showLoader = false
isHidden = false
registers = new Registers() registers = new Registers()
register2Id: Record<string, string> = {} register2Id: Record<string, string> = {}
@ -31,6 +32,7 @@ export default class Mocks extends Vue {
onPersonalCodeChanged () { onPersonalCodeChanged () {
this.registers.reset() this.registers.reset()
this.showLoader = false this.showLoader = false
this.isHidden = false
this.refreshMocks() this.refreshMocks()
} }
@ -115,6 +117,7 @@ export default class Mocks extends Vue {
}) })
.then(() => { .then(() => {
this.showLoader = false this.showLoader = false
this.isHidden = true
}) })
} }

@ -1,4 +1,4 @@
<div> <div v-if="!isHidden">
<div v-if="showLoader" class="lds-grid"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div> <div v-if="showLoader" class="lds-grid"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>
<div v-if="!showLoader"> <div v-if="!showLoader">
<div class="mock-service__select"> <div class="mock-service__select">

Loading…
Cancel
Save