【fix sonar】ImportExcelUtil文件
This commit is contained in:
+4
-4
@@ -41,8 +41,8 @@ public class ImportExcelUtil {
|
||||
}
|
||||
}
|
||||
|
||||
public static List<String> importDateSave(List<Object> list, Class serviceClass,List<String> errorMessage,String errorFlag) {
|
||||
IService bean =(IService) SpringContextUtils.getBean(serviceClass);
|
||||
public static List<String> importDateSave(List<Object> list, Class<?> serviceClass,List<String> errorMessage,String errorFlag) {
|
||||
IService<Object> bean =(IService) SpringContextUtils.getBean(serviceClass);
|
||||
for (int i = 0; i < list.size(); i++) {
|
||||
try {
|
||||
boolean save = bean.save(list.get(i));
|
||||
@@ -70,8 +70,8 @@ public class ImportExcelUtil {
|
||||
return errorMessage;
|
||||
}
|
||||
|
||||
public static List<String> importDateSaveOne(Object obj, Class serviceClass,List<String> errorMessage,int i,String errorFlag) {
|
||||
IService bean =(IService) SpringContextUtils.getBean(serviceClass);
|
||||
public static List<String> importDateSaveOne(Object obj, Class<?> serviceClass, List<String> errorMessage, int i, String errorFlag) {
|
||||
IService<Object> bean = (IService) SpringContextUtils.getBean(serviceClass);
|
||||
try {
|
||||
boolean save = bean.save(obj);
|
||||
if(!save){
|
||||
|
||||
Reference in New Issue
Block a user