仓储管理模块修改

This commit is contained in:
dingjie 2023-12-20 20:28:42 +08:00
parent 90660f5a1b
commit a729039137
26 changed files with 221 additions and 38 deletions

View File

@ -17,6 +17,11 @@ public class MaMachine extends BaseEntity {
*/
@ApiModelProperty(value = "类型ID")
private long typeId;
/**
* 类型ID
*/
@ApiModelProperty(value = "类型ID")
private long propId;
/**
* 物品种类
*/
@ -137,6 +142,11 @@ public class MaMachine extends BaseEntity {
*/
@ApiModelProperty(value = "数据所属组织")
private String companyId;
/**
* 标签编号
*/
@ApiModelProperty(value = "标签编号")
private String labelCode;
public long getMaId() {
@ -367,4 +377,20 @@ public class MaMachine extends BaseEntity {
public void setMaStatusName(String maStatusName) {
this.maStatusName = maStatusName;
}
public String getLabelCode() {
return labelCode;
}
public void setLabelCode(String labelCode) {
this.labelCode = labelCode;
}
public long getPropId() {
return propId;
}
public void setPropId(long propId) {
this.propId = propId;
}
}

View File

@ -174,6 +174,10 @@ public class MaType extends BaseEntity {
@ApiModelProperty(value = "资产属性名称")
private String propName;
/** 资产属性名称 */
@ApiModelProperty(value = "类型编码")
private String code;
/** 子节点 */
@JsonInclude(JsonInclude.Include.NON_EMPTY)
private List<MaType> children = new ArrayList<>();
@ -500,4 +504,20 @@ public class MaType extends BaseEntity {
public void setLabel(String label) {
this.label = label;
}
public Date getEffTime() {
return effTime;
}
public void setEffTime(Date effTime) {
this.effTime = effTime;
}
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
}

View File

@ -29,11 +29,10 @@ public class MaHouseController extends BaseController {
*/
@ApiOperation(value = "查询仓库货架列表")
@GetMapping("/list")
public TableDataInfo list(MaHouse house)
public AjaxResult list(MaHouse house)
{
startPage();
List<MaHouse> list = houseService.selectHouseList(house);
return getDataTable(list);
return AjaxResult.success(list);
}
/**

View File

@ -80,6 +80,18 @@ public class MaHouseSet {
@ApiModelProperty(value= "数据所属组织")
private String companyId;
@ApiModelProperty(value = "规格型号")
private String specificationType;
@ApiModelProperty(value = "机具类型名称")
private String machineTypeName;
@ApiModelProperty(value = "物品种类")
private String itemType;
@ApiModelProperty(value = "设备编码")
private String maCode;
public long getId() {
return id;
}
@ -211,4 +223,36 @@ public class MaHouseSet {
public void setShelfNum(String shelfNum) {
this.shelfNum = shelfNum;
}
public String getSpecificationType() {
return specificationType;
}
public void setSpecificationType(String specificationType) {
this.specificationType = specificationType;
}
public String getMachineTypeName() {
return machineTypeName;
}
public void setMachineTypeName(String machineTypeName) {
this.machineTypeName = machineTypeName;
}
public String getItemType() {
return itemType;
}
public void setItemType(String itemType) {
this.itemType = itemType;
}
public String getMaCode() {
return maCode;
}
public void setMaCode(String maCode) {
this.maCode = maCode;
}
}

View File

@ -2,6 +2,8 @@ package com.bonus.sgzb.base.domain;
import lombok.Data;
import java.util.Date;
@Data
public class MaPropSet {
/**
@ -31,7 +33,7 @@ public class MaPropSet {
/**
* 创建时间
*/
private java.sql.Timestamp createTime;
private Date createTime;
/**
* 更新者
*/
@ -39,7 +41,7 @@ public class MaPropSet {
/**
* 更新时间
*/
private java.sql.Timestamp updateTime;
private Date updateTime;
/**
* 备注
*/

View File

@ -3,6 +3,7 @@ package com.bonus.sgzb.base.mapper;
import java.util.List;
import com.bonus.sgzb.base.domain.BmUnitType;
import com.bonus.sgzb.system.api.domain.SysDept;
import org.apache.ibatis.annotations.Mapper;
/**
* 单位类型bm_unit_type同数据字典合并Mapper接口
@ -10,6 +11,7 @@ import com.bonus.sgzb.system.api.domain.SysDept;
* @author bonus
* @date 2023-12-11
*/
@Mapper
public interface BmUnitTypeMapper
{
/**

View File

@ -1,6 +1,7 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaHouse;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
@ -10,6 +11,7 @@ import java.util.List;
*
* @author ruoyi
*/
@Mapper
public interface MaHouseMapper {
/**
* 校验项目名称

View File

@ -1,9 +1,11 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaHouseSet;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface MaHouseSetMapper {
public List<MaHouseSet> getHouseSetList(MaHouseSet maHouseSet);

View File

@ -1,6 +1,7 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaPartType;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -10,6 +11,7 @@ import java.util.List;
* @author makejava
* @since 2023-11-27 16:44:07
*/
@Mapper
public interface MaPartTypeMapper {
/**

View File

@ -3,6 +3,7 @@ package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.api.domain.MaType;
import com.bonus.sgzb.base.domain.MaPropInfo;
import com.bonus.sgzb.base.domain.MaPropSet;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -12,6 +13,7 @@ import java.util.List;
* @author makejava
* @since 2023-11-28 10:18:07
*/
@Mapper
public interface MaPropInfoMapper {
/**

View File

@ -1,6 +1,7 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaSupplierInfo;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -10,6 +11,7 @@ import java.util.List;
* @author bonus
* @date 2023-12-10
*/
@Mapper
public interface MaSupplierInfoMapper
{
/**

View File

@ -1,6 +1,7 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaTypeFile;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -10,6 +11,7 @@ import java.util.List;
* @author bonus
* @date 2023-12-11
*/
@Mapper
public interface MaTypeFileMapper
{
/**

View File

@ -1,9 +1,11 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaTypeHisNum;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface MaTypeHisNumMapper {
public List<MaTypeHisNum> getTypeHisNum(MaTypeHisNum maTypeHisNum);

View File

@ -1,9 +1,11 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.domain.MaTypeHisPrice;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface MaTypeHisPriceMapper {
public List<MaTypeHisPrice> getTypeHisPrice(MaTypeHisPrice maTypeHisPrice);

View File

@ -2,6 +2,7 @@ package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.vo.DeptUser;
import com.bonus.sgzb.base.vo.MaTypeKeeperVO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -11,6 +12,7 @@ import java.util.List;
* @author makejava
* @since 2023-11-28 11:07:26
*/
@Mapper
public interface MaTypeKeeperMapper {
/**

View File

@ -1,6 +1,7 @@
package com.bonus.sgzb.base.mapper;
import com.bonus.sgzb.base.api.domain.SysDic;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -11,6 +12,7 @@ import java.util.List;
* @author bonus
* @date 2023-12-11
*/
@Mapper
public interface SysDicMapper
{
/**

View File

@ -7,6 +7,7 @@ import com.bonus.sgzb.base.service.IhouseService;
import com.bonus.sgzb.common.core.constant.UserConstants;
import com.bonus.sgzb.common.core.exception.ServiceException;
import com.bonus.sgzb.common.core.utils.StringUtils;
import com.bonus.sgzb.common.security.utils.SecurityUtils;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
@ -70,6 +71,7 @@ public class MaHouseServiceImpl implements IhouseService {
{
throw new ServiceException("仓库货架停用,不允许新增");
}
house.setCreateBy(SecurityUtils.getUsername());
return houseMapper.insertHouse(house);
}

View File

@ -2,12 +2,21 @@ package com.bonus.sgzb.base.service.impl;
import com.bonus.sgzb.base.api.domain.MaMachine;
import com.bonus.sgzb.base.api.domain.MaType;
import com.bonus.sgzb.base.domain.MaLabelBind;
import com.bonus.sgzb.base.domain.MaPropSet;
import com.bonus.sgzb.base.mapper.MaLabelBindMapper;
import com.bonus.sgzb.base.mapper.MaMachineMapper;
import com.bonus.sgzb.base.mapper.MaPropInfoMapper;
import com.bonus.sgzb.base.mapper.MaTypeMapper;
import com.bonus.sgzb.base.service.MaMachineService;
import com.bonus.sgzb.base.vo.MaLabelBindVO;
import com.bonus.sgzb.common.security.utils.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.Date;
import java.util.List;
@Service
@ -19,6 +28,12 @@ public class MaMachineServiceImpl implements MaMachineService {
@Resource
private MaTypeMapper typeMapper;
@Resource
private MaLabelBindMapper labelBindMapper;
@Resource
private MaPropInfoMapper maPropInfoMapper;
@Override
public List<MaMachine> getMaMachine(MaMachine maMachine) {
@ -43,9 +58,33 @@ public class MaMachineServiceImpl implements MaMachineService {
machine.setItemType(maType2.getTypeName());
}
/**
* 新增机具设备
* @param maMachine 机具设备信息
* @return 结果
*/
@Override
@Transactional
public int maMachineAdd(MaMachine maMachine) {
return maMachineMapper.maMachineAdd(maMachine);
int i = maMachineMapper.maMachineAdd(maMachine);
// 新增标签绑定
MaLabelBind maLabelBind = new MaLabelBind();
String labelCode = maMachine.getLabelCode();
maLabelBind.setLabelCode(labelCode);
maLabelBind.setMaId(maMachine.getMaId());
maLabelBind.setTypeId(maMachine.getTypeId());
labelBindMapper.insertLabelBind(maLabelBind);
// 新增机具和资产属性绑定关系
MaPropSet maPropSet = new MaPropSet();
maPropSet.setTypeId(maMachine.getTypeId());
maPropSet.setPropId(maMachine.getPropId());
maPropSet.setCreateTime(new Date());
maPropSet.setCreateBy(SecurityUtils.getUsername());
maPropSet.setCompanyId(maMachine.getCompanyId());
maPropInfoMapper.insertMaPropSet(maPropSet);
return i;
}
@Override

View File

@ -61,7 +61,7 @@ public class MaTypeServiceImpl implements ITypeService {
typeFile.setTypeId(typeId);
typeFile.setFileName(maType.getPhotoName());
typeFile.setFileUrl(maType.getPhotoUrl());
typeFile.setFileType("");
typeFile.setFileType("1");
typeFileMapper.insertMaTypeFile(typeFile);
}
// 文档路径保存
@ -70,7 +70,7 @@ public class MaTypeServiceImpl implements ITypeService {
typeFile1.setTypeId(typeId);
typeFile1.setFileName(maType.getDocumentName());
typeFile1.setFileUrl(maType.getDocumentUrl());
typeFile1.setFileType("");
typeFile1.setFileType("2");
typeFileMapper.insertMaTypeFile(typeFile1);
}
// 库管员配置

View File

@ -89,29 +89,36 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getHouseSetList" resultType="com.bonus.sgzb.base.domain.MaHouseSet">
select house_id, type_id, ma_id, num, status, dept_id, del_flag, create_by, create_time, update_by,update_time,remark,company_id
from ma_house_set
select mhs.house_id, mhs.type_id, mhs.ma_id, mhs.num, mhs.status, mhs.dept_id, mhs.del_flag,
mhs.create_by, mhs.create_time, mhs.update_by,mhs.update_time,mhs.remark,mhs.company_id,
mm.ma_code maCode , mt.type_name specificationType, mt1.type_name machineTypeName, mt2.type_name itemType
from ma_house_set mhs
left join ma_machine mm on mhs.ma_id = mm.ma_id
left join ma_type mt on mhs.type_id = mt.type_id
left join ma_type mt1 on mt.parent_id = mt1.type_id
left join ma_type mt2 on mt1.parent_id = mt2.type_id
<where>
<if test="houseId != null and houseId != ''">
AND house_id = #{houseId}
AND mhs.house_id = #{houseId}
</if>
<if test="typeId != null and typeId != ''">
AND type_id = #{typeId}
AND mhs.type_id = #{typeId}
</if>
<if test="maId != null and maId != ''">
AND ma_id = #{maId}
AND mhs.ma_id = #{maId}
</if>
<if test="status != null and status != ''">
and status = #{status}
and mhs.status = #{status}
</if>
<if test="deptId != null and deptId != ''">
and dept_id = #{deptId}
and mhs.dept_id = #{deptId}
</if>
<if test="delFlag != null and delFlag != ''">
and del_flag = #{delFlag}
and mhs.del_flag = #{delFlag}
</if>
<if test="companyId != null and companyId != ''">
and company_id = #{companyId}
and mhs.company_id = #{companyId}
</if>
</where>
</select>

View File

@ -39,12 +39,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getMaMachine" parameterType="com.bonus.sgzb.base.api.domain.MaMachine" resultMap="MaMachineResult">
select m.ma_id, m.type_id, m.ma_code, m.pre_code, m.ma_status, dic.name maStatusName, m.qr_code, m.buy_price, m.ma_vender, m.out_fac_time, m.out_fac_code,
m.assets_code, m.check_man, m.this_check_time, m.next_check_time, m.gps_code, m.rfid_code, m.erp_code, m.transfer_code,
m.in_out_num, m.buy_task, m.own_house ,m.company_id ,mt.type_name specificationType,mt1.type_name deviceType, mt2.type_name itemType
m.in_out_num, m.buy_task, m.own_house ,m.company_id ,mt.type_name specificationType,mt1.type_name deviceType, mt2.type_name itemType,
mmb.label_code labelCode
from ma_machine m
left join (select id,p_id,name from sys_dic where p_id in (select id from sys_dic where value = 'ma_status')) dic on m.ma_status = dic.id
left join ma_type mt on m.type_id = mt.type_id
left join ma_type mt1 on mt.parent_id = mt1.type_id
left join ma_type mt2 on mt1.parent_id = mt2.type_id
left join ma_label_bind mmb on m.ma_id = mmb.ma_id and m.type_id = mmb.type_id
<where>
<if test="maId != null and maId != ''">
AND ma_id = #{maId}

View File

@ -9,9 +9,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="parentId" column="parent_id" />
<result property="status" column="status" />
<result property="num" column="num" />
<result property="companyId" column="company_id" />
<result property="code" column="code" />
<result property="unitId" column="unit_id" />
<result property="unitName" column="unit_name" />
<result property="manageType" column="manage_type" />
<result property="leasePrice" column="lease_price" />
<result property="effTime" column="eff_time" />
<result property="rentPrice" column="rent_price" />
<result property="buyPrice" column="buy_price" />
<result property="payPrice" column="pay_price" />
@ -28,12 +32,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="isPlan" column="is_plan" />
<result property="isAncuo" column="is_ancuo" />
<result property="remark" column="remark" />
<result property="companyId" column="company_id" />
</resultMap>
<sql id="selectMaTypeVo">
select type_id, type_name, parent_id, status, num, unit_id, manage_type, lease_price, buy_price, pay_price, level, rated_load, test_load, holding_time, warn_num, del_flag, create_by, create_time, remark, company_id
from ma_type
select type_id, type_name, parent_id, status, num, company_id, code, unit_id, unit_name, manage_type, lease_price, eff_time, rent_price, buy_price, pay_price, level, rated_load, test_load, holding_time, warn_num, del_flag, create_by, create_time, update_by, update_time, is_plan, is_ancuo, remark from ma_type
</sql>
<insert id="insertType" parameterType="com.bonus.sgzb.base.api.domain.MaType" useGeneratedKeys="true" keyProperty="typeId">
@ -43,9 +45,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="parentId != null">parent_id,</if>
<if test="status != null">status,</if>
<if test="num != null">num,</if>
<if test="companyId != null">company_id,</if>
<if test="code != null">code,</if>
<if test="unitId != null">unit_id,</if>
<if test="unitName != null">unit_name,</if>
<if test="manageType != null">manage_type,</if>
<if test="leasePrice != null">lease_price,</if>
<if test="effTime != null">eff_time,</if>
<if test="rentPrice != null">rent_price,</if>
<if test="buyPrice != null">buy_price,</if>
<if test="payPrice != null">pay_price,</if>
<if test="level != null">level,</if>
@ -61,16 +68,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="isPlan != null">is_plan,</if>
<if test="isAncuo != null">is_ancuo,</if>
<if test="remark != null">remark,</if>
<if test="companyId != null">company_id,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="typeName != null and typeName != ''">#{typeName},</if>
<if test="parentId != null">#{parentId},</if>
<if test="status != null">#{status},</if>
<if test="num != null">#{num},</if>
<if test="companyId != null">#{companyId},</if>
<if test="code != null">#{code},</if>
<if test="unitId != null">#{unitId},</if>
<if test="unitName != null">#{unitName},</if>
<if test="manageType != null">#{manageType},</if>
<if test="leasePrice != null">#{leasePrice},</if>
<if test="effTime != null">#{effTime},</if>
<if test="rentPrice != null">#{rentPrice},</if>
<if test="buyPrice != null">#{buyPrice},</if>
<if test="payPrice != null">#{payPrice},</if>
<if test="level != null">#{level},</if>
@ -86,7 +97,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="isPlan != null">#{isPlan},</if>
<if test="isAncuo != null">#{isAncuo},</if>
<if test="remark != null">#{remark},</if>
<if test="companyId != null">#{companyId},</if>
</trim>
</insert>
@ -122,8 +132,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="status != null">status = #{status},</if>
<if test="num != null">num = #{num},</if>
<if test="unitId != null">unit_id = #{unitId},</if>
<if test="unitName != null">unit_name = #{unitName},</if>
<if test="manageType != null">manage_type = #{manageType},</if>
<if test="leasePrice != null">lease_price = #{leasePrice},</if>
<if test="effTime != null">eff_time = #{effTime},</if>
<if test="buyPrice != null">buy_price = #{buyPrice},</if>
<if test="payPrice != null">pay_price = #{payPrice},</if>
<if test="level != null">level = #{level},</if>
@ -150,7 +162,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectMaTypeList" parameterType="String" resultMap="MaTypeResult">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price,m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, mtf.file_name photoName, mtf.file_url photoUrl,
mtf2.file_name documentName, mtf2.file_url documentUrl, mtk.user_id keeperUserId,
su.user_name keeperUserName, mpi.prop_name, m.del_flag, m.create_by, m.create_time,
@ -251,18 +263,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectMaTypeByTypeId" resultMap="MaTypeResult">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price, m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, mtf.file_name photoName, mtf.file_url photoUrl,
mtf2.file_name documentName, mtf2.file_url documentUrl, mtk.user_id keeperUserId,
su.user_name keeperUserName, mpi.prop_name, m.del_flag, m.create_by, m.create_time,
su.user_name keeperUserName, mtr.user_id repairUserId, su1.user_name repairUserName, mpi.prop_name,
m.del_flag, m.create_by, m.create_time,
m.remark, m.company_id
from ma_type m
left join ma_prop_set mps on m.type_id = mps.type_id
left join ma_prop_info mpi on mps.prop_id = mpi.prop_id
left join (select * from ma_type_file where file_type = '1') mtf on m.type_id = mtf.type_id
left join (select * from ma_type_file where file_type = '2') mtf2 on m.type_id = mtf2.type_id
left join ma_type_keeper mtk on mtf.type_id = mtk.type_id
left join ma_type_keeper mtk on m.type_id = mtk.type_id
left join sys_user su on mtk.user_id = su.user_id
left join ma_type_repair mtr on m.type_id = mtr.type_id
left join sys_user su1 on mtr.user_id = su1.user_id
where m.type_id = #{typeId} and m.status = '0'
</select>
@ -285,7 +300,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectMaTypeTree" resultMap="MaTypeResult" parameterType="java.lang.String">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price, m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, m.del_flag, m.create_by, m.create_time,
m.remark, m.company_id
from ma_type m
@ -293,7 +308,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<select id="getMaTypeSelect" resultType="com.bonus.sgzb.base.api.domain.MaType">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price,m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, m.del_flag, m.create_by, m.create_time,
m.remark, m.company_id
from ma_type m
@ -304,7 +319,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getListByParentId" resultMap="MaTypeResult">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.unit_name, m.manage_type,
m.lease_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price, m.eff_time, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, mtf.file_name photoName, mtf.file_url photoUrl,
mtf2.file_name documentName, mtf2.file_url documentUrl, mtk.user_id keeperUserId,
su.user_name keeperUserName, mpi.prop_name, m.del_flag, m.create_by, m.create_time,
@ -314,7 +329,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join ma_prop_info mpi on mps.prop_id = mpi.prop_id
left join (select * from ma_type_file where file_type = '1') mtf on m.type_id = mtf.type_id
left join (select * from ma_type_file where file_type = '2') mtf2 on m.type_id = mtf2.type_id
left join ma_type_keeper mtk on mtf.type_id = mtk.type_id
left join ma_type_keeper mtk on m.type_id = mtk.type_id
left join sys_user su on mtk.user_id = su.user_id
where m.parent_id = #{typeId} and m.status = '0' and m.del_flag = '0'
<if test="typeName != null and typeName !=''">
@ -324,7 +339,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectMaTypeTreeByLevel" resultMap="MaTypeResult" parameterType="java.lang.String">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price, m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, m.del_flag, m.create_by, m.create_time,
m.remark, m.company_id
from ma_type m
@ -335,7 +350,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectMaTypeListByLevelNotFour" resultMap="MaTypeResult">
select m.type_id, m.type_name, m.parent_id, m.status, m.num, m.unit_id, m.manage_type,
m.lease_price, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.lease_price, m.eff_time, m.rent_price, m.buy_price, m.pay_price, m.level, m.rated_load, m.test_load,
m.holding_time, m.warn_num, m.del_flag, m.create_by, m.create_time,
m.remark, m.company_id
from ma_type m

View File

@ -130,7 +130,7 @@ public class PurchaseCheckInfoServiceImpl implements IPurchaseCheckInfoService
// 采购单号编码生成规则
private String purchaseCodeRule() {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyyMMdd");
Date nowDate = DateUtils.getNowDate();
String format = dateFormat.format(nowDate);
int taskNum = taskMapper.selectTaskNumByMonth(nowDate,23) + 1;

View File

@ -230,12 +230,17 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
}
}
// 修饰审核通过时改修任务为已通过审核
task1.setTaskStatus(47);
task1.setUpdateTime(new Date());
task1.setUpdateBy(SecurityUtils.getUsername());
taskMapper.updateTmTask(task1);
} else {
// 修饰审核任务不通过时
TmTask tmTask = new TmTask();
tmTask.setTaskId(taskId);
tmTask.setRemark(scrapAudit.getRemark());
tmTask.setTaskStatus(47);
tmTask.setTaskStatus(48);
tmTask.setUpdateTime(new Date());
tmTask.setUpdateBy(SecurityUtils.getUsername());
taskMapper.updateTmTask(tmTask);
@ -247,7 +252,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
// 采购单号编码生成规则
private String purchaseCodeRule(String code,Integer taskType) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyyMMdd");
Date nowDate = DateUtils.getNowDate();
String format = dateFormat.format(nowDate);
int taskNum = taskMapper.selectTaskNumByMonth(nowDate,taskType) + 1;

View File

@ -152,7 +152,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectScrapAuditList" resultMap="ScrapApplyDetailsResult">
select sad.* ,mt.type_name specificationType, mt1.type_name machineTypeName, mma.ma_code maCode
from scrap_apply_details sad
left join ma_type mt on pcd.type_id = mt.type_id
left join ma_type mt on sad.type_id = mt.type_id
left join ma_type mt1 on mt.parent_id = mt1.type_id
left join ma_machine mma on sad.ma_id= mma.ma_id
where sad.task_id = #{taskId}

View File

@ -46,6 +46,6 @@ public class ResourcesConfig implements WebMvcConfigurer
// 设置允许跨域请求的域名
.allowedOrigins("*")
// 设置允许的方法
.allowedMethods("GET");
.allowedMethods("*");
}
}