WIP
This commit is contained in:
@ -131,8 +131,9 @@ export default {
|
||||
let flat_items = []
|
||||
let item = undefined
|
||||
let label = this.form.list_label.split("::")
|
||||
this.list_label = label[1]
|
||||
itemlist.forEach((x) => {
|
||||
item = {}
|
||||
item = { ...x }
|
||||
for (const [k, v] of Object.entries(x)) {
|
||||
if (k == label[0]) {
|
||||
item["id"] = v.id
|
||||
@ -144,6 +145,7 @@ export default {
|
||||
flat_items.push(item)
|
||||
})
|
||||
this.first_run = false
|
||||
|
||||
return flat_items
|
||||
},
|
||||
unflattenItem: function (itemList) {
|
||||
|
@ -55,6 +55,7 @@
|
||||
</b-input-group-prepend>
|
||||
|
||||
<b-form-spinbutton min="1" v-model="recipe_servings" inline style="height: 3em"></b-form-spinbutton>
|
||||
<CustomInputSpinButton v-model.number="recipe_servings" style="height: 3em" />
|
||||
|
||||
<b-input-group-append>
|
||||
<b-button variant="secondary" @click="$bvModal.hide(`shopping_${modal_id}`)">{{ $t("Cancel") }} </b-button>
|
||||
@ -75,10 +76,11 @@ const { ApiApiFactory } = require("@/utils/openapi/api")
|
||||
import { StandardToasts } from "@/utils/utils"
|
||||
import IngredientsCard from "@/components/IngredientsCard"
|
||||
import LoadingSpinner from "@/components/LoadingSpinner"
|
||||
import CustomInputSpinButton from "@/components/CustomInputSpinButton"
|
||||
|
||||
export default {
|
||||
name: "ShoppingModal",
|
||||
components: { IngredientsCard, LoadingSpinner },
|
||||
components: { IngredientsCard, LoadingSpinner, CustomInputSpinButton },
|
||||
mixins: [],
|
||||
props: {
|
||||
recipe: { required: true, type: Object },
|
||||
|
Reference in New Issue
Block a user