|
@@ -1,7 +1,9 @@
|
|
|
package com.bosshand.virgo.controller;
|
|
|
|
|
|
import com.bosshand.virgo.core.model.MgrOrganizationProject;
|
|
|
+import com.bosshand.virgo.core.model.UserContext;
|
|
|
import com.bosshand.virgo.core.response.Response;
|
|
|
+import com.bosshand.virgo.core.utils.ContextUtils;
|
|
|
import com.bosshand.virgo.service.OrganizationProjectService;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -20,6 +22,8 @@ public class OrganizationProjectController {
|
|
|
@ApiOperation("绑定项目")
|
|
|
@RequestMapping(value = "", method = RequestMethod.POST)
|
|
|
public Response bindProject(@RequestBody MgrOrganizationProject mgrOrganizationProject) {
|
|
|
+ UserContext userContext = ContextUtils.getUserContext();
|
|
|
+ mgrOrganizationProject.setUserId(userContext.getUserId());
|
|
|
organizationProjectService.insert(mgrOrganizationProject);
|
|
|
return Response.ok();
|
|
|
}
|