- {{ mObj.name }}
+ {{ mObj.igdList[0].name }}
+
+
- {{ mObj.cusStr }}
- {{ mObj.weight }}克
+ {{
+ mObj.igdList[0].cusStr
+ }}
+ {{ mObj.igdList[0].weight }}克
@@ -82,24 +94,24 @@ export default {
if (!obj[cur.type]) {
obj[cur.type] = [];
}
- let tarMenu = cur;
- if (
- !tarMenu.methods &&
- !tarMenu.remark &&
- tarMenu.igdList.length === 1
- ) {
- tarMenu = tarMenu.igdList[0];
- tarMenu.cusStr = `${this.cusWeightDict[tarMenu.cusWeight] || ""}${
- this.cusUnitDict[tarMenu.cusUnit] || ""
+ // let tarMenu = cur;
+ // if (
+ // !tarMenu.methods &&
+ // !tarMenu.remark &&
+ // tarMenu.igdList.length === 1
+ // ) {
+ // tarMenu = tarMenu.igdList[0];
+ // tarMenu.cusStr = `${this.cusWeightDict[tarMenu.cusWeight] || ""}${
+ // this.cusUnitDict[tarMenu.cusUnit] || ""
+ // }`;
+ // } else {
+ cur.igdList.forEach((igd) => {
+ igd.cusStr = `${this.cusWeightDict[igd.cusWeight] || ""}${
+ this.cusUnitDict[igd.cusUnit] || ""
}`;
- } else {
- tarMenu.igdList.forEach((igd) => {
- igd.cusStr = `${this.cusWeightDict[igd.cusWeight] || ""}${
- this.cusUnitDict[igd.cusUnit] || ""
- }`;
- });
- }
- obj[cur.type].push(tarMenu);
+ });
+ // }
+ obj[cur.type].push(cur);
return obj;
}, {});
const mMenus = Object.keys(mData).map((type) => ({
@@ -107,7 +119,7 @@ export default {
typeName: this.menuTypeDict[type],
values: mData[type],
}));
- // console.log(mMenus);
+ console.log(mMenus);
return mMenus;
},
...mapState(["cusUnitDict", "cusWeightDict", "menuTypeDict"]),
diff --git a/stdiet-ui/src/views/custom/recipesShow/index.vue b/stdiet-ui/src/views/custom/recipesShow/index.vue
index 09a8eff3f..6e816630b 100644
--- a/stdiet-ui/src/views/custom/recipesShow/index.vue
+++ b/stdiet-ui/src/views/custom/recipesShow/index.vue
@@ -7,7 +7,6 @@
class="icon_btn"
@click="handleOnPlanClick"
/>
-
{{ curDate }}