|
@@ -7,6 +7,7 @@ import com.jeeplus.common.utils.StringUtils;
|
|
|
import com.jeeplus.common.web.BaseController;
|
|
|
import com.jeeplus.modules.projectConstruction.entity.ConstructionContract;
|
|
|
import com.jeeplus.modules.projectConstruction.service.ContractService;
|
|
|
+import com.jeeplus.modules.projectVisa.entity.ProjectVisa;
|
|
|
import com.jeeplus.modules.projectVisa.entity.VisaTreeData;
|
|
|
import com.jeeplus.modules.projectVisa.service.ProjectVisaService;
|
|
|
import com.jeeplus.modules.projectcontentinfo.entity.ProjectContentData;
|
|
@@ -80,7 +81,11 @@ public class MaterialController extends BaseController {
|
|
|
if(UserUtils.isManager()){
|
|
|
model.addAttribute("flag","1");
|
|
|
}
|
|
|
- Page<ConstructionContract> page = contractService.findPage(new Page<ConstructionContract>(request, response), constructionContract);
|
|
|
+ ProjectImplementEarly projectRecords = new ProjectImplementEarly();
|
|
|
+ if(StringUtils.isNotBlank(constructionContract.getProjectName())){
|
|
|
+ projectRecords.setProjectName(constructionContract.getProjectName());
|
|
|
+ }
|
|
|
+ Page<ProjectImplementEarly> page = projectImplementEarlyService.findProjectPage(new Page<ProjectImplementEarly>(request, response), projectRecords);
|
|
|
model.addAttribute("page", page);
|
|
|
return "modules/projectrecord/contractMaterial/materialList";
|
|
|
}
|
|
@@ -232,7 +237,7 @@ public class MaterialController extends BaseController {
|
|
|
|
|
|
String str = materialService.saveData(materialProjectInfo);
|
|
|
addMessage(redirectAttributes, "保存内容信息"+(str.equals("true")?"成功":"失败"));
|
|
|
- return "redirect:"+ Global.getAdminPath()+"/project/contractMaterial/?";
|
|
|
+ return "redirect:"+ Global.getAdminPath()+"/project/contractMaterial/?repage";
|
|
|
}
|
|
|
|
|
|
@RequestMapping("ajaxdelete")
|
|
@@ -261,30 +266,25 @@ public class MaterialController extends BaseController {
|
|
|
@RequestMapping(value = {"deleteConcealProject"})
|
|
|
public String deleteConcealProject(MaterialProjectInfo materialProjectInfo) {
|
|
|
materialService.deleteConcealProject(materialProjectInfo);
|
|
|
- return "redirect:"+ Global.getAdminPath()+"/project/contractMaterial/?";
|
|
|
+ return "redirect:"+ Global.getAdminPath()+"/project/contractMaterial/?repage";
|
|
|
}
|
|
|
-
|
|
|
- /*//添加暂定材料页面
|
|
|
- @RequestMapping(value = "view")
|
|
|
- public String view(MaterialProjectInfo materialProjectInfo, Model model) {
|
|
|
-
|
|
|
- ProjectContentData projectContentData = new ProjectContentData();
|
|
|
- projectContentData.setType("");
|
|
|
- if (StringUtils.isNotBlank(materialProjectInfo.getInfoId())){
|
|
|
- projectContentData = materialService.getProjectContentData(materialProjectInfo.getInfoId());
|
|
|
- }else if (materialProjectInfo.getProjectContentData()!=null && StringUtils.isNotBlank(materialProjectInfo.getProjectContentData().getId())) {
|
|
|
- projectContentData = materialService.getProjectContentData(materialProjectInfo.getProjectContentData().getId());
|
|
|
- }
|
|
|
- projectContentData.setMaster(UserUtils.getUser());
|
|
|
- if(StringUtils.isNotBlank(projectContentData.getId())){
|
|
|
- List<ProjectControlTable> controlData = projectControlTableService.getControlData(projectContentData.getId(),"");
|
|
|
- projectContentData.setProjectControlTableList(controlData);
|
|
|
- projectContentDataService.queryBasedData(projectContentData);
|
|
|
+ /**
|
|
|
+ * 删除依据性资料
|
|
|
+ */
|
|
|
+ @RequestMapping(value = "delete")
|
|
|
+ @ResponseBody
|
|
|
+ public Map<String,Object> delete(ProjectVisa projectVisa, RedirectAttributes redirectAttributes) {
|
|
|
+ Map<String,Object> j= new HashMap<>();
|
|
|
+ try {
|
|
|
+ projectVisaService.deleteByLogic(projectVisa.getId(),projectVisa.getType());
|
|
|
+ j.put("status",true);
|
|
|
+ j.put("msg","删除成功");
|
|
|
+ addMessage(redirectAttributes, "删除成功");
|
|
|
+ }catch (Exception e){
|
|
|
+ j.put("status",false);
|
|
|
+ j.put("msg","删除失败");
|
|
|
+ addMessage(redirectAttributes, "删除失败");
|
|
|
}
|
|
|
-
|
|
|
- materialProjectInfo.setProjectContentData(projectContentData);
|
|
|
- model.addAttribute("materialProjectInfo", materialProjectInfo);
|
|
|
-
|
|
|
- return "modules/projectrecord/contractMaterial/workContentForm";
|
|
|
- }*/
|
|
|
+ return j;
|
|
|
+ }
|
|
|
}
|