Pārlūkot izejas kodu

知识库-知识分享:增加,行业标准及规范、企业标准及规范类型
将通告中两个类型的数据转存到知识分享中

user5 3 gadi atpakaļ
vecāks
revīzija
b381f9207b

+ 19 - 0
src/main/java/com/jeeplus/modules/knowledgeSharing/entity/KnowledgeSharingInfo.java

@@ -2,6 +2,7 @@ package com.jeeplus.modules.knowledgeSharing.entity;
 
 import com.google.common.collect.Lists;
 import com.jeeplus.common.persistence.DataEntity;
+import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.sys.entity.User;
 import com.jeeplus.modules.sys.entity.Workattachment;
 import com.jeeplus.modules.sys.utils.UserUtils;
@@ -29,6 +30,8 @@ public class KnowledgeSharingInfo extends DataEntity<KnowledgeSharingInfo> {
     private String replyCount;      //回复数
     private Integer isAdmin;      //登陆人是否为管理员
     private String commentContent;
+    private Office office;		// 部门ID
+    private Office company;		// 公司ID
 
     public String getColumnName() {
         return columnName;
@@ -147,4 +150,20 @@ public class KnowledgeSharingInfo extends DataEntity<KnowledgeSharingInfo> {
     public void setCommentContent(String commentContent) {
         this.commentContent = commentContent;
     }
+
+    public Office getOffice() {
+        return office;
+    }
+
+    public void setOffice(Office office) {
+        this.office = office;
+    }
+
+    public Office getCompany() {
+        return company;
+    }
+
+    public void setCompany(Office company) {
+        this.company = company;
+    }
 }

+ 5 - 0
src/main/java/com/jeeplus/modules/knowledgeSharing/service/KnowledgeSharingDetailsService.java

@@ -48,6 +48,9 @@ public class KnowledgeSharingDetailsService extends CrudService<KnowledgeSharing
         attchment.setAttachmentId(knowledgeSharingInfo.getId());
         attchment.setAttachmentFlag("183");
         List<Workattachment> attachments = workattachmentService.findList(attchment);
+        attchment.setAttachmentFlag("79");
+        List<Workattachment> attachmentTwos = workattachmentService.findList(attchment);
+        attachments.addAll(attachmentTwos);
         knowledgeSharingInfo.setWorkAttachments(attachments);
         for (Workattachment clientAttachment:attachments){
             if (clientAttachment.getCollectFlag().equals("1")){
@@ -77,6 +80,8 @@ public class KnowledgeSharingDetailsService extends CrudService<KnowledgeSharing
 
     @Transactional(readOnly = false)
     public void save(KnowledgeSharingInfo knowledgeSharingInfo) {
+        knowledgeSharingInfo.setOffice(UserUtils.getSelectOffice());
+        knowledgeSharingInfo.setCompany(UserUtils.getSelectCompany());
         knowledgeSharingInfo.setModerator("系统管理员");
         //添加信息
         super.save(knowledgeSharingInfo);

+ 2 - 2
src/main/java/com/jeeplus/modules/knowledgeSharing/web/KnowledgeSharingDetailsController.java

@@ -62,7 +62,7 @@ public class KnowledgeSharingDetailsController extends BaseController {
     @RequestMapping(value = {"list", ""})
     public String list(KnowledgeSharingInfo knowledgeSharingInfo, HttpServletRequest request, HttpServletResponse response, Model model) {
         if(StringUtils.isBlank(knowledgeSharingInfo.getColumnId())){
-            knowledgeSharingInfo.setColumnId("1");
+            knowledgeSharingInfo.setColumnId("7");
         }
         Page<KnowledgeSharingInfo> page = service.findPage(new Page<KnowledgeSharingInfo>(request, response), knowledgeSharingInfo);
         model.addAttribute("page", page);
@@ -113,7 +113,7 @@ public class KnowledgeSharingDetailsController extends BaseController {
             service.save(knowledgeSharingInfo);//保存
         }
         addMessage(redirectAttributes, "保存成功");
-        return "redirect:"+ Global.getAdminPath()+"/knowledgeSharing/knowledgeSharing/?repage";
+        return "redirect:"+ Global.getAdminPath()+"/knowledgeSharingDetails/knowledgeSharingDetails/?repage";
     }
 
     /**

+ 17 - 2
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralCostProjectMessageNewTwoController.java

@@ -8,7 +8,6 @@ import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.projectAccessory.entity.ProjectAccessoryRelationInfo;
-import com.jeeplus.modules.projectAccessory.entity.ProjectTemplateInfo;
 import com.jeeplus.modules.projectAccessory.service.ProjectTemplateService;
 import com.jeeplus.modules.projectEngineering.service.ProjectEngineeringService;
 import com.jeeplus.modules.projectcontentinfo.dao.ProjectReportDataDao;
@@ -40,7 +39,6 @@ import org.springframework.ui.Model;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 
-import java.math.BigDecimal;
 import java.util.*;
 
 /**
@@ -510,7 +508,24 @@ public class RuralCostProjectMessageNewTwoController extends BaseController {
                 consultant.setRole("咨询员");
                 consultant.setZixunyuanName(user.getName());
                 if(consultant.getZixunyuan().equals(projectReportData.getBzshbUserId())){
+
+                    User chenHongXing=UserUtils.getByLoginName("陈红星");
+                    List<WorkStaffCertificate> chenHongXingCertificateList = ruralProjectMessageService.getCertificateByUser(chenHongXing.getId());
+                    //获取陈红星的造价师信息
+                    WorkStaffCertificate chenHongXingStaffCertificate = chenHongXingCertificateList.get(0);
+
+                    //根据用户查询技能信息
+                    List<WorkStaffCertificate> certificateBList = ruralProjectMessageService.getCertificateByUser(consultant.getZixunyuan());
+                    for (WorkStaffCertificate certificateInfo: certificateBList) {
+                        for (MainDictDetail type : certificateMajor) {
+                            if(certificateInfo.getMajor().equals(type.getValue())){
+                                bzshbConsultant.setMajor(type.getLabel());
+                            }
+                        }
+                    }
+
                     bzshbConsultant = consultant;
+                    bzshbConsultant.setZhucezigezhID(chenHongXingStaffCertificate.getNum());
                     bzshbConsultant.setZixunyuanName("陈红星("+consultant.getZixunyuanName()+"代)");
                     bzshbConsultant.setRole("技术负责人");
                     it.remove();

+ 9 - 4
src/main/resources/mappings/modules/knowledgeSharing/KnowledgeSharingDetailsDao.xml

@@ -14,7 +14,9 @@
 		a.column_id as "columnId",
 		a.subject as "subject",
 		a.moderator as "moderator",
-		a.contents as "contents"
+		a.contents as "contents",
+		a.office_id as "office.id",
+		a.company_id as "company.id"
 	</sql>
 
 
@@ -81,11 +83,12 @@
 			update_date,
 			remarks,
 			del_flag,
-
 			column_id,
 			subject,
 			moderator,
-			contents
+			contents,
+			office_id,
+			company_id
 		) VALUES (
 			#{id},
 			#{createBy.id},
@@ -98,7 +101,9 @@
 			#{columnId},
 			#{subject},
 			#{moderator},
-			#{contents}
+			#{contents},
+			#{office.id},
+			#{company.id}
 		)
 	</insert>
 

+ 2 - 0
src/main/webapp/webpage/modules/knowledgeSharing/knowledgeSharingDetailsList.jsp

@@ -159,6 +159,8 @@
 	<sys:message content="${message}"/>
 	<div class="list-form-tab contentShadow shadowLTR" id="tabDiv">
 		<ul class="list-tabs" >
+			<li value="7"><a>行业标准及规范</a></li>
+			<li value="8"><a>企业标准及规范</a></li>
 			<li value="1"><a>学习园地</a></li>
 			<li value="2"><a>请教专家</a></li>
 			<li value="3"><a>一事一议</a></li>

+ 0 - 63
src/main/webapp/webpage/modules/knowledgeSharing/knowledgeSharingView.jsp

@@ -6,69 +6,6 @@
     <meta name="decorator" content="default"/>
     <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
-    <style>
-        .wrapForm {
-            width: 100%;
-            height: 530px;
-            margin-top: -93px;
-        }
-        .mask{
-            width: 100%;
-            height:100%;
-        }
-        .layui-input-block{
-            border-top: 1px solid #cccccc;
-            overflow: hidden;
-            border-radius: 3px;
-        }
-
-        .comment_list {
-            padding-top:40px;
-            width:700px;
-            margin:0 auto;
-        }
-        .comment_details {
-            float:left;
-        }
-        .comment_content {
-            margin-top:10px;
-            font-size:16px;
-        }
-        .comment_add_or_last {
-
-            margin:0 auto;
-            clear: both;
-            width:600px;
-            height:40px;
-            background: #F0F0F0;
-            text-align: center;
-            line-height: 40px;   //行高(与div保持同高,垂直居中写法)
-        }
-        .imgdiv{
-            float:left;
-
-        }
-        .imgcss {
-            width:50px;
-            height:50px;
-            border-radius: 50%;
-        }
-        .comment_name {
-            margin-left:10px;
-            color:#3D9EEA;
-            font-size:15px;
-            font-weight: bolder;
-        }
-        .layui-icon {
-            font-size: 10px;
-            color: grey;
-        }
-        .del {
-            margin-left: 55px;
-        }
-    </style>
-
-
     <script>
         function deleteComment(id) {
             $.ajax({

+ 16 - 0
src/main/webapp/webpage/modules/projectFilingBatch/projectFilingBatchApply.jsp

@@ -56,6 +56,22 @@
 				$(span).find("span").eq(0).attr("class","default_shut")
 			}
 		}
+		function delListRow(o,obj){
+			var tr="#"+obj.id+" tr"
+			var html=$(tr).length
+			if(0 == html){
+				$(o).parent().parent().remove();
+				$(obj).parent().parent().parent().remove();
+			}else{
+				parent.layer.msg("该项目下有文件信息,请先删除项目下文件!", {icon: 5});
+			}
+
+
+			// var fu= $(obj).parent().parent().parent().html();
+			// if ()
+			// $(obj).parent().parent().parent().hide();
+		}
+
 		function addRowInfoForm(obj,tbody) {
 			var proid=$(obj).val();
 			var filingId=$("#filingId").val();