食材进销分类

This commit is contained in:
zjf committed 2025-05-28 12:56:34 +08:00
1 parent 642083b78e
commit 01095ce445
4 files changed
+24 -8

No files matched your search

@@ -7,6 +7,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.bsd.pjcloud.canteen.dto.boxes.admin.BokingPageDTO;
import com.bsd.pjcloud.canteen.job.BoxesAvaliabilityJob;
import com.bsd.pjcloud.canteen.vo.AppMakeSaveReqVO;
import com.bsd.pjcloud.common.core.util.R;
import com.bsd.pjcloud.common.log.annotation.SysLog;
@@ -47,6 +48,9 @@ public class BoxesBookingController {
private final BoxesBookingService boxesBookingService;
private final BoxesAvaliabilityJob batchAvaliabilityJob;
/**
* 分页查询
* @param page 分页对象
@@ -157,6 +161,15 @@ public class BoxesBookingController {
}
@Operation(summary = "同步包厢时间" , description = "同步包厢时间" )
@GetMapping("/anscyJob" )
public R getById() {
batchAvaliabilityJob.avaliabilityJobHandler();
return R.ok();
}
//-------------app------------------
// @GetMapping("/getMyBookingPage")
// @Operation(summary = "获得我的预约包厢信息")
@@ -26,7 +26,7 @@ public class BoxesAvaliabilityJob {
private final BoxesAvailabilityMapper boxesAvailabilityMapper;
@XxlJob("avaliabilityJobHandler")
public void demoJobHandler() {
public void avaliabilityJobHandler() {
//查询所有包厢
List<BoxesInfoEntity> rooms = boxesInfoMapper.selectList(null);
@@ -45,6 +45,7 @@ public class CanteenErpMaterialServiceImpl extends ServiceImpl<CanteenErpMateria
canteenErpMaterialEntity.setUnit(canteenErpMaterialSaveDTO.getUnit());
canteenErpMaterialEntity.setDeptId(deptId);
canteenErpMaterialEntity.setPurchasePrice(canteenErpMaterialSaveDTO.getPurchasePrice());
canteenErpMaterialEntity.setCategoryId(canteenErpMaterialSaveDTO.getCategoryId());
int insert = baseMapper.insert(canteenErpMaterialEntity);
CanteenStockEntity canteenStockEntity = new CanteenStockEntity();
canteenStockEntity.setItemType("1");
@@ -66,6 +67,7 @@ public class CanteenErpMaterialServiceImpl extends ServiceImpl<CanteenErpMateria
canteenErpMaterialEntity.setName(canteenErpMaterialEditorDTO.getName());
canteenErpMaterialEntity.setUnit(canteenErpMaterialEditorDTO.getUnit());
canteenErpMaterialEntity.setPurchasePrice(canteenErpMaterialEditorDTO.getPurchasePrice());
canteenErpMaterialEntity.setCategoryId(canteenErpMaterialEditorDTO.getCategoryId());
LambdaQueryWrapper<CanteenStockEntity> canteenStockEntityLambdaQueryWrapper = new LambdaQueryWrapper<>();
canteenStockEntityLambdaQueryWrapper.eq(CanteenStockEntity::getItemId, id);
@@ -105,6 +107,7 @@ public class CanteenErpMaterialServiceImpl extends ServiceImpl<CanteenErpMateria
canteenErpMaterialVO.setInventoryLowerLimit(sourceCanteenStockEntity.getInventoryLowerLimit());
canteenErpMaterialVO.setCurrentStock(sourceCanteenStockEntity.getCurrentStock());
canteenErpMaterialVO.setPurchasePrice(canteenErpMaterialEntity.getPurchasePrice());
canteenErpMaterialVO.setCategoryId(canteenErpMaterialEntity.getCategoryId());
return canteenErpMaterialVO;
}
@@ -21,13 +21,13 @@ spring:
import:
- optional:nacos:application-@profiles.active@.yml
- optional:nacos:${spring.application.name}-@profiles.active@.yml
datasource:
type: com.alibaba.druid.pool.DruidDataSource
druid:
driver-class-name: com.mysql.cj.jdbc.Driver
username: ${MYSQL_USER:root@sys}
password: ${MYSQL_PWD:bsd.1799}
url: jdbc:mysql://${MYSQL_HOST:pjcloud-mysql}:${MYSQL_PORT:2881}/${MYSQL_DB:pjcloudx_job}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true
# datasource:
# type: com.alibaba.druid.pool.DruidDataSource
# druid:
# driver-class-name: com.mysql.cj.jdbc.Driver
# username: ${MYSQL_USER:root@sys}
# password: ${MYSQL_PWD:bsd.1799}
# url: jdbc:mysql://${MYSQL_HOST:pjcloud-mysql}:${MYSQL_PORT:2881}/${MYSQL_DB:pjcloudx_job}?characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8&allowMultiQueries=true&allowPublicKeyRetrieval=true
mvc:
static-path-pattern: /static/**
freemarker: