mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-26 13:05:15 +00:00
Split Edit and Add constraints
This commit is contained in:
parent
727e1318cc
commit
8d5363d0f3
|
@ -2,6 +2,7 @@
|
||||||
<edit-value
|
<edit-value
|
||||||
v-model="plotStore.plotConfigName"
|
v-model="plotStore.plotConfigName"
|
||||||
:allow-edit="allowEdit"
|
:allow-edit="allowEdit"
|
||||||
|
:allow-add="allowEdit"
|
||||||
editable-name="plot configuration"
|
editable-name="plot configuration"
|
||||||
@rename="plotStore.renamePlotConfig"
|
@rename="plotStore.renamePlotConfig"
|
||||||
@delete="plotStore.deletePlotConfig"
|
@delete="plotStore.deletePlotConfig"
|
||||||
|
|
|
@ -22,15 +22,16 @@
|
||||||
>
|
>
|
||||||
<DeleteIcon :size="16" />
|
<DeleteIcon :size="16" />
|
||||||
</b-button>
|
</b-button>
|
||||||
<b-button
|
|
||||||
size="sm"
|
|
||||||
:title="`Add new ${editableName}.`"
|
|
||||||
class="ms-1"
|
|
||||||
variant="primary"
|
|
||||||
@click="addNewClick"
|
|
||||||
><AddIcon :size="16" />
|
|
||||||
</b-button>
|
|
||||||
</template>
|
</template>
|
||||||
|
<b-button
|
||||||
|
v-if="allowAdd && !(addNew || editing)"
|
||||||
|
size="sm"
|
||||||
|
:title="`Add new ${editableName}.`"
|
||||||
|
class="ms-1"
|
||||||
|
variant="primary"
|
||||||
|
@click="addNewClick"
|
||||||
|
><AddIcon :size="16" />
|
||||||
|
</b-button>
|
||||||
<template v-if="allowEdit && (addNew || editing)">
|
<template v-if="allowEdit && (addNew || editing)">
|
||||||
<b-button
|
<b-button
|
||||||
size="sm"
|
size="sm"
|
||||||
|
@ -66,6 +67,10 @@ const props = defineProps({
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
|
allowAdd: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
editableName: {
|
editableName: {
|
||||||
type: String,
|
type: String,
|
||||||
required: true,
|
required: true,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user