Commit 0944b317 by 赵剑炜

Merge branch 'develop' of http://gitlab.sothing.top/843502640/jyzb_platformV2 into develop-zhaojw

parents e3846c8d 06613496
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -3,6 +3,7 @@ package com.junmp.jyzb.api.bean.dto; ...@@ -3,6 +3,7 @@ package com.junmp.jyzb.api.bean.dto;
import lombok.Data; import lombok.Data;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Date;
import java.util.List; import java.util.List;
@Data @Data
...@@ -20,6 +21,7 @@ public class OrgDto { ...@@ -20,6 +21,7 @@ public class OrgDto {
private Integer statusFlag; private Integer statusFlag;
private Integer delFlag; private Integer delFlag;
private Integer childCount; private Integer childCount;
private Date updateTime;
private List<OrgDto> children = new ArrayList<>(); private List<OrgDto> children = new ArrayList<>();
public void addChild(OrgDto child) { public void addChild(OrgDto child) {
......
...@@ -12,4 +12,6 @@ public class SizeAndTypeDto { ...@@ -12,4 +12,6 @@ public class SizeAndTypeDto {
private List<TypeDto> typeList; private List<TypeDto> typeList;
private List<OrgDto> orgList;
} }
...@@ -21,5 +21,9 @@ public class QueryEquipmentTypeReq { ...@@ -21,5 +21,9 @@ public class QueryEquipmentTypeReq {
private String typeName; private String typeName;
private String nickName; private String nickName;
private Date updateTime; private Date updateTime;
/**
* 是否需要添加组织机构返回
*/
private Boolean flag;
} }
...@@ -47,6 +47,13 @@ public class DeviceConfigController { ...@@ -47,6 +47,13 @@ public class DeviceConfigController {
public ApiRes<Boolean> updateDeviceConfig(@RequestBody UpdateDeivceConfigReq req){ public ApiRes<Boolean> updateDeviceConfig(@RequestBody UpdateDeivceConfigReq req){
return ApiRes.success(deviceConfigService.updateDeviceConfig(req)); return ApiRes.success(deviceConfigService.updateDeviceConfig(req));
} }
//删除配置(通道和本地主机配置)
@PostMapping(path="/delDeviceConfig",name="删除配置#logType=30")
@ApiOperation("删除配置")
public ApiRes<Boolean> delDeviceConfig(@RequestBody UpdateDeivceConfigReq req){
return ApiRes.success(deviceConfigService.delDeviceConfig(req));
}
//查询配置Page(通道和本地主机配置) //查询配置Page(通道和本地主机配置)
@PostMapping(path="/showDeviceConfigPage",name="查询配置Page#enable") @PostMapping(path="/showDeviceConfigPage",name="查询配置Page#enable")
@ApiOperation("查询配置Page") @ApiOperation("查询配置Page")
...@@ -72,6 +79,13 @@ public class DeviceConfigController { ...@@ -72,6 +79,13 @@ public class DeviceConfigController {
public ApiRes<Boolean> updateWarehouseDev(@RequestBody UpdateWarehouseDevReq req){ public ApiRes<Boolean> updateWarehouseDev(@RequestBody UpdateWarehouseDevReq req){
return ApiRes.success(warehouseDevService.updateWarehouseDev(req)); return ApiRes.success(warehouseDevService.updateWarehouseDev(req));
} }
//删除除湿机配置
@PostMapping(path="/delWarehouseDev",name="删除除湿机配置#logType=30")
@ApiOperation("删除除湿机配置")
public ApiRes<Boolean> delWarehouseDev(@RequestBody UpdateWarehouseDevReq req){
return ApiRes.success(warehouseDevService.delWarehouseDev(req));
}
//查看除湿机配置 //查看除湿机配置
@PostMapping(path="/showWarehouseDevList",name="查看除湿机配置#enable") @PostMapping(path="/showWarehouseDevList",name="查看除湿机配置#enable")
@ApiOperation("查看除湿机配置") @ApiOperation("查看除湿机配置")
......
...@@ -19,7 +19,13 @@ import org.springframework.validation.annotation.Validated; ...@@ -19,7 +19,13 @@ import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource; import javax.annotation.Resource;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.io.IOException; import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.Arrays;
import java.util.Base64;
import java.util.List; import java.util.List;
@RestController @RestController
...@@ -110,10 +116,12 @@ public class EquipmentTypeController { ...@@ -110,10 +116,12 @@ public class EquipmentTypeController {
return ApiRes.success(equipmentTypeService.alignTypeInfo(req)); return ApiRes.success(equipmentTypeService.alignTypeInfo(req));
} }
@PostMapping(path = "/exportSizeAndType",name = "导出指定时间后的类型号型#enable") @PostMapping(path = "/exportSizeAndType",name = "导出指定时间后的类型号型组织机构#enable")
@ApiOperation("导出指定时间后的类型号型") @ApiOperation("导出指定时间后的类型号型组织机构")
public ApiRes<String> exportSizeAndType(@RequestBody QueryEquipmentTypeReq req){ public ApiRes<String> exportSizeAndType(@RequestBody QueryEquipmentTypeReq req){
return ApiRes.success(equipmentTypeService.exportSizeAndType(req)); return ApiRes.success(equipmentTypeService.exportSizeAndType(req));
} }
} }
...@@ -34,12 +34,6 @@ public class InventoryController { ...@@ -34,12 +34,6 @@ public class InventoryController {
public InventorySummaryService inventorySummaryService; public InventorySummaryService inventorySummaryService;
@Resource @Resource
public MQProductService mqProductService; public MQProductService mqProductService;
@GetMapping("/TestSum")
@ApiOperation("根据组织机构查询库存信息")
public ApiRes<Boolean> TestSum( ) {
inventorySummaryService.MonthStartSum();
return ApiRes.success();
}
@GetMapping("/testMQ") @GetMapping("/testMQ")
@ApiOperation("根据组织机构查询库存信息") @ApiOperation("根据组织机构查询库存信息")
...@@ -49,20 +43,6 @@ public class InventoryController { ...@@ -49,20 +43,6 @@ public class InventoryController {
} }
//填充汇总信息(根据base_inventory表中数据汇总同步)--第一次进行数据同步,适用于3.0初始化inventory_summary表
//该方法只有插入语句,要注意inventory_summary表中没有数据,仅有结构,否则数据不准确
@PostMapping(path="/SetInventoryMsg",name="填充汇总表信息#logType=30")
@ApiOperation("填充汇总表信息")
public ApiRes<Boolean> setInventoryMsg(InventorySumReq req) {
boolean result = inventoryService.setInventoryMsg(req);
if (!result){
return ApiRes.failure("汇总失败");
}
return ApiRes.success(result);
}
//装备绑定箱门 //装备绑定箱门
@PostMapping(path="/EquipmentBind",name="装备绑定箱门#logType=30") @PostMapping(path="/EquipmentBind",name="装备绑定箱门#logType=30")
......
...@@ -313,9 +313,14 @@ public class PoliceController { ...@@ -313,9 +313,14 @@ public class PoliceController {
return ApiRes.success(policemanService.alignUserInfo(req)); return ApiRes.success(policemanService.alignUserInfo(req));
} }
// @PostMapping(path = "/oneClickAccountCreation",name = "一键生成账号(运维,管理,审核)#logType=30")
// public ApiRes<Boolean> oneClickAccountCreation(@RequestBody PubOrg pubOrg) throws IOException {
// return ApiRes.success(policemanService.oneClickAccountCreation(pubOrg));
// }
@PostMapping(path = "/oneClickAccountCreation",name = "一键生成账号(运维,管理,审核)#logType=30") @PostMapping(path = "/oneClickAccountCreation",name = "一键生成账号(运维,管理,审核)#logType=30")
public ApiRes<Boolean> oneClickAccountCreation(@RequestBody PubOrg pubOrg) throws IOException { public ApiRes<Boolean> oneClickAccountCreation(@RequestBody PubOrg pubOrg) throws IOException {
return ApiRes.success(policemanService.oneClickAccountCreation(pubOrg)); return ApiRes.success(policemanService.oneClickAccountCreation1(pubOrg));
} }
} }
...@@ -91,7 +91,8 @@ public class TjController { ...@@ -91,7 +91,8 @@ public class TjController {
@PostMapping("/TjOrgPrice") @PostMapping("/TjOrgPrice")
@ApiOperation("/财务统计报表") @ApiOperation("/财务统计报表")
public ApiRes<PageResult<TjOrgPriceDto>> TjOrgPrice(@RequestBody TjOrgPriceReq req){ public ApiRes<PageResult<TjOrgPriceDto>> TjOrgPrice(@RequestBody TjOrgPriceReq req){
return ApiRes.success(tjService.TjOrgPrice(req)); PageResult<TjOrgPriceDto> tjOrgPriceDtoPageResult = tjService.TjOrgPrice(req);
return ApiRes.success(tjOrgPriceDtoPageResult);
} }
@PostMapping("/TjOrgPriceSum") @PostMapping("/TjOrgPriceSum")
@ApiOperation("/财务统计报表汇总") @ApiOperation("/财务统计报表汇总")
......
...@@ -139,6 +139,7 @@ import static com.junmp.junmpProcess.common.CommonConstants.*; ...@@ -139,6 +139,7 @@ import static com.junmp.junmpProcess.common.CommonConstants.*;
List<OrderDetail> list = orderDetailService.list(new LambdaQueryWrapper<OrderDetail>() List<OrderDetail> list = orderDetailService.list(new LambdaQueryWrapper<OrderDetail>()
.eq(OrderDetail::getOrderId, updateOrderReq.getId())); .eq(OrderDetail::getOrderId, updateOrderReq.getId()));
updateOrderReq.setId(existOrder.getId()); updateOrderReq.setId(existOrder.getId());
existOrder.setActualQuantity(0);
orderMainService.updateById(existOrder); orderMainService.updateById(existOrder);
// orderMainService.ChangeOrderState(updateOrderReq); // orderMainService.ChangeOrderState(updateOrderReq);
List<UpdateOrderDetailReq> collect = list.stream().map(orderDetail -> { List<UpdateOrderDetailReq> collect = list.stream().map(orderDetail -> {
...@@ -148,8 +149,11 @@ import static com.junmp.junmpProcess.common.CommonConstants.*; ...@@ -148,8 +149,11 @@ import static com.junmp.junmpProcess.common.CommonConstants.*;
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
updateOrderDetailReq.setProductionDate(format.format(orderDetail.getProductionDate())); updateOrderDetailReq.setProductionDate(format.format(orderDetail.getProductionDate()));
} }
orderDetail.setActualNum(0);
orderDetail.setModifyQuantity(0);
return updateOrderDetailReq; return updateOrderDetailReq;
}).collect(Collectors.toList()); }).collect(Collectors.toList());
orderDetailService.updateBatchById(list);
updateOrderReq.setDetailList(collect); updateOrderReq.setDetailList(collect);
//将单据上传到rabbitmq //将单据上传到rabbitmq
orderMainService.AddFinishOrder(updateOrderReq); orderMainService.AddFinishOrder(updateOrderReq);
......
...@@ -89,8 +89,5 @@ public interface InventoryMapper extends BaseMapper<Inventory> { ...@@ -89,8 +89,5 @@ public interface InventoryMapper extends BaseMapper<Inventory> {
// IPage<InventoryDto> GetDetailByTerms(@Param("page") Page<Object> defaultPage, @Param("req") InventoryReq req); // IPage<InventoryDto> GetDetailByTerms(@Param("page") Page<Object> defaultPage, @Param("req") InventoryReq req);
void reSetInventory(@Param("summaryTableName") String baseInventorySummary,
@Param("sourceTableName") String baseInventory,
@Param("warrantyThreshold") Integer brokenNumberDays,
@Param("sql") String sql);
} }
\ No newline at end of file
...@@ -13,6 +13,7 @@ import com.junmp.jyzb.entity.InventorySummary; ...@@ -13,6 +13,7 @@ import com.junmp.jyzb.entity.InventorySummary;
import com.junmp.jyzb.entity.Policeman; import com.junmp.jyzb.entity.Policeman;
import com.junmp.v2.sys.api.bean.user.SysUserDto; import com.junmp.v2.sys.api.bean.user.SysUserDto;
import com.junmp.v2.sys.api.bean.user.req.SysUserReq; import com.junmp.v2.sys.api.bean.user.req.SysUserReq;
import com.junmp.v2.sys.user.entity.SysUser;
import liquibase.pro.packaged.S; import liquibase.pro.packaged.S;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
...@@ -64,4 +65,7 @@ public interface PolicemanMapper extends BaseMapper<Policeman> { ...@@ -64,4 +65,7 @@ public interface PolicemanMapper extends BaseMapper<Policeman> {
List<UserDto> alignUserInfo(@Param("orgId") Long orgId, @Param("date")String date); List<UserDto> alignUserInfo(@Param("orgId") Long orgId, @Param("date")String date);
List<UserDto> oneClickAccountCreation(@Param("orgId") Long orgId,@Param("account")String account,@Param("roleId")Long roleId); List<UserDto> oneClickAccountCreation(@Param("orgId") Long orgId,@Param("account")String account,@Param("roleId")Long roleId);
List<UserDto> oneClickAccountCreation1(@Param("orgId") Long orgId);
void insertSysUser(@Param("userList") List<SysUser> sysUserList);
} }
\ No newline at end of file
...@@ -13,20 +13,7 @@ import java.util.List; ...@@ -13,20 +13,7 @@ import java.util.List;
public interface PriceSumSummaryMapper extends BaseMapper<PriceSumSummary> { public interface PriceSumSummaryMapper extends BaseMapper<PriceSumSummary> {
/**
* 存储过程-月初金额数量统计
*/
void MonthStart ();
/**
* 存储过程-月末金额数量统计
*/
void MonthEnd ();
/**
* 存储过程-月末差值计算统计
*/
void MonthDifference ();
TjOrgPriceDto TjOrgPrice(@Param("orgId") String orgId, TjOrgPriceDto TjOrgPrice(@Param("orgId") String orgId,
@Param("year") Integer year, @Param("year") Integer year,
......
...@@ -29,4 +29,6 @@ public interface DeviceConfigService extends IService<DeviceConfig> { ...@@ -29,4 +29,6 @@ public interface DeviceConfigService extends IService<DeviceConfig> {
List<String> alignDeviceConfigInfo(UpdateDeivceConfigReq req); List<String> alignDeviceConfigInfo(UpdateDeivceConfigReq req);
boolean delDeviceConfig(UpdateDeivceConfigReq req);
} }
...@@ -34,4 +34,5 @@ public interface EquipmentTypeService extends IService<EquipmentType> { ...@@ -34,4 +34,5 @@ public interface EquipmentTypeService extends IService<EquipmentType> {
List<TypeDto> alignTypeInfo(UpdateEquipmentTypeReq req); List<TypeDto> alignTypeInfo(UpdateEquipmentTypeReq req);
String exportSizeAndType(QueryEquipmentTypeReq req); String exportSizeAndType(QueryEquipmentTypeReq req);
} }
...@@ -21,8 +21,6 @@ public interface InventoryService extends IService<Inventory> { ...@@ -21,8 +21,6 @@ public interface InventoryService extends IService<Inventory> {
InventoryDto getInventoryDetail(InventoryReq msg); InventoryDto getInventoryDetail(InventoryReq msg);
//计算更新库存汇总表信息
boolean setInventoryMsg(InventorySumReq req);
boolean UpdateWarehouseInsNum(WarehouseReq req); boolean UpdateWarehouseInsNum(WarehouseReq req);
......
...@@ -13,8 +13,6 @@ import java.util.List; ...@@ -13,8 +13,6 @@ import java.util.List;
public interface InventorySummaryService extends IService<InventorySummary> { public interface InventorySummaryService extends IService<InventorySummary> {
void MonthStartSum();
void MonthEndSum();
//根据条件查询库存汇总信息 //根据条件查询库存汇总信息
PageResult<InventorySummary> getEquipmentInfo(InventorySumReq req); PageResult<InventorySummary> getEquipmentInfo(InventorySumReq req);
...@@ -44,10 +42,7 @@ public interface InventorySummaryService extends IService<InventorySummary> { ...@@ -44,10 +42,7 @@ public interface InventorySummaryService extends IService<InventorySummary> {
List<InventorySumDto> selectTotalNum(SelectTotalNumReq req); List<InventorySumDto> selectTotalNum(SelectTotalNumReq req);
/**
* 更新使用次数和维修次数
*/
void updateCount();
//根据条件查询库存汇总信息(仅类型) //根据条件查询库存汇总信息(仅类型)
PageResult<InventorySummary> GetEquipmentSummary(InventorySumReq req); PageResult<InventorySummary> GetEquipmentSummary(InventorySumReq req);
......
...@@ -124,5 +124,7 @@ public interface PolicemanService extends IService<Policeman> { ...@@ -124,5 +124,7 @@ public interface PolicemanService extends IService<Policeman> {
List<UserDto> alignUserInfo(PolicemanReq req); List<UserDto> alignUserInfo(PolicemanReq req);
boolean oneClickAccountCreation(PubOrg pubOrg) throws IOException; // boolean oneClickAccountCreation(PubOrg pubOrg) throws IOException;
boolean oneClickAccountCreation1(PubOrg pubOrg) throws IOException;
} }
...@@ -21,4 +21,6 @@ public interface WarehouseDevService extends IService<WarehouseDev> { ...@@ -21,4 +21,6 @@ public interface WarehouseDevService extends IService<WarehouseDev> {
List<WarehouseDev> showWarehouseDevList(UpdateWarehouseDevReq req); List<WarehouseDev> showWarehouseDevList(UpdateWarehouseDevReq req);
List<WarehouseDevInfoDto> alignWarehouseDevInfo(UpdateWarehouseDevReq req); List<WarehouseDevInfoDto> alignWarehouseDevInfo(UpdateWarehouseDevReq req);
boolean delWarehouseDev(UpdateWarehouseDevReq req);
} }
...@@ -10,6 +10,7 @@ import com.junmp.jyzb.api.bean.dto.MQDto; ...@@ -10,6 +10,7 @@ import com.junmp.jyzb.api.bean.dto.MQDto;
import com.junmp.jyzb.api.bean.query.QueryDeviceConfigReq; import com.junmp.jyzb.api.bean.query.QueryDeviceConfigReq;
import com.junmp.jyzb.api.bean.req.UpdateDeivceConfigReq; import com.junmp.jyzb.api.bean.req.UpdateDeivceConfigReq;
import com.junmp.jyzb.api.bean.req.UpdateWarehouseDevReq; import com.junmp.jyzb.api.bean.req.UpdateWarehouseDevReq;
import com.junmp.jyzb.api.exception.enums.CabinetExceptionEnum;
import com.junmp.jyzb.entity.DeviceConfig; import com.junmp.jyzb.entity.DeviceConfig;
import com.junmp.jyzb.entity.WarehouseDev; import com.junmp.jyzb.entity.WarehouseDev;
import com.junmp.jyzb.mapper.WarehouseDevMapper; import com.junmp.jyzb.mapper.WarehouseDevMapper;
...@@ -18,6 +19,7 @@ import com.junmp.jyzb.mapper.DeviceConfigMapper; ...@@ -18,6 +19,7 @@ import com.junmp.jyzb.mapper.DeviceConfigMapper;
import com.junmp.jyzb.service.WarehouseDevService; import com.junmp.jyzb.service.WarehouseDevService;
import com.junmp.jyzb.utils.DateTimeUtil; import com.junmp.jyzb.utils.DateTimeUtil;
import com.junmp.jyzb.utils.RabbitMQSendMsg; import com.junmp.jyzb.utils.RabbitMQSendMsg;
import com.junmp.v2.common.exception.base.ServiceException;
import com.junmp.v2.common.util.BeanPlusUtil; import com.junmp.v2.common.util.BeanPlusUtil;
import com.junmp.v2.db.api.factory.PageFactory; import com.junmp.v2.db.api.factory.PageFactory;
import com.junmp.v2.db.api.factory.PageResultFactory; import com.junmp.v2.db.api.factory.PageResultFactory;
...@@ -124,6 +126,14 @@ public class DeviceConfigServiceImpl extends ServiceImpl<DeviceConfigMapper, Dev ...@@ -124,6 +126,14 @@ public class DeviceConfigServiceImpl extends ServiceImpl<DeviceConfigMapper, Dev
return deviceConfigList; return deviceConfigList;
} }
@Override
public boolean delDeviceConfig(UpdateDeivceConfigReq req) {
if (ObjectUtil.isNull(req.getId())){
throw new ServiceException(CabinetExceptionEnum.PARAMETER_ERROR);
}
return this.removeById(req.getId());
}
} }
......
...@@ -66,11 +66,18 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E ...@@ -66,11 +66,18 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E
private RabbitMQSendMsg MQ; private RabbitMQSendMsg MQ;
@Resource @Resource
private PubOrgService pubOrgService;
@Resource
private EquipmentSizeService equipmentSizeService; private EquipmentSizeService equipmentSizeService;
private static final String REDIS_TYPE = "Type_"; private static final String REDIS_TYPE = "Type_";
private List<EquipmentTypeDto> typeDto; private List<EquipmentTypeDto> typeDto;
private ArrayList<String> ids; private ArrayList<String> ids;
private static final String DES_ALGORITHM = "DES";
private static final String CBC_PADDING = "DES/CBC/PKCS5Padding";
private static final int CHUNK_SIZE = 8;
//查询出类别表中数据的所有装备信息(入库时调用) //查询出类别表中数据的所有装备信息(入库时调用)
public List<EquipmentTypeDto> getEquipmentList(QueryEquipmentTypeReq req) { public List<EquipmentTypeDto> getEquipmentList(QueryEquipmentTypeReq req) {
List<EquipmentType> list = list(new LambdaQueryWrapper<EquipmentType>() List<EquipmentType> list = list(new LambdaQueryWrapper<EquipmentType>()
...@@ -537,6 +544,18 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E ...@@ -537,6 +544,18 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E
return sizeDto; return sizeDto;
}).collect(Collectors.toList()); }).collect(Collectors.toList());
sizeAndType.setSizeList(CollectionUtil.isNotEmpty(collect1)?collect1:new ArrayList<>()); sizeAndType.setSizeList(CollectionUtil.isNotEmpty(collect1)?collect1:new ArrayList<>());
if (req.getFlag()){
List<PubOrg> pubList = pubOrgService.list(new LambdaQueryWrapper<PubOrg>().ge(PubOrg::getUpdateTime, req.getUpdateTime())
.eq(PubOrg::getDelFlag,1));
List<OrgDto> collect2 = pubList.stream().map(pubOrg -> {
OrgDto orgDto = new OrgDto();
BeanPlusUtil.copyProperties(pubOrg, orgDto);
return orgDto;
}).collect(Collectors.toList());
sizeAndType.setOrgList(CollectionUtil.isNotEmpty(collect2)?collect2:new ArrayList<>());
}
String jsonString = JSONObject.toJSONString(sizeAndType); String jsonString = JSONObject.toJSONString(sizeAndType);
try { try {
...@@ -562,12 +581,41 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E ...@@ -562,12 +581,41 @@ public class EquipmentTypeServiceImpl extends ServiceImpl<EquipmentTypeMapper, E
// 对加密结果进行Base64编码并返回 // 对加密结果进行Base64编码并返回
return Base64.getEncoder().encodeToString(encryptedBytes); return Base64.getEncoder().encodeToString(encryptedBytes);
// byte[] byKey = Arrays.copyOf("junmp888".getBytes(StandardCharsets.UTF_8), 8);
// byte[] iv = { (byte) 0x12, (byte) 0x34, (byte) 0x56, (byte) 0x78, (byte) 0x90, (byte) 0xAB, (byte) 0xCD, (byte) 0xEF };
//
// SecretKeySpec secretKeySpec = new SecretKeySpec(byKey, DES_ALGORITHM);
// IvParameterSpec ivParameterSpec = new IvParameterSpec(iv);
//
// Cipher desCipher = Cipher.getInstance(CBC_PADDING);
// desCipher.init(Cipher.ENCRYPT_MODE, secretKeySpec, ivParameterSpec);
//
// byte[] inputByteArray = jsonString.getBytes(StandardCharsets.UTF_8);
// int offset = 0;
//
// StringBuilder encryptedString = new StringBuilder();
//
// while (offset < inputByteArray.length) {
// int length = Math.min(CHUNK_SIZE, inputByteArray.length - offset);
// byte[] chunk = new byte[length];
// System.arraycopy(inputByteArray, offset, chunk, 0, length);
//
// byte[] encryptedChunk = desCipher.doFinal(chunk);
// String base64EncodedChunk = Base64.getEncoder().encodeToString(encryptedChunk);
// encryptedString.append(base64EncodedChunk);
//
// offset += CHUNK_SIZE;
// }
// return encryptedString.toString();
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
return ""; return "";
} }
} }
} }
...@@ -131,31 +131,6 @@ public class InventoryServiceImpl extends ServiceImpl<InventoryMapper, Inventory ...@@ -131,31 +131,6 @@ public class InventoryServiceImpl extends ServiceImpl<InventoryMapper, Inventory
} }
@Override
@Transactional(rollbackFor = Exception.class)
public boolean setInventoryMsg(InventorySumReq req){
//查询字典表中的临近报废天数
SysDictItem sysDictItem = sysDictItemService.getOne(new LambdaQueryWrapper<SysDictItem>()
.eq(SysDictItem::getItemText, "brokenNumber"));
//如果配置找不到,那就默认设置为15天为临近报废(如果装备的质保期小于15天了,就是为临近报废)
Integer brokenNumberDays;
if (ObjectUtil.isNotNull(sysDictItem)){
brokenNumberDays=15;
}else {
brokenNumberDays=Integer.parseInt(sysDictItem.getItemValue());
}
boolean b = inventorySummaryService.remove(new LambdaQueryWrapper<InventorySummary>().eq(InventorySummary::getOrgId, req.getOrgId()));
// //放入仓库区域信息汇总
// boolean b1 = inventoryMapper.SetWarehouseInventory(brokenNumberDays);
// //放入单警柜信息汇总
// boolean b = inventoryMapper.SetCabinetInventory(brokenNumberDays);
String sql="and bi.org_id_int = "+req.getOrgId();
inventoryMapper.reSetInventory("base_inventory_summary","base_inventory",brokenNumberDays,sql);
return (b);
}
//设置仓库库存数量(总数,在库数,出库数,价格) //设置仓库库存数量(总数,在库数,出库数,价格)
@Override @Override
......
...@@ -75,16 +75,6 @@ public class InventorySummaryServiceImpl extends ServiceImpl<InventorySummaryMa ...@@ -75,16 +75,6 @@ public class InventorySummaryServiceImpl extends ServiceImpl<InventorySummaryMa
private EquipmentTypeService equipmentTypeService; private EquipmentTypeService equipmentTypeService;
@Override
public void MonthStartSum() {
PriceSumSummaryMapper.MonthStart();
}
@Override
public void MonthEndSum() {
PriceSumSummaryMapper.MonthEnd();
PriceSumSummaryMapper.MonthDifference();
}
//根据条件查询库存汇总信息 //根据条件查询库存汇总信息
@Override @Override
public PageResult<InventorySummary> getEquipmentInfo(InventorySumReq req) { public PageResult<InventorySummary> getEquipmentInfo(InventorySumReq req) {
...@@ -405,20 +395,6 @@ public class InventorySummaryServiceImpl extends ServiceImpl<InventorySummaryMa ...@@ -405,20 +395,6 @@ public class InventorySummaryServiceImpl extends ServiceImpl<InventorySummaryMa
return inventorySumDtoList; return inventorySumDtoList;
} }
/**
* 更新使用次数和维修次数
*/
@Override
@Transactional(rollbackFor = Exception.class)
public void updateCount() {
//先统计上一个月的使用次数和维修次数,然后再进行置零,开始计算下一个月的数据
equipmentCountSummaryMapper.deleteAll(null);
equipmentCountSummaryMapper.addInfo(" 1=1");
LambdaUpdateWrapper<InventorySummary> eq = new LambdaUpdateWrapper<InventorySummary>()
.set(InventorySummary::getUseCount,0).set(InventorySummary::getFixCount,0);
update(eq);
}
private LambdaQueryWrapper<InventorySummary> createWrapper(InventorySumReq req) { private LambdaQueryWrapper<InventorySummary> createWrapper(InventorySumReq req) {
......
...@@ -142,6 +142,9 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -142,6 +142,9 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
private RabbitMQSendMsg MQ; private RabbitMQSendMsg MQ;
@Resource @Resource
private EquipmentTypeService equipmentTypeService;
@Resource
private WarehouseInventoryService warehouseInventoryService; private WarehouseInventoryService warehouseInventoryService;
...@@ -1061,25 +1064,41 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -1061,25 +1064,41 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
if (ObjectUtil.isNull(detailJsonReq.getModifyQuantity())){ if (ObjectUtil.isNull(detailJsonReq.getModifyQuantity())){
detailJsonReq.setModifyQuantity(uploadDetailReq.getModifyQuantity()); detailJsonReq.setModifyQuantity(uploadDetailReq.getModifyQuantity());
} }
int subNum=detailJsonReq.getModifyQuantity()-detailJsonReq.getNum(); int subNum=detailJsonReq.getModifyQuantity()-(ObjectUtil.isNull(detailJsonReq.getNum())?0:detailJsonReq.getNum());
detailJsonReq.setSizeName(uploadDetailReq.getSizeName()); detailJsonReq.setSizeName(uploadDetailReq.getSizeName());
detailJsonReq.setTypeName(uploadDetailReq.getTypeName()); detailJsonReq.setTypeName(uploadDetailReq.getTypeName());
//添加list为修改库存Summary //添加list为修改库存Summary
UpdateOrderDetailReq data = new UpdateOrderDetailReq(); UpdateOrderDetailReq data = new UpdateOrderDetailReq();
data.setActualNum(detailJsonReq.getNum()); data.setActualNum(ObjectUtil.isNull(detailJsonReq.getNum())?0:detailJsonReq.getNum());
data.setWarehouseId(detailJsonReq.getLocationId()); data.setWarehouseId(detailJsonReq.getLocationId());
data.setWarehouseName(detailJsonReq.getLocationName()); data.setWarehouseName(detailJsonReq.getLocationName());
data.setSizeId(detailJsonReq.getSizeId()); data.setSizeId(ObjectUtil.isNull(detailJsonReq.getSizeId())? uploadDetailReq.getSizeId():detailJsonReq.getSizeId());
data.setTypeId(detailJsonReq.getTypeId()); data.setTypeId(ObjectUtil.isNull(detailJsonReq.getTypeId())? uploadDetailReq.getTypeId():detailJsonReq.getTypeId());
data.setPrice(detailJsonReq.getPrice().toString()); BigDecimal price=BigDecimal.ZERO;
data.setProperty(detailJsonReq.getProperty()); if (ObjectUtil.isNull(detailJsonReq.getPrice())){
price=equipmentTypeService.getOne(new LambdaQueryWrapper<EquipmentType>()
.eq(EquipmentType::getId,uploadDetailReq.getTypeId()))
.getPrice();
}
data.setPrice(ObjectUtil.isNull(detailJsonReq.getPrice())? price.toString() :detailJsonReq.getPrice().toString());
data.setProperty(ObjectUtil.isNull(detailJsonReq.getProperty())?0:detailJsonReq.getProperty());
data.setSizeName(detailJsonReq.getSizeName()); data.setSizeName(detailJsonReq.getSizeName());
data.setTypeName(detailJsonReq.getTypeName()); data.setTypeName(detailJsonReq.getTypeName());
data.setModifyQuantity(detailJsonReq.getModifyQuantity()); data.setModifyQuantity(detailJsonReq.getModifyQuantity());
orderDetailReqList.add(data); orderDetailReqList.add(data);
//添加出入库日志记录 //添加出入库日志记录
if (orderMain.getOrderType().equals("in")){
s = s+detailJsonReq.getLocationName()+"--"+detailJsonReq.getTypeName()+"【"+ s = s+detailJsonReq.getLocationName()+"--"+detailJsonReq.getTypeName()+"【"+
detailJsonReq.getSizeName()+"】,单价:"+detailJsonReq.getPrice()+",数量实入:"+detailJsonReq.getNum()+",记账:"+ detailJsonReq.getModifyQuantity()+"\n"; detailJsonReq.getSizeName()+"】,单价:"+(ObjectUtil.isNull(detailJsonReq.getPrice())?price:detailJsonReq.getPrice())
+",数量实入:"+(ObjectUtil.isNull(detailJsonReq.getNum())?0:detailJsonReq.getNum())+",记账:"+ detailJsonReq.getModifyQuantity()+"\n";
}else {
s = s+detailJsonReq.getLocationName()+"--"+detailJsonReq.getTypeName()+"【"+
detailJsonReq.getSizeName()+"】,单价:"+(ObjectUtil.isNull(detailJsonReq.getPrice())?price:detailJsonReq.getPrice())
+",数量实出:"+(ObjectUtil.isNull(detailJsonReq.getNum())?0:detailJsonReq.getNum())+",记账:"+ detailJsonReq.getModifyQuantity()+"\n";
}
if (subNum>0){ if (subNum>0){
//实际出库或者入库数量大于实际数量,则对空数据进行增删改查 //实际出库或者入库数量大于实际数量,则对空数据进行增删改查
...@@ -1087,17 +1106,17 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -1087,17 +1106,17 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
for (int j = 0; j < subNum; j++) { for (int j = 0; j < subNum; j++) {
inventory.setEpc("0"); inventory.setEpc("0");
inventory.setLocationId(detailJsonReq.getLocationId()); inventory.setLocationId(detailJsonReq.getLocationId());
inventory.setSizeId(detailJsonReq.getSizeId()); inventory.setSizeId(ObjectUtil.isNull(detailJsonReq.getSizeId())? uploadDetailReq.getSizeId():detailJsonReq.getSizeId());
inventory.setTypeId(detailJsonReq.getTypeId()); inventory.setTypeId(ObjectUtil.isNull(detailJsonReq.getTypeId())? uploadDetailReq.getTypeId():detailJsonReq.getTypeId());
inventory.setOrgId(orderMain.getEndOrgId()); inventory.setOrgId(orderMain.getEndOrgId());
inventory.setLocationType(0); inventory.setLocationType(0);
inventory.setPrice(detailJsonReq.getPrice()); inventory.setPrice(ObjectUtil.isNull(detailJsonReq.getPrice())?price:detailJsonReq.getPrice());
inventory.setProperty(0); inventory.setProperty(0);
addInvList.add(inventory); addInvList.add(inventory);
warehouseInventory.setOrgId(orderMain.getEndOrgId()); warehouseInventory.setOrgId(orderMain.getEndOrgId());
warehouseInventory.setLocationId(detailJsonReq.getLocationId()); warehouseInventory.setLocationId(detailJsonReq.getLocationId());
warehouseInventory.setTypeId(detailJsonReq.getTypeId()); warehouseInventory.setTypeId(ObjectUtil.isNull(detailJsonReq.getTypeId())? uploadDetailReq.getTypeId():detailJsonReq.getTypeId());
warehouseInventory.setSizeId(detailJsonReq.getSizeId()); warehouseInventory.setSizeId(ObjectUtil.isNull(detailJsonReq.getSizeId())? uploadDetailReq.getSizeId():detailJsonReq.getSizeId());
warehouseInventory.setLocationType("0"); warehouseInventory.setLocationType("0");
addWareInvList.add(warehouseInventory); addWareInvList.add(warehouseInventory);
} }
...@@ -1105,17 +1124,17 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -1105,17 +1124,17 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
List<Inventory> list1 = inventoryService.list(new LambdaQueryWrapper<Inventory>() List<Inventory> list1 = inventoryService.list(new LambdaQueryWrapper<Inventory>()
.eq(Inventory::getEpc, "0") .eq(Inventory::getEpc, "0")
.eq(Inventory::getLocationId, detailJsonReq.getLocationId()) .eq(Inventory::getLocationId, detailJsonReq.getLocationId())
.eq(Inventory::getSizeId, detailJsonReq.getSizeId()) .eq(Inventory::getSizeId, ObjectUtil.isNull(detailJsonReq.getSizeId())? uploadDetailReq.getSizeId():detailJsonReq.getSizeId())
.eq(Inventory::getOrgId, orderMain.getStartOrgId()) .eq(Inventory::getOrgId, orderMain.getStartOrgId())
.eq(Inventory::getTypeId, detailJsonReq.getTypeId()) .eq(Inventory::getTypeId, ObjectUtil.isNull(detailJsonReq.getTypeId())? uploadDetailReq.getTypeId():detailJsonReq.getTypeId())
.eq(Inventory::getPrice, detailJsonReq.getPrice()) .eq(Inventory::getPrice, detailJsonReq.getPrice())
.eq(Inventory::getLocationType, "0")); .eq(Inventory::getLocationType, "0"));
List<WarehouseInventory> list2 = warehouseInventoryService.list(new LambdaQueryWrapper<WarehouseInventory>() List<WarehouseInventory> list2 = warehouseInventoryService.list(new LambdaQueryWrapper<WarehouseInventory>()
.eq(WarehouseInventory::getEpc, "0") .eq(WarehouseInventory::getEpc, "0")
.eq(WarehouseInventory::getLocationId, detailJsonReq.getLocationId()) .eq(WarehouseInventory::getLocationId, detailJsonReq.getLocationId())
.eq(WarehouseInventory::getOrgId, orderMain.getStartOrgId()) .eq(WarehouseInventory::getOrgId, orderMain.getStartOrgId())
.eq(WarehouseInventory::getSizeId, detailJsonReq.getSizeId()) .eq(WarehouseInventory::getSizeId, ObjectUtil.isNull(detailJsonReq.getSizeId())? uploadDetailReq.getSizeId():detailJsonReq.getSizeId())
.eq(WarehouseInventory::getTypeId, detailJsonReq.getTypeId())); .eq(WarehouseInventory::getTypeId,ObjectUtil.isNull(detailJsonReq.getTypeId())? uploadDetailReq.getTypeId():detailJsonReq.getTypeId()));
if (list1.size()>0){ if (list1.size()>0){
...@@ -1329,7 +1348,6 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -1329,7 +1348,6 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
} }
SysUser sysUser = sysUserService.getById(userId); SysUser sysUser = sysUserService.getById(userId);
orderLog.setCreateUser(sysUser.getNickName()); orderLog.setCreateUser(sysUser.getNickName());
orderLog.setCreateUser(req.getUserId());
orderLog.setCreateTime(DateTimeUtil.getCurrentDateTime()); orderLog.setCreateTime(DateTimeUtil.getCurrentDateTime());
orderLog.setProcessType("accounting"); orderLog.setProcessType("accounting");
//将记账记录保存 //将记账记录保存
...@@ -1465,10 +1483,10 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain ...@@ -1465,10 +1483,10 @@ public class OrderMainServiceImpl extends ServiceImpl<OrderMainMapper, OrderMain
inventorySummary.setOutboundNumber(0); inventorySummary.setOutboundNumber(0);
inventorySummary.setUseNumber(0); inventorySummary.setUseNumber(0);
inventorySummary.setStockNumber(upReq.getModifyQuantity()); inventorySummary.setStockNumber(upReq.getModifyQuantity());
}
addList.add(inventorySummary); addList.add(inventorySummary);
} }
} }
}
boolean a=true; boolean a=true;
if (addList.size()>0){ if (addList.size()>0){
......
...@@ -5,11 +5,13 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; ...@@ -5,11 +5,13 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.junmp.jyzb.api.bean.dto.FetchingDataDto.WarehouseDevInfoDto; import com.junmp.jyzb.api.bean.dto.FetchingDataDto.WarehouseDevInfoDto;
import com.junmp.jyzb.api.bean.dto.MQDto; import com.junmp.jyzb.api.bean.dto.MQDto;
import com.junmp.jyzb.api.bean.req.UpdateWarehouseDevReq; import com.junmp.jyzb.api.bean.req.UpdateWarehouseDevReq;
import com.junmp.jyzb.api.exception.enums.CabinetExceptionEnum;
import com.junmp.jyzb.entity.WarehouseDev; import com.junmp.jyzb.entity.WarehouseDev;
import com.junmp.jyzb.service.WarehouseDevService; import com.junmp.jyzb.service.WarehouseDevService;
import com.junmp.jyzb.mapper.WarehouseDevMapper; import com.junmp.jyzb.mapper.WarehouseDevMapper;
import com.junmp.jyzb.utils.DateTimeUtil; import com.junmp.jyzb.utils.DateTimeUtil;
import com.junmp.jyzb.utils.RabbitMQSendMsg; import com.junmp.jyzb.utils.RabbitMQSendMsg;
import com.junmp.v2.common.exception.base.ServiceException;
import com.junmp.v2.common.util.BeanPlusUtil; import com.junmp.v2.common.util.BeanPlusUtil;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -86,6 +88,14 @@ public class WarehouseDevServiceImpl extends ServiceImpl<WarehouseDevMapper, War ...@@ -86,6 +88,14 @@ public class WarehouseDevServiceImpl extends ServiceImpl<WarehouseDevMapper, War
return warehouseDevMapper.alignWarehouseDevInfo(req.getOrgId(),date); return warehouseDevMapper.alignWarehouseDevInfo(req.getOrgId(),date);
} }
@Override
public boolean delWarehouseDev(UpdateWarehouseDevReq req) {
if (ObjectUtil.isNull(req.getId())){
throw new ServiceException(CabinetExceptionEnum.PARAMETER_ERROR);
}
return warehouseDevService.removeById(req.getId());
}
} }
......
package com.junmp.jyzb.task;
import com.junmp.jyzb.mapper.EquipmentCountSummaryMapper;
import com.junmp.jyzb.service.InventorySummaryService;
import com.junmp.v2.job.api.JobAction;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
@Slf4j
@Component
public class EquipmentCountAction implements JobAction {
private InventorySummaryService inventorySummaryService;
@Override
public void action() {
inventorySummaryService.updateCount();
}
}
package com.junmp.jyzb.task;
import com.junmp.jyzb.service.InventorySummaryService;
import com.junmp.v2.job.api.JobAction;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
@Slf4j
@Component
public class MonthEnd implements JobAction{
@Resource
public InventorySummaryService inventorySummaryService;
//月末执行以计算金额
@Override
public void action() {
// inventorySummaryService.MonthEndSum();
}
}
package com.junmp.jyzb.task;
import com.junmp.jyzb.service.InventorySummaryService;
import com.junmp.v2.job.api.JobAction;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
@Slf4j
@Component
public class MonthStart implements JobAction{
@Resource
public InventorySummaryService inventorySummaryService;
//月初执行
@Override
public void action() {
// inventorySummaryService.MonthStartSum();
}
}
package com.junmp.jyzb.task;
import com.junmp.jyzb.service.InventoryService;
import com.junmp.v2.job.api.JobAction;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
@Component
public class UpdateSummaryAction implements JobAction {
@Resource
private InventoryService inventoryService;
public void action(){
// inventoryService.setInventoryMsg();
}
}
...@@ -215,9 +215,7 @@ ...@@ -215,9 +215,7 @@
GROUP BY type_id,size_id,bi.org_id_int,location_id,bi.price) as t GROUP BY type_id,size_id,bi.org_id_int,location_id,bi.price) as t
GROUP BY t.locationId,t.type_id,t.size_id,t.orgId,t.unitPrice GROUP BY t.locationId,t.type_id,t.size_id,t.orgId,t.unitPrice
</insert> </insert>
<insert id="reSetInventory">
{CALL InsertInventorySummary(#{summaryTableName,mode=IN},#{sourceTableName,mode=IN},#{warrantyThreshold,mode=IN},#{sql,mode=IN})}
</insert>
<select id="getSumByShelf" resultType="com.junmp.jyzb.entity.InventorySummary" <select id="getSumByShelf" resultType="com.junmp.jyzb.entity.InventorySummary"
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.junmp.jyzb.mapper.PolicemanMapper"> <mapper namespace="com.junmp.jyzb.mapper.PolicemanMapper">
<insert id="insertSysUser" useGeneratedKeys="true" keyProperty="user_id" parameterType="java.util.List">
insert into sys_user(
nick_name,real_name,account,password,avatar,del_flag,creatie_time,update_time
)
<foreach collection="userList" item="item" separator=",">
(
#{item.nickName}, #{item.realName}, #{item.account}, #{item.password}, #{item.avatar},
#{item.delFlag}, #{item.createTime}, #{item.updateTime}
)
</foreach>
</insert>
<!--<resultMap id="PolicemanMap" type="Map">--> <!--<resultMap id="PolicemanMap" type="Map">-->
...@@ -382,6 +393,19 @@ WHERE o.org_id IN ...@@ -382,6 +393,19 @@ WHERE o.org_id IN
</if> </if>
order by uo.org_id order by uo.org_id
</select> </select>
<select id="oneClickAccountCreation1" resultType="com.junmp.jyzb.api.bean.dto.FetchingDataDto.UserDto">
select t.*,uo.org_id FROM (
SELECT u.* FROM `sys_user` u
where u.account like "gl33%" or u.account like "yw33%" or u.account like "sh33%"
) as t
join sys_user_org uo on t.user_id=uo.user_id
<if test="orgId != null and orgId != ''">
and uo.org_id=#{orgId}
</if>
join sys_user_role ur on t.user_id=ur.user_id
join sys_role r on ur.role_id=r.role_id and r.role_id in ("1528003832557232130","1663372320355389441","1663372027127402498")
order by uo.org_id
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -27,47 +27,10 @@ ...@@ -27,47 +27,10 @@
<!-- WHERE add_price IS NULL OR add_num IS NULL;--> <!-- WHERE add_price IS NULL OR add_num IS NULL;-->
<!-- </update>--> <!-- </update>-->
<select id="MonthStart" statementType="CALLABLE" >
{call UpdateStartSummary()}
</select>
<select id="MonthEnd" statementType="CALLABLE" >
{call UpdateEndSummary()}
</select>
<select id="MonthDifference" statementType="CALLABLE" >
{call UpdatePriceSummary()}
</select>
<select id="TjOrgPrice" resultType="com.junmp.jyzb.api.bean.dto.TjDto.TjOrgPriceDto">
<!-- select t1.org_id,t1.org_code,t1.org_name,t1.d_name,-->
<!-- t2.start_num,t2.start_price,t2.end_num,t2.end_price,t2.add_num,t2.add_price,t2.destory_num,t2.destory_price-->
<!-- FROM(-->
<!-- SELECT-->
<!-- `org_id`, `org_code`, `org_name`, `d_name`-->
<!-- FROM `pub_org`-->
<!-- WHERE org_id=#{orgId}-->
<!-- ) as t1-->
<!-- CROSS JOIN (select sum(COALESCE(vpss.start_num,0)) as start_num,sum(COALESCE(vpss.start_price,0)) as start_price,-->
<!-- sum(COALESCE(vpss.end_num,0)) as end_num,sum(COALESCE(vpss.end_price,0)) as end_price,-->
<!-- sum(COALESCE(vpss.add_num,0)) as add_num,sum(COALESCE(vpss.destory_num,0)) as destory_num,-->
<!-- sum(COALESCE(vpss.add_price,0)) as add_price,sum(COALESCE(vpss.destory_price,0)) as destory_price-->
<!-- FROM vie_price_sum_summary vpss-->
<!-- left join pub_org po on vpss.org_id_int=po.org_id-->
<!-- where vpss.`year`= #{year} and po.del_flag=1 and (po.org_id=#{orgId} or po.org_parent_ids like CONCAT('%', #{orgId}, '%'))-->
<!-- <if test="typeIdsList!=null and typeIdsList.size() > 0">-->
<!-- and type_id in-->
<!-- <foreach collection="typeIdsList" item="item" open="(" separator="," close=")">-->
<!-- #{item}-->
<!-- </foreach>-->
<!-- </if>-->
<!-- <if test="sizeNameList!=null and sizeNameList.size() > 0">-->
<!-- AND-->
<!-- <foreach collection="sizeNameList " item="item" open="(" separator="or" close=")">-->
<!-- size_name like CONCAT('%', #{item}, '%')-->
<!-- </foreach>-->
<!-- </if>-->
<!-- ) as t2-->
<select id="TjOrgPrice" resultType="com.junmp.jyzb.api.bean.dto.TjDto.TjOrgPriceDto">
SELECT SELECT
t3.org_id,t3.org_code,t3.org_name,t3.d_name,coalesce(t4.start_num,0) as start_num, t3.org_id,t3.org_code,t3.org_name,t3.d_name,coalesce(t4.start_num,0) as start_num,
......
package com.junmp.police.test;
import org.apache.tomcat.util.digester.DocumentProperties;
import java.nio.charset.StandardCharsets;
import java.util.Base64;
public class Base64Test {
public static void main(String args[]){
// String str = "abc";
// byte[] val = str.getBytes(StandardCharsets.UTF_8);
// String base64EncodedChunk = Base64.getEncoder().encodeToString(val);
// System.out.println(base64EncodedChunk);
}
}
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论