Commit be55e869 authored by 曹盼盼's avatar 曹盼盼

修改校验和弹窗

parent 95a5cdad
...@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.ugp.api.mapper; ...@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.ugp.api.mapper;
import com.yeejoin.amos.boot.module.ugp.api.dto.AttachmentDto; import com.yeejoin.amos.boot.module.ugp.api.dto.AttachmentDto;
import com.yeejoin.amos.boot.module.ugp.api.entity.Attachment; import com.yeejoin.amos.boot.module.ugp.api.entity.Attachment;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
/** /**
...@@ -19,4 +20,6 @@ public interface AttachmentMapper extends BaseMapper<Attachment> { ...@@ -19,4 +20,6 @@ public interface AttachmentMapper extends BaseMapper<Attachment> {
//根据source_id查询附件 //根据source_id查询附件
AttachmentDto selectAttBySeq(Long sourceId); AttachmentDto selectAttBySeq(Long sourceId);
@Select("select info from tz_ugp_attachment where source_id =#{sourceId}")
AttachmentDto getAttachment(Long sourceId);
} }
...@@ -12,6 +12,8 @@ import com.yeejoin.amos.boot.module.ugp.api.mapper.AttachmentMapper; ...@@ -12,6 +12,8 @@ import com.yeejoin.amos.boot.module.ugp.api.mapper.AttachmentMapper;
import com.yeejoin.amos.boot.module.ugp.api.service.IAttachmentService; import com.yeejoin.amos.boot.module.ugp.api.service.IAttachmentService;
import com.yeejoin.amos.boot.module.ugp.api.dto.AttachmentDto; import com.yeejoin.amos.boot.module.ugp.api.dto.AttachmentDto;
import com.yeejoin.amos.boot.module.ugp.biz.framework.BusinessIdentify; import com.yeejoin.amos.boot.module.ugp.biz.framework.BusinessIdentify;
import org.apache.commons.lang.StringUtils;
import org.checkerframework.checker.units.qual.A;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.typroject.tyboot.core.foundation.utils.ValidationUtil; import org.typroject.tyboot.core.foundation.utils.ValidationUtil;
import org.typroject.tyboot.core.rdbms.service.BaseService; import org.typroject.tyboot.core.rdbms.service.BaseService;
...@@ -38,6 +40,8 @@ public class AttachmentServiceImpl extends BaseService<AttachmentDto,Attachment, ...@@ -38,6 +40,8 @@ public class AttachmentServiceImpl extends BaseService<AttachmentDto,Attachment,
@Autowired @Autowired
OrgUsrServiceImpl orgUsrService; OrgUsrServiceImpl orgUsrService;
@Autowired
private AttachmentMapper attachmentMapper;
/** /**
* 分页查询 * 分页查询
*/ */
...@@ -97,4 +101,14 @@ public class AttachmentServiceImpl extends BaseService<AttachmentDto,Attachment, ...@@ -97,4 +101,14 @@ public class AttachmentServiceImpl extends BaseService<AttachmentDto,Attachment,
return map; return map;
} }
//source_id和附件类型查询数据
public AttachmentDto getAttachment(Long sourceId){
if (sourceId == null ) {
return new AttachmentDto();
}
return attachmentMapper.getAttachment(sourceId);
}
} }
\ No newline at end of file
...@@ -227,4 +227,9 @@ public class EquipmentServiceImpl extends BaseService<EquipmentDto, Equipment, E ...@@ -227,4 +227,9 @@ public class EquipmentServiceImpl extends BaseService<EquipmentDto, Equipment, E
} }
public Equipment getEquipment(Long e){
return equipmentMapper.selectById(e);
}
} }
\ No newline at end of file
...@@ -15,6 +15,7 @@ import com.yeejoin.amos.boot.module.ugp.api.mapper.AttachmentMapper; ...@@ -15,6 +15,7 @@ import com.yeejoin.amos.boot.module.ugp.api.mapper.AttachmentMapper;
import com.yeejoin.amos.boot.module.ugp.api.mapper.MaterialMapper; import com.yeejoin.amos.boot.module.ugp.api.mapper.MaterialMapper;
import com.yeejoin.amos.boot.module.ugp.api.service.IMaterialService; import com.yeejoin.amos.boot.module.ugp.api.service.IMaterialService;
import com.yeejoin.amos.boot.module.ugp.biz.framework.BusinessIdentify; import com.yeejoin.amos.boot.module.ugp.biz.framework.BusinessIdentify;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.typroject.tyboot.core.foundation.utils.ValidationUtil; import org.typroject.tyboot.core.foundation.utils.ValidationUtil;
...@@ -39,6 +40,8 @@ public class MaterialServiceImpl extends BaseService<MaterialDto, Material, Mate ...@@ -39,6 +40,8 @@ public class MaterialServiceImpl extends BaseService<MaterialDto, Material, Mate
AttachmentMapper attachmentMapper; AttachmentMapper attachmentMapper;
@Autowired @Autowired
OrgServiceImpl orgService; OrgServiceImpl orgService;
@Autowired
MaterialMapper materialMapper;
/** /**
* 分页查询 * 分页查询
*/ */
...@@ -165,4 +168,9 @@ public class MaterialServiceImpl extends BaseService<MaterialDto, Material, Mate ...@@ -165,4 +168,9 @@ public class MaterialServiceImpl extends BaseService<MaterialDto, Material, Mate
} }
return jsonObject; return jsonObject;
} }
public Material getMaterial(Long materialId){
Material material = materialMapper.selectById(materialId);
return material;
}
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment