|
@@ -30,7 +30,6 @@ import org.springframework.data.domain.Sort;
|
|
import org.springframework.data.domain.Sort.Direction;
|
|
import org.springframework.data.domain.Sort.Direction;
|
|
import org.springframework.data.jpa.domain.Specification;
|
|
import org.springframework.data.jpa.domain.Specification;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
-import org.springframework.web.bind.annotation.DeleteMapping;
|
|
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
@@ -63,6 +62,7 @@ import cn.com.qmth.examcloud.core.basic.dao.entity.OrgEntity;
|
|
import cn.com.qmth.examcloud.core.basic.dao.entity.OrgPropertyEntity;
|
|
import cn.com.qmth.examcloud.core.basic.dao.entity.OrgPropertyEntity;
|
|
import cn.com.qmth.examcloud.core.basic.dao.enums.OrgProperty;
|
|
import cn.com.qmth.examcloud.core.basic.dao.enums.OrgProperty;
|
|
import cn.com.qmth.examcloud.core.basic.service.bean.OrgInfo;
|
|
import cn.com.qmth.examcloud.core.basic.service.bean.OrgInfo;
|
|
|
|
+import cn.com.qmth.examcloud.core.basic.service.cache.OrgCache;
|
|
import cn.com.qmth.examcloud.core.basic.service.cache.SystemPropertyCache;
|
|
import cn.com.qmth.examcloud.core.basic.service.cache.SystemPropertyCache;
|
|
import cn.com.qmth.examcloud.core.basic.service.impl.OrgServiceImpl;
|
|
import cn.com.qmth.examcloud.core.basic.service.impl.OrgServiceImpl;
|
|
import cn.com.qmth.examcloud.exchange.inner.api.UpyunCloudService;
|
|
import cn.com.qmth.examcloud.exchange.inner.api.UpyunCloudService;
|
|
@@ -92,6 +92,9 @@ import io.swagger.annotations.ApiOperation;
|
|
@RequestMapping("${$rmp.ctr.basic}/org")
|
|
@RequestMapping("${$rmp.ctr.basic}/org")
|
|
public class OrgController extends ControllerSupport {
|
|
public class OrgController extends ControllerSupport {
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ OrgCache orgCache;
|
|
|
|
+
|
|
@Autowired
|
|
@Autowired
|
|
RedisClient redisClient;
|
|
RedisClient redisClient;
|
|
|
|
|
|
@@ -1018,6 +1021,10 @@ public class OrgController extends ControllerSupport {
|
|
req.setSyncType("update");
|
|
req.setSyncType("update");
|
|
dataSyncCloudService.syncOrg(req);
|
|
dataSyncCloudService.syncOrg(req);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ for (OrgEntity saved : savedList) {
|
|
|
|
+ orgCache.remove(saved.getId());
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "保存机构属性", notes = "")
|
|
@ApiOperation(value = "保存机构属性", notes = "")
|
|
@@ -1227,13 +1234,6 @@ public class OrgController extends ControllerSupport {
|
|
return url;
|
|
return url;
|
|
}
|
|
}
|
|
|
|
|
|
- @ApiOperation(value = "删除子机构", notes = "")
|
|
|
|
- @DeleteMapping("deleteSubOrg/{orgId}")
|
|
|
|
- @Transactional
|
|
|
|
- public void deleteSubOrg(@PathVariable Long orgId) {
|
|
|
|
- orgService.deleteSubOrg(orgId, false);
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
@ApiOperation(value = "下载导入模板", notes = "下载导入模板")
|
|
@ApiOperation(value = "下载导入模板", notes = "下载导入模板")
|
|
@GetMapping("importTemplate")
|
|
@GetMapping("importTemplate")
|
|
public void getDownloadTemplate(HttpServletResponse response) {
|
|
public void getDownloadTemplate(HttpServletResponse response) {
|