Parcourir la source

对外报表3

zhouli il y a 9 mois
Parent
commit
cedaa77e8c

+ 0 - 1
kd-ops/kd-resource/src/main/java/org/sky/resource/controller/AttachController.java

@@ -107,5 +107,4 @@ public class AttachController extends KdController {
 		return R.status(attachService.deleteLogic(Func.toLongList(ids)));
 		return R.status(attachService.deleteLogic(Func.toLongList(ids)));
 	}
 	}
 
 
-
 }
 }

+ 1 - 1
kd-service-api/kd-scientific-api/src/main/java/org/sky/scientific/pojo/entity/A107_2.java

@@ -62,5 +62,5 @@ public class A107_2 extends TenantEntity {
 	@Schema(description = "期末企业在境外设立的研究开发机构数")
 	@Schema(description = "期末企业在境外设立的研究开发机构数")
 	private Integer d50;
 	private Integer d50;
 	@Schema(description = "附件")
 	@Schema(description = "附件")
-	private String fj;
+	private String attachment;
 }
 }

+ 54 - 0
kd-service-api/kd-scientific-api/src/main/java/org/sky/scientific/pojo/entity/ArchiveAttachEntity.java

@@ -0,0 +1,54 @@
+package org.sky.scientific.pojo.entity;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import org.sky.core.tenant.mp.TenantEntity;
+
+@EqualsAndHashCode(callSuper = true)
+@Data
+@TableName("kd_archive_attach")
+@Schema(description = "科研档案-附件资料补充")
+public class ArchiveAttachEntity extends TenantEntity {
+
+	@Schema(description = "所属年份")
+	private String yearAndMonth;
+
+	@Schema(description = "高新项目技术鉴定资料")
+	private String d1;
+
+	@Schema(description = "加计扣除项目技术鉴定资料")
+	private String d2;
+
+	@Schema(description = "高新技术企业认定资料")
+	private String d3;
+
+	@Schema(description = "年度主要产品(服务)发挥核心支持作用的技术属于《国家重点支持的高新技术领域》规定范围的说明")
+	private String d4;
+
+	@Schema(description = "高新技术产品(服务)及对应收入资料")
+	private String d5;
+
+	@Schema(description = "年度职工和科技人员情况说明")
+	private String d6;
+
+	@Schema(description = "当年和前两个会计年度研发费用总额及占同期销售收入比例的说明")
+	private String d7;
+
+	@Schema(description = "研发管理制度")
+	private String d8;
+
+	@Schema(description = "研发费用结构明细表")
+	private String d9;
+
+	@Schema(description = "加计扣除情况说明")
+	private String d10;
+
+	@Schema(description = "其他高新备查资料")
+	private String d11;
+
+	@Schema(description = "其他加计扣除备查资料")
+	private String d12;
+
+}

+ 14 - 0
kd-service/kd-scientific/src/main/java/org/sky/scientific/controller/EnterpriseController.java

@@ -159,4 +159,18 @@ public class EnterpriseController extends KdController {
 		return R.status(enterpriseInfoService.gqnbUpdate(highTechYB));
 		return R.status(enterpriseInfoService.gqnbUpdate(highTechYB));
 	}
 	}
 
 
+	@GetMapping("fjbczl")
+	@ApiOperationSupport(order = 50)
+	@Operation(summary = "科研档案管理-附件补充资料")
+	public R<ArchiveAttachEntity> fjbczl(String year) {
+		return R.data(enterpriseInfoService.fjbczl(year));
+	}
+
+	@PostMapping("fjbczl")
+	@ApiOperationSupport(order = 51)
+	@Operation(summary = "科研档案管理-附件补充资料-保存")
+	public R<Boolean> fjbczlUpdate(@Valid @RequestBody ArchiveAttachEntity attach) {
+		return R.status(enterpriseInfoService.fjbczlUpdate(attach));
+	}
+
 }
 }

+ 15 - 0
kd-service/kd-scientific/src/main/java/org/sky/scientific/mapper/ArchiveAttachMapper.java

@@ -0,0 +1,15 @@
+package org.sky.scientific.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.sky.scientific.pojo.entity.ArchiveAttachEntity;
+
+/**
+ * 科研档案-附件资料补充 Mapper 接口
+ *
+ * @author Kd
+ * @since 2025-06-19
+ */
+public interface ArchiveAttachMapper extends BaseMapper<ArchiveAttachEntity> {
+
+
+}

+ 14 - 0
kd-service/kd-scientific/src/main/java/org/sky/scientific/service/IEnterpriseInfoService.java

@@ -100,4 +100,18 @@ public interface IEnterpriseInfoService extends BaseService<EnterpriseInfoEntity
 	 * @return
 	 * @return
 	 */
 	 */
 	boolean gqnbUpdate(HighTechYB highTechYB);
 	boolean gqnbUpdate(HighTechYB highTechYB);
+
+	/**
+	 * 科研档案-附件资料补充
+	 * @param year
+	 * @return
+	 */
+	ArchiveAttachEntity fjbczl(String year);
+
+	/**
+	 * 科研档案-附件资料补充-修改
+	 * @param attach
+	 * @return
+	 */
+	boolean fjbczlUpdate(ArchiveAttachEntity attach);
 }
 }

+ 84 - 2
kd-service/kd-scientific/src/main/java/org/sky/scientific/service/impl/EnterpriseInfoServiceImpl.java

@@ -52,6 +52,7 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 	private final CgJsbzMapper jsbzMapper;
 	private final CgJsbzMapper jsbzMapper;
 	private final CgRjzzqMapper rjzzqMapper;
 	private final CgRjzzqMapper rjzzqMapper;
 	private final CgQtMapper qtMapper;
 	private final CgQtMapper qtMapper;
+	private final ArchiveAttachMapper attachMapper;
 
 
 	@Override
 	@Override
 	@Transactional
 	@Transactional
@@ -165,6 +166,7 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 			vo.setD48(db.getD48());
 			vo.setD48(db.getD48());
 			vo.setD49(db.getD49());
 			vo.setD49(db.getD49());
 			vo.setD50(db.getD50());
 			vo.setD50(db.getD50());
+			vo.setAttachment(db.getAttachment());
 		}
 		}
 
 
 		//一、研究开发人员情况
 		//一、研究开发人员情况
@@ -300,7 +302,22 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 			throw new ServiceException("参数year为年份,如2025");
 			throw new ServiceException("参数year为年份,如2025");
 		}
 		}
 		A107012VO vo = new A107012VO();
 		A107012VO vo = new A107012VO();
+		A107012 one = a107012Mapper.selectOne(Wrappers.<A107012>lambdaQuery().eq(A107012::getYearAndMonth, year));
 
 
+		BigDecimal d43=new BigDecimal("0.00"),d44=new BigDecimal("0.00"),d46=new BigDecimal("0.00"),d48=new BigDecimal("0.00"),d49=new BigDecimal("0.00");
+		if(Func.notNull(one)){
+			d43 = one.getD43();
+			d44 = one.getD44();
+			d46 = one.getD46();
+			d48 = one.getD48();
+			d49 = one.getD49();
+
+		}
+		vo.setD43(d43);
+		vo.setD44(d44);
+		vo.setD46(d46);
+		vo.setD48(d48);
+		vo.setD49(d49);
 
 
 		return vo;
 		return vo;
 	}
 	}
@@ -320,7 +337,36 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 
 
 	@Override
 	@Override
 	public A107041VO gxjsqyyhqkjmxb(String year) {
 	public A107041VO gxjsqyyhqkjmxb(String year) {
-		return new A107041VO();
+		if(Func.isNull(year)){
+			throw new ServiceException("参数year不能为空");
+		}
+		if(year.length() != 4){
+			throw new ServiceException("参数year为年份,如2025");
+		}
+
+		A107041VO vo = new A107041VO();
+
+		A107041 one = a107041Mapper.selectOne(Wrappers.<A107041>lambdaQuery().eq(A107041::getYearAndMonth, year));
+
+		BigDecimal d5 = new BigDecimal("0.00"),d6 = new BigDecimal("0.00"),d8 = new BigDecimal("0.00"),d9 = new BigDecimal("0.00");
+		int d12=0;
+		BigDecimal d29_1 = new BigDecimal("0.00"),d29_2 = new BigDecimal("0.00"),d29_3 = new BigDecimal("0.00"),d31 = new BigDecimal("0.00"),d32 = new BigDecimal("0.00");
+
+		if(Func.notNull(one)){
+			d5 = one.getD5();
+			d6=one.getD6();d8=one.getD8();
+			d9=one.getD9();
+			d12 = one.getD12();
+			d29_1 = one.getD29_1();
+			d29_2=one.getD29_2();
+			d29_3=one.getD29_3();
+			d31=one.getD31();
+			d32=one.getD32();
+		}
+
+
+
+		return vo;
 	}
 	}
 
 
 	@Override
 	@Override
@@ -338,7 +384,6 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 
 
 	@Override
 	@Override
 	public HighTechYBVO gqnb(String year) {
 	public HighTechYBVO gqnb(String year) {
-
 		if(Func.isNull(year)){
 		if(Func.isNull(year)){
 			throw new ServiceException("参数year不能为空");
 			throw new ServiceException("参数year不能为空");
 		}
 		}
@@ -418,4 +463,41 @@ public class EnterpriseInfoServiceImpl extends BaseServiceImpl<EnterpriseInfoMap
 			return highTechYbMapper.updateById(highTechYB) == 1;
 			return highTechYbMapper.updateById(highTechYB) == 1;
 		}
 		}
 	}
 	}
+
+	@Override
+	public ArchiveAttachEntity fjbczl(String year) {
+		if(Func.isNull(year)){
+			throw new ServiceException("参数year不能为空");
+		}
+		if(year.length() != 4){
+			throw new ServiceException("参数year为年份,如2025");
+		}
+
+		ArchiveAttachEntity attach = attachMapper.selectOne(Wrappers.<ArchiveAttachEntity>lambdaQuery().eq(ArchiveAttachEntity::getYearAndMonth, year));
+		if(Func.isNull(attach)){
+			attach = new ArchiveAttachEntity();
+		}
+
+		return attach;
+	}
+
+	@Override
+	public boolean fjbczlUpdate(ArchiveAttachEntity attach) {
+		if(Func.isNull(attach.getYearAndMonth())){
+			throw new ServiceException("参数yearAndMonth不能为空");
+		}
+		if(attach.getYearAndMonth().length() != 4){
+			throw new ServiceException("参数yearAndMonth为年份,如2025");
+		}
+		LambdaQueryWrapper<ArchiveAttachEntity> eq = Wrappers.<ArchiveAttachEntity>lambdaQuery().eq(ArchiveAttachEntity::getYearAndMonth, attach.getYearAndMonth());
+		ArchiveAttachEntity one = attachMapper.selectOne(eq);
+		if (Func.isNull(one)) {
+			attach.setTenantId(SecureUtil.getTenantId());
+			return attachMapper.insert(attach) == 1;
+		} else {
+			attach.setId(one.getId());
+			return attachMapper.updateById(attach) == 1;
+		}
+	}
+
 }
 }