Commit 2e250cb4 by 涂亚平

准备周六在家加班......

1 parent d210f764
Showing with 2001 additions and 395 deletions
2023-04-06 10:02:12,197 [http-nio-34567-exec-7] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value (''); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('')
at [Source: (PushbackInputStream); line: 1, column: 50] (through reference chain: com.laowu.dto.job.JobDTO["recruitId"])
2023-04-06 10:10:33,728 [http-nio-34567-exec-10] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value (''); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('')
at [Source: (PushbackInputStream); line: 1, column: 50] (through reference chain: com.laowu.dto.job.JobDTO["recruitId"])
2023-04-06 10:17:30,530 [http-nio-34567-exec-4] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value (''); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('')
at [Source: (PushbackInputStream); line: 1, column: 50] (through reference chain: com.laowu.dto.job.JobDTO["recruitId"])
2023-04-06 11:49:33,386 [http-nio-34567-exec-5] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value (''); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('')
at [Source: (PushbackInputStream); line: 1, column: 50] (through reference chain: com.laowu.dto.job.JobDTO["recruitId"])
2023-04-06 13:27:53,468 [http-nio-34567-exec-10] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value (''); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot construct instance of `java.util.ArrayList` (although at least one Creator exists): no String-argument constructor/factory method to deserialize from String value ('')
at [Source: (PushbackInputStream); line: 1, column: 50] (through reference chain: com.laowu.dto.job.JobDTO["recruitId"])
2023-04-06 15:19:48,783 [main] ERROR org.springframework.boot.web.embedded.tomcat.TomcatStarter:61 - Error starting Tomcat context. Exception: org.springframework.beans.factory.UnsatisfiedDependencyException. Message: Error creating bean with name 'webConfig': Unsatisfied dependency expressed through field 'authenticationInterceptor'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'authenticationInterceptor': Unsatisfied dependency expressed through field 'administerMapper'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'administerMapper' defined in file [D:\code\laowu\target\classes\com\laowu\mapper\AdministerMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/baomidou/mybatisplus/autoconfigure/MybatisPlusAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
2023-04-06 15:19:48,820 [main] ERROR org.springframework.boot.SpringApplication:822 - Application run failed
org.springframework.context.ApplicationContextException: Unable to start web server; nested exception is org.springframework.boot.web.server.WebServerException: Unable to start embedded Tomcat
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.onRefresh(ServletWebServerApplicationContext.java:156)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:543)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:743)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:390)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:312)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1214)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1203)
at com.laowu.LaowuApplication.main(LaowuApplication.java:14)
Caused by: org.springframework.boot.web.server.WebServerException: Unable to start embedded Tomcat
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.initialize(TomcatWebServer.java:124)
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.<init>(TomcatWebServer.java:86)
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.getTomcatWebServer(TomcatServletWebServerFactory.java:416)
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.getWebServer(TomcatServletWebServerFactory.java:180)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.createWebServer(ServletWebServerApplicationContext.java:180)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.onRefresh(ServletWebServerApplicationContext.java:153)
... 8 common frames omitted
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'webConfig': Unsatisfied dependency expressed through field 'authenticationInterceptor'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'authenticationInterceptor': Unsatisfied dependency expressed through field 'administerMapper'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'administerMapper' defined in file [D:\code\laowu\target\classes\com\laowu\mapper\AdministerMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/baomidou/mybatisplus/autoconfigure/MybatisPlusAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:596)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:90)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:374)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1411)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:592)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:392)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1321)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1160)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:204)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.getOrderedBeansOfType(ServletContextInitializerBeans.java:211)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.addAsRegistrationBean(ServletContextInitializerBeans.java:174)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.addAsRegistrationBean(ServletContextInitializerBeans.java:169)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.addAdaptableBeans(ServletContextInitializerBeans.java:154)
at org.springframework.boot.web.servlet.ServletContextInitializerBeans.<init>(ServletContextInitializerBeans.java:86)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.getServletContextInitializerBeans(ServletWebServerApplicationContext.java:253)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.selfInitialize(ServletWebServerApplicationContext.java:227)
at org.springframework.boot.web.embedded.tomcat.TomcatStarter.onStartup(TomcatStarter.java:53)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5132)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
at java.util.concurrent.FutureTask.run$$$capture(FutureTask.java:266)
at java.util.concurrent.FutureTask.run(FutureTask.java)
at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134)
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:841)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
at java.util.concurrent.FutureTask.run$$$capture(FutureTask.java:266)
at java.util.concurrent.FutureTask.run(FutureTask.java)
at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134)
at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.core.StandardService.startInternal(StandardService.java:421)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:932)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.startup.Tomcat.start(Tomcat.java:456)
at org.springframework.boot.web.embedded.tomcat.TomcatWebServer.initialize(TomcatWebServer.java:105)
... 13 common frames omitted
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'authenticationInterceptor': Unsatisfied dependency expressed through field 'administerMapper'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'administerMapper' defined in file [D:\code\laowu\target\classes\com\laowu\mapper\AdministerMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/baomidou/mybatisplus/autoconfigure/MybatisPlusAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:596)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:90)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:374)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1411)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:592)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)
at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:277)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1251)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1171)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:593)
... 65 common frames omitted
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'administerMapper' defined in file [D:\code\laowu\target\classes\com\laowu\mapper\AdministerMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/baomidou/mybatisplus/autoconfigure/MybatisPlusAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByType(AbstractAutowireCapableBeanFactory.java:1515)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1395)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:592)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)
at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:277)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1251)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1171)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:593)
... 78 common frames omitted
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/baomidou/mybatisplus/autoconfigure/MybatisPlusAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:627)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:607)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1321)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1160)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199)
at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:277)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1251)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1171)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByType(AbstractAutowireCapableBeanFactory.java:1500)
... 89 common frames omitted
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:622)
... 102 common frames omitted
Caused by: org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean.buildSqlSessionFactory(MybatisSqlSessionFactoryBean.java:593)
at com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean.afterPropertiesSet(MybatisSqlSessionFactoryBean.java:429)
at com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean.getObject(MybatisSqlSessionFactoryBean.java:626)
at com.baomidou.mybatisplus.autoconfigure.MybatisPlusAutoConfiguration.sqlSessionFactory(MybatisPlusAutoConfiguration.java:214)
at com.baomidou.mybatisplus.autoconfigure.MybatisPlusAutoConfiguration$$EnhancerBySpringCGLIB$$d67b1f2c.CGLIB$sqlSessionFactory$2(<generated>)
at com.baomidou.mybatisplus.autoconfigure.MybatisPlusAutoConfiguration$$EnhancerBySpringCGLIB$$d67b1f2c$$FastClassBySpringCGLIB$$79376727.invoke(<generated>)
at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244)
at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:363)
at com.baomidou.mybatisplus.autoconfigure.MybatisPlusAutoConfiguration$$EnhancerBySpringCGLIB$$d67b1f2c.sqlSessionFactory(<generated>)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
... 103 common frames omitted
Caused by: org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. The XML location is 'file [D:\code\laowu\target\classes\mapper\WorkstationRequireMappingMapper.xml]'. Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.apache.ibatis.builder.xml.XMLMapperBuilder.configurationElement(XMLMapperBuilder.java:122)
at org.apache.ibatis.builder.xml.XMLMapperBuilder.parse(XMLMapperBuilder.java:94)
at com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean.buildSqlSessionFactory(MybatisSqlSessionFactoryBean.java:591)
... 116 common frames omitted
Caused by: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.apache.ibatis.builder.BaseBuilder.resolveClass(BaseBuilder.java:118)
at org.apache.ibatis.builder.xml.XMLStatementBuilder.parseStatementNode(XMLStatementBuilder.java:102)
at org.apache.ibatis.builder.xml.XMLMapperBuilder.buildStatementFromContext(XMLMapperBuilder.java:137)
at org.apache.ibatis.builder.xml.XMLMapperBuilder.buildStatementFromContext(XMLMapperBuilder.java:130)
at org.apache.ibatis.builder.xml.XMLMapperBuilder.configurationElement(XMLMapperBuilder.java:120)
... 118 common frames omitted
Caused by: org.apache.ibatis.type.TypeException: Could not resolve type alias ''. Cause: java.lang.ClassNotFoundException: Cannot find class:
at org.apache.ibatis.type.TypeAliasRegistry.resolveAlias(TypeAliasRegistry.java:120)
at org.apache.ibatis.builder.BaseBuilder.resolveAlias(BaseBuilder.java:149)
at org.apache.ibatis.builder.BaseBuilder.resolveClass(BaseBuilder.java:116)
... 122 common frames omitted
Caused by: java.lang.ClassNotFoundException: Cannot find class:
at org.apache.ibatis.io.ClassLoaderWrapper.classForName(ClassLoaderWrapper.java:200)
at org.apache.ibatis.io.ClassLoaderWrapper.classForName(ClassLoaderWrapper.java:89)
at org.apache.ibatis.io.Resources.classForName(Resources.java:261)
at org.apache.ibatis.type.TypeAliasRegistry.resolveAlias(TypeAliasRegistry.java:116)
... 124 common frames omitted
2023-04-12 14:01:43,192 [http-nio-34567-exec-8] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot deserialize value of type `java.lang.Long` from String "上海市": not a valid Long value; nested exception is com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type `java.lang.Long` from String "上海市": not a valid Long value
at [Source: (PushbackInputStream); line: 1, column: 78] (through reference chain: com.laowu.dto.company.StationCompanyDTO["stationId"])
2023-04-12 14:02:03,502 [http-nio-34567-exec-8] ERROR com.laowu.common.exception.GlobalExceptionHandler:88 - JSON parse error: Cannot deserialize value of type `java.lang.Long` from String "上海市": not a valid Long value; nested exception is com.fasterxml.jackson.databind.exc.InvalidFormatException: Cannot deserialize value of type `java.lang.Long` from String "上海市": not a valid Long value
at [Source: (PushbackInputStream); line: 1, column: 78] (through reference chain: com.laowu.dto.company.StationCompanyDTO["stationId"])
This diff could not be displayed because it is too large.
......@@ -2,6 +2,7 @@ package com.laowu.controller;
import com.laowu.common.interceptor.LoginRequired;
import com.laowu.dto.administer.AddAdministerDTO;
import com.laowu.dto.administer.AllDTO;
import com.laowu.model.AdministerDO;
import com.laowu.service.AdministerService;
......@@ -51,15 +52,15 @@ public class AdministerController {
}
@PostMapping("addAdminister")
@ApiOperation("新增管理员 addAdminister userName telephone remark")
public ResponseVO addAdminister(@RequestBody AdministerDO administerDO){
return ResponseData.generateCreatedResponse(0,administerService.addAdminister(administerDO));
@ApiOperation("新增管理员 addAdminister userName telephone remark stationIds")
public ResponseVO addAdminister(@RequestBody AddAdministerDTO addAdministerDTO){
return ResponseData.generateCreatedResponse(0,administerService.addAdminister(addAdministerDTO));
}
@PostMapping("updateAdminister")
@ApiOperation("修改管理员 id addAdminister userName telephone remark status")
public ResponseVO updateAdminister(@RequestBody AdministerDO administerDO){
return ResponseData.generateCreatedResponse(0,administerService.updateAdminister(administerDO));
@ApiOperation("修改管理员 id addAdminister userName telephone remark status stationIds")
public ResponseVO updateAdminister(@RequestBody AddAdministerDTO addAdministerDTO){
return ResponseData.generateCreatedResponse(0,administerService.updateAdminister(addAdministerDTO));
}
@PostMapping("deleteAdminister")
......
package com.laowu.controller;
import com.laowu.model.BusinessDictDO;
import com.laowu.service.BusinessDictService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* <p>
* 经营范围 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-13
*/
@RestController
@Api(tags = "经营范围")
@RequestMapping("/businessDict")
public class BusinessDictController {
@Autowired
private BusinessDictService businessDictService;
@PostMapping("addBusiness")
@ApiOperation("新增经营范围 business")
public ResponseVO addBusiness(@RequestBody BusinessDictDO businessDictDO){
return ResponseData.generateCreatedResponse(0,businessDictService.addBusiness(businessDictDO));
}
@PostMapping("updateBusiness")
@ApiOperation("修改经营范围 id business")
public ResponseVO updateBusiness(@RequestBody BusinessDictDO businessDictDO){
return ResponseData.generateCreatedResponse(0,businessDictService.updateBusiness(businessDictDO));
}
@PostMapping("deleteBusiness")
@ApiOperation("删除经营范围 id")
public ResponseVO deleteBusiness(@RequestBody BusinessDictDO businessDictDO){
return ResponseData.generateCreatedResponse(0,businessDictService.deleteBusiness(businessDictDO));
}
@PostMapping("queryBusiness")
@ApiOperation("查询经营范围")
public ResponseVO queryBusiness(){
return ResponseData.generateCreatedResponse(0,businessDictService.queryBusiness());
}
}
......@@ -47,13 +47,13 @@ public class CompanyDictController {
}
@PostMapping("addCompany")
@ApiOperation("添加企业 userId module 模块 companyName companyLogo province city county positionId companyCode account companyDesc companyOrigin companyPhotoDOS[ photo] companyLabelDOS[ label] 关联业务 stationId")
@ApiOperation("添加企业 userId module 模块 companyName companyLogo province city county businessId companyCode account companyDesc companyOrigin companyPhotoDOS[ photo] companyLabelDOS[ label] 关联业务 stationId")
public ResponseVO addCompany(@RequestBody AddCompanyDTO addCompanyDTO){
return ResponseData.generateCreatedResponse(0,companyDictService.addCompany(addCompanyDTO));
}
@PostMapping("updateCompany")
@ApiOperation("更新企业 userId module id companyName companyLogo province city county positionId companyCode account companyDesc companyOrigin companyPhotoDOS[ photo] companyLabelDOS[ label] 关联业务 stationId")
@ApiOperation("更新企业 userId module id companyName companyLogo province city county businessId companyCode account companyDesc companyOrigin companyPhotoDOS[ photo] companyLabelDOS[ label] 关联业务 stationId")
public ResponseVO updateCompany(@RequestBody AddCompanyDTO addCompanyDTO){
return ResponseData.generateCreatedResponse(0,companyDictService.updateCompany(addCompanyDTO));
}
......@@ -71,7 +71,7 @@ public class CompanyDictController {
}
@PostMapping("stationCompany")
@ApiOperation("查看工作站下的企业 id 工作站id")
@ApiOperation("查看工作站下的企业 id 工作站id province companyName city county")
public ResponseVO stationCompany(@RequestBody StationCompanyDTO stationCompanyDTO){
return ResponseData.generateCreatedResponse(0,companyDictService.stationCompany(stationCompanyDTO));
}
......
......@@ -53,5 +53,11 @@ public class LibJobSortController {
return ResponseData.generateCreatedResponse(0,libJobSortService.deleteSort(libJobSortDO));
}
@PostMapping("manage")
@ApiOperation("分类整理")
public ResponseVO manage(){
return ResponseData.generateCreatedResponse(0,libJobSortService.manage());
}
}
package com.laowu.controller;
import com.laowu.model.MemberCertsDO;
import com.laowu.service.MemberCertsService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* <p>
* 学员证书表 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@RestController
@Api(tags = "学员证书表")
@RequestMapping("/memberCerts")
public class MemberCertsController {
@Autowired
private MemberCertsService memberCertsService;
@PostMapping("addMemberCert")
@ApiOperation("添加证书信息 memberId cert")
public ResponseVO addMemberCert(@RequestBody MemberCertsDO memberCertsDO){
return ResponseData.generateCreatedResponse(0,memberCertsService.addMemberCert(memberCertsDO));
}
@PostMapping("deleteMemberCert")
@ApiOperation("删除证书信息 id 映射id")
public ResponseVO deleteMemberCert(@RequestBody MemberCertsDO memberCertsDO){
return ResponseData.generateCreatedResponse(0,memberCertsService.deleteMemberCert(memberCertsDO));
}
@PostMapping("updateMemberCert")
@ApiOperation("修改证书信息 id cert")
public ResponseVO updateMemberCert(@RequestBody MemberCertsDO memberCertsDO){
return ResponseData.generateCreatedResponse(0,memberCertsService.updateMemberCert(memberCertsDO));
}
}
......@@ -46,7 +46,7 @@ public class MemberDictController {
@PostMapping("addMember")
@ApiOperation("添加自然人 userId module userName status 学生/社会 telephone idCardType idCard province city county address education" +
"isPoor isMigration isParty jobStatus stationId")
"isPoor isMigration isParty jobStatus stationId positionIds[] teamId")
public ResponseVO addMember(@RequestBody AddMemberDTO addMemberDTO){
return ResponseData.generateCreatedResponse(0,memberDictService.addMember(addMemberDTO));
}
......@@ -59,7 +59,7 @@ public class MemberDictController {
@PostMapping("updateMember")
@ApiOperation("修改自然人 id userId module userName status 学生/社会 telephone idCardType idCard province city county address education" +
"isPoor isMigration isParty jobStatus infoOrigin")
"isPoor isMigration isParty jobStatus infoOrigin positionIds[]")
public ResponseVO updateMember(@RequestBody UpdateMemberDTO updateMemberDTO){
return ResponseData.generateCreatedResponse(0,memberDictService.updateMember(updateMemberDTO));
}
......
package com.laowu.controller;
import com.laowu.model.MemberPositionsDO;
import com.laowu.service.MemberPositionsService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import io.swagger.annotations.Api;
/**
* <p>
* 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@RestController
@Api(tags = "")
@RequestMapping("/memberPositions")
public class MemberPositionsController {
@Autowired
private MemberPositionsService memberPositionsService;
@PostMapping("deletePosition")
@ApiOperation("删除专业技能 映射id")
public ResponseVO deletePosition(@RequestBody MemberPositionsDO memberPositionsDO){
return ResponseData.generateCreatedResponse(0,memberPositionsService.deletePosition(memberPositionsDO));
}
@PostMapping("addPosition")
@ApiOperation("添加专业技能 memberId positionId")
public ResponseVO addPosition(@RequestBody MemberPositionsDO memberPositionsDO){
return ResponseData.generateCreatedResponse(0,memberPositionsService.addPosition(memberPositionsDO));
}
@PostMapping("updatePosition")
@ApiOperation("修改专业技能 id positionId")
public ResponseVO updatePosition(@RequestBody MemberPositionsDO memberPositions){
return ResponseData.generateCreatedResponse(0,memberPositionsService.updatePosition(memberPositions));
}
}
package com.laowu.controller;
import com.laowu.dto.member.AddTrainDTO;
import com.laowu.model.MemberTrainInfoDO;
import com.laowu.service.MemberTrainInfoService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* <p>
* 学员培训信息 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@RestController
@Api(tags = "学员培训信息")
@RequestMapping("/memberTrainInfo")
public class MemberTrainInfoController {
@Autowired
private MemberTrainInfoService memberTrainInfoService;
@PostMapping("addTrain")
@ApiOperation("添加培训 memberId trainFrom trainType trainName startDate endDate province city county trainContent trainResult positionIds[]")
public ResponseVO addTrain(@RequestBody AddTrainDTO addTrainDTO){
return ResponseData.generateCreatedResponse(0,memberTrainInfoService.addTrain(addTrainDTO));
}
@PostMapping("deleteTrain")
@ApiOperation("添加培训 id")
public ResponseVO deleteTrain(@RequestBody MemberTrainInfoDO memberTrainInfoDO){
return ResponseData.generateCreatedResponse(0,memberTrainInfoService.deleteTrain(memberTrainInfoDO));
}
@PostMapping("updateTrain")
@ApiOperation("修改培训 id memberId trainFrom trainType trainName startDate endDate province city county trainContent trainResult positionIds[] ")
public ResponseVO updateTrain(@RequestBody AddTrainDTO addTrainDTO){
return ResponseData.generateCreatedResponse(0,memberTrainInfoService.updateTrain(addTrainDTO));
}
}
package com.laowu.controller;
import com.laowu.model.MemberTrainPositionsDO;
import com.laowu.service.MemberTrainPositionsService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import io.swagger.annotations.Api;
/**
* <p>
* 培训关联职业范围 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@RestController
@Api(tags = "培训关联职业范围")
@RequestMapping("/memberTrainPositions")
public class MemberTrainPositionsController {
@Autowired
private MemberTrainPositionsService memberTrainPositionsService;
@PostMapping("addPosition")
@ApiOperation("添加职业技能范围 memberTrainId positionId")
public ResponseVO addPosition(@RequestBody MemberTrainPositionsDO memberTrainPositionsDO){
return ResponseData.generateCreatedResponse(0,memberTrainPositionsService.addPosition(memberTrainPositionsDO));
}
@PostMapping("deletePosition")
@ApiOperation("删除职业技能范围 id ")
public ResponseVO deletePosition(@RequestBody MemberTrainPositionsDO memberTrainPositionsDO){
return ResponseData.generateCreatedResponse(0,memberTrainPositionsService.deletePosition(memberTrainPositionsDO));
}
@PostMapping("updatePosition")
@ApiOperation("修改职业技能范围 id positionId")
public ResponseVO updatePosition(@RequestBody MemberTrainPositionsDO memberTrainPositionsDO){
return ResponseData.generateCreatedResponse(0,memberTrainPositionsService.updatePosition(memberTrainPositionsDO));
}
}
......@@ -31,7 +31,7 @@ public class PositionItemInfoController {
private PositionItemInfoService positionItemInfoService;
@PostMapping("updateItemInfo")
@ApiOperation("编辑职位信息 id positionName positionStatus requireCounts positionId startSalary endSalary address jobIds[] 职位分类 ")
@ApiOperation("编辑职位信息 id positionName positionStatus requireCounts positionIds[] startSalary endSalary address jobIds[] 职位分类 ")
public ResponseVO updateItemInfo(@RequestBody UpdateItemInfoDTO updateItemInfoDTO){
return ResponseData.generateCreatedResponse(0,positionItemInfoService.updateItemInfo(updateItemInfoDTO));
}
......@@ -43,7 +43,7 @@ public class PositionItemInfoController {
}
@PostMapping("addItemInfo")
@ApiOperation("编辑职位信息 positionRequireId positionName positionStatus requireCount positionId startSalary endSalary address jobIds[] 职位分类 ")
@ApiOperation("编辑职位信息 positionRequireId positionName positionStatus requireCount positionIds[] startSalary endSalary address jobIds[] 职位分类 ")
public ResponseVO addItemInfo(@RequestBody UpdateItemInfoDTO updateItemInfoDTO){
return ResponseData.generateCreatedResponse(0,positionItemInfoService.addItemInfo(updateItemInfoDTO));
}
......
package com.laowu.controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import io.swagger.annotations.Api;
/**
* <p>
* 职位需求职位范围 前端控制器
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@RestController
@Api(tags = "职位需求职位范围")
@RequestMapping("/position-require-positions-do")
public class PositionRequirePositionsController {
}
......@@ -31,7 +31,7 @@ public class TeamDictController {
private TeamDictService teamDictService;
@PostMapping("teams")
@ApiOperation("工作站下的团队 pageSize pageNum stationId teamName")
@ApiOperation("工作站下的团队 pageSize pageNum province stationId teamName")
public ResponseVO teams(@RequestBody TeamsDTO teamsDTO){
return ResponseData.generateCreatedResponse(0,teamDictService.teams(teamsDTO));
}
......@@ -103,7 +103,7 @@ public class TeamDictController {
}
@PostMapping("memberManagement")
@ApiOperation("人员管理 pageSize pageNum teamId stationId province jobStatus userName")
@ApiOperation("人员管理 pageSize pageNum userId teamId stationId province jobStatus userName")
public ResponseVO memberManagement (@RequestBody MemberManagementDTO memberManagementDTO){
return ResponseData.generateCreatedResponse(0,teamDictService.memberManagement(memberManagementDTO));
}
......
package com.laowu.dto.administer;
import com.laowu.model.AdministerDO;
import lombok.Data;
import java.util.List;
@Data
public class AddAdministerDTO extends AdministerDO {
private List<Long> stationIds;
}
......@@ -3,6 +3,8 @@ package com.laowu.dto.member;
import com.laowu.model.MemberDictDO;
import lombok.Data;
import java.util.List;
@Data
public class AddMemberDTO extends MemberDictDO {
......@@ -12,4 +14,8 @@ public class AddMemberDTO extends MemberDictDO {
private Long stationId;
private Long teamId;
private List<Long> positionIds;
}
package com.laowu.dto.member;
import com.laowu.model.MemberTrainInfoDO;
import lombok.Data;
import java.util.List;
@Data
public class AddTrainDTO extends MemberTrainInfoDO {
private List<Long> positionIds;
}
......@@ -15,4 +15,6 @@ public class UpdateMemberDTO extends MemberDictDO {
private String module;
private List<Long> positionIds;
}
......@@ -10,4 +10,6 @@ public class UpdateItemInfoDTO extends PositionItemInfoDO {
private List<Long> jobIds;
private List<Long> positionIds;
}
......@@ -18,4 +18,6 @@ public class MemberManagementDTO {
private String jobStatus;
private String userName;
private Long userId;
}
......@@ -13,4 +13,5 @@ public class TeamsDTO {
private String teamName;
private String province;
}
package com.laowu.mapper;
import com.laowu.model.BusinessDictDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
/**
* <p>
* 经营范围 Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-13
*/
@Repository
public interface BusinessDictMapper extends BaseMapper<BusinessDictDO> {
}
package com.laowu.mapper;
import com.laowu.model.MemberCertsDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
/**
* <p>
* 学员证书表 Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Repository
public interface MemberCertsMapper extends BaseMapper<MemberCertsDO> {
}
package com.laowu.mapper;
import com.laowu.model.MemberPositionsDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.laowu.model.PositionDictDO;
import org.springframework.stereotype.Repository;
import java.util.List;
/**
* <p>
* Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Repository
public interface MemberPositionsMapper extends BaseMapper<MemberPositionsDO> {
/**
* 查找已经存在的positionsId
*/
List<Long> memberPositionIds(Long memberId);
/**
* 查找已经存在的positionsId
*/
List<PositionDictDO> memberPositions(Long memberId);
}
package com.laowu.mapper;
import com.laowu.model.MemberTrainInfoDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;
/**
* <p>
* 学员培训信息 Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Repository
public interface MemberTrainInfoMapper extends BaseMapper<MemberTrainInfoDO> {
}
package com.laowu.mapper;
import com.laowu.model.MemberTrainPositionsDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.laowu.model.PositionDictDO;
import org.springframework.stereotype.Repository;
import java.util.List;
/**
* <p>
* 培训关联职业范围 Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Repository
public interface MemberTrainPositionsMapper extends BaseMapper<MemberTrainPositionsDO> {
List<Long> positionIds(Long memberTrainId);
List<PositionDictDO> positions(Long memberTrainId);
}
......@@ -21,7 +21,7 @@ public interface PositionItemJobMappingMapper extends BaseMapper<PositionItemJob
/**
* 职位分类
*/
List<LibJobSortDO> positionSorts(Long requireId);
List<LibJobSortDO> positionSorts(Long itemInfoId);
/**
......
package com.laowu.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.laowu.model.PositionDictDO;
import com.laowu.model.PositionRequirePositionsDO;
import org.springframework.stereotype.Repository;
import java.util.List;
/**
* <p>
* 职位需求职位范围 Mapper 接口
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Repository
public interface PositionRequirePositionsMapper extends BaseMapper<PositionRequirePositionsDO> {
/**
* 职位范围ids 返回id
*/
List<Long> positionIds(Long itemInfoId);
/**
* 返回职位范围
*/
List<PositionDictDO> positionDicts(Long itemInfoId);
}
......@@ -8,6 +8,8 @@ import com.laowu.vo.team.MemberManagementVO;
import com.laowu.vo.team.TeamsVO;
import org.springframework.stereotype.Repository;
import java.util.List;
/**
* <p>
* 团队字典表 Mapper 接口
......@@ -19,7 +21,7 @@ import org.springframework.stereotype.Repository;
@Repository
public interface TeamDictMapper extends BaseMapper<TeamDictDO> {
IPage<TeamsVO> teams(IPage iPage, Long stationId, String teamName);
IPage<TeamsVO> teams(IPage iPage, Long stationId, String teamName,String province);
/**
* 查看某个工作站的带头人总数
......@@ -34,7 +36,7 @@ public interface TeamDictMapper extends BaseMapper<TeamDictDO> {
/**
* 人员管理
*/
IPage<MemberManagementVO> memberManagement(IPage page, Long teamId, Long stationId, String province, String jobStatus,String userName);
IPage<MemberManagementVO> memberManagement(IPage page, Long teamId, Long stationId, String province, String jobStatus, String userName, List<Long> workstationIds);
/**
......
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
* 经营范围
* </p>
*
* @author Tuyp
* @since 2023-04-13
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("business_dict")
public class BusinessDictDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
private String business;
}
......@@ -53,7 +53,7 @@ public class CompanyDictDO extends BaseModel {
/**
* 经营范围id
*/
private Long positionId;
private Long businessId;
/**
* 企业代码
......
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
* 学员证书表
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("member_certs")
public class MemberCertsDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
/**
* 学员id
*/
private Long memberId;
/**
* 证书
*/
private String cert;
}
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
*
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("member_positions")
public class MemberPositionsDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
/**
* 人员id
*/
private Long memberId;
/**
* 技能id
*/
private Long positionId;
}
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
* 学员培训信息
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("member_train_info")
public class MemberTrainInfoDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
/**
* 学员id
*/
private Long memberId;
/**
* 培训项目来源
*/
private String trainFrom;
/**
* 培训类型
*/
private String trainType;
/**
* 培训项目名称
*/
private String trainName;
/**
* 培训开始时间
*/
private String startDate;
/**
* 培训结束时间
*/
private String endDate;
/**
* 省
*/
private String province;
/**
* 市
*/
private String city;
/**
* 县
*/
private String county;
/**
* 培训内容
*/
private String trainContent;
/**
* 培训结果
*/
private String trainResult;
}
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
* 培训关联职业范围
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("member_train_positions")
public class MemberTrainPositionsDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
private Long memberTrainId;
private Long positionId;
}
......@@ -31,11 +31,6 @@ public class PositionItemInfoDO extends BaseModel {
private Long positionRequireId;
/**
* 职位名称
*/
private String positionName;
/**
* 招聘状态
*/
private String positionStatus;
......@@ -46,11 +41,6 @@ public class PositionItemInfoDO extends BaseModel {
private Integer requireCounts;
/**
* 职位范围id
*/
private Long positionId;
/**
* 起薪
*/
private String startSalary;
......
......@@ -70,4 +70,24 @@ public class PositionRequireItemDO extends BaseModel {
*/
private Long originId;
/**
* 具体地址
*/
private String address;
/**
* 投资额
*/
private String amount;
/**
* 开始时间
*/
private String startDate;
/**
* 结束时间
*/
private String endDate;
}
package com.laowu.model;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.laowu.util.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
* <p>
* 职位需求职位范围
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("position_require_positions")
public class PositionRequirePositionsDO extends BaseModel {
private static final long serialVersionUID = 1L;
@TableId(value = "id", type = IdType.AUTO)
private Long id;
private Long itemInfoId;
private Long positionId;
}
......@@ -2,6 +2,7 @@ package com.laowu.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.laowu.dto.administer.AddAdministerDTO;
import com.laowu.dto.administer.AllDTO;
import com.laowu.model.AdministerDO;
import com.laowu.vo.admin.AdministerPermissionVO;
......@@ -23,9 +24,9 @@ public interface AdministerService extends IService<AdministerDO> {
IPage<AdministerDO> all(AllDTO allDTO);
String addAdminister(AdministerDO administerDO);
String addAdminister(AddAdministerDTO addAdministerDTO);
String updateAdminister(AdministerDO administerDO);
String updateAdminister(AddAdministerDTO addAdministerDTO);
String deleteAdminister(AdministerDO administerDO);
......
package com.laowu.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.laowu.model.BusinessDictDO;
import java.util.List;
/**
* <p>
* 经营范围 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-13
*/
public interface BusinessDictService extends IService<BusinessDictDO> {
String addBusiness(BusinessDictDO businessDictDO);
String updateBusiness(BusinessDictDO businessDictDO);
String deleteBusiness(BusinessDictDO businessDictDO);
List<BusinessDictDO> queryBusiness();
}
......@@ -22,4 +22,6 @@ public interface LibJobSortService extends IService<LibJobSortDO> {
String updateSort(LibJobSortDO libJobSortDO);
String deleteSort(LibJobSortDO libJobSortDO);
String manage();
}
package com.laowu.service;
import com.laowu.model.MemberCertsDO;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* <p>
* 学员证书表 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
public interface MemberCertsService extends IService<MemberCertsDO> {
String addMemberCert(MemberCertsDO memberCertsDO);
String deleteMemberCert(MemberCertsDO memberCertsDO);
String updateMemberCert(MemberCertsDO memberCertsDO);
}
package com.laowu.service;
import com.laowu.model.MemberPositionsDO;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* <p>
* 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
public interface MemberPositionsService extends IService<MemberPositionsDO> {
String deletePosition(MemberPositionsDO memberPositionsDO);
String addPosition(MemberPositionsDO memberPositionsDO);
String updatePosition(MemberPositionsDO memberPositionsDO);
}
package com.laowu.service;
import com.laowu.dto.member.AddTrainDTO;
import com.laowu.model.MemberTrainInfoDO;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* <p>
* 学员培训信息 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
public interface MemberTrainInfoService extends IService<MemberTrainInfoDO> {
String addTrain(AddTrainDTO addTrainDTO);
String deleteTrain(MemberTrainInfoDO memberTrainInfoDO);
String updateTrain(AddTrainDTO addTrainDTO);
}
package com.laowu.service;
import com.laowu.model.MemberTrainPositionsDO;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* <p>
* 培训关联职业范围 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
public interface MemberTrainPositionsService extends IService<MemberTrainPositionsDO> {
String addPosition(MemberTrainPositionsDO memberTrainPositionsDO);
String deletePosition(MemberTrainPositionsDO memberTrainPositionsDO);
String updatePosition(MemberTrainPositionsDO memberTrainPositionsDO);
}
package com.laowu.service;
import com.laowu.model.PositionRequirePositionsDO;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* <p>
* 职位需求职位范围 服务类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
public interface PositionRequirePositionsService extends IService<PositionRequirePositionsDO> {
}
......@@ -5,12 +5,14 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.common.exception.HttpException;
import com.laowu.dto.administer.AddAdministerDTO;
import com.laowu.dto.administer.AllDTO;
import com.laowu.mapper.AdministerMapper;
import com.laowu.mapper.RoleAdministerMappingMapper;
import com.laowu.mapper.WorkstationAdministersMapper;
import com.laowu.model.AdministerDO;
import com.laowu.model.RoleAdministerMappingDO;
import com.laowu.model.WorkstationAdministersDO;
import com.laowu.model.WorkstationDictDO;
import com.laowu.service.AdministerService;
import com.laowu.util.ConstantUtils;
......@@ -22,6 +24,7 @@ import com.laowu.vo.admin.PermissionsVO;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List;
......@@ -101,12 +104,12 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis
//是不是管理员
int count = roleAdministerMappingMapper.selectCount(new QueryWrapper<RoleAdministerMappingDO>()
.lambda()
.eq(RoleAdministerMappingDO::getAdministerId,administerDO.getId())
.eq(RoleAdministerMappingDO::getRoleId,1));
if (count >0){
.lambda()
.eq(RoleAdministerMappingDO::getAdministerId, administerDO.getId())
.eq(RoleAdministerMappingDO::getRoleId, 1));
if (count > 0) {
administerPermissionVO.setIsRole(true);
}else {
} else {
administerPermissionVO.setIsRole(false);
//站长所有的工作站
List<WorkstationDictDO> workstationDictDOS = workstationAdministersMapper.workstations(administerDO.getId());
......@@ -121,15 +124,20 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis
return this.baseMapper.all(pager, allDTO.getStatus());
}
public String addAdminister(AdministerDO administerDO) {
@Transactional(rollbackFor = Exception.class)
public String addAdminister(AddAdministerDTO addAdministerDTO) {
int count = this.baseMapper.selectCount(new QueryWrapper<AdministerDO>()
.lambda()
.eq(AdministerDO::getAccount, administerDO.getAccount()));
.eq(AdministerDO::getAccount, addAdministerDTO.getAccount()));
if (count > 0) {
throw new HttpException(70001);
}
AdministerDO administerDO = new AdministerDO();
BeanUtils.copyProperties(addAdministerDTO, administerDO);
administerDO.setStatus("正常");
administerDO.setPassword("123456");
this.baseMapper.insert(administerDO);
......@@ -139,20 +147,61 @@ public class AdministerServiceImpl extends ServiceImpl<AdministerMapper, Adminis
roleAdministerMappingDO.setRoleId(2L);
roleAdministerMappingMapper.insert(roleAdministerMappingDO);
List<Long> stations = addAdministerDTO.getStationIds();
for (Long stationId: stations){
WorkstationAdministersDO workstationAdministersDO = new WorkstationAdministersDO();
workstationAdministersDO.setAdministerId(administerDO.getId());
workstationAdministersDO.setWorkstationId(stationId);
workstationAdministersMapper.insert(workstationAdministersDO);
}
return ConstantUtils.ADD_SUCCESS;
}
public String updateAdminister(AdministerDO administerDO) {
public String updateAdminister(AddAdministerDTO addAdministerDTO) {
int count = this.baseMapper.selectCount(new QueryWrapper<AdministerDO>()
.lambda()
.eq(AdministerDO::getAccount, administerDO.getAccount())
.ne(AdministerDO::getId, administerDO.getId()));
.eq(AdministerDO::getAccount, addAdministerDTO.getAccount())
.ne(AdministerDO::getId, addAdministerDTO.getId()));
if (count > 0) {
throw new HttpException(70001);
}
AdministerDO administerDO = new AdministerDO();
BeanUtils.copyProperties(addAdministerDTO, administerDO);
this.baseMapper.updateById(administerDO);
//找到已经有的work
List<Long> oldIds = workstationAdministersMapper.administerStations(addAdministerDTO.getId());
List<Long> newIds = addAdministerDTO.getStationIds();
List<Long> newIds2 = new ArrayList<Long>();
for (Long id : newIds) {
newIds2.add(id);
}
newIds.removeAll(oldIds); //新增的人在newIds里面
if (newIds.size() > 0) {
for (Long id : newIds) {
WorkstationAdministersDO workstationAdministersDO = new WorkstationAdministersDO();
workstationAdministersDO.setAdministerId(addAdministerDTO.getId());
workstationAdministersDO.setWorkstationId(id);
workstationAdministersMapper.insert(workstationAdministersDO);
}
}
oldIds.removeAll(newIds2);//删掉以前的
if (oldIds.size() > 0) {
for (Long id : oldIds) {
workstationAdministersMapper.delete(new QueryWrapper<WorkstationAdministersDO>()
.lambda()
.eq(WorkstationAdministersDO::getAdministerId, addAdministerDTO.getId())
.eq(WorkstationAdministersDO::getWorkstationId, id));
}
}
return ConstantUtils.SUCCESS_UPDATE;
}
......
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.common.exception.HttpException;
import com.laowu.mapper.BusinessDictMapper;
import com.laowu.model.BusinessDictDO;
import com.laowu.service.BusinessDictService;
import com.laowu.util.ConstantUtils;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* <p>
* 经营范围 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-13
*/
@Service
public class BusinessDictServiceImpl extends ServiceImpl<BusinessDictMapper, BusinessDictDO> implements BusinessDictService {
public String addBusiness(BusinessDictDO businessDictDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<BusinessDictDO>()
.lambda()
.eq(BusinessDictDO::getBusiness, businessDictDO.getBusiness()));
if (count > 0) {
throw new HttpException(60001);
}
this.baseMapper.insert(businessDictDO);
return ConstantUtils.ADD_SUCCESS;
}
public String updateBusiness(BusinessDictDO businessDictDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<BusinessDictDO>()
.lambda()
.eq(BusinessDictDO::getBusiness, businessDictDO.getBusiness())
.ne(BusinessDictDO::getBusiness, businessDictDO.getBusiness()));
if (count > 0) {
throw new HttpException(60001);
}
this.baseMapper.updateById(businessDictDO);
return ConstantUtils.ADD_SUCCESS;
}
public String deleteBusiness(BusinessDictDO businessDictDO) {
this.baseMapper.deleteById(businessDictDO.getId());
return ConstantUtils.DELETE_SUCCESS;
}
public List<BusinessDictDO> queryBusiness() {
return this.baseMapper.selectList(null);
}
}
......@@ -53,6 +53,9 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
@Autowired
private WorkstationDictMapper workstationDictMapper;
@Autowired
private BusinessDictMapper businessDictMapper;
public IPage<CompanyVO> company(CompanyDTO companyDTO) {
Page pager = new Page(companyDTO.getPageNum(), companyDTO.getPageSize());
......@@ -216,7 +219,7 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
if (null != companyDictDO.getCounty() && !companyDictDO.getCounty().equals(addCompanyDTO.getCounty())) {
stringBuffer.append("县、");
}
if (null != companyDictDO.getPositionId() && !companyDictDO.getPositionId().equals(addCompanyDTO.getPositionId())) {
if (null != companyDictDO.getBusinessId() && !companyDictDO.getBusinessId().equals(addCompanyDTO.getBusinessId())) {
stringBuffer.append("经营范围、");
}
if (null != companyDictDO.getCompanyCode() && !companyDictDO.getCompanyCode().equals(addCompanyDTO.getCompanyCode())) {
......@@ -246,9 +249,11 @@ public class CompanyDictServiceImpl extends ServiceImpl<CompanyDictMapper, Compa
CompanyDictDO companyDictDO1 = this.baseMapper.selectById(companyDictDO.getId());
BeanUtils.copyProperties(companyDictDO1, companyVO);
if (null != companyDictDO1.getPositionId()) {
PositionDictDO positionDictDO = positionDictMapper.selectById(companyDictDO1.getPositionId());
companyVO.setPositionType(positionDictDO.getPositionType());
if (null != companyDictDO1.getBusinessId()) {
BusinessDictDO businessDictDO = businessDictMapper.selectById(companyDictDO1.getBusinessId());
if (null != businessDictDO){
companyVO.setBusiness(businessDictDO.getBusiness());
}
}
List<CompanyPhotoDO> companyPhotoDOS = companyPhotoMapper.selectList(new QueryWrapper<CompanyPhotoDO>()
......
......@@ -30,10 +30,10 @@ public class LibJobSortServiceImpl extends ServiceImpl<LibJobSortMapper, LibJobS
//找到所有的父节点
List<LibJobSortDO> libJobSortDOS = this.baseMapper.selectList(new QueryWrapper<LibJobSortDO>()
.lambda()
.isNull(LibJobSortDO::getParentId));
.lambda()
.isNull(LibJobSortDO::getParentId));
for (LibJobSortDO libJobSortDO : libJobSortDOS){
for (LibJobSortDO libJobSortDO : libJobSortDOS) {
libJobSortDO.setChildren(getChildNodes(libJobSortDO));
sortsVOS.add(libJobSortDO);
}
......@@ -43,22 +43,22 @@ public class LibJobSortServiceImpl extends ServiceImpl<LibJobSortMapper, LibJobS
/**
* 递归遍历子节点
* 递归遍历子节点
*/
public List<LibJobSortDO> getChildNodes(LibJobSortDO libJobSortDO){
public List<LibJobSortDO> getChildNodes(LibJobSortDO libJobSortDO) {
List<LibJobSortDO> sortsVOS = new ArrayList<>();
//查找该父节点下的子节点
List<LibJobSortDO> libJobSortDOS = this.baseMapper.selectList(new QueryWrapper<LibJobSortDO>()
.lambda()
.eq(LibJobSortDO::getParentId,libJobSortDO.getId()));
.eq(LibJobSortDO::getParentId, libJobSortDO.getId()));
for (LibJobSortDO ljd : libJobSortDOS){
for (LibJobSortDO ljd : libJobSortDOS) {
sortsVOS.add(ljd);
ljd.setChildren(getChildNodes(ljd));
}
if (libJobSortDOS.size()==0){
if (libJobSortDOS.size() == 0) {
return null;
}
return sortsVOS;
......@@ -101,16 +101,37 @@ public class LibJobSortServiceImpl extends ServiceImpl<LibJobSortMapper, LibJobS
//递归删除
List<LibJobSortDO> libJobSortDOS = this.baseMapper.selectList(new QueryWrapper<LibJobSortDO>()
.lambda()
.eq(LibJobSortDO::getParentId,libJobSortDO.getId()));
.lambda()
.eq(LibJobSortDO::getParentId, libJobSortDO.getId()));
for (LibJobSortDO libJobSortDO1 :libJobSortDOS){
for (LibJobSortDO libJobSortDO1 : libJobSortDOS) {
libJobSortDO1.setChildren(removeChildNodes(libJobSortDO1));
}
return ConstantUtils.DELETE_SUCCESS;
}
public String manage() {
List<LibJobSortDO> libJobSortDOS = this.baseMapper.selectList(new QueryWrapper<LibJobSortDO>()
.lambda()
.ge(LibJobSortDO::getId,66));
for (LibJobSortDO libJobSortDO : libJobSortDOS){
String sortCode = libJobSortDO.getSortCode().substring(0,7);
LibJobSortDO libJobSortDO1 = this.baseMapper.selectOne(new QueryWrapper<LibJobSortDO>()
.lambda()
.eq(LibJobSortDO::getSortCode,sortCode));
libJobSortDO.setParentId(libJobSortDO1.getId());
this.baseMapper.updateById(libJobSortDO);
}
return ConstantUtils.SUCCESS_UPDATE;
}
/**
* 递归遍历课程子节点 并移除
*/
......
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.laowu.common.exception.HttpException;
import com.laowu.model.MemberCertsDO;
import com.laowu.mapper.MemberCertsMapper;
import com.laowu.service.MemberCertsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.util.ConstantUtils;
import org.springframework.stereotype.Service;
/**
* <p>
* 学员证书表 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Service
public class MemberCertsServiceImpl extends ServiceImpl<MemberCertsMapper, MemberCertsDO> implements MemberCertsService {
public String addMemberCert(MemberCertsDO memberCertsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberCertsDO>()
.lambda()
.eq(MemberCertsDO::getMemberId, memberCertsDO.getMemberId())
.eq(MemberCertsDO::getCert, memberCertsDO.getCert()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.insert(memberCertsDO);
return ConstantUtils.ADD_SUCCESS;
}
public String deleteMemberCert(MemberCertsDO memberCertsDO) {
this.baseMapper.deleteById(memberCertsDO.getId());
return ConstantUtils.DELETE_SUCCESS;
}
public String updateMemberCert(MemberCertsDO memberCertsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberCertsDO>()
.lambda()
.eq(MemberCertsDO::getCert, memberCertsDO.getCert())
.ne(MemberCertsDO::getId, memberCertsDO.getId()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.updateById(memberCertsDO);
return ConstantUtils.SUCCESS_UPDATE;
}
}
......@@ -12,10 +12,7 @@ import com.laowu.mapper.*;
import com.laowu.model.*;
import com.laowu.service.MemberDictService;
import com.laowu.util.ConstantUtils;
import com.laowu.vo.member.AllMembersVO;
import com.laowu.vo.member.MemberCollegeVO;
import com.laowu.vo.member.MemberJobInfoVO;
import com.laowu.vo.member.OneMemberVO;
import com.laowu.vo.member.*;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
......@@ -65,9 +62,30 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
@Autowired
private TeamDictMapper teamDictMapper;
@Autowired
private MemberPositionsMapper memberPositionsMapper;
@Autowired
private MemberCertsMapper memberCertsMapper;
@Autowired
private MemberTrainInfoMapper memberTrainInfoMapper;
@Autowired
private MemberTrainPositionsMapper memberTrainPositionsMapper;
public IPage<AllMembersVO> allMembers(AllMembersDTO allMembersDTO) {
Page pager = new Page(allMembersDTO.getPageNum(), allMembersDTO.getPageSize());
return this.baseMapper.allMembers(pager, allMembersDTO.getProvince(), allMembersDTO.getCity(), allMembersDTO.getCounty(), allMembersDTO.getStatus(), allMembersDTO.getUserName());
IPage<AllMembersVO> allMembersVOIPage = this.baseMapper.allMembers(pager, allMembersDTO.getProvince(), allMembersDTO.getCity(), allMembersDTO.getCounty(), allMembersDTO.getStatus(), allMembersDTO.getUserName());
List<AllMembersVO> allMembersVOS = allMembersVOIPage.getRecords();
for (AllMembersVO allMembersVO : allMembersVOS) {
//专业技能信息
List<PositionDictDO> memberPositions = memberPositionsMapper.memberPositions(allMembersVO.getId());
allMembersVO.setPositionDictDOS(memberPositions);
}
return allMembersVOIPage;
}
@Transactional(rollbackFor = Exception.class)
......@@ -75,8 +93,12 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
this.baseMapper.deleteById(addMemberDTO.getId());
memberTeamMappingMapper.delete(new QueryWrapper<MemberTeamMappingDO>()
.lambda()
.eq(MemberTeamMappingDO::getMemberId,addMemberDTO.getId()));
.lambda()
.eq(MemberTeamMappingDO::getMemberId, addMemberDTO.getId()));
workstationMemberMappingMapper.delete(new QueryWrapper<WorkstationMemberMappingDO>()
.lambda()
.eq(WorkstationMemberMappingDO::getMemberId, addMemberDTO.getId()));
memberJobInfoMapper.delete(new QueryWrapper<MemberJobInfoDO>()
.lambda()
......@@ -84,10 +106,10 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
//团队领导人为id的团队组长职位空
List<TeamDictDO> teamDictDOS = teamDictMapper.selectList(new QueryWrapper<TeamDictDO>()
.lambda()
.eq(TeamDictDO::getMemberId,addMemberDTO.getId()));
.lambda()
.eq(TeamDictDO::getMemberId, addMemberDTO.getId()));
for (TeamDictDO teamDictDO : teamDictDOS){
for (TeamDictDO teamDictDO : teamDictDOS) {
teamDictMapper.noLeader(teamDictDO.getId());
}
......@@ -113,25 +135,41 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
}
MemberDictDO memberDictDO = new MemberDictDO();
BeanUtils.copyProperties(addMemberDTO,memberDictDO);
BeanUtils.copyProperties(addMemberDTO, memberDictDO);
//信息来源
if (null != addMemberDTO.getStationId()){
if (null != addMemberDTO.getStationId()) {
WorkstationDictDO workstationDictDO = workstationDictMapper.selectById(addMemberDTO.getStationId());
if (null != workstationDictDO){
if (null != workstationDictDO) {
memberDictDO.setInfoOrigin(workstationDictDO.getWorkstationName());
}
} else {
memberDictDO.setInfoOrigin("自然人数据库");
}
List<Long> positionIds = addMemberDTO.getPositionIds();
for (Long positionId : positionIds) {
MemberPositionsDO memberPositionsDO = new MemberPositionsDO();
memberPositionsDO.setMemberId(memberDictDO.getId());
memberPositionsDO.setPositionId(positionId);
memberPositionsMapper.insert(memberPositionsDO);
}
this.baseMapper.insert(memberDictDO);
if (null != addMemberDTO.getStationId()){
if (null != addMemberDTO.getStationId()) {
WorkstationMemberMappingDO workstationMemberMappingDO = new WorkstationMemberMappingDO();
workstationMemberMappingDO.setMemberId(memberDictDO.getId());
workstationMemberMappingDO.setStationId(addMemberDTO.getStationId());
workstationMemberMappingMapper.insert(workstationMemberMappingDO);
}
if (null != addMemberDTO.getTeamId()) {
MemberTeamMappingDO memberTeamMappingDO = new MemberTeamMappingDO();
memberTeamMappingDO.setMemberId(memberDictDO.getId());
memberTeamMappingDO.setTeamId(addMemberDTO.getTeamId());
memberTeamMappingMapper.insert(memberTeamMappingDO);
}
//历史
MemberUpdateHistoryDO memberUpdateHistoryDO = new MemberUpdateHistoryDO();
memberUpdateHistoryDO.setAdministerId(addMemberDTO.getUserId());
......@@ -162,11 +200,11 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
//院校信息
List<MemberCollegeVO> memberCollegeVOS = new ArrayList<>();
List<MemberCollegeMappingDO> memberCollegeMappingDOS = memberCollegeMappingMapper.selectList(new QueryWrapper<MemberCollegeMappingDO>()
.lambda()
.eq(MemberCollegeMappingDO::getMemberId,memberDictDO1.getId()));
for (MemberCollegeMappingDO mcmd : memberCollegeMappingDOS){
.lambda()
.eq(MemberCollegeMappingDO::getMemberId, memberDictDO1.getId()));
for (MemberCollegeMappingDO mcmd : memberCollegeMappingDOS) {
MemberCollegeVO memberCollegeVO = new MemberCollegeVO();
BeanUtils.copyProperties(mcmd,memberCollegeVO);
BeanUtils.copyProperties(mcmd, memberCollegeVO);
LibCollegeDO libCollegeDO = libCollegeMapper.selectById(mcmd.getCollegeId());
memberCollegeVO.setCollege(libCollegeDO.getCollege());
......@@ -180,7 +218,8 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
List<MemberJobInfoVO> memberJobInfoVOS = new ArrayList<MemberJobInfoVO>();
List<MemberJobInfoDO> memberJobInfoDOS = memberJobInfoMapper.selectList(new QueryWrapper<MemberJobInfoDO>()
.lambda()
.eq(MemberJobInfoDO::getMemberId, memberDictDO1.getId()));
.eq(MemberJobInfoDO::getMemberId, memberDictDO1.getId())
.orderByDesc(MemberJobInfoDO::getStartDate));
for (MemberJobInfoDO memberJobInfoDO : memberJobInfoDOS) {
MemberJobInfoVO memberJobInfoVO = new MemberJobInfoVO();
BeanUtils.copyProperties(memberJobInfoDO, memberJobInfoVO);
......@@ -190,6 +229,35 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
memberJobInfoVOS.add(memberJobInfoVO);
}
oneMemberVO.setMemberJobInfoVOS(memberJobInfoVOS);
//专业技能信息
List<PositionDictDO> memberPositions = memberPositionsMapper.memberPositions(memberDictDO.getId());
oneMemberVO.setPositionDictDOS(memberPositions);
//专业证书信息
List<MemberCertsDO> memberCertsDOS = memberCertsMapper.selectList(new QueryWrapper<MemberCertsDO>()
.lambda()
.eq(MemberCertsDO::getMemberId, memberDictDO1.getId()));
oneMemberVO.setMemberCertsDOS(memberCertsDOS);
//培训信息
List<MemberTrainInfoVO> memberTrainInfoVOS = new ArrayList<>();
List<MemberTrainInfoDO> memberTrainInfoDOS = memberTrainInfoMapper.selectList(new QueryWrapper<MemberTrainInfoDO>()
.lambda()
.eq(MemberTrainInfoDO::getMemberId, memberDictDO1.getId()));
for (MemberTrainInfoDO mtid : memberTrainInfoDOS) {
MemberTrainInfoVO memberTrainInfoVO = new MemberTrainInfoVO();
BeanUtils.copyProperties(mtid, memberTrainInfoVO);
//技能
List<PositionDictDO> positionDictDOS = memberTrainPositionsMapper.positions(mtid.getId());
memberTrainInfoVO.setPositionDictDOS(positionDictDOS);
memberTrainInfoVOS.add(memberTrainInfoVO);
}
oneMemberVO.setMemberTrainInfoVOS(memberTrainInfoVOS);
return oneMemberVO;
}
......@@ -218,6 +286,39 @@ public class MemberDictServiceImpl extends ServiceImpl<MemberDictMapper, MemberD
stringBuffer.append("就业信息、");
}
if (null != updateMemberDTO.getPositionIds()) {
List<Long> newIds = updateMemberDTO.getPositionIds();
List<Long> oldIds = memberPositionsMapper.memberPositionIds(memberDictDO.getId());
List<Long> newIds2 = new ArrayList<Long>();
for (Long id : newIds) {
newIds2.add(id);
}
newIds.removeAll(oldIds); //新增的人在newIds里面
if (newIds.size() > 0) {
for (Long id : newIds) {
MemberPositionsDO memberPositionsDO = new MemberPositionsDO();
memberPositionsDO.setMemberId(memberDictDO.getId());
memberPositionsDO.setPositionId(id);
memberPositionsMapper.insert(memberPositionsDO);
}
}
oldIds.removeAll(newIds2);//删掉以前的
if (oldIds.size() > 0) {
for (Long id : oldIds) {
memberPositionsMapper.delete(new QueryWrapper<MemberPositionsDO>()
.lambda()
.eq(MemberPositionsDO::getMemberId, memberDictDO.getId())
.eq(MemberPositionsDO::getPositionId, id));
}
}
}
//历史
MemberUpdateHistoryDO memberUpdateHistoryDO = new MemberUpdateHistoryDO();
memberUpdateHistoryDO.setAdministerId(updateMemberDTO.getUserId());
......
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.laowu.common.exception.HttpException;
import com.laowu.model.MemberPositionsDO;
import com.laowu.mapper.MemberPositionsMapper;
import com.laowu.service.MemberPositionsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.util.ConstantUtils;
import org.springframework.stereotype.Service;
/**
* <p>
* 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Service
public class MemberPositionsServiceImpl extends ServiceImpl<MemberPositionsMapper, MemberPositionsDO> implements MemberPositionsService {
public String deletePosition(MemberPositionsDO memberPositionsDO) {
this.baseMapper.deleteById(memberPositionsDO.getId());
return ConstantUtils.DELETE_SUCCESS;
}
public String addPosition(MemberPositionsDO memberPositionsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberPositionsDO>()
.lambda()
.eq(MemberPositionsDO::getMemberId, memberPositionsDO.getMemberId())
.eq(MemberPositionsDO::getPositionId, memberPositionsDO.getPositionId()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.insert(memberPositionsDO);
return ConstantUtils.ADD_SUCCESS;
}
public String updatePosition(MemberPositionsDO memberPositionsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberPositionsDO>()
.lambda()
.ne(MemberPositionsDO::getId, memberPositionsDO.getId())
.eq(MemberPositionsDO::getPositionId, memberPositionsDO.getPositionId()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.updateById(memberPositionsDO);
return ConstantUtils.SUCCESS_UPDATE;
}
}
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.dto.member.AddTrainDTO;
import com.laowu.mapper.MemberTrainInfoMapper;
import com.laowu.mapper.MemberTrainPositionsMapper;
import com.laowu.model.MemberTrainInfoDO;
import com.laowu.model.MemberTrainPositionsDO;
import com.laowu.service.MemberTrainInfoService;
import com.laowu.util.ConstantUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.List;
/**
* <p>
* 学员培训信息 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Service
public class MemberTrainInfoServiceImpl extends ServiceImpl<MemberTrainInfoMapper, MemberTrainInfoDO> implements MemberTrainInfoService {
@Autowired
private MemberTrainPositionsMapper memberTrainPositionsMapper;
public String addTrain(AddTrainDTO addTrainDTO) {
MemberTrainInfoDO memberTrainInfoDO = new MemberTrainInfoDO();
BeanUtils.copyProperties(addTrainDTO, memberTrainInfoDO);
this.baseMapper.insert(memberTrainInfoDO);
List<Long> positionIds = addTrainDTO.getPositionIds();
for (Long positionId : positionIds) {
MemberTrainPositionsDO memberTrainPositionsDO = new MemberTrainPositionsDO();
memberTrainPositionsDO.setMemberTrainId(memberTrainInfoDO.getId());
memberTrainPositionsDO.setPositionId(positionId);
memberTrainPositionsMapper.insert(memberTrainPositionsDO);
}
return ConstantUtils.ADD_SUCCESS;
}
public String deleteTrain(MemberTrainInfoDO memberTrainInfoDO) {
this.baseMapper.deleteById(memberTrainInfoDO.getId());
memberTrainPositionsMapper.delete(new QueryWrapper<MemberTrainPositionsDO>()
.lambda()
.eq(MemberTrainPositionsDO::getMemberTrainId, memberTrainInfoDO.getId()));
return ConstantUtils.DELETE_SUCCESS;
}
public String updateTrain(AddTrainDTO addTrainDTO) {
MemberTrainInfoDO memberTrainInfoDO = new MemberTrainInfoDO();
BeanUtils.copyProperties(addTrainDTO, memberTrainInfoDO);
this.baseMapper.updateById(memberTrainInfoDO);
//找到已经有的work
List<Long> oldIds = memberTrainPositionsMapper.positionIds(memberTrainInfoDO.getId());
List<Long> newIds = addTrainDTO.getPositionIds();
List<Long> newIds2 = new ArrayList<Long>();
for (Long id : newIds) {
newIds2.add(id);
}
newIds.removeAll(oldIds); //新增的人在newIds里面
if (newIds.size() > 0) {
for (Long id : newIds) {
MemberTrainPositionsDO memberTrainPositionsDO = new MemberTrainPositionsDO();
memberTrainPositionsDO.setMemberTrainId(addTrainDTO.getId());
memberTrainPositionsDO.setPositionId(id);
memberTrainPositionsMapper.insert(memberTrainPositionsDO);
}
}
oldIds.removeAll(newIds2);//删掉以前的
if (oldIds.size() > 0) {
for (Long id : oldIds) {
memberTrainPositionsMapper.delete(new QueryWrapper<MemberTrainPositionsDO>()
.lambda()
.eq(MemberTrainPositionsDO::getMemberTrainId, addTrainDTO.getId())
.eq(MemberTrainPositionsDO::getPositionId, id));
}
}
return ConstantUtils.SUCCESS_UPDATE;
}
}
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.laowu.common.exception.HttpException;
import com.laowu.model.MemberTrainPositionsDO;
import com.laowu.mapper.MemberTrainPositionsMapper;
import com.laowu.service.MemberTrainPositionsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.util.ConstantUtils;
import org.springframework.stereotype.Service;
/**
* <p>
* 培训关联职业范围 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Service
public class MemberTrainPositionsServiceImpl extends ServiceImpl<MemberTrainPositionsMapper, MemberTrainPositionsDO> implements MemberTrainPositionsService {
public String addPosition(MemberTrainPositionsDO memberTrainPositionsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberTrainPositionsDO>()
.lambda()
.eq(MemberTrainPositionsDO::getMemberTrainId, memberTrainPositionsDO.getMemberTrainId())
.eq(MemberTrainPositionsDO::getPositionId, memberTrainPositionsDO.getPositionId()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.insert(memberTrainPositionsDO);
return ConstantUtils.ADD_SUCCESS;
}
public String deletePosition(MemberTrainPositionsDO memberTrainPositionsDO) {
this.baseMapper.deleteById(memberTrainPositionsDO.getId());
return ConstantUtils.DELETE_SUCCESS;
}
public String updatePosition(MemberTrainPositionsDO memberTrainPositionsDO) {
int count = this.baseMapper.selectCount(new QueryWrapper<MemberTrainPositionsDO>()
.lambda()
.ne(MemberTrainPositionsDO::getId, memberTrainPositionsDO.getId())
.eq(MemberTrainPositionsDO::getPositionId, memberTrainPositionsDO.getPositionId()));
if (count > 0) {
throw new HttpException(70001);
}
this.baseMapper.updateById(memberTrainPositionsDO);
return ConstantUtils.SUCCESS_UPDATE;
}
}
package com.laowu.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
......@@ -55,6 +56,10 @@ public class PositionAloneInfoServiceImpl extends ServiceImpl<PositionAloneInfoM
public String deleteRequestment(AddAloneDTO addAloneDTO) {
this.baseMapper.deleteById(addAloneDTO.getId());
workstationAloneMappingMapper.delete(new QueryWrapper<WorkstationAloneMappingDO>()
.lambda()
.eq(WorkstationAloneMappingDO::getAloneId, addAloneDTO.getId()));
//历史
PositionAloneHistoryDO positionAloneHistoryDO = new PositionAloneHistoryDO();
positionAloneHistoryDO.setAdministerId(addAloneDTO.getUserId());
......@@ -82,7 +87,7 @@ public class PositionAloneInfoServiceImpl extends ServiceImpl<PositionAloneInfoM
positionAloneHistoryMapper.insert(positionAloneHistoryDO);
//添加映射
if (null != addAloneDTO.getStationId()){
if (null != addAloneDTO.getStationId()) {
WorkstationAloneMappingDO workstationAloneMappingDO = new WorkstationAloneMappingDO();
workstationAloneMappingDO.setStationId(addAloneDTO.getStationId());
workstationAloneMappingDO.setAloneId(positionAloneInfoDO.getId());
......@@ -97,12 +102,12 @@ public class PositionAloneInfoServiceImpl extends ServiceImpl<PositionAloneInfoM
PositionAloneInfoDO positionAloneInfoDO1 = this.baseMapper.selectById(addAloneDTO.getId());
PositionAloneInfoDO positionAloneInfoDO = new PositionAloneInfoDO();
BeanUtils.copyProperties(addAloneDTO,positionAloneInfoDO);
BeanUtils.copyProperties(addAloneDTO, positionAloneInfoDO);
this.baseMapper.updateById(positionAloneInfoDO);
//
//修改内容
PositionAloneHistoryDO positionAloneHistoryDO= new PositionAloneHistoryDO();
PositionAloneHistoryDO positionAloneHistoryDO = new PositionAloneHistoryDO();
positionAloneHistoryDO.setAdministerId(addAloneDTO.getUserId());
positionAloneHistoryDO.setModule(addAloneDTO.getModule());
positionAloneHistoryDO.setRequireId(positionAloneInfoDO.getId());
......@@ -110,48 +115,43 @@ public class PositionAloneInfoServiceImpl extends ServiceImpl<PositionAloneInfoM
StringBuffer stringBuffer = new StringBuffer();
stringBuffer.append("变更了“");
//id itemName itemStatus companyId jobId infoOrigin province city county
if (null != positionAloneInfoDO1.getPositionName() && !positionAloneInfoDO1.getPositionName().equals(addAloneDTO.getPositionName())){
stringBuffer.append("职位名称、");
}
if (null != positionAloneInfoDO1.getCompanyId() && !positionAloneInfoDO1.getCompanyId().equals(addAloneDTO.getCompanyId())){
if (null != positionAloneInfoDO1.getCompanyId() && !positionAloneInfoDO1.getCompanyId().equals(addAloneDTO.getCompanyId())) {
stringBuffer.append("企业名称、");
}
if (null != positionAloneInfoDO1.getPositionStatus() && !positionAloneInfoDO1.getPositionStatus().equals(addAloneDTO.getPositionStatus())){
if (null != positionAloneInfoDO1.getPositionStatus() && !positionAloneInfoDO1.getPositionStatus().equals(addAloneDTO.getPositionStatus())) {
stringBuffer.append("招聘状态、");
}
if (null != positionAloneInfoDO1.getRequireCounts() && !positionAloneInfoDO1.getRequireCounts().equals(addAloneDTO.getRequireCounts())){
if (null != positionAloneInfoDO1.getRequireCounts() && !positionAloneInfoDO1.getRequireCounts().equals(addAloneDTO.getRequireCounts())) {
stringBuffer.append("预招人数、");
}
if (null != positionAloneInfoDO1.getRecruitType() && !positionAloneInfoDO1.getRecruitType().equals(addAloneDTO.getRecruitType())){
if (null != positionAloneInfoDO1.getRecruitType() && !positionAloneInfoDO1.getRecruitType().equals(addAloneDTO.getRecruitType())) {
stringBuffer.append("招聘类型、");
}
if (null != positionAloneInfoDO1.getPositionDesc() && !positionAloneInfoDO1.getPositionDesc().equals(addAloneDTO.getPositionDesc())){
if (null != positionAloneInfoDO1.getPositionDesc() && !positionAloneInfoDO1.getPositionDesc().equals(addAloneDTO.getPositionDesc())) {
stringBuffer.append("职位描述、");
}
if (null != positionAloneInfoDO1.getPositionRequire() && !positionAloneInfoDO1.getPositionRequire().equals(addAloneDTO.getPositionRequire())){
if (null != positionAloneInfoDO1.getPositionRequire() && !positionAloneInfoDO1.getPositionRequire().equals(addAloneDTO.getPositionRequire())) {
stringBuffer.append("职位要求、");
}
if (null != positionAloneInfoDO1.getInfoOrigin() && !positionAloneInfoDO1.getInfoOrigin().equals(addAloneDTO.getInfoOrigin())){
if (null != positionAloneInfoDO1.getInfoOrigin() && !positionAloneInfoDO1.getInfoOrigin().equals(addAloneDTO.getInfoOrigin())) {
stringBuffer.append("关联信息、");
}
if (null != positionAloneInfoDO1.getStartSalary() && !positionAloneInfoDO1.getStartSalary().equals(addAloneDTO.getStartSalary())){
if (null != positionAloneInfoDO1.getStartSalary() && !positionAloneInfoDO1.getStartSalary().equals(addAloneDTO.getStartSalary())) {
stringBuffer.append("起薪、");
}
if (null != positionAloneInfoDO1.getEndSalary() && !positionAloneInfoDO1.getEndSalary().equals(addAloneDTO.getEndSalary())){
if (null != positionAloneInfoDO1.getEndSalary() && !positionAloneInfoDO1.getEndSalary().equals(addAloneDTO.getEndSalary())) {
stringBuffer.append("止薪、");
}
if (null != positionAloneInfoDO1.getProvince() && !positionAloneInfoDO1.getProvince().equals(addAloneDTO.getProvince())||!positionAloneInfoDO1.getCity().equals(addAloneDTO.getCity())||!positionAloneInfoDO1.getCounty().equals(addAloneDTO.getCounty())){
if (null != positionAloneInfoDO1.getProvince() && !positionAloneInfoDO1.getProvince().equals(addAloneDTO.getProvince()) || !positionAloneInfoDO1.getCity().equals(addAloneDTO.getCity()) || !positionAloneInfoDO1.getCounty().equals(addAloneDTO.getCounty())) {
stringBuffer.append("就业地区");
}
......
......@@ -5,8 +5,11 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.dto.position.UpdateItemInfoDTO;
import com.laowu.mapper.PositionItemInfoMapper;
import com.laowu.mapper.PositionItemJobMappingMapper;
import com.laowu.mapper.PositionRequirePositionsMapper;
import com.laowu.mapper.WorkstationRequireMappingMapper;
import com.laowu.model.PositionItemInfoDO;
import com.laowu.model.PositionItemJobMappingDO;
import com.laowu.model.PositionRequirePositionsDO;
import com.laowu.service.PositionItemInfoService;
import com.laowu.util.ConstantUtils;
import org.springframework.beans.BeanUtils;
......@@ -30,6 +33,12 @@ public class PositionItemInfoServiceImpl extends ServiceImpl<PositionItemInfoMap
@Autowired
private PositionItemJobMappingMapper positionItemJobMappingMapper;
@Autowired
private PositionRequirePositionsMapper positionRequirePositionsMapper;
@Autowired
private WorkstationRequireMappingMapper workstationRequireMappingMapper;
public String updateItemInfo(UpdateItemInfoDTO updateItemInfoDTO) {
PositionItemInfoDO positionItemInfoDO = new PositionItemInfoDO();
......@@ -68,27 +77,76 @@ public class PositionItemInfoServiceImpl extends ServiceImpl<PositionItemInfoMap
}
}
}
if (null != updateItemInfoDTO.getPositionIds()) {
//找到已经有的work
List<Long> oldIds = positionRequirePositionsMapper.positionIds(updateItemInfoDTO.getId());
List<Long> newIds = updateItemInfoDTO.getPositionIds();
List<Long> newIds2 = new ArrayList<Long>();
for (Long id : newIds) {
newIds2.add(id);
}
newIds.removeAll(oldIds); //新增的人在newIds里面
if (newIds.size() > 0) {
for (Long id : newIds) {
PositionRequirePositionsDO positionRequirePositionsDO = new PositionRequirePositionsDO();
positionRequirePositionsDO.setItemInfoId(updateItemInfoDTO.getId());
positionRequirePositionsDO.setPositionId(id);
positionRequirePositionsMapper.insert(positionRequirePositionsDO);
}
}
oldIds.removeAll(newIds2);//删掉以前的
if (oldIds.size() > 0) {
for (Long id : oldIds) {
positionRequirePositionsMapper.delete(new QueryWrapper<PositionRequirePositionsDO>()
.lambda()
.eq(PositionRequirePositionsDO::getItemInfoId, updateItemInfoDTO.getId())
.eq(PositionRequirePositionsDO::getPositionId, id));
}
}
}
return ConstantUtils.SUCCESS_UPDATE;
}
public String deleteItemInfo(PositionItemJobMappingDO positionItemJobMappingDO) {
PositionItemInfoDO positionItemInfoDO = this.baseMapper.selectById(positionItemJobMappingDO.getId());
this.baseMapper.deleteById(positionItemJobMappingDO.getId());
return ConstantUtils.DELETE_SUCCESS;
}
public String addItemInfo(UpdateItemInfoDTO updateItemInfoDTO) {
PositionItemInfoDO positionItemInfoDO = new PositionItemInfoDO();
BeanUtils.copyProperties(updateItemInfoDTO,positionItemInfoDO);
BeanUtils.copyProperties(updateItemInfoDTO, positionItemInfoDO);
this.baseMapper.insert(positionItemInfoDO);
List<Long> jobIds = new ArrayList<Long>();
jobIds.stream().forEach(x->{
List<Long> jobIds = updateItemInfoDTO.getJobIds();
jobIds.stream().forEach(x -> {
PositionItemJobMappingDO positionItemJobMappingDO = new PositionItemJobMappingDO();
positionItemJobMappingDO.setItemInfoId(positionItemInfoDO.getId());
positionItemJobMappingDO.setJobSortId(x);
positionItemJobMappingMapper.insert(positionItemJobMappingDO);
});
List<Long> positionsIds = updateItemInfoDTO.getPositionIds();
positionsIds.stream().forEach(x -> {
PositionRequirePositionsDO positionRequirePositionsDO = new PositionRequirePositionsDO();
positionRequirePositionsDO.setItemInfoId(positionItemInfoDO.getId());
positionRequirePositionsDO.setPositionId(x);
positionRequirePositionsMapper.insert(positionRequirePositionsDO);
});
return ConstantUtils.ADD_SUCCESS;
}
......
......@@ -44,6 +44,9 @@ public class PositionRequireItemServiceImpl extends ServiceImpl<PositionRequireI
@Autowired
private CompanyDictMapper companyDictMapper;
@Autowired
private PositionRequirePositionsMapper positionRequirePositionsMapper;
public IPage<RequirementsVO> requirements(RequirementsDTO requirementsDTO) {
Page pager = new Page(requirementsDTO.getPageNum(), requirementsDTO.getPageSize());
......@@ -52,14 +55,17 @@ public class PositionRequireItemServiceImpl extends ServiceImpl<PositionRequireI
for (RequirementsVO rv : records) {
//预招人数
List<PositionCountsVO> positionItemInfoDOS = positionItemInfoMapper.positionCounts(rv.getId());
for (PositionCountsVO positionCountsVO : positionItemInfoDOS){
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(positionCountsVO.getId());
positionCountsVO.setLibJobSortDOS(libJobSortDOS);
}
rv.setPositionItemInfoDOS(positionItemInfoDOS);
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(rv.getId());
rv.setLibJobSortDOS(libJobSortDOS);
}
return iPage;
}
@Transactional(rollbackFor = Exception.class)
public String deleteRequirements(AddRequirementsDTO addRequirementsDTO) {
List<PositionItemInfoDO> itemInfoDOS = positionItemInfoMapper.selectList(new QueryWrapper<PositionItemInfoDO>()
......@@ -76,8 +82,13 @@ public class PositionRequireItemServiceImpl extends ServiceImpl<PositionRequireI
});
positionItemInfoMapper.deleteById(piid.getId());
}
this.baseMapper.deleteById(addRequirementsDTO.getId());
workstationRequireMappingMapper.delete(new QueryWrapper<WorkstationRequireMappingDO>()
.lambda()
.eq(WorkstationRequireMappingDO::getRequireId,addRequirementsDTO.getId()));
PositionRequireHistoryDO positionRequireHistoryDO = new PositionRequireHistoryDO();
positionRequireHistoryDO.setRequireId(addRequirementsDTO.getId());
positionRequireHistoryDO.setAdministerId(addRequirementsDTO.getUserId());
......@@ -167,9 +178,15 @@ public class PositionRequireItemServiceImpl extends ServiceImpl<PositionRequireI
List<PositionCountsVO> positionItemInfoDOS = positionItemInfoMapper.positionCounts(positionRequireItemDO.getId());
oneRequirementVO.setPositionItemInfoDOS(positionItemInfoDOS);
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(positionRequireItemDO.getId());
oneRequirementVO.setLibJobSortDOS(libJobSortDOS);
for (PositionCountsVO positionCountsVO : positionItemInfoDOS){
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(positionCountsVO.getId());
positionCountsVO.setLibJobSortDOS(libJobSortDOS);
//职业范围
List<PositionDictDO> positionDictDOS = positionRequirePositionsMapper.positionDicts(positionCountsVO.getId());
positionCountsVO.setPositionDictDOS(positionDictDOS);
}
//关联业务
List<RequireWorkstationsVO> requireWorkstationsVOS = workstationRequireMappingMapper.requireWorkstations(positionRequireItemDO.getId());
......
package com.laowu.service.impl;
import com.laowu.model.PositionRequirePositionsDO;
import com.laowu.mapper.PositionRequirePositionsMapper;
import com.laowu.service.PositionRequirePositionsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
/**
* <p>
* 职位需求职位范围 服务实现类
* </p>
*
* @author Tuyp
* @since 2023-04-12
*/
@Service
public class PositionRequirePositionsServiceImpl extends ServiceImpl<PositionRequirePositionsMapper, PositionRequirePositionsDO> implements PositionRequirePositionsService {
}
......@@ -45,9 +45,12 @@ public class TeamDictServiceImpl extends ServiceImpl<TeamDictMapper, TeamDictDO>
@Autowired
private RoleAdministerMappingMapper roleAdministerMappingMapper;
@Autowired
private WorkstationAdministersMapper workstationAdministersMapper;
public IPage<TeamsVO> teams(TeamsDTO teamsDTO) {
Page pager = new Page(teamsDTO.getPageNum(), teamsDTO.getPageSize());
return this.baseMapper.teams(pager, teamsDTO.getStationId(), teamsDTO.getTeamName());
return this.baseMapper.teams(pager, teamsDTO.getStationId(), teamsDTO.getTeamName(),teamsDTO.getProvince());
}
public TotalTeamsVO totalTeams(TeamDictDO teamDictDO) {
......@@ -288,7 +291,10 @@ public class TeamDictServiceImpl extends ServiceImpl<TeamDictMapper, TeamDictDO>
Page pager = new Page(memberManagementDTO.getPageNum(), memberManagementDTO.getPageSize());
IPage<MemberManagementVO> memberManagementVOIPage = this.baseMapper.memberManagement(pager, memberManagementDTO.getTeamId(), memberManagementDTO.getStationId(), memberManagementDTO.getProvince(), memberManagementDTO.getJobStatus(), memberManagementDTO.getUserName());
//查看某个人所在的工作站
List<Long> workstationIds = workstationAdministersMapper.administerStations(memberManagementDTO.getUserId());
IPage<MemberManagementVO> memberManagementVOIPage = this.baseMapper.memberManagement(pager, memberManagementDTO.getTeamId(), memberManagementDTO.getStationId(), memberManagementDTO.getProvince(), memberManagementDTO.getJobStatus(), memberManagementDTO.getUserName(),workstationIds);
List<MemberManagementVO> memberManagementVOS = memberManagementVOIPage.getRecords();
......
......@@ -211,6 +211,12 @@ public class WorkstationDictServiceImpl extends ServiceImpl<WorkstationDictMappe
workstationAdministersMapper.insert(workstationAdministersDO);
}
}
RoleAdministerMappingDO roleAdministerMappingDO = new RoleAdministerMappingDO();
roleAdministerMappingDO.setAdministerId(administerDO.getId());
roleAdministerMappingDO.setRoleId(2L);
roleAdministerMappingMapper.insert(roleAdministerMappingDO);
return ConstantUtils.ADD_SUCCESS;
}
......
......@@ -6,14 +6,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.laowu.dto.station.RequiresDTO;
import com.laowu.dto.station.ShareDTO;
import com.laowu.mapper.PositionItemInfoMapper;
import com.laowu.mapper.PositionItemJobMappingMapper;
import com.laowu.mapper.PositionRequireItemMapper;
import com.laowu.mapper.WorkstationRequireMappingMapper;
import com.laowu.model.LibJobSortDO;
import com.laowu.model.PositionItemInfoDO;
import com.laowu.model.PositionRequireItemDO;
import com.laowu.model.WorkstationRequireMappingDO;
import com.laowu.mapper.*;
import com.laowu.model.*;
import com.laowu.service.WorkstationRequireMappingService;
import com.laowu.util.ConstantUtils;
import com.laowu.vo.position.PositionCountsVO;
......@@ -24,7 +18,9 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
/**
* <p>
......@@ -46,18 +42,32 @@ public class WorkstationRequireMappingServiceImpl extends ServiceImpl<Workstatio
@Autowired
private PositionRequireItemMapper positionRequireItemMapper;
@Autowired
private PositionRequirePositionsMapper positionRequirePositionsMapper;
public IPage<RequiresVO> requires(RequiresDTO requiresDTO) {
Page pager = new Page(requiresDTO.getPageNum(), requiresDTO.getPageSize());
IPage<RequiresVO> iPage = this.baseMapper.requires(pager, requiresDTO.getItemName(), requiresDTO.getItemStatus(), requiresDTO.getProvince(), requiresDTO.getCity(), requiresDTO.getCounty(), requiresDTO.getPositionId(), requiresDTO.getStationId());
List<RequiresVO> records = iPage.getRecords();
for (RequiresVO rv : records) {
Set<PositionDictDO> positionDictDOSet = new HashSet<>();
//预招人数
List<PositionCountsVO> positionItemInfoDOS = positionItemInfoMapper.positionCounts(rv.getId());
for (PositionCountsVO rc : positionItemInfoDOS) {
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(rc.getId());
rc.setLibJobSortDOS(libJobSortDOS);
//职业范围
List<PositionDictDO> positionDictDOS = positionRequirePositionsMapper.positionDicts(rc.getId());
for (PositionDictDO rcc : positionDictDOS) {
positionDictDOSet.add(rcc);
}
}
rv.setPositionDictDOSet(positionDictDOSet);
rv.setPositionItemInfoDOS(positionItemInfoDOS);
//职位分类
List<LibJobSortDO> libJobSortDOS = positionItemJobMappingMapper.positionSorts(rv.getId());
rv.setLibJobSortDOS(libJobSortDOS);
}
return iPage;
}
......@@ -69,13 +79,15 @@ public class WorkstationRequireMappingServiceImpl extends ServiceImpl<Workstatio
.eq(WorkstationRequireMappingDO::getRequireId, workstationRequireMappingDO.getRequireId())
.eq(WorkstationRequireMappingDO::getStationId, workstationRequireMappingDO.getStationId()));
positionRequireItemMapper.deleteById(workstationRequireMappingDO.getRequireId());
return ConstantUtils.DELETE_SUCCESS;
}
public String share(ShareDTO shareDTO) {
List<Long> requireIds = shareDTO.getRequireIds();
for (Long requireId : requireIds){
for (Long requireId : requireIds) {
List<Long> oldIds = this.baseMapper.requiresStations(requireId);
List<Long> newIds = shareDTO.getStationIds();
......@@ -86,21 +98,21 @@ public class WorkstationRequireMappingServiceImpl extends ServiceImpl<Workstatio
newIds.removeAll(oldIds); //新增的人在newIds里面
if (newIds.size()>0){
for (Long id : newIds){
if (newIds.size() > 0) {
for (Long id : newIds) {
PositionRequireItemDO positionRequireItemDO = positionRequireItemMapper.selectById(requireId);
PositionRequireItemDO positionRequireItemDO1 = new PositionRequireItemDO();
BeanUtils.copyProperties(positionRequireItemDO,positionRequireItemDO1);
BeanUtils.copyProperties(positionRequireItemDO, positionRequireItemDO1);
positionRequireItemDO1.setOriginId(positionRequireItemDO.getId());
positionRequireItemMapper.insert(positionRequireItemDO1);
List<PositionItemInfoDO> positionItemInfoDOS = positionItemInfoMapper.selectList(new QueryWrapper<PositionItemInfoDO>()
.lambda()
.eq(PositionItemInfoDO::getPositionRequireId,requireId));
for (PositionItemInfoDO positionItemInfoDO : positionItemInfoDOS){
.lambda()
.eq(PositionItemInfoDO::getPositionRequireId, requireId));
for (PositionItemInfoDO positionItemInfoDO : positionItemInfoDOS) {
PositionItemInfoDO positionItemInfoDO1 = new PositionItemInfoDO();
BeanUtils.copyProperties(positionItemInfoDO,positionItemInfoDO1);
BeanUtils.copyProperties(positionItemInfoDO, positionItemInfoDO1);
positionItemInfoDO1.setPositionRequireId(positionRequireItemDO1.getId());
positionItemInfoMapper.insert(positionItemInfoDO1);
}
......@@ -113,12 +125,12 @@ public class WorkstationRequireMappingServiceImpl extends ServiceImpl<Workstatio
}
oldIds.removeAll(newIds2);//删掉以前的
if (oldIds.size()>0){
for (Long id : oldIds){
if (oldIds.size() > 0) {
for (Long id : oldIds) {
this.baseMapper.delete(new QueryWrapper<WorkstationRequireMappingDO>()
.lambda()
.eq(WorkstationRequireMappingDO::getRequireId,requireId)
.eq(WorkstationRequireMappingDO::getStationId,id));
.eq(WorkstationRequireMappingDO::getRequireId, requireId)
.eq(WorkstationRequireMappingDO::getStationId, id));
}
}
}
......
......@@ -11,7 +11,7 @@ public class CompanyVO {
private Long id;
private Long positionId;
private Long businessId;
private String companyName;
......@@ -21,7 +21,7 @@ public class CompanyVO {
private String city;
private String positionType;
private String business;
private String companyCode;
......
package com.laowu.vo.member;
import com.laowu.model.PositionDictDO;
import lombok.Data;
import java.util.List;
@Data
public class AllMembersVO {
......@@ -25,4 +28,6 @@ public class AllMembersVO {
private String address;
private List<PositionDictDO> positionDictDOS;
}
package com.laowu.vo.member;
import com.laowu.model.MemberTrainInfoDO;
import com.laowu.model.PositionDictDO;
import lombok.Data;
import java.util.List;
@Data
public class MemberTrainInfoVO extends MemberTrainInfoDO {
private List<PositionDictDO> positionDictDOS;
}
package com.laowu.vo.member;
import com.laowu.model.MemberCertsDO;
import com.laowu.model.MemberDictDO;
import com.laowu.model.PositionDictDO;
import lombok.Data;
import java.util.List;
......@@ -15,4 +17,11 @@ public class OneMemberVO extends MemberDictDO {
private List<MemberJobInfoVO> memberJobInfoVOS;
private List<MemberCollegeVO> memberCollegeVOS;
private List<PositionDictDO> positionDictDOS;
private List<MemberCertsDO> memberCertsDOS;
private List<MemberTrainInfoVO> memberTrainInfoVOS;
}
......@@ -27,7 +27,7 @@ public class AloneRequirementsVO {
private Long jobSortId;
private Long positionId;
private Long businessId;
private String jobId;
......
package com.laowu.vo.position;
import com.laowu.model.LibJobSortDO;
import com.laowu.model.PositionRequireItemDO;
import lombok.Data;
......@@ -19,5 +18,4 @@ public class OneRequirementVO extends PositionRequireItemDO {
private List<PositionCountsVO> positionItemInfoDOS;
private List<LibJobSortDO> libJobSortDOS;
}
package com.laowu.vo.position;
import com.laowu.model.LibJobSortDO;
import com.laowu.model.PositionDictDO;
import lombok.Data;
import java.util.List;
@Data
public class PositionCountsVO {
private Long id;
private String positionName;
private String positionStatus;
private Integer requireCounts;
......@@ -23,4 +25,8 @@ public class PositionCountsVO {
private String positionType;
private List<LibJobSortDO> libJobSortDOS;
private List<PositionDictDO> positionDictDOS;
}
package com.laowu.vo.position;
import com.laowu.model.LibJobSortDO;
import lombok.Data;
import java.util.List;
......@@ -24,11 +23,17 @@ public class RequirementsVO {
private String itemStatus;
private String startDate;
private String endDate;
private String amount;
private String address;
private String jobId;
private String positionStatus;
private List<PositionCountsVO> positionItemInfoDOS;
private List<LibJobSortDO> libJobSortDOS;
}
package com.laowu.vo.station;
import com.laowu.model.LibJobSortDO;
import com.laowu.model.PositionDictDO;
import com.laowu.vo.position.PositionCountsVO;
import lombok.Data;
import java.util.List;
import java.util.Set;
@Data
public class RequiresVO {
......@@ -25,12 +26,20 @@ public class RequiresVO {
private String itemStatus;
private String startDate;
private String endDate;
private String address;
private String jobId;
private String amount;
private Long stationId;
private List<PositionCountsVO> positionItemInfoDOS;
private List<LibJobSortDO> libJobSortDOS;
private Set<PositionDictDO> positionDictDOSet;
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.BusinessDictMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.BusinessDictDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="delete_date" property="deleteDate" />
<result column="business" property="business" />
<result column="update" property="update" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
delete_date,
id, business, update
</sql>
</mapper>
......@@ -24,9 +24,9 @@
<select id="company" resultType="com.laowu.vo.company.CompanyVO">
SELECT
t.id,
t3.id as position_id,
t3.id as business_id,
t.company_name,
t3.position_type,
t3.business,
t.company_code,
t.company_desc,
t.province,
......@@ -35,7 +35,7 @@
t.company_origin
FROM
company_dict t
LEFT JOIN position_dict t3 ON t.position_id = t3.id
LEFT JOIN business_dict t3 ON t.business_id = t3.id
WHERE
t.delete_date IS NULL
AND t3.delete_date IS NULL
......@@ -87,9 +87,9 @@
<select id="stationCompany" resultType="com.laowu.vo.company.CompanyVO">
SELECT
t2.id,
t2.position_id,
t2.business_id,
t2.company_name,
t3.position_type,
t3.business,
t2.company_code,
t2.company_desc,
t2.province,
......@@ -98,7 +98,7 @@
FROM
company_relate_work t
LEFT JOIN company_dict t2 ON t.company_id = t2.id
LEFT JOIN position_dict t3 ON t2.position_id = t3.id
LEFT JOIN business_dict t3 ON t2.business_id = t3.id
WHERE
t.delete_date IS NULL
AND t2.delete_date IS NULL
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.MemberCertsMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.MemberCertsDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="delete_date" property="deleteDate" />
<result column="member_id" property="memberId" />
<result column="cert" property="cert" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
update_date,
delete_date,
id, member_id, cert
</sql>
</mapper>
......@@ -69,6 +69,7 @@
<if test="userName != null and userName != ''">
AND t.user_name like concat('%', #{userName}, '%')
</if>
order by t.create_date
</select>
<select id="members" parameterType="long" resultType="long">
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.MemberPositionsMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.MemberPositionsDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="delete_date" property="deleteDate" />
<result column="member_id" property="memberId" />
<result column="position_id" property="positionId" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
update_date,
delete_date,
id, member_id, position_id
</sql>
<select id="memberPositionIds" parameterType="long" resultType="long">
SELECT
t.position_id
FROM
member_positions t
WHERE
t.delete_date IS NULL
AND t.member_id = #{memberId}
</select>
<select id="memberPositions" parameterType="long" resultType="com.laowu.model.PositionDictDO">
SELECT
t2.*
FROM
member_positions t
left join position_dict t2 on t.position_id = t2.id
WHERE
t.delete_date IS NULL
and t2.delete_date is null
AND t.member_id = #{memberId}
</select>
</mapper>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.MemberTrainInfoMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.MemberTrainInfoDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="delete_date" property="deleteDate" />
<result column="member_id" property="memberId" />
<result column="train_from" property="trainFrom" />
<result column="train_type" property="trainType" />
<result column="train_name" property="trainName" />
<result column="start_date" property="startDate" />
<result column="end_date" property="endDate" />
<result column="train_area" property="trainArea" />
<result column="train_range" property="trainRange" />
<result column="train_content" property="trainContent" />
<result column="train_result" property="trainResult" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
update_date,
delete_date,
id, member_id, train_from, train_type, train_name, start_date, end_date, train_area, train_range, train_content, train_result
</sql>
</mapper>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.MemberTrainPositionsMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.MemberTrainPositionsDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="delete_date" property="deleteDate" />
<result column="member_train_id" property="memberTrainId" />
<result column="position_id" property="positionId" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
update_date,
delete_date,
id, member_train_id, position_id
</sql>
<select id="positionIds" parameterType="long" resultType="long">
SELECT
t.position_id
FROM
member_train_positions t
WHERE
t.delete_date IS NULL
AND t.member_train_id = #{memberTrainId}
</select>
<select id="positions" parameterType="long" resultType="com.laowu.model.PositionDictDO">
SELECT
t2.*
FROM
member_train_positions t
left join position_dict t2 on t.position_id = t2.id
WHERE
t.delete_date IS NULL
and t2.delete_date is null
AND t.member_train_id = #{memberTrainId}
</select>
</mapper>
......@@ -7,8 +7,6 @@
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="position_name" property="positionName" />
<result column="position_id" property="positionId" />
<result column="start_salary" property="startSalary" />
<result column="end_salary" property="endSalary" />
</resultMap>
......@@ -16,7 +14,6 @@
<select id="positionCounts" parameterType="long" resultType="com.laowu.vo.position.PositionCountsVO">
SELECT
t.id,
t.position_name,
t.position_status,
t.require_counts,
t.address,
......
......@@ -24,17 +24,15 @@
SELECT DISTINCT
t3.*
FROM
position_require_item t
LEFT JOIN position_item_info t1 ON t.id = t1.position_require_id
position_item_info t1
LEFT JOIN position_item_job_mapping t2 ON t2.item_info_id = t1.id
LEFT JOIN lib_job_sort t3 ON t2.job_sort_id = t3.id
WHERE
t.delete_date IS NULL
AND t1.delete_date IS NULL
t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t3.id IS NOT NULL
and t.id = #{requireId}
and t1.id = #{itemInfoId}
</select>
<select id="positionSortIds" parameterType="long" resultType="long">
......
......@@ -32,7 +32,11 @@
t.county,
t.item_name,
t.job_id,
t3.position_status
t3.position_status,
t.start_date,
t.end_date,
t.amount,
t.address
FROM
position_require_item t
LEFT JOIN company_dict t2 ON t.company_id = t2.id
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.laowu.mapper.PositionRequirePositionsMapper">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.laowu.model.PositionRequirePositionsDO">
<id column="id" property="id" />
<result column="create_date" property="createDate" />
<result column="update_date" property="updateDate" />
<result column="delete_date" property="deleteDate" />
<result column="require_id" property="requireId" />
<result column="position_id" property="positionId" />
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
create_date,
update_date,
delete_date,
id, require_id, position_id
</sql>
<select id="positionIds" parameterType="long" resultType="long">
SELECT
t.position_id
FROM
position_require_positions t
WHERE
t.delete_date IS NULL
AND t.item_info_id = #{itemInfoId}
</select>
<select id="positionDicts" parameterType="long" resultType="com.laowu.model.PositionDictDO">
SELECT
t2.*
FROM
position_require_positions t
left join position_dict t2 on t.position_id = t2.id
WHERE
t.delete_date IS NULL
AND t.item_info_id = #{itemInfoId}
</select>
</mapper>
......@@ -32,12 +32,18 @@
team_dict t1
LEFT JOIN member_team_mapping t5 ON t1.id = t5.team_id and t5.delete_date is null
LEFT JOIN member_dict t2 ON t2.id = t5.member_id
left join workstation_dict t3 on t1.station_id = t3.id
WHERE
t1.delete_date IS NULL
and t1.station_id = #{stationId}
<if test="stationId != null and stationId != ''">
and t1.station_id = #{stationId}
</if>
<if test="teamName != null and teamName != ''">
and t1.team_name like concat('%', #{teamName}, '%')
</if>
<if test=" province != null and province != ''">
and t3.province = #{province}
</if>
GROUP BY
t1.id
) t3
......@@ -130,28 +136,39 @@
t1.is_migration,
t1.is_party
FROM
member_dict t1
LEFT JOIN member_team_mapping t2 ON t1.id = t2.member_id AND t2.delete_date IS NULL
LEFT JOIN team_dict t3 ON t2.team_id = t3.id AND t3.delete_date IS NULL
LEFT JOIN workstation_dict t4 ON t3.station_id = t4.id AND t4.delete_date IS NULL
member_dict t1
LEFT JOIN member_team_mapping t2 ON t1.id = t2.member_id
LEFT JOIN team_dict t3 ON t2.team_id = t3.id
LEFT JOIN workstation_member_mapping t5 ON t1.id = t5.member_id
LEFT JOIN workstation_dict t4 ON t5.station_id = t4.id
WHERE
t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t4.delete_date IS NULL
and t5.delete_date is null
<if test="jobStatus != null and jobStatus != ''">
AND t1.job_status = #{jobStatus}
</if>
<if test="teamId != null and teamId != ''">
AND t3.id = #{teamId}
</if>
<if test="province != null and province != ''">
AND t1.province = #{province}
AND t4.province = #{province}
</if>
<if test="stationId != null and stationId != ''">
<if test="stationId != null and stationId != '' and teamId == null and teamId == ''">
AND t4.id = #{stationId}
</if>
<if test="stationId != null and stationId != '' and teamId != null and teamId != ''">
AND t3.id = #{teamId}
</if>
<if test="userName != null and userName != ''">
and t1.user_name LIKE concat('%', #{userName}, '%')
</if>
<if test="workstationIds.size >0">
and t4.id in
<foreach collection="workstationIds" item="id" index="index" open="(" close=")" separator=",">
#{id}
</foreach>
</if>
order by t1.create_date
</select>
<select id="memberManagementCount" resultType="integer">
......
......@@ -99,17 +99,36 @@
workstation_dict t1
LEFT JOIN (
SELECT
t1.id,
count( DISTINCT t3.member_id ) AS ct1
t9.id,
sum( ct8 + ct9 ) AS ct1
FROM
workstation_dict t1
LEFT JOIN team_dict t2 ON t1.id = t2.station_id
LEFT JOIN member_team_mapping t3 ON t2.id = t3.team_id
WHERE
t1.id = #{stationId}
AND t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
(
SELECT
t1.id,
count( DISTINCT t3.member_id ) AS ct8
FROM
workstation_dict t1
LEFT JOIN team_dict t2 ON t1.id = t2.station_id
LEFT JOIN member_team_mapping t3 ON t2.id = t3.team_id
WHERE
t1.id = #{stationId}
AND t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
) t9
LEFT JOIN (
SELECT
t1.id,
count( DISTINCT t2.id ) AS ct9
FROM
workstation_dict t1
LEFT JOIN workstation_member_mapping t2 ON t1.id = t2.station_id
LEFT JOIN member_dict t3 ON t2.member_id = t3.id
WHERE
t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t1.id = #{stationId}
) t10 ON t9.id = t10.id
) t4 ON t1.id = t4.id
LEFT JOIN (
SELECT
......@@ -126,7 +145,7 @@
LEFT JOIN (
SELECT
t1.id,
count(*) AS ct3
count( DISTINCT t2.id ) AS ct3
FROM
workstation_dict t1
LEFT JOIN team_dict t2 ON t1.id = t2.station_id
......@@ -139,64 +158,40 @@
) t6 ON t1.id = t6.id
LEFT JOIN (
SELECT
t5.id,
count(*) AS ct4
t1.id,
count( t2.id ) AS ct4
FROM
(
SELECT
t1.id,
t4.company_name
FROM
workstation_dict t1
LEFT JOIN workstation_alone_mapping t2 ON t1.id = t2.station_id
LEFT JOIN position_alone_info t3 ON t2.alone_id = t3.id
LEFT JOIN company_dict t4 ON t3.company_id = t4.id
WHERE
t1.id = #{stationId}
AND t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t4.delete_date IS NULL
and t4.id is not null
UNION
SELECT
t1.id,
t4.company_name
FROM
workstation_dict t1
LEFT JOIN workstation_require_mapping t2 ON t1.id = t2.station_id
LEFT JOIN position_require_item t3 ON t2.require_id = t3.id
LEFT JOIN company_dict t4 ON t3.company_id = t4.id
WHERE
t1.id = #{stationId}
AND t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t4.delete_date IS NULL
and t4.id is not null
) t5
workstation_dict t1
LEFT JOIN company_relate_work t2 ON t1.id = t2.station_id
WHERE
t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t1.id = #{stationId}
) t7 ON t1.id = t7.id
LEFT JOIN (
SELECT
t5.id,
sum( t5.require_counts ) AS ct5
t3.id,
sum( t3.ct15 + t4.ct16 ) AS ct5
FROM
(
SELECT
t1.id,
t3.require_counts
sum( t3.require_counts ) AS ct15
FROM
workstation_dict t1
LEFT JOIN workstation_alone_mapping t2 ON t1.id = t2.station_id
LEFT JOIN position_alone_info t3 ON t2.alone_id = t3.id
WHERE
t1.id = #{stationId}
AND t1.delete_date IS NULL
t1.delete_date IS NULL
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL UNION
AND t3.delete_date IS NULL
AND origin_id IS NOT NULL
AND t1.id = #{stationId}
) t3
LEFT JOIN (
SELECT
t1.id,
sum(t4.require_counts) as require_counts
sum( t4.require_counts ) AS ct16
FROM
workstation_dict t1
LEFT JOIN workstation_require_mapping t2 ON t1.id = t2.station_id
......@@ -208,8 +203,9 @@
AND t2.delete_date IS NULL
AND t3.delete_date IS NULL
AND t4.delete_date IS NULL
group by t1.id
) t5
GROUP BY
t1.id
) t4 ON t3.id = t4.id
) t8 ON t1.id = t8.id
WHERE
t1.id = #{stationId}
......
......@@ -30,8 +30,12 @@
t.city,
t.county,
t.item_name,
t.start_date,
t.end_date,
t.job_id,
t4.station_id
t4.station_id,
t.address,
t.amount
FROM
position_require_item t
LEFT JOIN company_dict t2 ON t.company_id = t2.id
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!