修改每日菜品删除接口
This commit is contained in:
1 parent
e5b9768998
commit
d660e55f26
2 files changed
+5
-5
No files matched your search
@@ -23,11 +23,11 @@ export function getObj(id?: string) {
|
||||
})
|
||||
}
|
||||
|
||||
export function delObjs(data?: Object) {
|
||||
export function delObjs(tid: number[], merchantId: string) {
|
||||
return request({
|
||||
url: "/canteen/canteenDailyMenu",
|
||||
url: `/canteen/canteenDailyMenu?merchantId=${merchantId}`,
|
||||
method: "delete",
|
||||
data,
|
||||
data: tid,
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ const weekParams = reactive({
|
||||
const weekData = reactive({
|
||||
data: [],
|
||||
}) //时间数组
|
||||
const merchantId = ref()
|
||||
const merchantId = ref() // 商户id
|
||||
const merchantInfo = ref<any>([])
|
||||
|
||||
const addFood = async (hourType: number) => {
|
||||
@@ -177,7 +177,7 @@ const selectTimeFood = async () => {
|
||||
const delteData = async (tid: number) => {
|
||||
await message.delConfirm("确定删除菜品吗?", "今日菜品?")
|
||||
try {
|
||||
await delObjs([tid])
|
||||
await delObjs([tid], merchantId.value)
|
||||
message.success("删除成功")
|
||||
} catch (error) {
|
||||
message.error("删除失败")
|
||||
|
||||
Reference in new issue
Block a user