周计划预览
This commit is contained in:
@ -103,4 +103,23 @@ public class ByThemeController extends BaseController {
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(byThemeService.deleteByThemeByIds(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询主题整合活动列表
|
||||
*/
|
||||
@PostMapping("/listthemebyid/{ids}")
|
||||
public TableDataInfo listbythemeid(@PathVariable Long[] ids) {
|
||||
List<ByTheme> list = byThemeService.selectByThemeByIds(ids);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询主题整合活动列表
|
||||
*/
|
||||
@PostMapping("/listthemebyactivityid/{ids}")
|
||||
public TableDataInfo listthemebyactivityid(@PathVariable Long[] ids) {
|
||||
List<ByTheme> list = byThemeService.selectByThemeByActivityIds(ids);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -14,6 +14,7 @@ import com.ruoyi.project.benyi.service.IByThemeMonthplanitemService;
|
||||
import com.ruoyi.project.benyi.service.IByThemeWeekplanitemService;
|
||||
import com.ruoyi.project.common.SchoolCommon;
|
||||
import com.ruoyi.project.system.service.IByClassService;
|
||||
import com.ruoyi.project.system.service.ISysUserService;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@ -54,6 +55,9 @@ public class ByThemeWeekplanController extends BaseController {
|
||||
private IByThemeMonthplanitemService byThemeonthplanitemService;
|
||||
@Autowired
|
||||
private IByThemeWeekplanitemService byThemeWeekplanitemService;
|
||||
@Autowired
|
||||
private ISysUserService userService;
|
||||
|
||||
|
||||
/**
|
||||
* 查询主题整合周计划(根据月计划明细)列表
|
||||
@ -93,7 +97,12 @@ public class ByThemeWeekplanController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('benyi:themeweekplan:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") String id) {
|
||||
return AjaxResult.success(byThemeWeekplanService.selectByThemeWeekplanById(id));
|
||||
AjaxResult ajax=AjaxResult.success();
|
||||
ByThemeWeekplan byThemeWeekplan=byThemeWeekplanService.selectByThemeWeekplanById(id);
|
||||
ajax.put(AjaxResult.DATA_TAG, byThemeWeekplan);
|
||||
ajax.put("classname",byClassService.selectByClassById(byThemeWeekplan.getClassid()).getBjmc());
|
||||
ajax.put("createusername",userService.selectUserById(byThemeWeekplan.getCreateuserid()).getNickName());
|
||||
return ajax;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -66,4 +66,20 @@ public interface ByThemeMapper {
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteByThemeByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合
|
||||
*/
|
||||
public List<ByTheme> selectByThemeByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合
|
||||
*/
|
||||
public List<ByTheme> selectByThemeByActivityIds(Long[] ids);
|
||||
}
|
||||
|
@ -83,4 +83,20 @@ public interface IByThemeService {
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteByThemeById(Long id);
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合
|
||||
*/
|
||||
public List<ByTheme> selectByThemeByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合
|
||||
*/
|
||||
public List<ByTheme> selectByThemeByActivityIds(Long[] ids);
|
||||
}
|
||||
|
@ -185,4 +185,26 @@ public class ByThemeServiceImpl implements IByThemeService {
|
||||
public int deleteByThemeById(Long id) {
|
||||
return byThemeMapper.deleteByThemeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合selectByThemeByIds
|
||||
*/
|
||||
@Override
|
||||
public List<ByTheme> selectByThemeByIds(Long[] ids) {
|
||||
return byThemeMapper.selectByThemeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询主题整合列表
|
||||
*
|
||||
* @param ids 主题整合
|
||||
* @return 主题整合集合
|
||||
*/
|
||||
@Override
|
||||
public List<ByTheme> selectByThemeByActivityIds(Long[] ids) {
|
||||
return byThemeMapper.selectByThemeByActivityIds(ids);
|
||||
}
|
||||
}
|
||||
|
@ -92,11 +92,28 @@
|
||||
delete from by_theme where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteByThemeByIds" parameterType="String">
|
||||
<delete id="deleteByThemeByIds" parameterType="Long">
|
||||
delete from by_theme where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<select id="selectByThemeByIds" parameterType="Long" resultMap="ByThemeResult">
|
||||
<include refid="selectByThemeVo"/>
|
||||
where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</select>
|
||||
|
||||
<select id="selectByThemeByActivityIds" parameterType="Long" resultMap="ByThemeResult">
|
||||
select * from by_theme where id in (
|
||||
select themeid from by_theme_activity where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
)
|
||||
</select>
|
||||
|
||||
</mapper>
|
Reference in New Issue
Block a user