Commit ef0d04ed authored by 赵啸非's avatar 赵啸非

修改工作人员导入

parent 85cacb44
...@@ -26,14 +26,6 @@ import com.mortals.framework.springcloud.service.IApplicationStartedService; ...@@ -26,14 +26,6 @@ import com.mortals.framework.springcloud.service.IApplicationStartedService;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import java.util.List; import java.util.List;
/**
* 应用级服务,在应用启动后、停止过程中调用
* 应用已经完成启动完成,才调用该服务
* 应用场景:
* 1、应用任务,应用启动后定时或间隔执行的任务
* 2、Socket服务端
*/
@Component @Component
@Slf4j @Slf4j
public class DemoStartedService implements IApplicationStartedService { public class DemoStartedService implements IApplicationStartedService {
...@@ -56,12 +48,11 @@ public class DemoStartedService implements IApplicationStartedService { ...@@ -56,12 +48,11 @@ public class DemoStartedService implements IApplicationStartedService {
ThreadPool.getInstance().execute(syncTreeSiteThread); ThreadPool.getInstance().execute(syncTreeSiteThread);
userService.find(new UserQuery()).forEach(user->{ /* userService.find(new UserQuery()).forEach(user->{
Context context = new Context(); Context context = new Context();
context.setUser(user); context.setUser(user);
ThreadPool.getInstance().execute(new SyncTreeSiteThread(context)); ThreadPool.getInstance().execute(new SyncTreeSiteThread(context));
}); });*/
/* if(ObjectUtils.isEmpty(userFeign)){ /* if(ObjectUtils.isEmpty(userFeign)){
logger.info("userFeign未加载,加载本地用户"); logger.info("userFeign未加载,加载本地用户");
......
...@@ -177,6 +177,7 @@ public class WorkmanController extends BaseCRUDJsonBodyMappingController<Workman ...@@ -177,6 +177,7 @@ public class WorkmanController extends BaseCRUDJsonBodyMappingController<Workman
boolean bool = FileUtil.write(filePath, workmanEntity.getPicObj().getData(), true, true); boolean bool = FileUtil.write(filePath, workmanEntity.getPicObj().getData(), true, true);
if (bool) { if (bool) {
workmanEntity.setPhotoPath(newName); workmanEntity.setPhotoPath(newName);
workmanEntity.setPicObj(null);
} }
} catch (IOException e) { } catch (IOException e) {
log.error("写入证照异常",e); log.error("写入证照异常",e);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment