feat:更新美食模块图片功能
This commit is contained in:
@@ -11,6 +11,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<draggable-button @click="addClick"/>
|
||||
|
||||
<arrive-bottom v-if="foodStore.isScrollEnd"/>
|
||||
</div>
|
||||
</template>
|
||||
@@ -21,9 +23,12 @@ import FoodCard from '@/components/Food/FoodCard.vue'
|
||||
import ArriveBottom from '@/components/Common/ArriveButton.vue'
|
||||
import { useFoodStore } from '@/store/food.ts'
|
||||
import { onBeforeUnmount, onMounted, ref } from 'vue'
|
||||
import DraggableButton from '@/components/Common/DraggableButton.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
const foodRecipeRef = ref()
|
||||
const foodStore = useFoodStore()
|
||||
const router = useRouter()
|
||||
|
||||
onMounted(async () => {
|
||||
foodStore.pageInfo = {
|
||||
@@ -51,6 +56,12 @@ const handleScroll = () => {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const addClick = () => {
|
||||
foodStore.foodRecipeApiType = 'ADD'
|
||||
foodStore.currentFoodRecipe = foodStore.getEmptyFoodRecipe()
|
||||
router.push({ name: 'FoodRecipeForm' })
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
|
||||
Reference in New Issue
Block a user