1
0
mirror of https://github.com/PanJiaChen/vue-element-admin.git synced 2025-08-07 18:25:45 +08:00

Improve the display when recording the location (#1051)

Co-authored-by: elsiosanchez <elsiossanches@gmail.com>
This commit is contained in:
Elsio Sanchez 2021-08-12 17:11:50 -04:00 committed by GitHub
parent 2ce8853978
commit 427ffd0b75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 25 additions and 24 deletions

View File

@ -16,28 +16,26 @@
along with this program. If not, see <https:www.gnu.org/licenses/>.
-->
<template>
<div>
<el-popover
ref="locationAddress"
v-model="isShowedLocationForm"
:placement="popoverPlacement"
width="300"
trigger="manual"
>
<location-address-form
v-if="isShowedLocationForm"
:values="localValues"
:parent-metadata="metadata"
/>
</el-popover>
<el-input
v-model="displayedValue"
readonly
@focus="setShowedLocationForm(true)"
>
<i slot="prefix" class="el-icon-location-information el-input__icon" />
</el-input>
</div>
<el-popover
ref="locationAddress"
v-model="isShowedLocationForm"
placement="left-end"
width="300"
trigger="manual"
>
<location-address-form
:values="localValues"
:parent-metadata="metadata"
/>
<el-button slot="reference" type="text" style="width: -webkit-fill-available;" @click="setShowedLocationForm(true)">
<el-input
v-model="displayedValue"
readonly
>
<i slot="prefix" class="el-icon-location-information el-input__icon" />
</el-input>
</el-button>
</el-popover>
</template>
<script>

View File

@ -42,8 +42,7 @@
style="min-height: calc(50vh - 84px)"
class="loading-panel"
/>
<el-col :span="24">
<el-col :span="24" style="padding-left: 12px;padding-right: 12px;padding-top: 3%;padding-bottom: 3%;">
<samp style="float: right; padding-right: 10px;">
<el-button
:disabled="!isLoaded"

View File

@ -24,6 +24,7 @@
placement="right"
width="400"
trigger="click"
@hide="popoverClose"
>
<business-partner-create
:parent-metadata="parentMetadata"
@ -402,6 +403,9 @@ export default {
},
popoverOpen(value) {
this.$store.dispatch('changePopover', true)
},
popoverClose(value) {
this.$store.commit('setShowedLocation', false)
}
}
}