|
@@ -142,7 +142,7 @@ public class FileInfoServiceImpl extends ServiceImpl<FileInfoMapper, FileInfo> i
|
|
|
* @param businessType 业务文件类型
|
|
|
*/
|
|
|
@Transactional(propagation = Propagation.REQUIRES_NEW)
|
|
|
- @DS(DatasourceConstant.SLAVE_NAME)
|
|
|
+ @DS(DatasourceConstant.BASE)
|
|
|
@Override
|
|
|
public void saveFile(List<ObsFile> obsFileList, Long businessId, Integer businessType) {
|
|
|
// 切换到从库
|
|
@@ -167,7 +167,7 @@ public class FileInfoServiceImpl extends ServiceImpl<FileInfoMapper, FileInfo> i
|
|
|
* @param businessType 业务文件类型
|
|
|
*/
|
|
|
@Transactional(propagation = Propagation.REQUIRES_NEW)
|
|
|
- @DS(DatasourceConstant.SLAVE_NAME)
|
|
|
+ @DS(DatasourceConstant.BASE)
|
|
|
@Override
|
|
|
public void editFile(List<ObsFile> obsFileList, Long businessId, Integer businessType) {
|
|
|
if (obsFileList.size() == 0) {
|
|
@@ -189,7 +189,7 @@ public class FileInfoServiceImpl extends ServiceImpl<FileInfoMapper, FileInfo> i
|
|
|
* @param businessType 业务文件类型
|
|
|
*/
|
|
|
@Transactional(propagation = Propagation.REQUIRES_NEW)
|
|
|
- @DS(DatasourceConstant.SLAVE_NAME)
|
|
|
+ @DS(DatasourceConstant.BASE)
|
|
|
@Override
|
|
|
public void removeFile(Long businessId, Integer businessType) {
|
|
|
this.remove(q -> q
|
|
@@ -203,7 +203,7 @@ public class FileInfoServiceImpl extends ServiceImpl<FileInfoMapper, FileInfo> i
|
|
|
* @param businessId 业务id
|
|
|
*/
|
|
|
@Transactional(propagation = Propagation.REQUIRES_NEW)
|
|
|
- @DS(DatasourceConstant.SLAVE_NAME)
|
|
|
+ @DS(DatasourceConstant.BASE)
|
|
|
@Override
|
|
|
public void removeFile(Long businessId) {
|
|
|
this.remove(q -> q.eq(FileInfo::getBusinessId, businessId));
|