
267 changed files with 17077 additions and 67 deletions
@ -0,0 +1,122 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8"?> |
||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0" |
||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
||||
|
<parent> |
||||
|
<artifactId>wh</artifactId> |
||||
|
<groupId>com.wh</groupId> |
||||
|
<version>1.0-SNAPSHOT</version> |
||||
|
</parent> |
||||
|
<modelVersion>4.0.0</modelVersion> |
||||
|
|
||||
|
<artifactId>wh-manage-xxs</artifactId> |
||||
|
|
||||
|
<!-- 依赖工具API--> |
||||
|
<dependencies> |
||||
|
<!-- <dependency>--> |
||||
|
<!-- <groupId>com.wh</groupId>--> |
||||
|
<!-- <artifactId>wh-common</artifactId>--> |
||||
|
<!-- <version>1.0</version>--> |
||||
|
<!-- </dependency>--> |
||||
|
<dependency> |
||||
|
<groupId>org.jetbrains</groupId> |
||||
|
<artifactId>annotations</artifactId> |
||||
|
<version>21.0.1</version> |
||||
|
<scope>compile</scope> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>com.yxt</groupId> |
||||
|
<artifactId>yxt-common-base</artifactId> |
||||
|
<version>0.0.1</version> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>org.springframework.boot</groupId> |
||||
|
<artifactId>spring-boot-starter-cache</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>org.springframework.cloud</groupId> |
||||
|
<artifactId>spring-cloud-starter-openfeign</artifactId> |
||||
|
</dependency> |
||||
|
<!-- <dependency>--> |
||||
|
<!-- <groupId>com.yxt.supervise.dispatchcenter</groupId>--> |
||||
|
<!-- <artifactId>supervise-dispatchcenter-api</artifactId>--> |
||||
|
<!-- <version>0.0.1</version>--> |
||||
|
<!-- </dependency>--> |
||||
|
<dependency> |
||||
|
<groupId>com.yxt</groupId> |
||||
|
<artifactId>yxt-common-base</artifactId> |
||||
|
<version>0.0.1</version> |
||||
|
</dependency> |
||||
|
<!-- <dependency>--> |
||||
|
<!-- <groupId>com.alibaba.cloud</groupId>--> |
||||
|
<!-- <artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>--> |
||||
|
<!-- </dependency>--> |
||||
|
|
||||
|
<dependency> |
||||
|
<groupId>org.projectlombok</groupId> |
||||
|
<artifactId>lombok</artifactId> |
||||
|
<version>1.18.24</version> |
||||
|
<optional>true</optional> |
||||
|
</dependency> |
||||
|
|
||||
|
<dependency> |
||||
|
<groupId>mysql</groupId> |
||||
|
<artifactId>mysql-connector-java</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>org.apache.poi</groupId> |
||||
|
<artifactId>poi-ooxml</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>io.jsonwebtoken</groupId> |
||||
|
<artifactId>jjwt</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>cn.hutool</groupId> |
||||
|
<artifactId>hutool-extra</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>cn.hutool</groupId> |
||||
|
<artifactId>hutool-http</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>cn.hutool</groupId> |
||||
|
<artifactId>hutool-crypto</artifactId> |
||||
|
</dependency> |
||||
|
<dependency> |
||||
|
<groupId>cn.hutool</groupId> |
||||
|
<artifactId>hutool-cache</artifactId> |
||||
|
</dependency> |
||||
|
|
||||
|
<dependency> |
||||
|
<groupId>com.github.xiaoymin</groupId> |
||||
|
<artifactId>knife4j-spring-boot-starter</artifactId> |
||||
|
</dependency> |
||||
|
|
||||
|
<dependency> |
||||
|
<groupId>org.springframework.boot</groupId> |
||||
|
<artifactId>spring-boot-starter-test</artifactId> |
||||
|
<scope>test</scope> |
||||
|
</dependency> |
||||
|
</dependencies> |
||||
|
<!--添加build标签--> |
||||
|
<build> |
||||
|
<!--打包成jar包时的名字--> |
||||
|
<finalName>wm-manager</finalName> |
||||
|
<plugins> |
||||
|
<plugin> |
||||
|
<groupId>org.springframework.boot</groupId> |
||||
|
<artifactId>spring-boot-maven-plugin</artifactId> |
||||
|
<version>2.5.6</version> |
||||
|
<executions> |
||||
|
<execution> |
||||
|
<goals> |
||||
|
<goal>repackage</goal> |
||||
|
</goals> |
||||
|
</execution> |
||||
|
</executions> |
||||
|
</plugin> |
||||
|
</plugins> |
||||
|
</build> |
||||
|
|
||||
|
</project> |
@ -0,0 +1,42 @@ |
|||||
|
package com.wh; |
||||
|
|
||||
|
import org.mybatis.spring.annotation.MapperScan; |
||||
|
import org.springframework.boot.SpringApplication; |
||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.web.cors.CorsConfiguration; |
||||
|
import org.springframework.web.cors.UrlBasedCorsConfigurationSource; |
||||
|
import org.springframework.web.filter.CorsFilter; |
||||
|
|
||||
|
//@EnableDiscoveryClient
|
||||
|
//@EnableFeignClients(basePackages = {"com.wh.*"})
|
||||
|
@MapperScan("com.wh.mapper") |
||||
|
@SpringBootApplication(scanBasePackages = { |
||||
|
"com.yxt.common.base.config", |
||||
|
"com.wh.*" |
||||
|
}) |
||||
|
public class WarehouseApplicationNoNacos { |
||||
|
|
||||
|
private CorsConfiguration buildConfig() { |
||||
|
CorsConfiguration corsConfiguration = new CorsConfiguration(); |
||||
|
corsConfiguration.addAllowedOrigin("*"); |
||||
|
corsConfiguration.addAllowedHeader("*"); |
||||
|
corsConfiguration.addAllowedMethod("*"); |
||||
|
corsConfiguration.setAllowCredentials(true);//这两句不加不能跨域上传文件,
|
||||
|
corsConfiguration.setMaxAge(3600l);//加上去就可以了
|
||||
|
return corsConfiguration; |
||||
|
} |
||||
|
/** |
||||
|
* 跨域过滤器 |
||||
|
* @return |
||||
|
*/ |
||||
|
@Bean |
||||
|
public CorsFilter corsFilter() { |
||||
|
UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource(); |
||||
|
source.registerCorsConfiguration("/**", buildConfig()); // 4
|
||||
|
return new CorsFilter(source); |
||||
|
} |
||||
|
public static void main(String[] args) { |
||||
|
SpringApplication.run(WarehouseApplicationNoNacos.class,args); |
||||
|
} |
||||
|
} |
@ -0,0 +1,15 @@ |
|||||
|
package com.wh.aop; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import org.springframework.web.bind.annotation.ExceptionHandler; |
||||
|
import org.springframework.web.bind.annotation.RestControllerAdvice; |
||||
|
|
||||
|
@RestControllerAdvice |
||||
|
public class AOPException { |
||||
|
|
||||
|
@ExceptionHandler({RuntimeException.class}) |
||||
|
public Object Exception(){ |
||||
|
return SysResult.fail(); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.wh.api; |
||||
|
|
||||
|
import java.text.SimpleDateFormat; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
public class Api { |
||||
|
|
||||
|
public String getTime(){ |
||||
|
Date dNow = new Date( ); |
||||
|
SimpleDateFormat ft = new SimpleDateFormat ("yyyy-MM-dd HH:mm:ss"); |
||||
|
return ft.format(dNow); |
||||
|
} |
||||
|
} |
@ -0,0 +1,29 @@ |
|||||
|
package com.wh.config; |
||||
|
|
||||
|
import org.springframework.boot.web.servlet.MultipartConfigFactory; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.util.unit.DataSize; |
||||
|
|
||||
|
import javax.servlet.MultipartConfigElement; |
||||
|
|
||||
|
/** |
||||
|
* 文件上传配置类 |
||||
|
* |
||||
|
* @Author mashanghaoyun |
||||
|
* @Date 2020/11/11 01:34 |
||||
|
* @Version 1.0 |
||||
|
**/ |
||||
|
@Configuration |
||||
|
public class FileUploadConfig { |
||||
|
@Bean |
||||
|
public MultipartConfigElement multipartConfigElement() { |
||||
|
MultipartConfigFactory factory = new MultipartConfigFactory(); |
||||
|
// 单个数据大小
|
||||
|
factory.setMaxFileSize(DataSize.parse("502400KB")); // KB,MB
|
||||
|
// 总上传数据大小
|
||||
|
factory.setMaxRequestSize(DataSize.parse("1024000KB")); |
||||
|
return factory.createMultipartConfig(); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,16 @@ |
|||||
|
package com.wh.config; |
||||
|
import com.wh.controller.UserInterceptor; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.web.servlet.config.annotation.InterceptorRegistry; |
||||
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; |
||||
|
@Configuration |
||||
|
public class MyInterceptor implements WebMvcConfigurer { |
||||
|
// @Autowired
|
||||
|
// private UserInterceptor userInterceptor;
|
||||
|
|
||||
|
@Override |
||||
|
public void addInterceptors(InterceptorRegistry registry) { |
||||
|
// registry.addInterceptor(userInterceptor);
|
||||
|
} |
||||
|
} |
@ -0,0 +1,67 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.config; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor; |
||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.optimize.JsqlParserCountOptimize; |
||||
|
import org.springframework.context.annotation.Bean; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt-common <br/> |
||||
|
* File: MybatisPlusConfig.java <br/> |
||||
|
* Class: com.yxt.common.base.config.MybatisPlusConfig <br/> |
||||
|
* Description: <描述类的功能>. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2020/8/24 下午12:42 <br/> |
||||
|
* |
||||
|
* @author popo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
//@Configuration
|
||||
|
public class MybatisPlusConfig { |
||||
|
/* |
||||
|
* 分页插件,自动识别数据库类型 多租户,请参考官网【插件扩展】 |
||||
|
*/ |
||||
|
// @Bean
|
||||
|
// public MybatisPlusInterceptor paginationInterceptor() {
|
||||
|
// return new MybatisPlusInterceptor();
|
||||
|
// }
|
||||
|
|
||||
|
@Bean |
||||
|
public PaginationInterceptor paginationInterceptor() { |
||||
|
PaginationInterceptor paginationInterceptor = new PaginationInterceptor(); |
||||
|
// 设置请求的页面大于最大页后操作, true调回到首页,false 继续请求 默认false
|
||||
|
// paginationInterceptor.setOverflow(false);
|
||||
|
// 设置最大单页限制数量,默认 500 条,-1 不受限制
|
||||
|
// paginationInterceptor.setLimit(500);
|
||||
|
// 开启 count 的 join 优化,只针对部分 left join
|
||||
|
paginationInterceptor.setCountSqlParser(new JsqlParserCountOptimize(true)); |
||||
|
return paginationInterceptor; |
||||
|
} |
||||
|
} |
@ -0,0 +1,36 @@ |
|||||
|
package com.wh.config; |
||||
|
|
||||
|
import org.springframework.beans.factory.annotation.Value; |
||||
|
import org.springframework.context.annotation.Configuration; |
||||
|
import org.springframework.web.servlet.config.annotation.CorsRegistry; |
||||
|
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry; |
||||
|
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; |
||||
|
|
||||
|
@Configuration |
||||
|
public class WebMvcConfig implements WebMvcConfigurer { |
||||
|
@Value("${yuan.file.root.path}") |
||||
|
public String fileRootPath; |
||||
|
|
||||
|
/** |
||||
|
* 资源映射:把请求的/archive/** 映射到该文件根路径 |
||||
|
*/ |
||||
|
@Override |
||||
|
public void addResourceHandlers(ResourceHandlerRegistry registry) { |
||||
|
registry.addResourceHandler("/archive/**").addResourceLocations("file:" + fileRootPath); |
||||
|
} |
||||
|
@Override |
||||
|
public void addCorsMappings(CorsRegistry registry){ |
||||
|
//设置允许跨域的路径
|
||||
|
registry.addMapping ("/**") |
||||
|
//设置允许跨域请求的域名
|
||||
|
.allowedOrigins("*") |
||||
|
//是否允许证书
|
||||
|
.allowCredentials (true) |
||||
|
//设置允许的方法
|
||||
|
.allowedMethods ("GET","POST") |
||||
|
//设置允许的header属性
|
||||
|
.allowedHeaders ("*") |
||||
|
//允许跨域时间
|
||||
|
.maxAge (3600); |
||||
|
} |
||||
|
} |
@ -0,0 +1,35 @@ |
|||||
|
package com.wh.controller; |
||||
|
|
||||
|
import com.wh.pojo.Rights; |
||||
|
import com.wh.service.RightsService; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.CrossOrigin; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@RestController("com.wh.controller.RightsController") |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/rights") |
||||
|
public class RightsController { |
||||
|
|
||||
|
@Autowired |
||||
|
private RightsService rightsService; |
||||
|
|
||||
|
/** |
||||
|
* URL: /rights/getRightsList |
||||
|
* 参数: null |
||||
|
* 类型: get |
||||
|
* 返回值: SysResult对象 List |
||||
|
* 业务: 只查询前 2级权限 |
||||
|
*/ |
||||
|
@GetMapping("/getRightsList") |
||||
|
public SysResult getRightsList(){ |
||||
|
List<Rights> rightsList = |
||||
|
rightsService.findRightsList(); |
||||
|
return SysResult.success(rightsList); |
||||
|
} |
||||
|
} |
@ -0,0 +1,36 @@ |
|||||
|
package com.wh.controller; |
||||
|
|
||||
|
import com.wh.pojo.User; |
||||
|
import com.wh.service.UserService; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.util.StringUtils; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import javax.servlet.http.HttpSession; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/user/") |
||||
|
public class UserController { |
||||
|
|
||||
|
@Autowired |
||||
|
private UserService userService; |
||||
|
@Autowired |
||||
|
private HttpSession session; |
||||
|
@PostMapping("login") |
||||
|
public SysResult login(@RequestBody User user){ |
||||
|
String fixationToken = (String)session.getAttribute("token"); |
||||
|
if (StringUtils.hasLength(fixationToken)){ |
||||
|
return SysResult.success(fixationToken); |
||||
|
}else { |
||||
|
String token = userService.findUserByUP(user); |
||||
|
if (StringUtils.hasLength(token)){ |
||||
|
session.setAttribute("token",token); |
||||
|
return SysResult.success(token); |
||||
|
}else { |
||||
|
return SysResult.fail(); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
} |
@ -0,0 +1,33 @@ |
|||||
|
package com.wh.controller; |
||||
|
|
||||
|
import org.springframework.stereotype.Component; |
||||
|
import org.springframework.web.servlet.HandlerInterceptor; |
||||
|
import org.springframework.web.servlet.ModelAndView; |
||||
|
|
||||
|
import javax.servlet.http.HttpServletRequest; |
||||
|
import javax.servlet.http.HttpServletResponse; |
||||
|
|
||||
|
@Component |
||||
|
public class UserInterceptor implements HandlerInterceptor { |
||||
|
long start; |
||||
|
long end ; |
||||
|
@Override |
||||
|
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception { |
||||
|
System.out.println("拦截器拦截成功"); |
||||
|
start = System.currentTimeMillis(); |
||||
|
return true; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler, ModelAndView modelAndView) throws Exception { |
||||
|
end = System.currentTimeMillis(); |
||||
|
System.out.println("拦截结束"); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public void afterCompletion(HttpServletRequest request, HttpServletResponse response, Object handler, Exception ex) throws Exception { |
||||
|
System.out.println("释放资源"+(end-start)+"ms"); |
||||
|
|
||||
|
} |
||||
|
} |
@ -0,0 +1,76 @@ |
|||||
|
package com.wh.controller.api.input; |
||||
|
|
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.api.*; |
||||
|
import com.wh.pojo.purchasenew.PurchasenewQuery; |
||||
|
import com.wh.pojo.purchasenew.PurchasenewVo; |
||||
|
import com.wh.service.api.instorehouse.InStorehouseMainService; |
||||
|
import com.wh.service.purchasenew.PurchasenewService; |
||||
|
import com.wh.service.purchasenewproduct.PurchasenewProductService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import javax.annotation.Resource; |
||||
|
import java.util.Map; |
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/input/") |
||||
|
public class InStoreHouseMainController { |
||||
|
|
||||
|
@Autowired |
||||
|
private InStorehouseMainService inStorehouseMainService; |
||||
|
@Autowired |
||||
|
private PurchasenewService purchasenewService; |
||||
|
@Autowired |
||||
|
private PurchasenewProductService purchasenewProductService; |
||||
|
// @ApiOperation("根据条件分页查询数据的列表")
|
||||
|
// @PostMapping("/listPage")
|
||||
|
// public ResultBean<PagerVo<PurchasenewVo>> listPage(@RequestBody PagerQuery<PurchasenewQuery> pq){
|
||||
|
// pq.getParams().setState("2");
|
||||
|
// ResultBean rb = ResultBean.fireFail();
|
||||
|
// PagerVo<PurchasenewVo> pv = purchasenewService.listPageVo(pq);
|
||||
|
// return rb.success().setData(pv);
|
||||
|
// }
|
||||
|
@PostMapping("addInStorehouse") |
||||
|
public ResultBean addInStorehouse(@RequestBody InStoreHouseMainDto inStoreHouseMainDto){ |
||||
|
log.info("/input/addInStorehouse:{}", JSONObject.toJSONString(inStoreHouseMainDto)); |
||||
|
ResultBean resultBean = inStorehouseMainService.addInStorehouse(inStoreHouseMainDto); |
||||
|
return resultBean; |
||||
|
} |
||||
|
@PostMapping("addInStorehouseByPurchase") |
||||
|
public ResultBean addInStorehouseByPurchase(@RequestBody PurchaseInStoreHouseParams purchaseInStoreHouseParams){ |
||||
|
log.info("/input/addInStorehouseByPurchase:{}", JSONObject.toJSONString(purchaseInStoreHouseParams)); |
||||
|
return inStorehouseMainService.addInStorehouseByPurchase(purchaseInStoreHouseParams); |
||||
|
} |
||||
|
@PostMapping("listPage") |
||||
|
public ResultBean listPage(@RequestBody PagerQuery<InStorehouseMainQuery> pq){ |
||||
|
PagerVo<InStoreHouseMainVo> pv = inStorehouseMainService.listPage(pq); |
||||
|
ResultBean<PagerVo<InStoreHouseMainVo>> r = ResultBean.fireSuccess(); |
||||
|
return r.setData(pv); |
||||
|
} |
||||
|
@GetMapping("getInStorehouse/{sid}") |
||||
|
public ResultBean getInStorehouse(@PathVariable(value = "sid") String sid){ |
||||
|
return inStorehouseMainService.getInStorehouse(sid); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* 获取所有未入库的采购订单编号和仓库信息 |
||||
|
* @return |
||||
|
*/ |
||||
|
@GetMapping("getQuery") |
||||
|
public SysResult getQuery(@RequestBody InStorehouseMainQuery query){ |
||||
|
Map<String,Object> map = inStorehouseMainService.getQuery(query); |
||||
|
return SysResult.success(map); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,78 @@ |
|||||
|
package com.wh.controller.api.output; |
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.pojo.api.*; |
||||
|
import com.wh.pojo.purchasenew.Purchasenew; |
||||
|
import com.wh.service.api.outstorehouse.OutStorehouseListingService; |
||||
|
import com.wh.service.api.outstorehouse.OutStorehouseMainService; |
||||
|
import com.yxt.common.base.utils.StringUtils; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.BeanUtils; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/output/") |
||||
|
public class OutStorehouseMainController { |
||||
|
|
||||
|
@Autowired |
||||
|
private OutStorehouseMainService outStorehouseMainService; |
||||
|
|
||||
|
@Autowired |
||||
|
private OutStorehouseListingService outStorehouseListingService; |
||||
|
|
||||
|
@PostMapping("importOutStorehouse") |
||||
|
public ResultBean importOutStorehouse(@RequestBody OutStorehouseMainDto outStorehouseMainDto){ |
||||
|
log.info("/output/importOutStorehouse:{}", JSONObject.toJSONString(outStorehouseMainDto)); |
||||
|
ResultBean resultBean = outStorehouseMainService.importOutStorehouse(outStorehouseMainDto); |
||||
|
return resultBean; |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addOutStorehouse") |
||||
|
public ResultBean addOutStorehouse(@RequestBody OutStorehouseMainDto outStorehouseMainDto){ |
||||
|
log.info("/output/addOutStorehouse:{}", JSONObject.toJSONString(outStorehouseMainDto)); |
||||
|
ResultBean resultBean = outStorehouseMainService.addOutStorehouse(outStorehouseMainDto); |
||||
|
return resultBean; |
||||
|
} |
||||
|
@PostMapping("listPage") |
||||
|
public ResultBean listPage(@RequestBody PagerQuery<OutStorehouseMainQuery> pq){ |
||||
|
PagerVo<OutStorehouseVo> pv = outStorehouseMainService.listPage(pq); |
||||
|
ResultBean<PagerVo<OutStorehouseVo>> r = ResultBean.fireSuccess(); |
||||
|
return r.setData(pv); |
||||
|
} |
||||
|
@PostMapping("listAllForPicking") |
||||
|
public ResultBean listAllForPicking(@RequestBody OutStorehouseMainQuery pq){ |
||||
|
ResultBean r=ResultBean.fireFail(); |
||||
|
if(StringUtils.isBlank(pq.getCusterSid())){ |
||||
|
return r.setMsg("CusterSid不能为空"); |
||||
|
} |
||||
|
List<OutStorehouseMain> list= outStorehouseMainService.listAllForPicking(pq); |
||||
|
return r.success().setData(list); |
||||
|
} |
||||
|
@GetMapping("getOutStorehouse/{sid}") |
||||
|
public ResultBean getOutStorehouse(@PathVariable(value = "sid") String sid){ |
||||
|
return outStorehouseMainService.getOutStorehouse(sid); |
||||
|
} |
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
for (String sid : sids) { |
||||
|
OutStorehouseMain entity=outStorehouseMainService.fetchBySid(sid); |
||||
|
int state = entity.getState(); |
||||
|
if(2==state){ |
||||
|
continue; |
||||
|
} |
||||
|
int i = outStorehouseMainService.deleteOutStorehouseMainBySid(sid); |
||||
|
} |
||||
|
return rb.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,46 @@ |
|||||
|
package com.wh.controller.api.prodstock; |
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.pojo.api.*; |
||||
|
import com.wh.service.api.outstorehouse.OutStorehouseMainService; |
||||
|
import com.wh.service.api.prodstock.ProdStockService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/stock/") |
||||
|
public class ProdStockController { |
||||
|
@Autowired |
||||
|
private ProdStockService prodStockService; |
||||
|
|
||||
|
@PostMapping("listPage") |
||||
|
public ResultBean listPage(@RequestBody PagerQuery<ProdStockQuery> pq){ |
||||
|
PagerVo<ProdStockVo> pv = prodStockService.listPage(pq); |
||||
|
ResultBean<PagerVo<ProdStockVo>> r = ResultBean.fireSuccess(); |
||||
|
return r.setData(pv); |
||||
|
} |
||||
|
@PostMapping("importStock") |
||||
|
public ResultBean importStock(@RequestBody ProdStocks datas){ |
||||
|
log.info("/stock/importStock:{}", JSONObject.toJSONString(datas)); |
||||
|
ResultBean rb=ResultBean.fireFail(); |
||||
|
List<ProdStock> list = datas.getList(); |
||||
|
if(list.size()>0){ |
||||
|
List<ProdStock> prodStocks = prodStockService.importStock(list); |
||||
|
if(prodStocks.size()>0){ |
||||
|
return rb.fail().setData(prodStocks).setMsg("部分数据导入失败,商品、仓库、货位信息不能为空," + |
||||
|
"storeHouseSid(仓库),proSid(商品id),proName(商品名称))," + |
||||
|
"locationId(货位编码),locationNumber(货位名称)"); |
||||
|
} |
||||
|
}else{ |
||||
|
return rb.setMsg("导入失败"); |
||||
|
} |
||||
|
return rb.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,95 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.brandinfo; |
||||
|
|
||||
|
import com.wh.pojo.brandinfo.BrandInfoDetailsVo; |
||||
|
import com.wh.pojo.brandinfo.BrandInfoDto; |
||||
|
import com.wh.pojo.brandinfo.BrandInfoQuery; |
||||
|
import com.wh.pojo.brandinfo.BrandInfoVo; |
||||
|
import com.wh.service.brandinfo.BrandInfoService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: BrandInfoFeignFallback.java <br/> |
||||
|
* Class: com.supervise.biz.brandinfo.BrandInfoRest <br/> |
||||
|
* Description: 品牌信息. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:28 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "品牌信息") |
||||
|
@RestController("com.supervise.biz.brandinfo.BrandInfoRest") |
||||
|
@RequestMapping("v1/brandinfo") |
||||
|
public class BrandInfoRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private BrandInfoService brandInfoService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<BrandInfoVo>> listPage(@RequestBody PagerQuery<BrandInfoQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<BrandInfoVo> pv = brandInfoService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody BrandInfoDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
brandInfoService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
brandInfoService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<BrandInfoDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
BrandInfoDetailsVo vo = brandInfoService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,92 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.dictcommon; |
||||
|
|
||||
|
|
||||
|
import com.wh.pojo.dictcommon.*; |
||||
|
import com.wh.service.dictcommon.DictCommonService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: DictCommonFeignFallback.java <br/> |
||||
|
* Class: com.supervise.biz.dictcommon.DictCommonRest <br/> |
||||
|
* Description: 数据字典——数据项. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:29 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "数据字典——数据项") |
||||
|
@RestController("com.wh.controller.dictcommon.DictCommonRest") |
||||
|
@RequestMapping("v1/dictcommon") |
||||
|
public class DictCommonRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private DictCommonService dictCommonService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<DictCommonVo>> listPage(@RequestBody PagerQuery<DictCommonQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<DictCommonVo> pv = dictCommonService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody DictCommonDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
dictCommonService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
dictCommonService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<DictCommonDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
DictCommonDetailsVo vo = dictCommonService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,94 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.dicttype; |
||||
|
|
||||
|
import com.wh.pojo.dicttype.DictTypeDetailsVo; |
||||
|
import com.wh.pojo.dicttype.DictTypeDto; |
||||
|
import com.wh.pojo.dicttype.DictTypeQuery; |
||||
|
import com.wh.pojo.dicttype.DictTypeVo; |
||||
|
import com.wh.service.dicttype.DictTypeService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: DictTypeFeignFallback.java <br/> |
||||
|
* Class: com.supervise.biz.dicttype.DictTypeRest <br/> |
||||
|
* Description: 数据字典——数据类型. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:29 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "数据字典——数据类型") |
||||
|
@RestController("com.wh.controller.dicttype.DictTypeRest") |
||||
|
@RequestMapping("v1/dicttype") |
||||
|
public class DictTypeRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private DictTypeService dictTypeService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<DictTypeVo>> listPage(@RequestBody PagerQuery<DictTypeQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<DictTypeVo> pv = dictTypeService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody DictTypeDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
dictTypeService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
dictTypeService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<DictTypeDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
DictTypeDetailsVo vo = dictTypeService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,103 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.entinfo; |
||||
|
|
||||
|
import com.wh.pojo.entinfo.EntInfoDetailsVo; |
||||
|
import com.wh.pojo.entinfo.EntInfoDto; |
||||
|
import com.wh.pojo.entinfo.EntInfoQuery; |
||||
|
import com.wh.pojo.entinfo.EntInfoVo; |
||||
|
import com.wh.service.entinfo.EntInfoService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: warehouse(仓储) <br/> |
||||
|
* File: EntInfoFeignFallback.java <br/> |
||||
|
* Class: com.wh.biz.entinfo.EntInfoRest <br/> |
||||
|
* Description: 客户信息. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-13 22:19:45 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "客户信息") |
||||
|
@RestController("com.wh.biz.entinfo.EntInfoRest") |
||||
|
@RequestMapping("v1/entinfo") |
||||
|
public class EntInfoRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private EntInfoService entInfoService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<EntInfoVo>> listPage(@RequestBody PagerQuery<EntInfoQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<EntInfoVo> pv = entInfoService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
// @ApiOperation("查询所有的企业信息")
|
||||
|
// @GetMapping("/listAll")
|
||||
|
// public ResultBean<List<WhEnterpriseInformationVo>> listAll(){
|
||||
|
// ResultBean rb = ResultBean.fireFail();
|
||||
|
// List<WhEnterpriseInformationVo> pv = entInfoService.listAll();
|
||||
|
// return rb.success().setData(pv);
|
||||
|
// }
|
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody EntInfoDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
entInfoService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
entInfoService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<EntInfoDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
EntInfoDetailsVo vo = entInfoService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,93 @@ |
|||||
|
package com.wh.controller.initial; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.*; |
||||
|
import com.wh.pojo.shstorehouse.ShStorehouse; |
||||
|
import com.wh.service.initial.LocationService; |
||||
|
import com.wh.service.shstorehouse.ShStorehouseService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import org.apache.commons.lang3.StringUtils; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/location/") |
||||
|
public class LocationController { |
||||
|
|
||||
|
@Autowired |
||||
|
private LocationService locationService; |
||||
|
@Autowired |
||||
|
private ShStorehouseService shStorehouseService; |
||||
|
|
||||
|
@PostMapping("list") |
||||
|
public ResultBean getLocationList(@RequestBody PagerQuery<LocationQuery> pq){ |
||||
|
// pageResult = locationService.getLocationList(pageResult);
|
||||
|
// return SysResult.success(pageResult);
|
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<Location> pv = locationService.getSupplierList(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@GetMapping("listAll") |
||||
|
public SysResult listAll(PageResult pageResult){ |
||||
|
List<Location> locations = locationService.getLocations(); |
||||
|
return SysResult.success(locations); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addLocation") |
||||
|
public SysResult addLocation(@RequestBody Location location){ |
||||
|
if(StringUtils.isBlank(location.getStorehouseid())){ |
||||
|
return SysResult.fail(); |
||||
|
} |
||||
|
ShStorehouse shStorehouse = shStorehouseService.fetchBySid(location.getStorehouseid()); |
||||
|
if(shStorehouse==null){ |
||||
|
return SysResult.fail(); |
||||
|
} |
||||
|
location.setStorehouse(shStorehouse.getName()); |
||||
|
locationService.addLocation(location); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataLocation") |
||||
|
public SysResult updataLocation(@RequestBody Location location){ |
||||
|
locationService.updataLocation(location); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{name}") |
||||
|
public SysResult deleteLocation(@PathVariable String name){ |
||||
|
locationService.deleteLocation(name); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
@DeleteMapping("deleteById/{id}") |
||||
|
public ResultBean deleteById(@PathVariable String id){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
int i = locationService.deleteById(id); |
||||
|
if(i==0){ |
||||
|
return rb; |
||||
|
} |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getStorehouse") |
||||
|
public SysResult getStorehouse(){ |
||||
|
List<Storehouse> storehouseList = locationService.getStorehouse(); |
||||
|
return SysResult.success(storehouseList); |
||||
|
} |
||||
|
@GetMapping("getLocationsByStoreId/{id}") |
||||
|
public SysResult getLocationsByStoreId(String id){ |
||||
|
List<LocationVo> locations = locationService.getLocationsByStoreId(id); |
||||
|
return SysResult.success(locations); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getType") |
||||
|
public SysResult getType(){ |
||||
|
List<LocationType> locationTypeList = locationService.getType(); |
||||
|
return SysResult.success(locationTypeList); |
||||
|
} |
||||
|
} |
@ -0,0 +1,56 @@ |
|||||
|
package com.wh.controller.initial; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Product; |
||||
|
import com.wh.pojo.ProductQuery; |
||||
|
import com.wh.pojo.Storehouse; |
||||
|
import com.wh.pojo.shstorehouse.ShStorehouseQuery; |
||||
|
import com.wh.pojo.shstorehouse.ShStorehouseVo; |
||||
|
import com.wh.service.initial.ProductService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/product/") |
||||
|
public class ProductController { |
||||
|
@Autowired |
||||
|
private ProductService productService; |
||||
|
|
||||
|
@PostMapping("list") |
||||
|
public ResultBean getProductList(@RequestBody PagerQuery<ProductQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<Product> pv = productService.getProductList(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addProduct") |
||||
|
public SysResult addProduct(@RequestBody Product product){ |
||||
|
productService.addProduct(product); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataProduct") |
||||
|
public SysResult updataProduct(@RequestBody Product product){ |
||||
|
productService.updataProduct(product); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{barCode}") |
||||
|
public SysResult deleteProduct(@PathVariable String barCode){ |
||||
|
productService.deleteProduct(barCode); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getStorehouse") |
||||
|
public SysResult getStorehouse(){ |
||||
|
List<Storehouse> storehouses = productService.getStorehouse(); |
||||
|
return SysResult.success(storehouses); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,41 @@ |
|||||
|
package com.wh.controller.initial; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Storehouse; |
||||
|
import com.wh.service.initial.StorehouseService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/storehouse/") |
||||
|
public class StorehouseController { |
||||
|
|
||||
|
@Autowired |
||||
|
private StorehouseService storehouseService; |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getStorehouseList(PageResult pageResult){ |
||||
|
pageResult = storehouseService.getStorehouseList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addStorehouse") |
||||
|
public SysResult addStorehouse(@RequestBody Storehouse storehouse){ |
||||
|
storehouseService.addStorehouse(storehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataStorehouse") |
||||
|
public SysResult updataStorehouse(@RequestBody Storehouse storehouse){ |
||||
|
storehouseService.updataStorehouse(storehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{name}") |
||||
|
public SysResult deleteStorehouse(@PathVariable String name) throws Exception { |
||||
|
storehouseService.deleteStorehouse(name); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,59 @@ |
|||||
|
package com.wh.controller.initial; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Product; |
||||
|
import com.wh.pojo.ProductQuery; |
||||
|
import com.wh.pojo.Supplier; |
||||
|
import com.wh.pojo.SupplierQuery; |
||||
|
import com.wh.service.initial.SupplierService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/supplier/") |
||||
|
public class SupplierController { |
||||
|
|
||||
|
@Autowired |
||||
|
private SupplierService supplierService; |
||||
|
|
||||
|
@PostMapping("list") |
||||
|
public ResultBean getSupplierList(@RequestBody PagerQuery<SupplierQuery> pq){ |
||||
|
// pageResult = supplierService.getSupplierList(pageResult);
|
||||
|
// return SysResult.success(pageResult);
|
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<Supplier> pv = supplierService.getSupplierList(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@PostMapping("listAll") |
||||
|
public ResultBean listAll(@RequestBody PagerQuery<SupplierQuery> pq){ |
||||
|
// pageResult = supplierService.getSupplierList(pageResult);
|
||||
|
// return SysResult.success(pageResult);
|
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<Supplier> list=supplierService.listAll(); |
||||
|
return rb.success().setData(list); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addSupplier") |
||||
|
public SysResult addSupplier(@RequestBody Supplier supplier){ |
||||
|
supplierService.addSupplier(supplier); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataSupplier") |
||||
|
public SysResult updataSupplier(@RequestBody Supplier supplier){ |
||||
|
supplierService.updataSupplier(supplier); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{name}") |
||||
|
public SysResult deleteSupplier(@PathVariable String name){ |
||||
|
supplierService.deleteSupplier(name); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,69 @@ |
|||||
|
package com.wh.controller.instorehouse; |
||||
|
|
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Product; |
||||
|
import com.wh.pojo.Purchase; |
||||
|
import com.wh.pojo.Storehouse; |
||||
|
import com.wh.pojo.Supplier; |
||||
|
import com.wh.service.instorehouse.PurchaseService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/purchase/") |
||||
|
public class PurchaseController { |
||||
|
|
||||
|
@Autowired |
||||
|
private PurchaseService purchaseService; |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getPurchaseList(PageResult pageResult){ |
||||
|
pageResult = purchaseService.getPurchaseList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addPurchase") |
||||
|
public SysResult addPurchase(@RequestBody Purchase purchase){ |
||||
|
purchaseService.addPurchase(purchase); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getProductList") |
||||
|
public SysResult getProductList(Product product){ |
||||
|
// String name = (String) map.get("name");
|
||||
|
// System.out.println(product.getName());
|
||||
|
// System.out.println(map.toString());
|
||||
|
List<Product> productList = purchaseService.getProductList(product.getName()); |
||||
|
return SysResult.success(productList); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getSupplier") |
||||
|
public SysResult getSupplier(){ |
||||
|
List<Supplier> supplierList = purchaseService.getSupplier(); |
||||
|
return SysResult.success(supplierList); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getStorehouse") |
||||
|
public SysResult getStorehouse(){ |
||||
|
List<Storehouse> storehouseList = purchaseService.getStorehouse(); |
||||
|
return SysResult.success(storehouseList); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{purchaseId}") |
||||
|
public SysResult deletePurchase(@PathVariable String purchaseId){ |
||||
|
purchaseService.deletePurchase(purchaseId); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updata") |
||||
|
public SysResult updataPurchase(@RequestBody Purchase purchase){ |
||||
|
purchaseService.updataPurchase(purchase); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,52 @@ |
|||||
|
package com.wh.controller.instorehouse; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.Options; |
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Receiving; |
||||
|
import com.wh.service.instorehouse.ReceivingService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/receiving/") |
||||
|
public class ReceivingController { |
||||
|
|
||||
|
@Autowired |
||||
|
private ReceivingService receivingService; |
||||
|
|
||||
|
@GetMapping("getOptions") |
||||
|
public SysResult getOptions(){ |
||||
|
List<Options> optionsList = receivingService.getOptions(); |
||||
|
return SysResult.success(optionsList); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addReceiving") |
||||
|
public SysResult addReceiving(@RequestBody Map<String,String> map){ |
||||
|
System.out.println(map); |
||||
|
receivingService.addReceiving(map.get("id"),map.get("user")); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getReceiving") |
||||
|
public SysResult getReceiving(PageResult pageResult){ |
||||
|
pageResult = receivingService.getReceiving(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataReceiving") |
||||
|
public SysResult updataReceiving(@RequestBody Receiving receiving){ |
||||
|
receivingService.updataReceiving(receiving); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("deleteReceiving/{receivingId}/{purchaseId}") |
||||
|
public SysResult deleteReceiving(@PathVariable String receivingId,@PathVariable String purchaseId){ |
||||
|
receivingService.deleteReceiving(receivingId,purchaseId); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,60 @@ |
|||||
|
package com.wh.controller.outstorehouse; |
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.OutStorehouse; |
||||
|
import com.wh.service.outstorehouse.OutStorehouseService; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/outStorehouse/") |
||||
|
public class OutStorehouseController { |
||||
|
|
||||
|
@Autowired |
||||
|
private OutStorehouseService outStorehouseService; |
||||
|
|
||||
|
|
||||
|
|
||||
|
@GetMapping("getQuery") |
||||
|
public SysResult getQuery(OutStorehouse outStorehouse){ |
||||
|
Map<String,Object> map = outStorehouseService.getQuery(outStorehouse); |
||||
|
return SysResult.success(map); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getOutStorehouseList(PageResult pageResult){ |
||||
|
pageResult = outStorehouseService.getOutStorehouseList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addOutStorehouse") |
||||
|
public SysResult addOutStorehouse(@RequestBody OutStorehouse outStorehouse){ |
||||
|
log.info("/outStorehouse/addOutStorehouse:{}", JSONObject.toJSONString(outStorehouse)); |
||||
|
outStorehouseService.addOutStorehouse(outStorehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataOutStorehouse") |
||||
|
public SysResult updataOutStorehouse(@RequestBody OutStorehouse outStorehouse){ |
||||
|
outStorehouseService.updataOutStorehouse(outStorehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("delete/{outStorehouseId}") |
||||
|
public SysResult deleteOutStorehouse(@PathVariable String outStorehouseId){ |
||||
|
// outStorehouseService.deleteOutStorehouse(outStorehouseId);
|
||||
|
return SysResult.success("连接成功"); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("out") |
||||
|
public SysResult out(@RequestBody OutStorehouse outStorehouse){ |
||||
|
outStorehouseService.out(outStorehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,63 @@ |
|||||
|
package com.wh.controller.outstorehouse; |
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.PickingUser; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Picking; |
||||
|
import com.wh.pojo.api.OutStorehouseMainQuery; |
||||
|
import com.wh.pojo.api.OutStorehouseVo; |
||||
|
import com.wh.service.api.outstorehouse.OutStorehouseMainService; |
||||
|
import com.wh.service.outstorehouse.PickingService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/picking/") |
||||
|
public class PickingController { |
||||
|
|
||||
|
@Autowired |
||||
|
private PickingService pickingService; |
||||
|
@Autowired |
||||
|
private OutStorehouseMainService outStorehouseMainService; |
||||
|
@PostMapping("listPage") |
||||
|
public ResultBean listPage(@RequestBody PagerQuery<OutStorehouseMainQuery> pq){ |
||||
|
pq.getParams().setState("2"); |
||||
|
PagerVo<OutStorehouseVo> pv = outStorehouseMainService.listPage(pq); |
||||
|
ResultBean<PagerVo<OutStorehouseVo>> r = ResultBean.fireSuccess(); |
||||
|
return r.setData(pv); |
||||
|
} |
||||
|
@GetMapping("getOptions") |
||||
|
public SysResult getOptions(){ |
||||
|
List<String> outStorehouseIdList = pickingService.getOptions(); |
||||
|
return SysResult.success(outStorehouseIdList); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("picking") |
||||
|
public ResultBean picking(@RequestBody PickingUser pickingUser){ |
||||
|
log.info("/picking/picking:{}", JSONObject.toJSONString(pickingUser)); |
||||
|
return pickingService.picking(pickingUser); |
||||
|
// ss pickingService.picking(pickingUser.getOutStorehouseId(),pickingUser.getUser());
|
||||
|
} |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getPickingList(PageResult pageResult){ |
||||
|
pageResult = pickingService.getPickingList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("finish") |
||||
|
public SysResult finish(@RequestBody Picking picking){ |
||||
|
pickingService.finish(picking); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,83 @@ |
|||||
|
package com.wh.controller.purchasenew; |
||||
|
|
||||
|
import com.alibaba.fastjson.JSONObject; |
||||
|
import com.wh.pojo.purchasenew.*; |
||||
|
import com.wh.service.purchasenew.PurchasenewService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
@Slf4j |
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/purchasenew") |
||||
|
public class PurchasenewController { |
||||
|
@Autowired |
||||
|
private PurchasenewService purchasenewService; |
||||
|
|
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<PurchasenewVo>> listPage(@RequestBody PagerQuery<PurchasenewQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<PurchasenewVo> pv = purchasenewService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@ApiOperation("获取所有的采购订单") |
||||
|
@PostMapping("/listAll") |
||||
|
public ResultBean<List<Purchasenew>> listAll(@RequestBody PurchasenewQuery pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
// String custId = pq.getCustId();
|
||||
|
// if(StringUtils.isBlank(custId)){
|
||||
|
// return rb.setMsg("企业id不能为空");
|
||||
|
// }
|
||||
|
List<Purchasenew> list = purchasenewService.listForInput(pq); |
||||
|
return rb.success().setData(list); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("导入采购订单 入库") |
||||
|
@PostMapping("/importPurchase") |
||||
|
public ResultBean importPurchase(@RequestBody PurchasenewForImportDto dto){ |
||||
|
log.info("/stock/importStock:{}", JSONObject.toJSONString(dto)); |
||||
|
return purchasenewService.importPurchase(dto); |
||||
|
} |
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody PurchasenewDto dto){ |
||||
|
log.info("/stock/importStock:{}", JSONObject.toJSONString(dto)); |
||||
|
return purchasenewService.saveOrUpdateDto(dto); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
int i = purchasenewService.delByPurchasenewSids(sids); |
||||
|
if (i==0) |
||||
|
return rb; |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<PurchasenewDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PurchasenewDetailsVo vo = purchasenewService.fetchDetailsVoBySid(sid); |
||||
|
if(vo==null){ |
||||
|
return rb; |
||||
|
} |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
// @ApiOperation("获取所有的企业信息")
|
||||
|
// @GetMapping("/fetchEntList")
|
||||
|
// public ResultBean<List<WhEnterpriseInformationVo>> fetchDetailsBySid(){
|
||||
|
// ResultBean<List<WhEnterpriseInformationVo>> enterpriseBySid = whEnterpriseInformationFeign.EnterpriseList();
|
||||
|
// return enterpriseBySid;
|
||||
|
// }
|
||||
|
|
||||
|
} |
@ -0,0 +1,54 @@ |
|||||
|
package com.wh.controller.purchasenewproduct; |
||||
|
|
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProductDetailsVo; |
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProductDto; |
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProductQuery; |
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProductVo; |
||||
|
import com.wh.service.purchasenewproduct.PurchasenewProductService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/purchasenewproduct/") |
||||
|
public class PurchasenewProductController { |
||||
|
|
||||
|
@Autowired |
||||
|
private PurchasenewProductService purchasenewProductService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<PurchasenewProductVo>> listPage(@RequestBody PagerQuery<PurchasenewProductQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<PurchasenewProductVo> pv = purchasenewProductService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody PurchasenewProductDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
purchasenewProductService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
purchasenewProductService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<PurchasenewProductDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PurchasenewProductDetailsVo vo = purchasenewProductService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,14 @@ |
|||||
|
package com.wh.controller.purchasenewproduct.vo; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
public class Options { |
||||
|
private String value; |
||||
|
private String label; |
||||
|
private List<Options> children; |
||||
|
} |
@ -0,0 +1,15 @@ |
|||||
|
package com.wh.controller.purchasenewproduct.vo; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
public class PageResult { |
||||
|
private String query; |
||||
|
private String entSid; |
||||
|
private Integer pageNum; |
||||
|
private Integer pageSize; |
||||
|
private Long total; |
||||
|
private Object rows; |
||||
|
} |
@ -0,0 +1,11 @@ |
|||||
|
package com.wh.controller.purchasenewproduct.vo; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
public class PickingUser { |
||||
|
private String outStorehouseId; |
||||
|
private String user; |
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.wh.controller.purchasenewproduct.vo; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
public class QueryInfo { |
||||
|
private String barCode; |
||||
|
private String locationId; |
||||
|
private String fromLocationId; |
||||
|
private Integer count; |
||||
|
} |
@ -0,0 +1,70 @@ |
|||||
|
package com.wh.controller.purchasenewproduct.vo; |
||||
|
|
||||
|
import lombok.experimental.Accessors; |
||||
|
//@Builder
|
||||
|
//@Data
|
||||
|
@Accessors(chain = true) |
||||
|
//@NoArgsConstructor
|
||||
|
//@AllArgsConstructor
|
||||
|
public class SysResult { |
||||
|
|
||||
|
private Integer status; //状态码信息 200成功 201失败
|
||||
|
private String msg; //服务器提示信息
|
||||
|
private Object data; //服务器返回值
|
||||
|
|
||||
|
public SysResult(Integer status, String msg, Object data) { |
||||
|
this.status = status; |
||||
|
this.msg = msg; |
||||
|
this.data = data; |
||||
|
} |
||||
|
|
||||
|
public Integer getStatus() { |
||||
|
return status; |
||||
|
} |
||||
|
|
||||
|
public void setStatus(Integer status) { |
||||
|
this.status = status; |
||||
|
} |
||||
|
|
||||
|
public String getMsg() { |
||||
|
return msg; |
||||
|
} |
||||
|
|
||||
|
public void setMsg(String msg) { |
||||
|
this.msg = msg; |
||||
|
} |
||||
|
|
||||
|
public Object getData() { |
||||
|
return data; |
||||
|
} |
||||
|
|
||||
|
public void setData(Object data) { |
||||
|
this.data = data; |
||||
|
} |
||||
|
|
||||
|
public static SysResult fail(){ |
||||
|
return new SysResult(201,"服务器运行失败",null); |
||||
|
} |
||||
|
|
||||
|
public static SysResult success(){ |
||||
|
return new SysResult(200, "服务器运行成功", null); |
||||
|
} |
||||
|
|
||||
|
public static SysResult noAccess(){ |
||||
|
return new SysResult(202,"无访问权限",null); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
public static SysResult notEnough(){ |
||||
|
return new SysResult(203,"数量不足",null); |
||||
|
} |
||||
|
|
||||
|
public static SysResult success(Object data){ |
||||
|
|
||||
|
return new SysResult(200, "服务器运行成功", data); |
||||
|
} |
||||
|
|
||||
|
public static SysResult success(String msg, Object data){ |
||||
|
return new SysResult(200, msg, data); |
||||
|
} |
||||
|
} |
@ -0,0 +1,246 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.shstorehouse; |
||||
|
|
||||
|
import cn.hutool.core.lang.Assert; |
||||
|
//import com.wh.feign.crm.ProjectInformationFeign;
|
||||
|
//import com.wh.feign.enterpriseinformation.WhEnterpriseInformationFeign;
|
||||
|
//import com.wh.feign.enterpriseinformation.WhEnterpriseInformationVo;
|
||||
|
import com.wh.pojo.Supplier; |
||||
|
import com.wh.pojo.shstorehouse.*; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentDto; |
||||
|
import com.wh.service.initial.SupplierService; |
||||
|
import com.wh.service.shstorehouse.ShStorehouseService; |
||||
|
import com.wh.service.shstorehouseattachment.ShStorehouseAttachmentService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.beans.factory.annotation.Value; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
import org.springframework.web.multipart.MultipartFile; |
||||
|
|
||||
|
import javax.servlet.http.HttpServletRequest; |
||||
|
import java.io.File; |
||||
|
import java.util.List; |
||||
|
import java.util.UUID; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseFeignFallback.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouse.ShStorehouseRest <br/> |
||||
|
* Description: 库房信息表. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "库房信息表") |
||||
|
@RestController("com.wh.biz.shstorehouse.ShStorehouseRest") |
||||
|
@RequestMapping("v1/shstorehouse") |
||||
|
public class ShStorehouseRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private ShStorehouseService shStorehouseService; |
||||
|
@Autowired |
||||
|
private ShStorehouseAttachmentService shStorehouseAttachmentService; |
||||
|
// @Autowired
|
||||
|
// private WhEnterpriseInformationFeign whEnterpriseInformationFeign;
|
||||
|
// @Autowired
|
||||
|
// private ProjectInformationFeign projectInformationFeign;
|
||||
|
@Autowired |
||||
|
private SupplierService supplierService; |
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<ShStorehouseVo>> listPage(@RequestBody PagerQuery<ShStorehouseQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<ShStorehouseVo> pv = shStorehouseService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
// @ApiOperation("查询项目所有")
|
||||
|
// @GetMapping("/selectAllProject")
|
||||
|
// public ResultBean selectAllProject(){
|
||||
|
// ResultBean rb = ResultBean.fireFail();
|
||||
|
// ResultBean resultBean = projectInformationFeign.listAll();
|
||||
|
// return resultBean;
|
||||
|
// }
|
||||
|
@ApiOperation("查询所有可用仓库") |
||||
|
@PostMapping("/selectStoreHouse") |
||||
|
public ResultBean selectStoreHouse(@RequestBody List<String> List){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<ShStorehouseVo> list= shStorehouseService.selectStoreHouse(List); |
||||
|
return rb.success().setData(list); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* 根据仓库sid查询仓库信息 |
||||
|
* @return |
||||
|
*/ |
||||
|
@ApiOperation("根据仓库sid查询仓库信息") |
||||
|
@GetMapping("/selectStoreBySid") |
||||
|
public ResultBean<ShStorehouseVo> selectStoreBySid(@RequestParam("shSid")String shSid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
ShStorehouseVo shStorehouseVo= shStorehouseService.selectStoreBySid(shSid); |
||||
|
return rb.success().setData(shStorehouseVo); |
||||
|
} |
||||
|
@ApiOperation("根据项目sid查询仓库") |
||||
|
@GetMapping("/getStorehouseBySid") |
||||
|
public ResultBean<List<ShStorehouseVo>> getStorehouseBySid(String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<ShStorehouseVo> pv = shStorehouseService.getStorehouseBySid(sid); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@ApiOperation("根据客户sid获取所有的仓库") |
||||
|
@GetMapping("/listAllBycusterSid") |
||||
|
public ResultBean<List<ShStorehouseVo>> listAllBycusterSid(@RequestParam("custerSid") String custerSid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<ShStorehouseVo> pv = shStorehouseService.listAllBycusterSid(custerSid); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@ApiOperation("获取所有的仓库") |
||||
|
@GetMapping("/listAll") |
||||
|
public ResultBean<List<ShStorehouse>> listAll(){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
return rb.success().setData(shStorehouseService.list()); |
||||
|
} |
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody ShStorehouseDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
shStorehouseService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
int i = shStorehouseService.delBySids(sids); |
||||
|
if(i==0){ |
||||
|
return rb; |
||||
|
} |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<ShStorehouseDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
ShStorehouseDetailsVo vo = shStorehouseService.fetchDetailsVoBySid(sid); |
||||
|
if(vo==null) |
||||
|
return rb.setMsg("没有查询到数据"); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
// @ApiOperation(value = "上传附件")
|
||||
|
// @ResponseBody
|
||||
|
// @PostMapping("/uploadFile")
|
||||
|
// public ResultBean updateHeadImage(@RequestParam("file")MultipartFile multipartFile) {
|
||||
|
// if (multipartFile.isEmpty()) {
|
||||
|
// return new ResultBean().fail().setMsg("上传附件不能为空");
|
||||
|
// }
|
||||
|
//
|
||||
|
// return shStorehouseService.updateFile(multipartFile);
|
||||
|
//
|
||||
|
// }
|
||||
|
@Value("${yuan.file.root.path}") |
||||
|
public String fileRootPath; |
||||
|
@ApiOperation("文件上传") |
||||
|
@PostMapping("/upload") |
||||
|
public ResultBean upload(@RequestParam("file") MultipartFile file, HttpServletRequest request) { |
||||
|
String filePath = ""; // 文件保存的位置
|
||||
|
String urlPath = "";// 文件web浏览路径
|
||||
|
Assert.isTrue(!file.isEmpty(), "文件为空"); |
||||
|
// 原始名 以 a.jpg为例
|
||||
|
String originalFilename = file.getOriginalFilename(); |
||||
|
// 获取后缀并拼接'/'用于分类,也可以用日期 例: suffix = "jpg/"
|
||||
|
String suffix = originalFilename.substring(originalFilename.lastIndexOf(".") + 1) + "/"; |
||||
|
// 加上时间戳生成新的文件名,防止重复 newFileName = "1595511980146a.jpg"
|
||||
|
String newFileName = System.currentTimeMillis() + originalFilename; |
||||
|
filePath = fileRootPath+ suffix + newFileName; |
||||
|
System.out.println(filePath); |
||||
|
try { |
||||
|
File file1 = new File(filePath); |
||||
|
if (!file1.exists()) file1.mkdirs(); // 要是目录不存在,创建一个
|
||||
|
file.transferTo(file1); // 保存起来
|
||||
|
//urlPath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + "/archive/" + suffix + newFileName;
|
||||
|
|
||||
|
urlPath = "http://jianguan.yyundong.com/warehouseapi/archive/" + suffix + newFileName; |
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
} |
||||
|
return ResultBean.fireSuccess().setData(urlPath); |
||||
|
} |
||||
|
@ApiOperation("图片上传") |
||||
|
@PostMapping("/uploadPics") |
||||
|
public ResultBean uploadPics(@RequestParam("file") MultipartFile file, HttpServletRequest request) { |
||||
|
String filePath = ""; // 文件保存的位置
|
||||
|
String urlPath = "";// 文件web浏览路径
|
||||
|
Assert.isTrue(!file.isEmpty(), "文件为空"); |
||||
|
// 原始名 以 a.jpg为例
|
||||
|
String originalFilename = file.getOriginalFilename(); |
||||
|
// 获取后缀并拼接'/'用于分类,也可以用日期 例: suffix = "jpg/"
|
||||
|
String suffix = originalFilename.substring(originalFilename.lastIndexOf(".") + 1) + "/"; |
||||
|
// 加上时间戳生成新的文件名,防止重复 newFileName = "1595511980146a.jpg"
|
||||
|
String newFileName = System.currentTimeMillis() + originalFilename; |
||||
|
filePath = fileRootPath+ suffix + newFileName; |
||||
|
System.out.println(filePath); |
||||
|
ShStorehouseAttachmentDto dto=new ShStorehouseAttachmentDto(); |
||||
|
String s = UUID.randomUUID().toString(); |
||||
|
try { |
||||
|
File file1 = new File(filePath); |
||||
|
if (!file1.exists()) file1.mkdirs(); // 要是目录不存在,创建一个
|
||||
|
file.transferTo(file1); // 保存起来
|
||||
|
//urlPath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + "/archive/" + suffix + newFileName;
|
||||
|
urlPath = "http://jianguan.yyundong.com/warehouseapi/archive/" + suffix + newFileName; |
||||
|
|
||||
|
// dto.setStorehouseSid(); // 库房sid
|
||||
|
// dto.setStorehouseName(); // 库房名称
|
||||
|
dto.setFileName(newFileName); // 文件名称
|
||||
|
dto.setFileDesc(""); // 文件描述
|
||||
|
dto.setFileType(suffix); // 文件类型,Word,Excel,PDF或图片
|
||||
|
dto.setFileSuffix(suffix); // 文件后缀,如:png,jpg,xls,xlsx
|
||||
|
dto.setFilePath(filePath); // 文件在服务器的存放路径
|
||||
|
dto.setFileUrl(urlPath); // 文件获取的url地址
|
||||
|
dto.setSid(s); |
||||
|
shStorehouseAttachmentService.insertByDto(dto); |
||||
|
} catch (Exception e) { |
||||
|
e.printStackTrace(); |
||||
|
} |
||||
|
return ResultBean.fireSuccess().setData(dto); |
||||
|
} |
||||
|
@ApiOperation("获取所有的企业信息") |
||||
|
@GetMapping("/fetchEntList") |
||||
|
public ResultBean fetchDetailsBySid(){ |
||||
|
return ResultBean.fireSuccess().setData(supplierService.listAll()); |
||||
|
} |
||||
|
} |
@ -0,0 +1,96 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.shstorehouseattachment; |
||||
|
|
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentDetailsVo; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentDto; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentQuery; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentVo; |
||||
|
import com.wh.service.shstorehouseattachment.ShStorehouseAttachmentService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseAttachmentFeignFallback.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouseattachment.ShStorehouseAttachmentRest <br/> |
||||
|
* Description: 库房附件,如合同,图片等. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "库房附件,如合同,图片等") |
||||
|
@RestController("com.wh.biz.shstorehouseattachment.ShStorehouseAttachmentRest") |
||||
|
@RequestMapping("v1/shstorehouseattachment") |
||||
|
public class ShStorehouseAttachmentRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private ShStorehouseAttachmentService shStorehouseAttachmentService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<ShStorehouseAttachmentVo>> listPage(@RequestBody PagerQuery<ShStorehouseAttachmentQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<ShStorehouseAttachmentVo> pv = shStorehouseAttachmentService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody ShStorehouseAttachmentDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
shStorehouseAttachmentService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
shStorehouseAttachmentService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<ShStorehouseAttachmentDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
ShStorehouseAttachmentDetailsVo vo = shStorehouseAttachmentService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,96 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.controller.shstorehouseattribute; |
||||
|
|
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttributeDetailsVo; |
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttributeDto; |
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttributeQuery; |
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttributeVo; |
||||
|
import com.wh.service.shstorehouseattribute.ShStorehouseAttributeService; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseAttributeFeignFallback.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouseattribute.ShStorehouseAttributeRest <br/> |
||||
|
* Description: 库房性质. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "库房性质") |
||||
|
@RestController("com.wh.biz.shstorehouseattribute.ShStorehouseAttributeRest") |
||||
|
@RequestMapping("v1/shstorehouseattribute") |
||||
|
public class ShStorehouseAttributeRest { |
||||
|
|
||||
|
@Autowired |
||||
|
private ShStorehouseAttributeService shStorehouseAttributeService; |
||||
|
|
||||
|
@ApiOperation("根据条件分页查询数据的列表") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<ShStorehouseAttributeVo>> listPage(@RequestBody PagerQuery<ShStorehouseAttributeQuery> pq){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
PagerVo<ShStorehouseAttributeVo> pv = shStorehouseAttributeService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@RequestBody ShStorehouseAttributeDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
shStorehouseAttributeService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据sid批量删除") |
||||
|
@PostMapping("/delBySids") |
||||
|
public ResultBean delBySids(@RequestBody String[] sids){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
shStorehouseAttributeService.delBySids(sids); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@ApiOperation("根据SID获取一条记录") |
||||
|
@GetMapping("/fetchDetailsBySid/{sid}") |
||||
|
public ResultBean<ShStorehouseAttributeDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
ShStorehouseAttributeDetailsVo vo = shStorehouseAttributeService.fetchDetailsVoBySid(sid); |
||||
|
return rb.success().setData(vo); |
||||
|
} |
||||
|
} |
@ -0,0 +1,26 @@ |
|||||
|
package com.wh.controller.stock; |
||||
|
|
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.service.stock.StockService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.CrossOrigin; |
||||
|
import org.springframework.web.bind.annotation.GetMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/stock/") |
||||
|
public class StockController { |
||||
|
|
||||
|
@Autowired |
||||
|
private StockService stockService; |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getStockList(PageResult pageResult){ |
||||
|
pageResult = stockService.getStockList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
} |
@ -0,0 +1,54 @@ |
|||||
|
package com.wh.controller.storehousemanage; |
||||
|
|
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.InStorehouse; |
||||
|
import com.wh.service.instorehouse.PutInService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/putIn/") |
||||
|
public class PutInController { |
||||
|
|
||||
|
@Autowired |
||||
|
private PutInService putInService; |
||||
|
|
||||
|
@GetMapping("getQuery") |
||||
|
public SysResult getQuery(InStorehouse inStorehouse){ |
||||
|
Map<String,Object> map = putInService.getQuery(inStorehouse); |
||||
|
return SysResult.success(map); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addInStorehouse") |
||||
|
public SysResult addInStorehouse(@RequestBody InStorehouse inStorehouse){ |
||||
|
String data = putInService.addInStorehouse(inStorehouse); |
||||
|
return SysResult.success(data); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getInStorehouseList(PageResult pageResult){ |
||||
|
pageResult = putInService.getInStorehouseList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataInStorehouse") |
||||
|
public SysResult updataInStorehouse(@RequestBody InStorehouse inStorehouse){ |
||||
|
// System.out.println(inStorehouse);
|
||||
|
putInService.updataInStorehouse(inStorehouse); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("deleteInStorehouse/{inStorehouseId}/{receivingId}") |
||||
|
public SysResult deleteInStorehouse(@PathVariable String inStorehouseId,@PathVariable String receivingId){ |
||||
|
String data = putInService.deleteInStorehouse(inStorehouseId,receivingId); |
||||
|
return SysResult.success(data); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,44 @@ |
|||||
|
package com.wh.controller.storehousemanage; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.Remove; |
||||
|
import com.wh.service.storehousemanage.RemoveService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.data.domain.Page; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/remove/") |
||||
|
public class RemoveController { |
||||
|
|
||||
|
@Autowired |
||||
|
private RemoveService removeService; |
||||
|
|
||||
|
@GetMapping("getQuery") |
||||
|
public SysResult getQuery(Remove remove){ |
||||
|
Map<String,Object> map = removeService.getQuery(remove); |
||||
|
return SysResult.success(map); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("addRemove") |
||||
|
public SysResult addRemove(@RequestBody Remove remove){ |
||||
|
removeService.addRemove(remove); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("list") |
||||
|
public SysResult getRemoveList(PageResult pageResult){ |
||||
|
pageResult = removeService.getRemoveList(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updata") |
||||
|
public SysResult updataRemove(@RequestBody Remove remove){ |
||||
|
removeService.updataRemove(remove); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,57 @@ |
|||||
|
package com.wh.controller.storehousemanage; |
||||
|
|
||||
|
import com.wh.controller.purchasenewproduct.vo.PageResult; |
||||
|
import com.wh.controller.purchasenewproduct.vo.QueryInfo; |
||||
|
import com.wh.controller.purchasenewproduct.vo.SysResult; |
||||
|
import com.wh.pojo.OnShelves; |
||||
|
import com.wh.service.storehousemanage.ShelvesService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
|
||||
|
@RestController |
||||
|
@CrossOrigin |
||||
|
@RequestMapping("/shelves/") |
||||
|
public class ShelvesController { |
||||
|
|
||||
|
@Autowired |
||||
|
private ShelvesService shelvesService; |
||||
|
|
||||
|
@GetMapping("getQuery") |
||||
|
public SysResult getQuery(QueryInfo queryInfo){ |
||||
|
Map<String,Object> map = shelvesService.getQuery(queryInfo); |
||||
|
if (map.size()==0){ |
||||
|
return SysResult.notEnough(); |
||||
|
}else { |
||||
|
return SysResult.success(map); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
@PostMapping("add") |
||||
|
public SysResult addShelves(@RequestBody OnShelves onShelves){ |
||||
|
// System.out.println(onShelves);
|
||||
|
shelvesService.addShelves(onShelves); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("getShelves") |
||||
|
public SysResult getShelves(PageResult pageResult){ |
||||
|
pageResult = shelvesService.getShelves(pageResult); |
||||
|
return SysResult.success(pageResult); |
||||
|
} |
||||
|
|
||||
|
@DeleteMapping("deleteShelves/{id}") |
||||
|
public SysResult deleteShelves(@PathVariable String id){ |
||||
|
shelvesService.deleteShelves(id); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
@PutMapping("updataShelves") |
||||
|
public SysResult updataShelves(@RequestBody OnShelves onShelves) throws Exception { |
||||
|
System.out.println(onShelves); |
||||
|
shelvesService.updataShelves(onShelves); |
||||
|
return SysResult.success(); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,35 @@ |
|||||
|
package com.wh.controller.storehouseproject; |
||||
|
|
||||
|
import com.wh.pojo.shstorehouse.ShStorehouseDto; |
||||
|
import com.wh.pojo.storehouseproject.StoreHouseProjectDto; |
||||
|
import com.wh.service.storehouseproject.StoreHouseProjectService; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/7/19 15:31 |
||||
|
*/ |
||||
|
@CrossOrigin |
||||
|
@Api(tags = "库房信息表") |
||||
|
@RestController("com.wh.biz.storehouseproject.StoreHouseProjectRest") |
||||
|
@RequestMapping("v1/storehouseproject") |
||||
|
public class StoreHouseProjectRest { |
||||
|
|
||||
|
@Autowired |
||||
|
StoreHouseProjectService storeHouseProjectService; |
||||
|
|
||||
|
|
||||
|
|
||||
|
//
|
||||
|
@ApiOperation("新增或修改") |
||||
|
@PostMapping("/saveOrUpdateDto") |
||||
|
public ResultBean saveOrUpdateDto(@RequestBody StoreHouseProjectDto dto){ |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
storeHouseProjectService.saveOrUpdateDto(dto); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
} |
@ -0,0 +1,18 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/4/25 9:29 |
||||
|
*/ |
||||
|
@ApiModel(value = "项目信息 视图数据对象", description = "项目信息 视图数据对象") |
||||
|
@Data |
||||
|
public class ProjectInformationVo implements Vo { |
||||
|
private String sid; |
||||
|
//项目名称
|
||||
|
private String entryName; |
||||
|
} |
@ -0,0 +1,77 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableField; |
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
|
import com.yxt.common.core.domain.BaseEntity; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUser.java <br/> |
||||
|
* Class: SysUser <br/> |
||||
|
* Description: 用户表. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@ApiModel(value = "用户表", description = "用户表") |
||||
|
@TableName("sys_user") |
||||
|
@Data |
||||
|
public class SysUser extends BaseEntity { |
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
|
||||
|
@ApiModelProperty("登录名,登录名不能相同") |
||||
|
private String userName; |
||||
|
|
||||
|
@ApiModelProperty("密码(加密或签名后)") |
||||
|
private String password; |
||||
|
|
||||
|
@ApiModelProperty("密码修改时限") |
||||
|
private String pwdDayslimit; |
||||
|
|
||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") |
||||
|
@ApiModelProperty("最后一次密码修改时间") |
||||
|
private Date pwdModifyTime; |
||||
|
|
||||
|
@ApiModelProperty("在线状态(0为离线、1为在线)") |
||||
|
private Integer onlineState; |
||||
|
|
||||
|
@ApiModelProperty("用户登录时随机生成身份验证字符串") |
||||
|
private String token; |
||||
|
|
||||
|
@ApiModelProperty("是否是管理员:1管理员,2一般用户,0是超级管理员,3尚无单位人员") |
||||
|
private String isAdmin; |
||||
|
|
||||
|
@ApiModelProperty("手机登录唯一标识,手机与用户绑定字段") |
||||
|
private String appId; |
||||
|
|
||||
|
@ApiModelProperty("关联的人员sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
@ApiModelProperty("手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@ApiModelProperty("用户类型:1员工、2客户、3供应商") |
||||
|
private Integer userType; |
||||
|
|
||||
|
@ApiModelProperty("用户头像") |
||||
|
private String headImage; |
||||
|
private String openId; |
||||
|
private String appletOpenid; |
||||
|
@TableField(exist = false) |
||||
|
private List<String> roleNames; |
||||
|
private String unionid; |
||||
|
//d订阅状态
|
||||
|
private String subscriptionStatus; |
||||
|
} |
@ -0,0 +1,42 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUserDto.java <br/> |
||||
|
* Class: SysUserDto <br/> |
||||
|
* Description: 用户表 数据传输对象. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@ApiModel(value = "用户表 数据传输对象", description = "用户表 数据传输对象") |
||||
|
@Data |
||||
|
public class SysUserDto implements Dto { |
||||
|
@ApiModelProperty("手机号") |
||||
|
private String mobile; |
||||
|
@ApiModelProperty("用户类型:1员工、2客户、3供应商") |
||||
|
private Integer userType; |
||||
|
@ApiModelProperty(value = "姓名", required = true) |
||||
|
//@NotBlank(message = "姓名不能为空")
|
||||
|
private String name; |
||||
|
@ApiModelProperty(value = "验证码", required = true) |
||||
|
//@NotBlank(message = "验证码不能为空")
|
||||
|
private String verificationCode; |
||||
|
@ApiModelProperty(value = "部门sid") |
||||
|
private String deptSid; |
||||
|
@ApiModelProperty(value = "岗位sid") |
||||
|
private String postSid; |
||||
|
private String bankMessageSid; |
||||
|
private String openid; |
||||
|
private String sid; |
||||
|
} |
@ -0,0 +1,30 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/2/9 9:12 |
||||
|
* @Description 用户组织信息 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SysUserInfoVo implements Vo { |
||||
|
|
||||
|
private static final long serialVersionUID = 7931121025686046432L; |
||||
|
@ApiModelProperty("关联的员工sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
@ApiModelProperty("关联的员工名称") |
||||
|
private String staffName; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织sid(多个时为第一个)") |
||||
|
private String orgSid; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织名称(多个时为第一个)") |
||||
|
private String orgName; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织部门编码") |
||||
|
private String orgCode; |
||||
|
} |
@ -0,0 +1,19 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/9/14 15:36 |
||||
|
* @Description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SysUserListVo implements Vo { |
||||
|
private static final long serialVersionUID = -3047907553025391436L; |
||||
|
|
||||
|
private String name; |
||||
|
|
||||
|
private String sid; |
||||
|
|
||||
|
} |
@ -0,0 +1,51 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUserQuery.java <br/> |
||||
|
* Class: SysUserQuery <br/> |
||||
|
* Description: 用户表 查询条件. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@ApiModel(value = "用户表 查询条件", description = "用户表 查询条件") |
||||
|
@Data |
||||
|
public class SysUserQuery implements Query { |
||||
|
|
||||
|
|
||||
|
@ApiModelProperty("角色sid") |
||||
|
private String roleSid; |
||||
|
@ApiModelProperty("用户名称") |
||||
|
private String userName; |
||||
|
@ApiModelProperty("姓名") |
||||
|
private String name; |
||||
|
@ApiModelProperty("部门名称") |
||||
|
private String orgName; |
||||
|
|
||||
|
@ApiModelProperty("密码(加密或签名后)") |
||||
|
private String password; |
||||
|
|
||||
|
@ApiModelProperty("用户登录时随机生成身份验证字符串") |
||||
|
private String token; |
||||
|
@ApiModelProperty("用户登录时随机生成的验证码字符串") |
||||
|
private String verifyCode; |
||||
|
private String uuid; |
||||
|
|
||||
|
@ApiModelProperty("手机登录唯一标识,手机与用户绑定字段") |
||||
|
private String appId; |
||||
|
@ApiModelProperty("手机登录类型:1、密码登录2、验证码登录") |
||||
|
private String type; |
||||
|
@ApiModelProperty(value = "是否是测试",example = "false") |
||||
|
private Boolean isTest; |
||||
|
} |
@ -0,0 +1,197 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import cn.hutool.core.bean.BeanUtil; |
||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
|
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
|
import com.wh.service.sysuser.SysUserService; |
||||
|
import com.yxt.common.base.config.RedisUtil; |
||||
|
import com.yxt.common.base.config.component.FileUploadComponent; |
||||
|
import com.yxt.common.base.utils.Encodes; |
||||
|
import com.yxt.common.core.query.PagerQuery; |
||||
|
import com.yxt.common.core.result.FileUploadResult; |
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import com.yxt.common.core.vo.PagerVo; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.apache.commons.lang3.StringUtils; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
import org.springframework.web.multipart.MultipartFile; |
||||
|
|
||||
|
import javax.servlet.http.HttpServletRequest; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
import java.util.UUID; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUserFeignFallback.java <br/> |
||||
|
* Class: SysUserRest <br/> |
||||
|
* Description: 用户表. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Api(tags = "用户表") |
||||
|
@RestController |
||||
|
@RequestMapping("v1/sysuser") |
||||
|
public class SysUserRest { |
||||
|
@Autowired |
||||
|
private RedisUtil redisUtil; |
||||
|
@Autowired |
||||
|
private SysUserService sysUserService; |
||||
|
@Autowired |
||||
|
private FileUploadComponent fileUploadComponent; |
||||
|
// 定义点选文字图片验证码允许的误差值
|
||||
|
private static final int ERROR_AMOUNT = 50;// 定义允许的误差值,单位是px
|
||||
|
@ApiOperation("根据条件分页查询数据的列表 ") |
||||
|
@PostMapping("/listPage") |
||||
|
public ResultBean<PagerVo<SysUserVo>> listPage(@RequestBody PagerQuery<SysUserQuery> pq) { |
||||
|
ResultBean rb = ResultBean.fireFail();//roleSid
|
||||
|
PagerVo<SysUserVo> pv = sysUserService.listPageVo(pq); |
||||
|
return rb.success().setData(pv); |
||||
|
} |
||||
|
@ApiOperation("根据条件查询所有数据列表") |
||||
|
@PostMapping("/listAll") |
||||
|
public ResultBean<List<SysUserVo>> listAll(@RequestBody SysUserQuery query) { |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<SysUserVo> list = sysUserService.listAllVo(query); |
||||
|
return rb.success().setData(list); |
||||
|
} |
||||
|
@ApiOperation("所有数据列表") |
||||
|
@GetMapping("/list") |
||||
|
public ResultBean<List<SysUserVo>> list() { |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
List<SysUserVo> list = sysUserService.listVo(); |
||||
|
return rb.success().setData(list); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("/saveOpenId") |
||||
|
public ResultBean saveOpenId(@RequestBody SysUserDto dto){ |
||||
|
ResultBean rb=new ResultBean(); |
||||
|
SysUser sysUser=sysUserService.getOne(new QueryWrapper<SysUser>().eq("sid",dto.getSid())); |
||||
|
sysUser.setOpenId(dto.getOpenid()); |
||||
|
sysUserService.update(sysUser,new QueryWrapper<SysUser>().eq("sid",dto.getSid())); |
||||
|
return rb.success().setMsg("保存成功"); |
||||
|
} |
||||
|
@PostMapping("/saveBank") |
||||
|
public ResultBean saveBank(@RequestBody SysUserDto dto) { |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
//手机号
|
||||
|
String mobile = dto.getMobile(); |
||||
|
//姓名
|
||||
|
String name = dto.getName(); |
||||
|
//用户类型
|
||||
|
int userType = dto.getUserType(); |
||||
|
//部门sid
|
||||
|
if (StringUtils.isBlank(mobile)) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("手机号不能为空"); |
||||
|
} else { |
||||
|
SysUser one = sysUserService.fetchByUserName(mobile); |
||||
|
if (null != one) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("手机号重复!`"); |
||||
|
} |
||||
|
} |
||||
|
if (StringUtils.isBlank(name)) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("姓名不能为空"); |
||||
|
} |
||||
|
if (userType == 0) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("用户类型不能为空"); |
||||
|
} |
||||
|
String password = mobile.substring(5, 11); |
||||
|
String md5 = Encodes.md5(password); |
||||
|
SysUser su = new SysUser(); |
||||
|
dto.fillEntity(su); |
||||
|
su.setSid(UUID.randomUUID().toString()); |
||||
|
su.setStaffSid(dto.getBankMessageSid()); |
||||
|
su.setUserName(mobile); |
||||
|
su.setPassword(md5); |
||||
|
sysUserService.save(su); |
||||
|
return rb.success(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("/getUserBySid") |
||||
|
public ResultBean<SysUser> getUserBySid(@RequestParam("sid")String sid) { |
||||
|
SysUser sysUser = sysUserService.getUserBySid(sid); |
||||
|
return new ResultBean().success().setData(sysUser); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("/login") |
||||
|
@ResponseBody |
||||
|
@ApiOperation(value = "3、登录") |
||||
|
@ApiOperationSupport(order = 30) |
||||
|
public ResultBean<SysUserVo> login(@RequestBody SysUserQuery userQuery) { |
||||
|
String userName = userQuery.getUserName(); |
||||
|
String password = userQuery.getPassword(); |
||||
|
// 遍历其中的map,取出每个属性值
|
||||
|
if (StringUtils.isBlank(userName)) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("用户名不能为空"); |
||||
|
} |
||||
|
if (StringUtils.isBlank(password)) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("密码不能为空"); |
||||
|
} |
||||
|
SysUser user = null; |
||||
|
// 验证通过之后删除redis上的验证过的该条uuid
|
||||
|
String md5 = Encodes.md5(password); |
||||
|
user = sysUserService.selectByUserNameAndPassword(userName,md5); |
||||
|
if (user == null) { |
||||
|
return new ResultBean<SysUserVo>().fail().setMsg("用户名或密码错误"); |
||||
|
} |
||||
|
// 根据用户信息查询用户的角色信息
|
||||
|
SysUserVo userInfoOneVo = new SysUserVo();//sysUserService.setUserRedisSessionToken(user);
|
||||
|
BeanUtil.copyProperties(user,userInfoOneVo); |
||||
|
return new ResultBean<SysUserVo>().success().setData(userInfoOneVo); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* 退出登录 |
||||
|
* |
||||
|
* @return |
||||
|
*/ |
||||
|
@PostMapping("/signOut") |
||||
|
@ResponseBody |
||||
|
@ApiOperation(value = "退出登录") |
||||
|
@ApiOperationSupport(order = 30) |
||||
|
public ResultBean signOut(HttpServletRequest httpServletRequest) { |
||||
|
String token = httpServletRequest.getHeader("token"); |
||||
|
String redisToken = redisUtil.get(token); |
||||
|
if (StringUtils.isBlank(redisToken)) { |
||||
|
return ResultBean.fireSuccess().setMsg("您已退出,请刷新"); |
||||
|
} |
||||
|
redisUtil.remove(token); |
||||
|
return ResultBean.fireSuccess().setMsg("退出成功"); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@GetMapping("getUserByType") |
||||
|
public ResultBean getUserByType(@RequestParam("userType") String userType){ |
||||
|
return sysUserService.getUserByType(userType); |
||||
|
} |
||||
|
@GetMapping("getUserOrgBySid") |
||||
|
public ResultBean getUserOrgBySid(@RequestParam("sid") String sid){ |
||||
|
return sysUserService.getUserOrgBySid(sid); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("/uploadfile") |
||||
|
public ResultBean<FileUploadResult> uploadImage(@RequestParam(value = "file") MultipartFile file) { |
||||
|
ResultBean rb = ResultBean.fireFail(); |
||||
|
if (file == null || file.isEmpty()) { |
||||
|
return rb.setMsg("文件为空"); |
||||
|
} |
||||
|
rb = fileUploadComponent.uploadFile(file, null); |
||||
|
return rb; |
||||
|
} |
||||
|
|
||||
|
@PostMapping("/uploadImage") |
||||
|
public ResultBean updateSysUserImage(@RequestBody Map<String, String> map){ |
||||
|
return sysUserService.updateSysUserImage(map); |
||||
|
} |
||||
|
@PostMapping("/getUsersBySid") |
||||
|
public ResultBean<List<SysUser>> getUsersBySid(@RequestBody List<String> list){ |
||||
|
return sysUserService.getUsersBySid(list); |
||||
|
} |
||||
|
} |
@ -0,0 +1,15 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author feikefei |
||||
|
* @create 2023-08-18-17:19 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SysUserUpdate { |
||||
|
private String original; |
||||
|
private String password; |
||||
|
private String confirmPassword; |
||||
|
private String userSid; |
||||
|
} |
@ -0,0 +1,94 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
|
||||
|
import com.fasterxml.jackson.annotation.JsonProperty; |
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
import lombok.NoArgsConstructor; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUserVo.java <br/> |
||||
|
* Class: SysUserVo <br/> |
||||
|
* Description: 用户表 视图数据对象. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@ApiModel(value = "用户表 视图数据对象", description = "用户表 视图数据对象") |
||||
|
@Data |
||||
|
@NoArgsConstructor |
||||
|
public class SysUserVo implements Vo { |
||||
|
private static final long serialVersionUID = 2415131854581950721L; |
||||
|
@ApiModelProperty("部门sid") |
||||
|
private String departmentSid; |
||||
|
@ApiModelProperty("部门名称") |
||||
|
private String departmentName; |
||||
|
@ApiModelProperty("上级部门名称-本级部门名称 岗位名称") |
||||
|
@JsonProperty("pNameAndDepartmentNameAndPostName") |
||||
|
private String pNameAndDepartmentNameAndPostName; |
||||
|
@ApiModelProperty("岗位名称") |
||||
|
private String postName; |
||||
|
@ApiModelProperty("岗位Sid") |
||||
|
private String postSid; |
||||
|
@ApiModelProperty("单位sid") |
||||
|
private String organizationSid; |
||||
|
@ApiModelProperty("单位名称") |
||||
|
private String organizationName; |
||||
|
@ApiModelProperty("用户姓名") |
||||
|
private String name; |
||||
|
@ApiModelProperty("登录名,登录名不能相同") |
||||
|
private String userName; |
||||
|
|
||||
|
@ApiModelProperty("id") |
||||
|
private Integer id; |
||||
|
@ApiModelProperty("用户sid") |
||||
|
private String sid; |
||||
|
@ApiModelProperty("是否是管理员:1管理员,2一般用户,0是超级管理员,3尚无单位人员") |
||||
|
private String isAdmin; |
||||
|
@ApiModelProperty("角色名称") |
||||
|
private String roleName; |
||||
|
|
||||
|
@ApiModelProperty("关联的人员sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
@ApiModelProperty("手机号") |
||||
|
private String mobile; |
||||
|
@ApiModelProperty(value = "禁用状态") |
||||
|
private String isEnable; |
||||
|
|
||||
|
@ApiModelProperty("用户类型:1员工、2客户、3供应商") |
||||
|
private String userType; |
||||
|
@ApiModelProperty("用户类型:1、2、3") |
||||
|
private String userTypeKey; |
||||
|
@ApiModelProperty("用户头像") |
||||
|
private String headImage; |
||||
|
@ApiModelProperty("组织名称") |
||||
|
private String orgNamePath; |
||||
|
@ApiModelProperty("组织sid") |
||||
|
private String orgSidPath; |
||||
|
@ApiModelProperty(value = "token") |
||||
|
private String token; |
||||
|
@ApiModelProperty(value = "角色sids") |
||||
|
private List<String> roleSids = new ArrayList<>(); |
||||
|
|
||||
|
private String defaultOrgPath; |
||||
|
private String defaultOrgPathName; |
||||
|
|
||||
|
@ApiModelProperty("是否需要更换密码") |
||||
|
private Boolean needResetPsd; |
||||
|
@ApiModelProperty("工号") |
||||
|
private String jobNumber; |
||||
|
private String openid; |
||||
|
@ApiModelProperty("项目sid集合") |
||||
|
private List<ProjectInformationVo> projectSidList; |
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/6/21 8:47 |
||||
|
* @Description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class UserQuery implements Query { |
||||
|
|
||||
|
private static final long serialVersionUID = -3979717077029562761L; |
||||
|
@ApiModelProperty(value = "角色sid必传项") |
||||
|
private String roleSid; |
||||
|
@ApiModelProperty(value = "用户部门sid路径是必传项") |
||||
|
private String orgSidPath; |
||||
|
|
||||
|
} |
@ -0,0 +1,19 @@ |
|||||
|
package com.wh.controller.sysuser; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/8/25 8:38 |
||||
|
* @Description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class UserRoleQuery implements Query { |
||||
|
private static final long serialVersionUID = 1913450300189800653L; |
||||
|
|
||||
|
@ApiModelProperty("角色sid") |
||||
|
private String roleSid; |
||||
|
private String orgSid; |
||||
|
} |
@ -0,0 +1,28 @@ |
|||||
|
package com.wh.controller.sysuser.app; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Description |
||||
|
* @Author liuguohui |
||||
|
* @Date 2021/9/14 |
||||
|
*/ |
||||
|
@ApiOperation(value = "App我的信息") |
||||
|
@Data |
||||
|
public class AppMySysUserInfo implements Vo { |
||||
|
|
||||
|
@ApiModelProperty("id") |
||||
|
private String id; |
||||
|
@ApiModelProperty("用户姓名") |
||||
|
private String name; |
||||
|
@ApiModelProperty("用户头像") |
||||
|
private String headImage; |
||||
|
|
||||
|
@ApiModelProperty("职位") |
||||
|
private String position; |
||||
|
@ApiModelProperty("部门") |
||||
|
private String department; |
||||
|
} |
@ -0,0 +1,34 @@ |
|||||
|
package com.wh.controller.sysuser.app; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Description |
||||
|
* @Author liuguohui |
||||
|
* @Date 2021/12/17 |
||||
|
*/ |
||||
|
@ApiOperation("用户组织信息") |
||||
|
@Data |
||||
|
public class AppUserOrgInfoVo implements Vo { |
||||
|
|
||||
|
@ApiModelProperty("关联的员工sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
@ApiModelProperty("关联的员工名称") |
||||
|
private String staffName; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织sid(多个时为第一个)") |
||||
|
private String orgSid; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织名称(多个时为第一个)") |
||||
|
private String orgName; |
||||
|
|
||||
|
@ApiModelProperty("员工的组织部门编码") |
||||
|
private String orgCode; |
||||
|
|
||||
|
@ApiModelProperty("部门路径") |
||||
|
private String orgSidPath; |
||||
|
} |
@ -0,0 +1,19 @@ |
|||||
|
package com.wh.controller.sysuser.app; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/10/22 15:24 |
||||
|
* @Description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class MyInfoQuery implements Query { |
||||
|
private static final long serialVersionUID = -4771501933318214145L; |
||||
|
@ApiModelProperty("用户sid") |
||||
|
private String userSid; |
||||
|
@ApiModelProperty("组织机构sid") |
||||
|
private String orgPath; |
||||
|
} |
@ -0,0 +1,17 @@ |
|||||
|
package com.wh.controller.sysuser.app; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author dimengzhe |
||||
|
* @Date 2022/9/21 9:26 |
||||
|
* @Description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class OrgList implements Vo { |
||||
|
private static final long serialVersionUID = -2867882982421321776L; |
||||
|
|
||||
|
private String orgName; |
||||
|
private String orgPath; |
||||
|
} |
@ -0,0 +1,15 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
@Data |
||||
|
public class SmsVerifyCodeQuery implements Query { |
||||
|
@ApiModelProperty("手机号码") |
||||
|
private String mobile; |
||||
|
@ApiModelProperty("手机验证码") |
||||
|
private String code; |
||||
|
@ApiModelProperty("调用定位") |
||||
|
String callLocation; |
||||
|
} |
@ -0,0 +1,15 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
@Data |
||||
|
public class SysUserLoginVo implements Vo { |
||||
|
@ApiModelProperty(value = "用户Sid") |
||||
|
private String sysUserSid; |
||||
|
@ApiModelProperty(value = "用户登录时随机生成身份验证字符串") |
||||
|
private String token; |
||||
|
@ApiModelProperty(value = "是否登陆") |
||||
|
private Boolean isLogin; |
||||
|
} |
@ -0,0 +1,18 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
@Data |
||||
|
public class SysUserWxBindMobileDto implements Dto { |
||||
|
@ApiModelProperty(value = "用户登陆授权Sid") |
||||
|
private String sysUserWxAuthSid; |
||||
|
@ApiModelProperty(value = "手机号") |
||||
|
private String mobile; |
||||
|
@ApiModelProperty(value = "验证码") |
||||
|
private String code; |
||||
|
//微信id
|
||||
|
private String openid; |
||||
|
private String unionid; |
||||
|
} |
@ -0,0 +1,27 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author dimengzhe |
||||
|
* @date 2021/10/12 10:53 |
||||
|
* @description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class WxHomePageVo implements Vo { |
||||
|
private static final long serialVersionUID = 2116719971434282451L; |
||||
|
@ApiModelProperty(value = "头像") |
||||
|
private String headImage; |
||||
|
|
||||
|
@ApiModelProperty(value = "提醒") |
||||
|
private String message; |
||||
|
|
||||
|
@ApiModelProperty(value = "身份证有效期") |
||||
|
private String idTerm; |
||||
|
@ApiModelProperty(value = "是否有提示") |
||||
|
private Boolean isHave; |
||||
|
@ApiModelProperty(value = "客户sid") |
||||
|
private String staffSid; |
||||
|
} |
@ -0,0 +1,23 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.utils.desensitized.Sensitive; |
||||
|
import com.yxt.common.core.utils.desensitized.SensitiveTypeEnum; |
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author dimengzhe |
||||
|
* @date 2021/10/6 9:12 |
||||
|
* @description 客户端我的页面 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class WxMySysUserInfoVo implements Vo { |
||||
|
private static final long serialVersionUID = 6495105262502269503L; |
||||
|
|
||||
|
@ApiModelProperty(value = "姓名") |
||||
|
@Sensitive(type = SensitiveTypeEnum.CHINESE_NAME) |
||||
|
private String name; |
||||
|
@ApiModelProperty(value = "头像") |
||||
|
private String headImage; |
||||
|
} |
@ -0,0 +1,33 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import javax.validation.constraints.Pattern; |
||||
|
|
||||
|
/** |
||||
|
* @author dimengzhe |
||||
|
* @date 2021/10/5 13:31 |
||||
|
* @description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class WxSysUserDto implements Dto { |
||||
|
private static final long serialVersionUID = -3446342255009165324L; |
||||
|
|
||||
|
@ApiModelProperty(value = "手机号", required = true) |
||||
|
@NotBlank(message = "手机号不能为空") |
||||
|
@Pattern(regexp = "^((13[0-9])|(14[5,7])|(15[0-3,5-9])|(17[0,3,5-8])|(18[0-9])|166|198|199|(147))\\d{8}$", message = "手机号码格式不正确") |
||||
|
private String mobile; |
||||
|
@ApiModelProperty(value = "验证码", required = true) |
||||
|
@NotBlank(message = "验证码不能为空") |
||||
|
private String verificationCode; |
||||
|
@ApiModelProperty(value = "姓名", required = true) |
||||
|
@NotBlank(message = "姓名不能为空") |
||||
|
private String name; |
||||
|
@ApiModelProperty(value = "身份证号", required = true) |
||||
|
@NotBlank(message = "身份证号不能为空") |
||||
|
private String idNo; |
||||
|
|
||||
|
} |
@ -0,0 +1,29 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
|
||||
|
/** |
||||
|
* @author dimengzhe |
||||
|
* @date 2021/10/6 14:31 |
||||
|
* @description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class WxSysUserLoginQuery implements Query { |
||||
|
private static final long serialVersionUID = -3754864114501469472L; |
||||
|
@ApiModelProperty(value = "用户名或手机号", required = true) |
||||
|
@NotBlank(message = "用户名不能为空") |
||||
|
private String userName; |
||||
|
@ApiModelProperty(value = "手机登录类型:1、密码登录,2、验证码登录", required = true) |
||||
|
@NotBlank(message = "手机登录类型不能为空") |
||||
|
private String type; |
||||
|
|
||||
|
@ApiModelProperty(value = "密码") |
||||
|
private String password; |
||||
|
|
||||
|
@ApiModelProperty(value = "验证码") |
||||
|
private String verifyCode; |
||||
|
} |
@ -0,0 +1,38 @@ |
|||||
|
package com.wh.controller.sysuser.wx; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author dimengzhe |
||||
|
* @date 2021/10/6 14:52 |
||||
|
* @description |
||||
|
*/ |
||||
|
@Data |
||||
|
public class WxSysUserVo implements Vo { |
||||
|
private static final long serialVersionUID = 1700823767702299465L; |
||||
|
/*若为员工,则为人员sid。若为客户,则为客户sid。若为供应厂商,则为供应厂商的sid*/ |
||||
|
@ApiModelProperty(value = "关联的客户sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
@ApiModelProperty(value = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@ApiModelProperty(value = "用户类型:1员工、2客户、3供应商") |
||||
|
private String userType; |
||||
|
|
||||
|
@ApiModelProperty(value = "用户sid") |
||||
|
private String userSid; |
||||
|
|
||||
|
@ApiModelProperty(value = "登录名,登录名不能相同") |
||||
|
private String userName; |
||||
|
@ApiModelProperty(value = "用户姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@ApiModelProperty(value = "token") |
||||
|
private String token; |
||||
|
|
||||
|
@ApiModelProperty(value = "未读数量",example = "1") |
||||
|
private String num; |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Rights; |
||||
|
|
||||
|
public interface RightsMapper extends BaseMapper<Rights> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.User; |
||||
|
|
||||
|
public interface UserMapper extends BaseMapper<User> { |
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.wh.mapper.api.instorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.api.InStorehouseListing; |
||||
|
|
||||
|
|
||||
|
public interface InStorehouseListingMapper extends BaseMapper<InStorehouseListing> { |
||||
|
} |
@ -0,0 +1,17 @@ |
|||||
|
package com.wh.mapper.api.instorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.api.InStoreHouseMainVo; |
||||
|
import com.wh.pojo.api.InStorehouseMain; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
|
||||
|
@Mapper |
||||
|
public interface InStorehouseMainMapper extends BaseMapper<InStorehouseMain> { |
||||
|
IPage<InStoreHouseMainVo> selectPageVo(IPage<InStoreHouseMainVo> page, |
||||
|
@Param(Constants.WRAPPER) Wrapper<InStoreHouseMainVo> qw); |
||||
|
|
||||
|
} |
@ -0,0 +1,12 @@ |
|||||
|
package com.wh.mapper.api.outstorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.api.OutStorehouseListing; |
||||
|
import org.apache.ibatis.annotations.Delete; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
|
||||
|
|
||||
|
public interface OutStorehouseListingMapper extends BaseMapper<OutStorehouseListing> { |
||||
|
@Delete("delete from out_storehouse_listing where main_sid=#{mainSid}") |
||||
|
int deleteByMainSid(@Param("mainSid") String sid); |
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
package com.wh.mapper.api.outstorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.api.OutStorehouseMain; |
||||
|
import com.wh.pojo.api.OutStorehouseVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
@Mapper |
||||
|
public interface OutStorehouseMainMapper extends BaseMapper<OutStorehouseMain> { |
||||
|
IPage<OutStorehouseVo> selectPageVo(IPage<OutStorehouseVo> page, |
||||
|
@Param(Constants.WRAPPER) Wrapper<OutStorehouseVo> qw); |
||||
|
@Select("select * from out_storehouse_main where state=1 and custer_sid=#{custerSid};") |
||||
|
List<OutStorehouseMain> listAllForPicking(@Param("custerSid")String custerSid); |
||||
|
} |
@ -0,0 +1,22 @@ |
|||||
|
package com.wh.mapper.api.prodstock; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.api.InStorehouseMain; |
||||
|
import com.wh.pojo.api.ProdStock; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Update; |
||||
|
|
||||
|
|
||||
|
public interface ProdStockMapper extends BaseMapper<ProdStock> { |
||||
|
@Update("update prod_stock set num=num-#{num} , calculated_value=(num*confirmed_price) where pro_sid=#{proSid} and custer_sid=#{custerSid}") |
||||
|
void reduceNumByProdSidAndCustSid(@Param("proSid") String proSid, @Param("custerSid")String custerSid, |
||||
|
@Param("num")String num); |
||||
|
@Update("update prod_stock set num=num+#{num}, calculated_value=(num*confirmed_price) " + |
||||
|
" where pro_sid=#{proSid} and custer_sid=#{custerSid} and store_house_sid=#{storehousesid}" + |
||||
|
" and location_number=#{locationnum}") |
||||
|
void addNumByProdSidAndCustSid(@Param("proSid")String proSid, @Param("custerSid")String custerSid, |
||||
|
@Param("num")String num, @Param("storehousesid")String storehousesid, |
||||
|
@Param("locationnum")String locationnum); |
||||
|
@Update("update prod_stock set num=#{num} , calculated_value=#{value} where id=#{id} ") |
||||
|
void updateByProdStockId(@Param("num")String num, @Param("value")String value, @Param("id")int id); |
||||
|
} |
@ -0,0 +1,69 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.brandinfo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.brandinfo.BrandInfo; |
||||
|
import com.wh.pojo.brandinfo.BrandInfoVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: BrandInfoMapper.java <br/> |
||||
|
* Class: com.supervise.biz.brandinfo.BrandInfoMapper <br/> |
||||
|
* Description: 品牌信息. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:28 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface BrandInfoMapper extends BaseMapper<BrandInfo> { |
||||
|
|
||||
|
//@Update("update brand_info set name=#{msg} where id=#{id}")
|
||||
|
//IPage<BrandInfoVo> voPage(IPage<BrandInfo> page, @Param(Constants.WRAPPER) QueryWrapper<BrandInfo> qw);
|
||||
|
|
||||
|
IPage<BrandInfoVo> selectPageVo(IPage<BrandInfo> page, @Param(Constants.WRAPPER) Wrapper<BrandInfo> qw); |
||||
|
|
||||
|
List<BrandInfoVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<BrandInfo> qw); |
||||
|
|
||||
|
@Select("select * from brand_info") |
||||
|
List<BrandInfoVo> selectListVo(); |
||||
|
@Select("select * from brand_info where code=#{code}") |
||||
|
BrandInfoVo selectByCode(String code); |
||||
|
@Select("select name,code from restricted_brand where code=#{code} group by name") |
||||
|
BrandInfo fetchByCodeForLimit(String brandSid); |
||||
|
} |
@ -0,0 +1,73 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.dictcommon; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.dictcommon.DictCommon; |
||||
|
import com.wh.pojo.dictcommon.DictCommonDetailsVo; |
||||
|
import com.wh.pojo.dictcommon.DictCommonVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: DictCommonMapper.java <br/> |
||||
|
* Class: com.supervise.biz.dictcommon.DictCommonMapper <br/> |
||||
|
* Description: 数据字典——数据项. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:29 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface DictCommonMapper extends BaseMapper<DictCommon> { |
||||
|
|
||||
|
//@Update("update dict_common set name=#{msg} where id=#{id}")
|
||||
|
//IPage<DictCommonVo> voPage(IPage<DictCommon> page, @Param(Constants.WRAPPER) QueryWrapper<DictCommon> qw);
|
||||
|
|
||||
|
IPage<DictCommonVo> selectPageVo(IPage<DictCommon> page, @Param(Constants.WRAPPER) Wrapper<DictCommon> qw); |
||||
|
|
||||
|
List<DictCommonVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<DictCommon> qw); |
||||
|
|
||||
|
@Select("select * from dict_common") |
||||
|
List<DictCommonVo> selectListVo(); |
||||
|
@Select("select * from dict_common where dictkey=#{key}") |
||||
|
DictCommonDetailsVo fetchByKey(@Param("key")String key); |
||||
|
@Select("select * from dict_common where dictkey=#{key} and dictType=#{type}") |
||||
|
DictCommonDetailsVo fetchByKeyAndType(@Param("key")String key, @Param("type")String type); |
||||
|
@Select("select * from restricted_category where dictkey=#{key} and dictType=#{type}") |
||||
|
DictCommonDetailsVo fetchByKeyAndTypeForLimit(@Param("type")String category, @Param("key")String categoryKey); |
||||
|
} |
@ -0,0 +1,65 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.dicttype; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.dicttype.DictType; |
||||
|
import com.wh.pojo.dicttype.DictTypeVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: DictTypeMapper.java <br/> |
||||
|
* Class: com.supervise.biz.dicttype.DictTypeMapper <br/> |
||||
|
* Description: 数据字典——数据类型. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-11-11 11:40:29 <br/> |
||||
|
* |
||||
|
* @author dongjianzhao |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface DictTypeMapper extends BaseMapper<DictType> { |
||||
|
|
||||
|
//@Update("update dict_type set name=#{msg} where id=#{id}")
|
||||
|
//IPage<DictTypeVo> voPage(IPage<DictType> page, @Param(Constants.WRAPPER) QueryWrapper<DictType> qw);
|
||||
|
|
||||
|
IPage<DictTypeVo> selectPageVo(IPage<DictType> page, @Param(Constants.WRAPPER) Wrapper<DictType> qw); |
||||
|
|
||||
|
List<DictTypeVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<DictType> qw); |
||||
|
|
||||
|
@Select("select * from dict_type") |
||||
|
List<DictTypeVo> selectListVo(); |
||||
|
} |
@ -0,0 +1,65 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.entinfo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.entinfo.EntInfo; |
||||
|
import com.wh.pojo.entinfo.EntInfoVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: warehouse(仓储) <br/> |
||||
|
* File: EntInfoMapper.java <br/> |
||||
|
* Class: com.wh.biz.entinfo.EntInfoMapper <br/> |
||||
|
* Description: 客户信息. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-13 22:19:45 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface EntInfoMapper extends BaseMapper<EntInfo> { |
||||
|
|
||||
|
//@Update("update ent_info set name=#{msg} where id=#{id}")
|
||||
|
//IPage<EntInfoVo> voPage(IPage<EntInfo> page, @Param(Constants.WRAPPER) QueryWrapper<EntInfo> qw);
|
||||
|
|
||||
|
IPage<EntInfoVo> selectPageVo(IPage<EntInfo> page, @Param(Constants.WRAPPER) Wrapper<EntInfo> qw); |
||||
|
|
||||
|
List<EntInfoVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<EntInfo> qw); |
||||
|
|
||||
|
@Select("select * from ent_info") |
||||
|
List<EntInfoVo> selectListVo(); |
||||
|
} |
@ -0,0 +1,16 @@ |
|||||
|
package com.wh.mapper.initial; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Location; |
||||
|
import com.wh.pojo.LocationVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
@Mapper |
||||
|
public interface LocationMapper extends BaseMapper<Location> { |
||||
|
@Select("select * from location ") |
||||
|
List<Location> listAll(); |
||||
|
@Select("select * from location where storehouseid=#{id};") |
||||
|
List<LocationVo> getLocationsByStoreId(String id); |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.initial; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.LocationType; |
||||
|
|
||||
|
public interface LocationTypeMapper extends BaseMapper<LocationType> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.initial; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Product; |
||||
|
|
||||
|
public interface ProductMapper extends BaseMapper<Product> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.initial; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Storehouse; |
||||
|
|
||||
|
public interface StorehouseMapper extends BaseMapper<Storehouse> { |
||||
|
} |
@ -0,0 +1,12 @@ |
|||||
|
package com.wh.mapper.initial; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Supplier; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
public interface SupplierMapper extends BaseMapper<Supplier> { |
||||
|
@Select("select * from supplier") |
||||
|
List<Supplier> listAll(); |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.instorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Purchase; |
||||
|
|
||||
|
public interface PurchaseMapper extends BaseMapper<Purchase> { |
||||
|
} |
@ -0,0 +1,8 @@ |
|||||
|
package com.wh.mapper.instorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.InStorehouse; |
||||
|
|
||||
|
|
||||
|
public interface PutInMapper extends BaseMapper<InStorehouse> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.instorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Receiving; |
||||
|
|
||||
|
public interface ReceivingMapper extends BaseMapper<Receiving> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.outstorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.OutStorehouse; |
||||
|
|
||||
|
public interface OutStorehouseMapper extends BaseMapper<OutStorehouse> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.outstorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Picking; |
||||
|
|
||||
|
public interface PickingMapper extends BaseMapper<Picking> { |
||||
|
} |
@ -0,0 +1,76 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.purchasenew; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.purchasenew.Purchasenew; |
||||
|
import com.wh.pojo.purchasenew.PurchasenewVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
import org.apache.ibatis.annotations.Update; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: warehouse(仓储) <br/> |
||||
|
* File: PurchasenewMapper.java <br/> |
||||
|
* Class: com.wh..biz.purchasenew.PurchasenewMapper <br/> |
||||
|
* Description: 采购订单. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-10 18:09:57 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface PurchasenewMapper extends BaseMapper<Purchasenew> { |
||||
|
|
||||
|
//@Update("update purchasenew set name=#{msg} where id=#{id}")
|
||||
|
//IPage<PurchasenewVo> voPage(IPage<Purchasenew> page, @Param(Constants.WRAPPER) QueryWrapper<Purchasenew> qw);
|
||||
|
|
||||
|
IPage<PurchasenewVo> selectPageVo(IPage<Purchasenew> page, @Param(Constants.WRAPPER) Wrapper<Purchasenew> qw); |
||||
|
|
||||
|
List<PurchasenewVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<Purchasenew> qw); |
||||
|
|
||||
|
@Select("select * from purchasenew") |
||||
|
List<PurchasenewVo> selectListVo(); |
||||
|
|
||||
|
/** |
||||
|
* 将采购订单的状态修改为已入库 |
||||
|
* @param sid |
||||
|
* @return |
||||
|
*/ |
||||
|
@Update("update purchasenew set status='2' where sid=#{sid}") |
||||
|
int updatePutInStatus(@Param("sid") String sid); |
||||
|
@Select("select * from purchasenew where state=1 ")//and cust_id=#{custId}
|
||||
|
List<Purchasenew> listForInput( String custId);//@Param("custId")
|
||||
|
} |
@ -0,0 +1,73 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.purchasenewproduct; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProduct; |
||||
|
import com.wh.pojo.purchasenewproduct.PurchasenewProductVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: warehouse(仓储) <br/> |
||||
|
* File: PurchasenewProductMapper.java <br/> |
||||
|
* Class: com.wh..biz.purchasenewproduct.PurchasenewProductMapper <br/> |
||||
|
* Description: purchasenew_product. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-10 18:09:57 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface PurchasenewProductMapper extends BaseMapper<PurchasenewProduct> { |
||||
|
|
||||
|
//@Update("update purchasenew_product set name=#{msg} where id=#{id}")
|
||||
|
//IPage<PurchasenewProductVo> voPage(IPage<PurchasenewProduct> page, @Param(Constants.WRAPPER) QueryWrapper<PurchasenewProduct> qw);
|
||||
|
|
||||
|
IPage<PurchasenewProductVo> selectPageVo(IPage<PurchasenewProduct> page, @Param(Constants.WRAPPER) Wrapper<PurchasenewProduct> qw); |
||||
|
|
||||
|
List<PurchasenewProductVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<PurchasenewProduct> qw); |
||||
|
|
||||
|
@Select("select * from purchasenew_product") |
||||
|
List<PurchasenewProductVo> selectListVo(); |
||||
|
|
||||
|
/** |
||||
|
* 根据采购订单的sid查询 对应的商品列表 |
||||
|
* @param sid |
||||
|
* @return |
||||
|
*/ |
||||
|
@Select("select * from purchasenew_product where main_sid=#{sid}") |
||||
|
List<PurchasenewProductVo> fetchDetailsVoByPurchaseSid(String sid); |
||||
|
} |
@ -0,0 +1,75 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.shstorehouse; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.shstorehouse.ShStorehouse; |
||||
|
import com.wh.pojo.shstorehouse.ShStorehouseVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
import org.apache.ibatis.annotations.Update; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseMapper.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouse.ShStorehouseMapper <br/> |
||||
|
* Description: 库房信息表. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ShStorehouseMapper extends BaseMapper<ShStorehouse> { |
||||
|
|
||||
|
//@Update("update sh_storehouse set name=#{msg} where id=#{id}")
|
||||
|
//IPage<ShStorehouseVo> voPage(IPage<ShStorehouse> page, @Param(Constants.WRAPPER) QueryWrapper<ShStorehouse> qw);
|
||||
|
|
||||
|
IPage<ShStorehouseVo> selectPageVo(IPage<ShStorehouse> page, @Param(Constants.WRAPPER) Wrapper<ShStorehouse> qw); |
||||
|
|
||||
|
List<ShStorehouseVo> selectSh(List<String> list); |
||||
|
@Select("select * from sh_storehouse where sid=#{shSid}") |
||||
|
ShStorehouseVo selectStoreBySid(@Param("shSid")String shSid); |
||||
|
@Select("select * from storehouse_project p left join sh_storehouse s on s.sid=p.sh_sid where p.project_sid=#{sid}") |
||||
|
List<ShStorehouseVo> getStorehouseBySid(@Param("sid") String sid); |
||||
|
|
||||
|
List<ShStorehouseVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<ShStorehouse> qw); |
||||
|
|
||||
|
@Select("select * from sh_storehouse") |
||||
|
List<ShStorehouseVo> selectListVo(); |
||||
|
|
||||
|
@Update("update sh_storehouse set picurl=#{url} where sid=#{sid} ") |
||||
|
int updatePicUrl(@Param("sid")String sid,@Param("url") String url); |
||||
|
} |
@ -0,0 +1,68 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.shstorehouseattachment; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachment; |
||||
|
import com.wh.pojo.shstorehouseattachment.ShStorehouseAttachmentVo; |
||||
|
import org.apache.ibatis.annotations.Delete; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseAttachmentMapper.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouseattachment.ShStorehouseAttachmentMapper <br/> |
||||
|
* Description: 库房附件,如合同,图片等. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ShStorehouseAttachmentMapper extends BaseMapper<ShStorehouseAttachment> { |
||||
|
|
||||
|
//@Update("update sh_storehouse_attachment set name=#{msg} where id=#{id}")
|
||||
|
//IPage<ShStorehouseAttachmentVo> voPage(IPage<ShStorehouseAttachment> page, @Param(Constants.WRAPPER) QueryWrapper<ShStorehouseAttachment> qw);
|
||||
|
|
||||
|
IPage<ShStorehouseAttachmentVo> selectPageVo(IPage<ShStorehouseAttachment> page, @Param(Constants.WRAPPER) Wrapper<ShStorehouseAttachment> qw); |
||||
|
|
||||
|
List<ShStorehouseAttachmentVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<ShStorehouseAttachment> qw); |
||||
|
|
||||
|
@Select("select * from sh_storehouse_attachment") |
||||
|
List<ShStorehouseAttachmentVo> selectListVo(); |
||||
|
@Delete("delete from sh_storehouse_attachment where storehouse_sid=#{shsid}") |
||||
|
void deleteByHouseSid(@Param("shsid") String dtoSid); |
||||
|
} |
@ -0,0 +1,65 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.wh.mapper.shstorehouseattribute; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttribute; |
||||
|
import com.wh.pojo.shstorehouseattribute.ShStorehouseAttributeVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: yxt_supervise(宇信通监管) <br/> |
||||
|
* File: ShStorehouseAttributeMapper.java <br/> |
||||
|
* Class: com.wh.biz.shstorehouseattribute.ShStorehouseAttributeMapper <br/> |
||||
|
* Description: 库房性质. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2023-06-14 23:18:54 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ShStorehouseAttributeMapper extends BaseMapper<ShStorehouseAttribute> { |
||||
|
|
||||
|
//@Update("update sh_storehouse_attribute set name=#{msg} where id=#{id}")
|
||||
|
//IPage<ShStorehouseAttributeVo> voPage(IPage<ShStorehouseAttribute> page, @Param(Constants.WRAPPER) QueryWrapper<ShStorehouseAttribute> qw);
|
||||
|
|
||||
|
IPage<ShStorehouseAttributeVo> selectPageVo(IPage<ShStorehouseAttribute> page, @Param(Constants.WRAPPER) Wrapper<ShStorehouseAttribute> qw); |
||||
|
|
||||
|
List<ShStorehouseAttributeVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<ShStorehouseAttribute> qw); |
||||
|
|
||||
|
@Select("select * from sh_storehouse_attribute") |
||||
|
List<ShStorehouseAttributeVo> selectListVo(); |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.stock; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Stock; |
||||
|
|
||||
|
public interface StockMapper extends BaseMapper<Stock> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.storehousemanage; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.Remove; |
||||
|
|
||||
|
public interface RemoveMapper extends BaseMapper<Remove> { |
||||
|
} |
@ -0,0 +1,7 @@ |
|||||
|
package com.wh.mapper.storehousemanage; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.OnShelves; |
||||
|
|
||||
|
public interface ShelvesMapper extends BaseMapper<OnShelves> { |
||||
|
} |
@ -0,0 +1,13 @@ |
|||||
|
package com.wh.mapper.storehouseproject; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.wh.pojo.storehouseproject.StoreHouseProject; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* @author wangpengfei |
||||
|
* @date 2023/7/19 15:43 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface StoreHouseProjectMapper extends BaseMapper<StoreHouseProject> { |
||||
|
} |
@ -0,0 +1,157 @@ |
|||||
|
package com.wh.mapper.sysuser; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.Wrapper; |
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants; |
||||
|
import com.wh.controller.sysuser.SysUser; |
||||
|
import com.wh.controller.sysuser.SysUserInfoVo; |
||||
|
import com.wh.controller.sysuser.SysUserVo; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
import org.apache.ibatis.annotations.Update; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui_portal(门户建设) <br/> |
||||
|
* File: SysUserMapper.java <br/> |
||||
|
* Class: SysUserMapper <br/> |
||||
|
* Description: 用户表. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2021-08-03 00:24:30 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface SysUserMapper extends BaseMapper<SysUser> { |
||||
|
|
||||
|
//@Update("update sys_user set name=#{msg} where id=#{id}")
|
||||
|
//IPage<SysUserVo> voPage(IPage<SysUser> page, @Param(Constants.WRAPPER) QueryWrapper<SysUser> qw);
|
||||
|
|
||||
|
IPage<SysUserVo> selectPageVo(IPage<SysUser> page, @Param(Constants.WRAPPER) Wrapper<SysUser> ew, @Param("orgName") String orgName, @Param("userName") String userName); |
||||
|
|
||||
|
List<SysUserVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<SysUser> qw); |
||||
|
|
||||
|
@Select("SELECT user.*,staff.name FROM sys_user user left join sys_staffinfo staff on user.staffSid=staff.sid where user.isDelete=0") |
||||
|
List<SysUserVo> selectListVo(); |
||||
|
|
||||
|
public int updatePassword(String sid, String password); |
||||
|
public int deleteBySid(String sid); |
||||
|
|
||||
|
public int updatePasswordApp(String sid, String password); |
||||
|
|
||||
|
SysUser selectByUserName(String userName); |
||||
|
|
||||
|
SysUser selectByUserNameApp(String userName); |
||||
|
|
||||
|
SysUser selectByAppId(String appId); |
||||
|
|
||||
|
@Update("UPDATE sys_user SET appId=#{appId} WHERE sid=#{sid} and userType=1") |
||||
|
int updateAppId(@Param("sid") String sid, @Param("appId") String appId); |
||||
|
|
||||
|
@Update("UPDATE sys_user SET token=#{token} WHERE sid=#{sid}") |
||||
|
int updateToken(@Param("sid") String sid, @Param("token") String token); |
||||
|
|
||||
|
SysUser fetchByUserName(String userName); |
||||
|
|
||||
|
void delBySid(String sid); |
||||
|
|
||||
|
@Update("UPDATE sys_user SET headImage=#{headImage} WHERE sid=#{sid}") |
||||
|
int updateHeadImage(@Param("sid") String sid, @Param("headImage") String headImage); |
||||
|
|
||||
|
/** |
||||
|
* @param mobile 手机号 |
||||
|
* @param userType 用户类型 |
||||
|
* @description: 根据手机号和用户类型查询客户是否存在 |
||||
|
* @return: |
||||
|
* @Author: dimengzhe |
||||
|
* @Date: 2021/10/6 11:35 |
||||
|
*/ |
||||
|
SysUser selectByMobileAndType(@Param("mobile") String mobile, @Param("userType") int userType); |
||||
|
|
||||
|
|
||||
|
// @Select("SELECT * FROM sys_user WHERE staffSid=#{staffSid} and isDelete=0")
|
||||
|
SysUserVo selectByStaffsid(@Param("staffSid") String staffSid); |
||||
|
|
||||
|
@Update("update sys_user set isDelete=1 where isDelete=0 and userType=2 and userName=#{mobile}") |
||||
|
int delSysUserByMobile(@Param("mobile") String mobile); |
||||
|
|
||||
|
@Select("select sid from sys_user") |
||||
|
List<String> selectAllUserSid(); |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 根据用户sid查询用户的组织信息 |
||||
|
* |
||||
|
* @param userSid 用户的sid |
||||
|
* @return |
||||
|
*/ |
||||
|
SysUserInfoVo selectUserInfoByUserSid(String userSid); |
||||
|
SysUserInfoVo selectUserInfoByUserSidOne(@Param("userSid") String userSid,@Param("orgSid") String orgSid); |
||||
|
|
||||
|
/** |
||||
|
* 根据员工sid更新用户的工号以及手机号 |
||||
|
* |
||||
|
* @param mobile 手机号 |
||||
|
* @param sid 员工sid |
||||
|
* @return |
||||
|
*/ |
||||
|
int updateByStaffSid( @Param("mobile") String mobile, @Param("sid") String sid); |
||||
|
|
||||
|
/** |
||||
|
* 根据员工sid更新用户中的员工工号 |
||||
|
* |
||||
|
* @param jobNumber 员工工号 |
||||
|
* @param sid 员工sid |
||||
|
* @return |
||||
|
*/ |
||||
|
int updateByStaSid(@Param("jobNumber") String jobNumber, @Param("sid") String sid); |
||||
|
|
||||
|
/** |
||||
|
* 根据手机号查询用户是否存在 |
||||
|
* |
||||
|
* @param mobile 手机号 |
||||
|
* @return |
||||
|
*/ |
||||
|
SysUser selectByMobile(String mobile); |
||||
|
|
||||
|
int updateIsEnable(@Param("sid") String sid, @Param("isEnable") String isEnable); |
||||
|
|
||||
|
List<SysUserVo> getUsersByRoleSid(@Param("roleSid") String roleSid); |
||||
|
|
||||
|
List<SysUserVo> getUserByRole(@Param("roleSid") String roleSid, @Param("levelOrgSid") String levelOrgSid); |
||||
|
List<SysUserVo> getUserByRoleNoOrgPath(@Param("roleSid") String roleSid ); |
||||
|
List<Map<String,String>> getUserByOrgSid(@Param("orgSid") String orgSid,@Param("userSid") String userSid); |
||||
|
|
||||
|
List<SysUserVo> fetchBySids(@Param("sids")List<String> sids); |
||||
|
|
||||
|
List<SysUserVo> getUserByRoleSid(String roleSid); |
||||
|
|
||||
|
/** |
||||
|
* 根据手机号解绑用户绑定的设备 |
||||
|
* @param mobile |
||||
|
* @return |
||||
|
*/ |
||||
|
int updateAppIdByMobile(String mobile); |
||||
|
|
||||
|
/** |
||||
|
* 解绑所有用户绑定的设备 |
||||
|
* @return |
||||
|
*/ |
||||
|
int updateAppIdAll(); |
||||
|
|
||||
|
String selectIdBySid(@Param("list") List<String> stringList); |
||||
|
|
||||
|
List<SysUserVo> getUserMessageByRole(@Param("roleSid") String roleSid,@Param("levelOrgSid") String levelOrgSid, @Param("list") List<String> stringList); |
||||
|
String fetchByUserNameAndUserPhone(@Param("userName") String userName, @Param("userPhone") String userPhone); |
||||
|
List<SysUserVo> getUserByType(@Param("userType")String userType); |
||||
|
List<SysUserVo> getUserOrgBySid(@Param("sid")String sid); |
||||
|
@Select("select * from sys_user where userName=#{userName} and password=#{md5}") |
||||
|
SysUser selectByUserNameAndPassword(@Param("userName")String userName, @Param("md5")String md5); |
||||
|
} |
@ -0,0 +1,19 @@ |
|||||
|
package com.wh.pojo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.FieldFill; |
||||
|
import com.baomidou.mybatisplus.annotation.TableField; |
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
//pojo基类,完成2个任务,2个日期,实现序列化
|
||||
|
@Data |
||||
|
@Accessors(chain=true) |
||||
|
public class BasePojo implements Serializable{ |
||||
|
@TableField(fill = FieldFill.INSERT) |
||||
|
private Date created; //表示入库时需要赋值
|
||||
|
@TableField(fill = FieldFill.INSERT_UPDATE) |
||||
|
private Date updated; //表示入库/更新时赋值.
|
||||
|
} |
@ -0,0 +1,22 @@ |
|||||
|
package com.wh.pojo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableId; |
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
@TableName("in_storehouse") |
||||
|
public class InStorehouse { |
||||
|
@TableId("in_storehouse_id") |
||||
|
private String inStorehouseId; //入库单号
|
||||
|
private String receivingId; //接货单号
|
||||
|
private String locationId; //货位编码
|
||||
|
private String createPerson; //创建者
|
||||
|
private String createTime; //创建时间
|
||||
|
private String checkPerson; //审批人id
|
||||
|
private String checkTime; //审批时间
|
||||
|
private String status; //状态
|
||||
|
private String remarks; //备注
|
||||
|
} |
@ -0,0 +1,22 @@ |
|||||
|
package com.wh.pojo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.IdType; |
||||
|
import com.baomidou.mybatisplus.annotation.TableId; |
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
@TableName("location") |
||||
|
public class Location { |
||||
|
|
||||
|
private String name; //货位名称
|
||||
|
@TableId(type = IdType.AUTO) |
||||
|
private int id; |
||||
|
private String locationId; //货位编号
|
||||
|
private String type; //货位类型
|
||||
|
private String status; //货位状态
|
||||
|
private String storehouse; //所属仓库
|
||||
|
private String storehouseid; |
||||
|
} |
@ -0,0 +1,21 @@ |
|||||
|
package com.wh.pojo; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.IdType; |
||||
|
import com.baomidou.mybatisplus.annotation.TableId; |
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import lombok.Data; |
||||
|
import lombok.experimental.Accessors; |
||||
|
|
||||
|
@Data |
||||
|
@Accessors(chain = true) |
||||
|
public class LocationQuery implements Query { |
||||
|
|
||||
|
private String name; //货位名称
|
||||
|
@TableId(type = IdType.AUTO) |
||||
|
private int id; |
||||
|
private String locationId; //货位编号
|
||||
|
private String type; //货位类型
|
||||
|
private String status; //货位状态
|
||||
|
private String storehouse; //所属仓库
|
||||
|
private String storehouseid; |
||||
|
} |
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue