several small fixes to new components
This commit is contained in:
@ -12,8 +12,7 @@
|
|||||||
:list_name="this_model.name"
|
:list_name="this_model.name"
|
||||||
@reset="resetList"
|
@reset="resetList"
|
||||||
@get-list="getItems"
|
@get-list="getItems"
|
||||||
@item-action="startAction"
|
@item-action="startAction">
|
||||||
>
|
|
||||||
<template v-slot:cards-left>
|
<template v-slot:cards-left>
|
||||||
<generic-horizontal-card
|
<generic-horizontal-card
|
||||||
v-for="i in items_left" v-bind:key="i.id"
|
v-for="i in items_left" v-bind:key="i.id"
|
||||||
@ -22,8 +21,7 @@
|
|||||||
:draggable="true"
|
:draggable="true"
|
||||||
:merge="true"
|
:merge="true"
|
||||||
:move="true"
|
:move="true"
|
||||||
@item-action="startAction($event, 'left')"
|
@item-action="startAction($event, 'left')">
|
||||||
>
|
|
||||||
<!-- foods can also be a recipe, show link to the recipe if it exists -->
|
<!-- foods can also be a recipe, show link to the recipe if it exists -->
|
||||||
<template v-slot:upper-right>
|
<template v-slot:upper-right>
|
||||||
<b-button v-if="i.recipe" v-b-tooltip.hover :title="i.recipe.name"
|
<b-button v-if="i.recipe" v-b-tooltip.hover :title="i.recipe.name"
|
||||||
@ -38,8 +36,7 @@
|
|||||||
:draggable="true"
|
:draggable="true"
|
||||||
:merge="true"
|
:merge="true"
|
||||||
:move="true"
|
:move="true"
|
||||||
@item-action="startAction($event, 'right')"
|
@item-action="startAction($event, 'right')">
|
||||||
>
|
|
||||||
<!-- foods can also be a recipe, show link to the recipe if it exists -->
|
<!-- foods can also be a recipe, show link to the recipe if it exists -->
|
||||||
<template v-slot:upper-right>
|
<template v-slot:upper-right>
|
||||||
<b-button v-if="i.recipe" v-b-tooltip.hover :title="i.recipe.name"
|
<b-button v-if="i.recipe" v-b-tooltip.hover :title="i.recipe.name"
|
||||||
@ -50,7 +47,6 @@
|
|||||||
</generic-split-lists>
|
</generic-split-lists>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -273,7 +269,10 @@ export default {
|
|||||||
this.clearState()
|
this.clearState()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.genericAPI(this.this_model, this.Actions.MERGE, {'source': source_id, 'target': target_id}).then((result) => {
|
this.genericAPI(this.this_model, this.Actions.MERGE, {
|
||||||
|
'source': source_id,
|
||||||
|
'target': target_id
|
||||||
|
}).then((result) => {
|
||||||
this.items_left = this.destroyCard(source_id, this.items_left)
|
this.items_left = this.destroyCard(source_id, this.items_left)
|
||||||
this.items_right = this.destroyCard(source_id, this.items_right)
|
this.items_right = this.destroyCard(source_id, this.items_right)
|
||||||
this.refreshThis(target_id)
|
this.refreshThis(target_id)
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div row>
|
<div row style="margin: 4px">
|
||||||
<b-card no-body d-flex flex-column :class="{'border border-primary' : over, 'shake': isError}"
|
<b-card no-body d-flex flex-column :class="{'border border-primary' : over, 'shake': isError}"
|
||||||
style="height: 10vh;" :style="{'cursor:grab' : draggable}"
|
style="height: 10vh;" :style="{'cursor:grab' : draggable}"
|
||||||
@dragover.prevent
|
@dragover.prevent
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
style="flex-grow: 1; flex-shrink: 1; flex-basis: 0"
|
style="flex-grow: 1; flex-shrink: 1; flex-basis: 0"
|
||||||
:placeholder="modelName">
|
:placeholder="modelName">
|
||||||
</generic-multiselect>
|
</generic-multiselect>
|
||||||
|
</b-form-group>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user