|
|
@ -7,12 +7,15 @@ import com.epmet.datareport.service.evaluationindex.screen.AgencyService; |
|
|
|
import com.epmet.evaluationindex.screen.dto.form.CompartmentFormDTO; |
|
|
|
import com.epmet.evaluationindex.screen.dto.result.CompartmentResultDTO; |
|
|
|
import com.epmet.evaluationindex.screen.dto.result.TreeResultDTO; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.web.bind.annotation.PostMapping; |
|
|
|
import org.springframework.web.bind.annotation.RequestBody; |
|
|
|
import org.springframework.web.bind.annotation.RequestMapping; |
|
|
|
import org.springframework.web.bind.annotation.RestController; |
|
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest; |
|
|
|
|
|
|
|
/** |
|
|
|
* 组织相关api |
|
|
|
* |
|
|
@ -34,7 +37,11 @@ public class AgencyController { |
|
|
|
*/ |
|
|
|
//@ExternalAppRequestAuth
|
|
|
|
@PostMapping("tree") |
|
|
|
public Result<TreeResultDTO> tree(ExternalAppRequestParam externalAppRequestParam){ |
|
|
|
public Result<TreeResultDTO> tree(HttpServletRequest request, ExternalAppRequestParam externalAppRequestParam){ |
|
|
|
String customerId = request.getHeader("CustomerId"); |
|
|
|
if(StringUtils.isBlank(externalAppRequestParam.getCustomerId())){ |
|
|
|
externalAppRequestParam.setCustomerId(customerId); |
|
|
|
} |
|
|
|
return new Result<TreeResultDTO>().ok(agencyService.tree(externalAppRequestParam)); |
|
|
|
} |
|
|
|
|
|
|
|