联调修改
This commit is contained in:
parent
72888e955a
commit
ae02fbcd8f
|
|
@ -4,7 +4,9 @@ import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.bonus.canteen.core.menu.domain.MapBean;
|
import com.bonus.canteen.core.menu.domain.MapBean;
|
||||||
|
import com.bonus.canteen.core.menu.dto.LongIds;
|
||||||
import com.bonus.canteen.core.menu.dto.MenuDishesDTO;
|
import com.bonus.canteen.core.menu.dto.MenuDishesDTO;
|
||||||
|
import com.bonus.canteen.core.menu.dto.StringIds;
|
||||||
import com.bonus.canteen.core.menu.service.IMenuDishesService;
|
import com.bonus.canteen.core.menu.service.IMenuDishesService;
|
||||||
import com.bonus.common.log.enums.OperaType;
|
import com.bonus.common.log.enums.OperaType;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
|
|
@ -133,8 +135,8 @@ public class MenuDishesController extends BaseController {
|
||||||
//@PreventRepeatSubmit
|
//@PreventRepeatSubmit
|
||||||
//@RequiresPermissions("menu:dishes:remove")
|
//@RequiresPermissions("menu:dishes:remove")
|
||||||
@SysLog(title = "菜品信息", businessType = OperaType.DELETE, logType = 1,module = "仓储管理->删除菜品信息")
|
@SysLog(title = "菜品信息", businessType = OperaType.DELETE, logType = 1,module = "仓储管理->删除菜品信息")
|
||||||
@PostMapping("/del/{ids}")
|
@PostMapping("/del")
|
||||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
public AjaxResult remove(@RequestBody LongIds ids) {
|
||||||
return toAjax(menuDishesService.deleteMenuDishesByIds(ids));
|
return toAjax(menuDishesService.deleteMenuDishesByIds(ids.getIds()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -48,6 +48,14 @@ public class MenuNutritionController extends BaseController {
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "根据categoryId获取营养类别集合")
|
||||||
|
//@RequiresPermissions("menu:nutrition:list")
|
||||||
|
@PostMapping ("/getListByCategoryId")
|
||||||
|
public AjaxResult getListByCategoryId(@RequestBody MenuNutrition menuNutrition) {
|
||||||
|
List<MenuNutrition> list = menuNutritionService.selectMenuNutritionList(menuNutrition);
|
||||||
|
return success(list);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出食材营养基础信息列表
|
* 导出食材营养基础信息列表
|
||||||
*/
|
*/
|
||||||
|
|
@ -69,7 +77,7 @@ public class MenuNutritionController extends BaseController {
|
||||||
//@RequiresPermissions("menu:nutrition:query")
|
//@RequiresPermissions("menu:nutrition:query")
|
||||||
@PostMapping(value = "/getInfo")
|
@PostMapping(value = "/getInfo")
|
||||||
public AjaxResult getInfo(@RequestBody MenuNutritionDTO menuNutrition) {
|
public AjaxResult getInfo(@RequestBody MenuNutritionDTO menuNutrition) {
|
||||||
return success(menuNutritionService.selectMenuNutritionById(menuNutrition.getId()));
|
return success(menuNutritionService.selectMenuNutritionById(menuNutrition.getNutritionId()));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -134,12 +134,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="nutritionName != null and nutritionName != ''"> and nutrition_name like concat('%', #{nutritionName}, '%')</if>
|
<if test="nutritionName != null and nutritionName != ''"> and nutrition_name like concat('%', #{nutritionName}, '%')</if>
|
||||||
<if test="bigType != null and bigType != ''"> and big_type = #{bigType}</if>
|
<if test="bigType != null and bigType != ''"> and big_type = #{bigType}</if>
|
||||||
<if test="littleType != null and littleType != ''"> and little_type = #{littleType}</if>
|
<if test="littleType != null and littleType != ''"> and little_type = #{littleType}</if>
|
||||||
|
<if test="categoryId != null and categoryId != ''"> and category_id = #{categoryId}</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectMenuNutritionById" parameterType="Long" resultMap="MenuNutritionResult">
|
<select id="selectMenuNutritionById" parameterType="Long" resultMap="MenuNutritionResult">
|
||||||
<include refid="selectMenuNutritionVo"/>
|
<include refid="selectMenuNutritionVo"/>
|
||||||
where nutrition_id = #{id}
|
where nutrition_id = #{nutritionId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertMenuNutrition" parameterType="com.bonus.canteen.core.menu.domain.MenuNutrition" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insertMenuNutrition" parameterType="com.bonus.canteen.core.menu.domain.MenuNutrition" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
|
|
||||||
|
|
@ -71,9 +71,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
left join menu_recipe mr on mar.recipe_id = mr.recipe_id
|
left join menu_recipe mr on mar.recipe_id = mr.recipe_id
|
||||||
where bind_type = #{bindType}
|
where bind_type = #{bindType}
|
||||||
) a on a.stall_id =t1.stall_id
|
) a on a.stall_id =t1.stall_id
|
||||||
WHERE
|
WHERE 1=1
|
||||||
<if test="deviceTypeList != null and deviceTypeList.size() > 0">
|
<if test="deviceTypeList != null and deviceTypeList.size() > 0">
|
||||||
|
and
|
||||||
EXISTS (
|
EXISTS (
|
||||||
SELECT NULL
|
SELECT NULL
|
||||||
FROM
|
FROM
|
||||||
|
|
@ -86,25 +86,25 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<foreach collection="deviceTypeList" item="deviceType" separator="," open="(" close=")">
|
<foreach collection="deviceTypeList" item="deviceType" separator="," open="(" close=")">
|
||||||
#{deviceType}
|
#{deviceType}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
)
|
||||||
</if>
|
</if>
|
||||||
)
|
|
||||||
|
|
||||||
and 1=1
|
where 1= 1
|
||||||
|
|
||||||
<if test="areaIds !=null">
|
<if test="areaIds !=null">
|
||||||
and ala.area_id in
|
and t3.area_id in
|
||||||
<foreach collection="areaIds" open="(" close=")" item="item" separator=",">
|
<foreach collection="areaIds" open="(" close=")" item="item" separator=",">
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
<if test="canteenIds !=null">
|
<if test="canteenIds !=null">
|
||||||
and ac.canteen_id in
|
and t2.canteen_id in
|
||||||
<foreach collection="canteenIds" open="(" close=")" item="item" separator=",">
|
<foreach collection="canteenIds" open="(" close=")" item="item" separator=",">
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
<if test="stallIds !=null">
|
<if test="stallIds !=null">
|
||||||
and als.stall_id in
|
and t1.stall_id in
|
||||||
<foreach collection="stallIds" open="(" close=")" item="item" separator=",">
|
<foreach collection="stallIds" open="(" close=")" item="item" separator=",">
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
|
@ -114,7 +114,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
and a.recipe_name like concat('%', #{recipeName}, '%')
|
and a.recipe_name like concat('%', #{recipeName}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
|
||||||
<!-- <include refid="selectMenuRecipeVo"/>-->
|
<!-- <include refid="selectMenuRecipeVo"/>-->
|
||||||
<!-- <where> -->
|
<!-- <where> -->
|
||||||
<!-- <if test="recipeId != null "> and recipe_id = #{recipeId}</if>-->
|
<!-- <if test="recipeId != null "> and recipe_id = #{recipeId}</if>-->
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue