|
@@ -16,6 +16,7 @@ import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
+import org.springframework.util.CollectionUtils;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import java.util.List;
|
|
@@ -87,6 +88,9 @@ public class ExamOrganizationRelationController extends BaseController {
|
|
|
if(Objects.isNull(employee)){
|
|
|
return failed("用户异常");
|
|
|
}
|
|
|
+ if(CollectionUtils.isEmpty(organizationRelations)){
|
|
|
+ return failed("请选择合作单位");
|
|
|
+ }
|
|
|
examOrganizationRelationService.addExamOrganizations(organizationRelations,employee.getOrganId());
|
|
|
return succeed();
|
|
|
}
|