Commit ddbcf971 authored by kevin's avatar kevin

Merge branch 'dev_mysql' of http://code.tech.tax.asia.pwcinternal.com/root/atms into dev_mysql

parents b047a373 2339e2cb
...@@ -27,6 +27,7 @@ import java.util.*; ...@@ -27,6 +27,7 @@ import java.util.*;
*/ */
public class JxlsUtils { public class JxlsUtils {
private static final Logger log = LoggerFactory.getLogger(JxlsUtils.class); private static final Logger log = LoggerFactory.getLogger(JxlsUtils.class);
public static String sheetName = "汇总表";
public static void toPackageOs(HttpServletResponse response , String fileName) { public static void toPackageOs(HttpServletResponse response , String fileName) {
ResponseUtil.response(response, fileName, null); ResponseUtil.response(response, fileName, null);
...@@ -81,8 +82,8 @@ public class JxlsUtils { ...@@ -81,8 +82,8 @@ public class JxlsUtils {
AreaBuilder areaBuilder = new XlsCommentAreaBuilder(trans); AreaBuilder areaBuilder = new XlsCommentAreaBuilder(trans);
List<Area> areaList = areaBuilder.build(); List<Area> areaList = areaBuilder.build();
//"汇总表!A1"
areaList.get(0).applyAt(new CellRef("汇总表!A1"), context); areaList.get(0).applyAt(new CellRef( sheetName + "!A1"), context);
try { try {
trans.write(); trans.write();
......
...@@ -29,7 +29,7 @@ import static javax.servlet.http.HttpServletResponse.SC_OK; ...@@ -29,7 +29,7 @@ import static javax.servlet.http.HttpServletResponse.SC_OK;
* @description CIT报表生成(数据处理) * @description CIT报表生成(数据处理)
*/ */
@RestController @RestController
@RequestMapping(value = "api/v1/citReport") @RequestMapping(value = "/api/v1/citReport/")
public class CitReportController { public class CitReportController {
private static Logger logger = LoggerFactory.getLogger(CitReportController.class); private static Logger logger = LoggerFactory.getLogger(CitReportController.class);
...@@ -68,17 +68,35 @@ public class CitReportController { ...@@ -68,17 +68,35 @@ public class CitReportController {
/** /**
* 生成CIT总分机构分配表 * 生成CIT总分机构分配表
* @param projectId
* @return * @return
*/ */
@RequestMapping(value = "generateDistributionTable/{projectId}", method = RequestMethod.POST, @RequestMapping(value = "generateDistributionTable", method = RequestMethod.POST)
produces = MediaType.APPLICATION_JSON_UTF8_VALUE) public @ResponseBody ApiResultDto generateDistributionTable(@RequestBody CitDistributionDto citDistributionDto) {
public ApiResultDto generateDistributionTable(@PathVariable String projectId) {
ApiResultDto apiResultDto = new ApiResultDto(); ApiResultDto apiResultDto = new ApiResultDto();
try{ try{
apiResultDto.setCode(1); apiResultDto.setCode(1);
apiResultDto.setMessage("生成成功"); apiResultDto.setMessage("生成成功");
apiResultDto.setData(citReportService.generateTotalBranchOrgDisTable(projectId)); apiResultDto.setData(citReportService.generateTotalBranchOrgDisTable(citDistributionDto.getProjectId()));
return apiResultDto;
}catch(Exception e){
e.printStackTrace();
apiResultDto.setCode(0);
apiResultDto.setMessage("生成失败");
return apiResultDto;
}
}
/**
* 生成CIT固资损失计算
* @return
*/
@RequestMapping(value = "generateAssetEamMapping", method = RequestMethod.POST)
public @ResponseBody ApiResultDto generateAssetEamMapping(@RequestBody CitAssetsListDto citAssetsListDto) {
ApiResultDto apiResultDto = new ApiResultDto();
try{
apiResultDto.setCode(1);
apiResultDto.setMessage("生成成功");
apiResultDto.setData(citReportService.generateAssetEamMapping(citAssetsListDto));
return apiResultDto; return apiResultDto;
}catch(Exception e){ }catch(Exception e){
e.printStackTrace(); e.printStackTrace();
...@@ -179,7 +197,21 @@ public class CitReportController { ...@@ -179,7 +197,21 @@ public class CitReportController {
return apiResultDto; return apiResultDto;
} }
} }
/**
* 固定资产及EAM Mapping导出
* @param paras
* @param response
*/
@RequestMapping(value = "exportDTData", method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
public void exportDTData(@RequestBody CitDistributionDto paras, HttpServletResponse response) {
int count = citReportService.exportDTData2(paras, response);
if (count == 0) {
response.setStatus(SC_NO_CONTENT);
} else {
response.setStatus(SC_OK);
}
}
/** /**
* 获取单元格相关数据 * 获取单元格相关数据
* @param reportId * @param reportId
......
...@@ -95,7 +95,7 @@ public class OrganizationController { ...@@ -95,7 +95,7 @@ public class OrganizationController {
public @ResponseBody public @ResponseBody
List<OrgSelectDto> getOrgSimpleList() { List<OrgSelectDto> getOrgSimpleList() {
logger.info("GET /api/v1/org/getOrgListByUserId"); logger.info("GET /api/v1/org/getOrgListByUserId");
return organizationService.getOrgSimpleList(); return organizationService.getMyOrgList();
} }
// @ApiOperation(value = "纳税人识别号唯一性验证") // @ApiOperation(value = "纳税人识别号唯一性验证")
......
...@@ -229,6 +229,37 @@ public class CitDistributionDto implements Serializable { ...@@ -229,6 +229,37 @@ public class CitDistributionDto implements Serializable {
private PagingDto pageInfo; private PagingDto pageInfo;
//营业收入合计变量
private BigDecimal totalBusinessIncome;
//职工薪酬合计变量
private BigDecimal totalEmployeeRemuneration;
//资产总额合计变量
private BigDecimal totalTotalAssets;
public BigDecimal getTotalBusinessIncome() {
return totalBusinessIncome;
}
public void setTotalBusinessIncome(BigDecimal totalBusinessIncome) {
this.totalBusinessIncome = totalBusinessIncome;
}
public BigDecimal getTotalEmployeeRemuneration() {
return totalEmployeeRemuneration;
}
public void setTotalEmployeeRemuneration(BigDecimal totalEmployeeRemuneration) {
this.totalEmployeeRemuneration = totalEmployeeRemuneration;
}
public BigDecimal getTotalTotalAssets() {
return totalTotalAssets;
}
public void setTotalTotalAssets(BigDecimal totalTotalAssets) {
this.totalTotalAssets = totalTotalAssets;
}
public PagingDto getPageInfo() { public PagingDto getPageInfo() {
return pageInfo; return pageInfo;
} }
......
...@@ -31,6 +31,7 @@ public class TableRule { ...@@ -31,6 +31,7 @@ public class TableRule {
map.put("CITZCFZB", "cit_balance_sheet_prc_adjust"); map.put("CITZCFZB", "cit_balance_sheet_prc_adjust");
map.put("CITLRB", "cit_profit_prc_adjust"); map.put("CITLRB", "cit_profit_prc_adjust");
map.put("CIT_TBAM", "cit_tbam"); map.put("CIT_TBAM", "cit_tbam");
map.put("cit_asset_eam_mapping", "cit_asset_eam_mapping");
} }
} }
...@@ -27,6 +27,7 @@ import javax.servlet.http.HttpServletResponse; ...@@ -27,6 +27,7 @@ import javax.servlet.http.HttpServletResponse;
import java.io.OutputStream; import java.io.OutputStream;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.*; import java.util.*;
import java.util.stream.Collectors;
/** /**
* @Auther: Gary J Li * @Auther: Gary J Li
...@@ -98,7 +99,7 @@ public class DataPreviewSerivceImpl extends BaseService { ...@@ -98,7 +99,7 @@ public class DataPreviewSerivceImpl extends BaseService {
ProfitLossStatementCondition condition = beanUtil.copyProperties(param, new ProfitLossStatementCondition()); ProfitLossStatementCondition condition = beanUtil.copyProperties(param, new ProfitLossStatementCondition());
Page page = PageHelper.startPage(condition.getPageInfo().getPageIndex(), condition.getPageInfo().getPageSize()); Page page = PageHelper.startPage(condition.getPageInfo().getPageIndex(), condition.getPageInfo().getPageSize());
List<ProfitLossStatement> profitLossStatements = profitLossStatementPrcMapper.selectByCondition(condition); List<ProfitLossStatementPrc> profitLossStatements = profitLossStatementPrcMapper.selectByCondition(condition);
List<ProfitLossStatementDto> profitLossDtos = Lists.newArrayList(); List<ProfitLossStatementDto> profitLossDtos = Lists.newArrayList();
profitLossStatements.forEach(pl -> { profitLossStatements.forEach(pl -> {
...@@ -196,10 +197,10 @@ public class DataPreviewSerivceImpl extends BaseService { ...@@ -196,10 +197,10 @@ public class DataPreviewSerivceImpl extends BaseService {
BalanceSheetCondition condition = beanUtil.copyProperties(param, new BalanceSheetCondition()); BalanceSheetCondition condition = beanUtil.copyProperties(param, new BalanceSheetCondition());
Page page = PageHelper.startPage(condition.getPageInfo().getPageIndex(), condition.getPageInfo().getPageSize()); Page page = PageHelper.startPage(condition.getPageInfo().getPageIndex(), condition.getPageInfo().getPageSize());
List<BalanceSheet> balanceSheets = balanceSheetPrcMapper.selectByCondition(condition); List<BalanceSheetPrc> bsPrcList = balanceSheetPrcMapper.selectByCondition(condition);
List<BalanceSheetDto> balanceSheetDtos = Lists.newArrayList(); List<BalanceSheetDto> balanceSheetDtos = Lists.newArrayList();
balanceSheets.forEach(bs -> { bsPrcList.forEach(bs -> {
BalanceSheetDto balanceSheetDto = new BalanceSheetDto(); BalanceSheetDto balanceSheetDto = new BalanceSheetDto();
beanUtil.copyProperties(bs, balanceSheetDto); beanUtil.copyProperties(bs, balanceSheetDto);
balanceSheetDtos.add(balanceSheetDto); balanceSheetDtos.add(balanceSheetDto);
...@@ -343,7 +344,7 @@ public class DataPreviewSerivceImpl extends BaseService { ...@@ -343,7 +344,7 @@ public class DataPreviewSerivceImpl extends BaseService {
ProfitLossStatementCondition condition = new ProfitLossStatementCondition(); ProfitLossStatementCondition condition = new ProfitLossStatementCondition();
beanUtil.copyProperties(param, condition); beanUtil.copyProperties(param, condition);
List<ProfitLossStatement> profitLossStatements = profitLossStatementPrcMapper.selectByCondition(condition); List<ProfitLossStatementPrc> profitLossStatements = profitLossStatementPrcMapper.selectByCondition(condition);
Map<String, String> header = generalPLHeader(); Map<String, String> header = generalPLHeader();
List<ProfitLossStatementExportDto> cellList = new ArrayList<>(); List<ProfitLossStatementExportDto> cellList = new ArrayList<>();
profitLossStatements.forEach(pl -> { profitLossStatements.forEach(pl -> {
...@@ -384,7 +385,7 @@ public class DataPreviewSerivceImpl extends BaseService { ...@@ -384,7 +385,7 @@ public class DataPreviewSerivceImpl extends BaseService {
try { try {
BalanceSheetCondition condition = new BalanceSheetCondition(); BalanceSheetCondition condition = new BalanceSheetCondition();
beanUtil.copyProperties(param, condition); beanUtil.copyProperties(param, condition);
List<BalanceSheet> balanceSheets = balanceSheetPrcMapper.selectByCondition(condition); List<BalanceSheetPrc> balanceSheets = balanceSheetPrcMapper.selectByCondition(condition);
Map<String, String> header = generalBSHeader(); Map<String, String> header = generalBSHeader();
List<BalanceSheetExportDto> cellList = new ArrayList<>(); List<BalanceSheetExportDto> cellList = new ArrayList<>();
balanceSheets.forEach(bs -> { balanceSheets.forEach(bs -> {
......
...@@ -322,6 +322,10 @@ public class ReportServiceImpl extends BaseService { ...@@ -322,6 +322,10 @@ public class ReportServiceImpl extends BaseService {
lastPeriod = lastProject.getYear() + "12"; lastPeriod = lastProject.getYear() + "12";
} }
} }
TrialBalanceFinalExample example = new TrialBalanceFinalExample();
example.createCriteria().andProjectIdEqualTo(projectId).andPeriodEqualTo(Integer.valueOf(queryPeriod));
trialBalanceFinalMapper.deleteByExample(example);
trialBalanceFinalMapper.generateFinalData(projectId,Integer.valueOf(queryPeriod),lastProject==null?"0":lastProject.getId(),Integer.valueOf(lastPeriod));
} }
public void assembleInvoiceRecord(String projectId,Integer period){ public void assembleInvoiceRecord(String projectId,Integer period){
Project project = projectMapper.selectByPrimaryKey(projectId); Project project = projectMapper.selectByPrimaryKey(projectId);
......
...@@ -100,7 +100,8 @@ public class BB extends FunctionBase implements FreeRefFunction { ...@@ -100,7 +100,8 @@ public class BB extends FunctionBase implements FreeRefFunction {
CellTemplatePerGroupDto cellTemplateData = cellTemplateDataList.get(0); CellTemplatePerGroupDto cellTemplateData = cellTemplateDataList.get(0);
nullCellDto.fixedWithGroup(cellTemplateData); nullCellDto.fixedWithGroup(cellTemplateData);
//当年当期 //当年当期
if (bo.getPeriod().intValue() == 0 && bo.getYear().intValue() == 0) { if ((bo.getPeriod().intValue() == 0 && bo.getYear().intValue() == 0)||
(bo.getYear().equals(formulaContext.getYear())&&bo.getPeriod().equals(formulaContext.getPeriod()))) {
int index = ec.getWorkbook().getSheetIndex(bo.getReportCode()); int index = ec.getWorkbook().getSheetIndex(bo.getReportCode());
cellValue = getCellValue(index, ec, formulaContext, agent, bo.getRowIndex() - 1, bo.getColumnIndex() - 1, cellValue = getCellValue(index, ec, formulaContext, agent, bo.getRowIndex() - 1, bo.getColumnIndex() - 1,
Long.parseLong(cellTemplateData.getCellTemplateId())); Long.parseLong(cellTemplateData.getCellTemplateId()));
......
...@@ -41,11 +41,21 @@ ...@@ -41,11 +41,21 @@
<property name="rootInterface" value="pwc.taxtech.atms.MyMapper"/> <property name="rootInterface" value="pwc.taxtech.atms.MyMapper"/>
</javaClientGenerator> </javaClientGenerator>
<table tableName="operation_log_entry_log" domainObjectName="OperationLogEntryLog"> <table tableName="cit_asset_eam_mapping" domainObjectName="CitAssetEamMapping">
<property name="useActualColumnNames" value="false"/> <property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/> <property name="ignoreQualifiersAtRuntime" value="true"/>
</table> </table>
<!--<table tableName="cit_distribution" domainObjectName="CitDistribution">-->
<!--<property name="useActualColumnNames" value="false"/>-->
<!--<property name="ignoreQualifiersAtRuntime" value="true"/>-->
<!--</table>-->
<!--<table tableName="operation_log_entry_log" domainObjectName="OperationLogEntryLog">-->
<!--<property name="useActualColumnNames" value="false"/>-->
<!--<property name="ignoreQualifiersAtRuntime" value="true"/>-->
<!--</table>-->
<!--<table tableName="organization" domainObjectName="Organization"> <!--<table tableName="organization" domainObjectName="Organization">
<property name="useActualColumnNames" value="false"/> <property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/> <property name="ignoreQualifiersAtRuntime" value="true"/>
......
package pwc.taxtech.atms.dao;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyMapper;
import pwc.taxtech.atms.entity.CitAssetEamMapping;
import pwc.taxtech.atms.entity.CitAssetEamMappingExample;
@Mapper
public interface CitAssetEamMappingMapper extends MyMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
long countByExample(CitAssetEamMappingExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int deleteByExample(CitAssetEamMappingExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int insert(CitAssetEamMapping record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int insertSelective(CitAssetEamMapping record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
List<CitAssetEamMapping> selectByExampleWithRowbounds(CitAssetEamMappingExample example, RowBounds rowBounds);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
List<CitAssetEamMapping> selectByExample(CitAssetEamMappingExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
CitAssetEamMapping selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") CitAssetEamMapping record, @Param("example") CitAssetEamMappingExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int updateByExample(@Param("record") CitAssetEamMapping record, @Param("example") CitAssetEamMappingExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(CitAssetEamMapping record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_asset_eam_mapping
*
* @mbg.generated
*/
int updateByPrimaryKey(CitAssetEamMapping record);
int insertBatch(List<CitAssetEamMapping> citAssetEamMappings);
}
\ No newline at end of file
...@@ -6,8 +6,8 @@ import org.apache.ibatis.annotations.Param; ...@@ -6,8 +6,8 @@ import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds; import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyMapper; import pwc.taxtech.atms.MyMapper;
import pwc.taxtech.atms.dpo.CitAssetDetailResultDto; import pwc.taxtech.atms.dpo.CitAssetDetailResultDto;
import pwc.taxtech.atms.dpo.CitAssetEamMappingDto;
import pwc.taxtech.atms.dpo.CitAssetSumDataDto; import pwc.taxtech.atms.dpo.CitAssetSumDataDto;
import pwc.taxtech.atms.entity.CitAssetEamMapping;
import pwc.taxtech.atms.entity.CitAssetsList; import pwc.taxtech.atms.entity.CitAssetsList;
import pwc.taxtech.atms.entity.CitAssetsListExample; import pwc.taxtech.atms.entity.CitAssetsListExample;
...@@ -117,7 +117,7 @@ public interface CitAssetsListMapper extends MyMapper { ...@@ -117,7 +117,7 @@ public interface CitAssetsListMapper extends MyMapper {
* @param citAsset * @param citAsset
* @return Result<XxxxDO> * @return Result<XxxxDO>
*/ */
List<CitAssetEamMappingDto> getAssetEamMapping(CitAssetsList citAsset); List<CitAssetEamMapping> getAssetEamMapping(CitAssetsList citAsset);
List<CitAssetDetailResultDto> getCitAssetDetialResult(@Param("assetType") Integer assetType, List<CitAssetDetailResultDto> getCitAssetDetialResult(@Param("assetType") Integer assetType,
@Param("assetDetailType") Integer assetDetailType); @Param("assetDetailType") Integer assetDetailType);
......
package pwc.taxtech.atms.dpo;
import pwc.taxtech.atms.entity.CitAssetsList;
import java.math.BigDecimal;
/**
* @author zhikai.z.wei
*/
public class CitAssetEamMappingDto extends CitAssetsList {
/**
* EAM 资产里面的赔偿/变卖金额
*/
private BigDecimal compensationSaleAmount;
public BigDecimal getCompensationSaleAmount() {
return compensationSaleAmount;
}
public void setCompensationSaleAmount(BigDecimal compensationSaleAmount) {
this.compensationSaleAmount = compensationSaleAmount;
}
}
...@@ -221,6 +221,28 @@ public class CitDistribution extends BaseEntity implements Serializable { ...@@ -221,6 +221,28 @@ public class CitDistribution extends BaseEntity implements Serializable {
*/ */
private Date updateTime; private Date updateTime;
/**
* Database Column Remarks:
* 机构编码
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column cit_distribution.code
*
* @mbg.generated
*/
private String code;
/**
* Database Column Remarks:
* 期间月份
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column cit_distribution.period_month
*
* @mbg.generated
*/
private String periodMonth;
/** /**
* This field was generated by MyBatis Generator. * This field was generated by MyBatis Generator.
* This field corresponds to the database table cit_distribution * This field corresponds to the database table cit_distribution
...@@ -685,6 +707,54 @@ public class CitDistribution extends BaseEntity implements Serializable { ...@@ -685,6 +707,54 @@ public class CitDistribution extends BaseEntity implements Serializable {
this.updateTime = updateTime; this.updateTime = updateTime;
} }
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column cit_distribution.code
*
* @return the value of cit_distribution.code
*
* @mbg.generated
*/
public String getCode() {
return code;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column cit_distribution.code
*
* @param code the value for cit_distribution.code
*
* @mbg.generated
*/
public void setCode(String code) {
this.code = code == null ? null : code.trim();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column cit_distribution.period_month
*
* @return the value of cit_distribution.period_month
*
* @mbg.generated
*/
public String getPeriodMonth() {
return periodMonth;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column cit_distribution.period_month
*
* @param periodMonth the value for cit_distribution.period_month
*
* @mbg.generated
*/
public void setPeriodMonth(String periodMonth) {
this.periodMonth = periodMonth == null ? null : periodMonth.trim();
}
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_distribution * This method corresponds to the database table cit_distribution
...@@ -716,6 +786,8 @@ public class CitDistribution extends BaseEntity implements Serializable { ...@@ -716,6 +786,8 @@ public class CitDistribution extends BaseEntity implements Serializable {
sb.append(", createBy=").append(createBy); sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime); sb.append(", createTime=").append(createTime);
sb.append(", updateTime=").append(updateTime); sb.append(", updateTime=").append(updateTime);
sb.append(", code=").append(code);
sb.append(", periodMonth=").append(periodMonth);
sb.append("]"); sb.append("]");
return sb.toString(); return sb.toString();
} }
......
...@@ -1415,6 +1415,146 @@ public class CitDistributionExample { ...@@ -1415,6 +1415,146 @@ public class CitDistributionExample {
addCriterion("update_time not between", value1, value2, "updateTime"); addCriterion("update_time not between", value1, value2, "updateTime");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andCodeIsNull() {
addCriterion("code is null");
return (Criteria) this;
}
public Criteria andCodeIsNotNull() {
addCriterion("code is not null");
return (Criteria) this;
}
public Criteria andCodeEqualTo(String value) {
addCriterion("code =", value, "code");
return (Criteria) this;
}
public Criteria andCodeNotEqualTo(String value) {
addCriterion("code <>", value, "code");
return (Criteria) this;
}
public Criteria andCodeGreaterThan(String value) {
addCriterion("code >", value, "code");
return (Criteria) this;
}
public Criteria andCodeGreaterThanOrEqualTo(String value) {
addCriterion("code >=", value, "code");
return (Criteria) this;
}
public Criteria andCodeLessThan(String value) {
addCriterion("code <", value, "code");
return (Criteria) this;
}
public Criteria andCodeLessThanOrEqualTo(String value) {
addCriterion("code <=", value, "code");
return (Criteria) this;
}
public Criteria andCodeLike(String value) {
addCriterion("code like", value, "code");
return (Criteria) this;
}
public Criteria andCodeNotLike(String value) {
addCriterion("code not like", value, "code");
return (Criteria) this;
}
public Criteria andCodeIn(List<String> values) {
addCriterion("code in", values, "code");
return (Criteria) this;
}
public Criteria andCodeNotIn(List<String> values) {
addCriterion("code not in", values, "code");
return (Criteria) this;
}
public Criteria andCodeBetween(String value1, String value2) {
addCriterion("code between", value1, value2, "code");
return (Criteria) this;
}
public Criteria andCodeNotBetween(String value1, String value2) {
addCriterion("code not between", value1, value2, "code");
return (Criteria) this;
}
public Criteria andPeriodMonthIsNull() {
addCriterion("period_month is null");
return (Criteria) this;
}
public Criteria andPeriodMonthIsNotNull() {
addCriterion("period_month is not null");
return (Criteria) this;
}
public Criteria andPeriodMonthEqualTo(String value) {
addCriterion("period_month =", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthNotEqualTo(String value) {
addCriterion("period_month <>", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthGreaterThan(String value) {
addCriterion("period_month >", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthGreaterThanOrEqualTo(String value) {
addCriterion("period_month >=", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthLessThan(String value) {
addCriterion("period_month <", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthLessThanOrEqualTo(String value) {
addCriterion("period_month <=", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthLike(String value) {
addCriterion("period_month like", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthNotLike(String value) {
addCriterion("period_month not like", value, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthIn(List<String> values) {
addCriterion("period_month in", values, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthNotIn(List<String> values) {
addCriterion("period_month not in", values, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthBetween(String value1, String value2) {
addCriterion("period_month between", value1, value2, "periodMonth");
return (Criteria) this;
}
public Criteria andPeriodMonthNotBetween(String value1, String value2) {
addCriterion("period_month not between", value1, value2, "periodMonth");
return (Criteria) this;
}
} }
/** /**
......
...@@ -108,7 +108,7 @@ public interface BalanceSheetPrcMapper extends MyVatMapper { ...@@ -108,7 +108,7 @@ public interface BalanceSheetPrcMapper extends MyVatMapper {
*/ */
int updateByPrimaryKey(BalanceSheetPrc record); int updateByPrimaryKey(BalanceSheetPrc record);
List<BalanceSheet> selectByCondition(@Param("bsCondition") BalanceSheetCondition condition); List<BalanceSheetPrc> selectByCondition(@Param("bsCondition") BalanceSheetCondition condition);
int insertBatch(List<BalanceSheet> bls); int insertBatch(List<BalanceSheet> bls);
} }
\ No newline at end of file
...@@ -108,7 +108,7 @@ public interface ProfitLossStatementPrcMapper extends MyVatMapper { ...@@ -108,7 +108,7 @@ public interface ProfitLossStatementPrcMapper extends MyVatMapper {
*/ */
int updateByPrimaryKey(ProfitLossStatementPrc record); int updateByPrimaryKey(ProfitLossStatementPrc record);
List<ProfitLossStatement> selectByCondition(@Param("plCondition") ProfitLossStatementCondition condition); List<ProfitLossStatementPrc> selectByCondition(@Param("plCondition") ProfitLossStatementCondition condition);
int insertBatch(List<ProfitLossStatement> pls); int insertBatch(List<ProfitLossStatement> pls);
} }
\ No newline at end of file
...@@ -25,6 +25,8 @@ ...@@ -25,6 +25,8 @@
<result column="create_by" jdbcType="VARCHAR" property="createBy" /> <result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" /> <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" /> <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="period_month" jdbcType="VARCHAR" property="periodMonth" />
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<!-- <!--
...@@ -100,7 +102,7 @@ ...@@ -100,7 +102,7 @@
id, organization_id, project_id, date, source, period, quarter, tax_payer_number, id, organization_id, project_id, date, source, period, quarter, tax_payer_number,
org_name, business_income, employee_remuneration, total_assets, distribution_ratio, org_name, business_income, employee_remuneration, total_assets, distribution_ratio,
distribution_ratio_formula, distribution_amount, distribution_amount_formula, create_by, distribution_ratio_formula, distribution_amount, distribution_amount_formula, create_by,
create_time, update_time create_time, update_time, code, period_month
</sql> </sql>
<select id="selectByExample" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultMap="BaseResultMap">
<!-- <!--
...@@ -159,16 +161,16 @@ ...@@ -159,16 +161,16 @@
business_income, employee_remuneration, total_assets, business_income, employee_remuneration, total_assets,
distribution_ratio, distribution_ratio_formula, distribution_ratio, distribution_ratio_formula,
distribution_amount, distribution_amount_formula, distribution_amount, distribution_amount_formula,
create_by, create_time, update_time create_by, create_time, update_time,
) code, period_month)
values (#{id,jdbcType=BIGINT}, #{organizationId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR}, values (#{id,jdbcType=BIGINT}, #{organizationId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR},
#{date,jdbcType=TIMESTAMP}, #{source,jdbcType=VARCHAR}, #{period,jdbcType=INTEGER}, #{date,jdbcType=TIMESTAMP}, #{source,jdbcType=VARCHAR}, #{period,jdbcType=INTEGER},
#{quarter,jdbcType=INTEGER}, #{taxPayerNumber,jdbcType=VARCHAR}, #{orgName,jdbcType=VARCHAR}, #{quarter,jdbcType=INTEGER}, #{taxPayerNumber,jdbcType=VARCHAR}, #{orgName,jdbcType=VARCHAR},
#{businessIncome,jdbcType=DECIMAL}, #{employeeRemuneration,jdbcType=DECIMAL}, #{totalAssets,jdbcType=DECIMAL}, #{businessIncome,jdbcType=DECIMAL}, #{employeeRemuneration,jdbcType=DECIMAL}, #{totalAssets,jdbcType=DECIMAL},
#{distributionRatio,jdbcType=DECIMAL}, #{distributionRatioFormula,jdbcType=VARCHAR}, #{distributionRatio,jdbcType=DECIMAL}, #{distributionRatioFormula,jdbcType=VARCHAR},
#{distributionAmount,jdbcType=DECIMAL}, #{distributionAmountFormula,jdbcType=VARCHAR}, #{distributionAmount,jdbcType=DECIMAL}, #{distributionAmountFormula,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP} #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
) #{code,jdbcType=VARCHAR}, #{periodMonth,jdbcType=VARCHAR})
</insert> </insert>
<insert id="insertSelective" parameterType="pwc.taxtech.atms.entity.CitDistribution"> <insert id="insertSelective" parameterType="pwc.taxtech.atms.entity.CitDistribution">
<!-- <!--
...@@ -234,6 +236,12 @@ ...@@ -234,6 +236,12 @@
<if test="updateTime != null"> <if test="updateTime != null">
update_time, update_time,
</if> </if>
<if test="code != null">
code,
</if>
<if test="periodMonth != null">
period_month,
</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null"> <if test="id != null">
...@@ -293,6 +301,12 @@ ...@@ -293,6 +301,12 @@
<if test="updateTime != null"> <if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="code != null">
#{code,jdbcType=VARCHAR},
</if>
<if test="periodMonth != null">
#{periodMonth,jdbcType=VARCHAR},
</if>
</trim> </trim>
</insert> </insert>
<select id="countByExample" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultType="java.lang.Long"> <select id="countByExample" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultType="java.lang.Long">
...@@ -369,6 +383,12 @@ ...@@ -369,6 +383,12 @@
<if test="record.updateTime != null"> <if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP}, update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="record.code != null">
code = #{record.code,jdbcType=VARCHAR},
</if>
<if test="record.periodMonth != null">
period_month = #{record.periodMonth,jdbcType=VARCHAR},
</if>
</set> </set>
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
...@@ -398,7 +418,9 @@ ...@@ -398,7 +418,9 @@
distribution_amount_formula = #{record.distributionAmountFormula,jdbcType=VARCHAR}, distribution_amount_formula = #{record.distributionAmountFormula,jdbcType=VARCHAR},
create_by = #{record.createBy,jdbcType=VARCHAR}, create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP}, create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP} update_time = #{record.updateTime,jdbcType=TIMESTAMP},
code = #{record.code,jdbcType=VARCHAR},
period_month = #{record.periodMonth,jdbcType=VARCHAR}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
...@@ -464,6 +486,12 @@ ...@@ -464,6 +486,12 @@
<if test="updateTime != null"> <if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP}, update_time = #{updateTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="code != null">
code = #{code,jdbcType=VARCHAR},
</if>
<if test="periodMonth != null">
period_month = #{periodMonth,jdbcType=VARCHAR},
</if>
</set> </set>
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
...@@ -490,7 +518,9 @@ ...@@ -490,7 +518,9 @@
distribution_amount_formula = #{distributionAmountFormula,jdbcType=VARCHAR}, distribution_amount_formula = #{distributionAmountFormula,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR}, create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP}, create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP} update_time = #{updateTime,jdbcType=TIMESTAMP},
code = #{code,jdbcType=VARCHAR},
period_month = #{periodMonth,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
<select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultMap="BaseResultMap"> <select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.entity.CitDistributionExample" resultMap="BaseResultMap">
......
<?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">
<mapper namespace="pwc.taxtech.atms.dao.CitAssetEamMappingMapper">
<insert id="insertBatch" parameterType="java.util.List">
insert into cit_asset_eam_mapping
(<include refid="Base_Column_List"/>)
values
<foreach collection="list" item="item" index="index" separator=",">
<trim prefix="(" suffix=")" suffixOverrides=",">
<choose>
<when test="item.id != null">#{item.id,jdbcType=BIGINT},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.projectId != null">#{item.projectId,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.period != null">#{item.period,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.assetNumber != null">#{item.assetNumber,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.serialNumber != null">#{item.serialNumber,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.assetGroupName != null">#{item.assetGroupName,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.assetDetailGroupId != null">#{item.assetDetailGroupId,jdbcType=BIGINT},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.assetDescription != null">#{item.assetDescription,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.buyDate != null">#{item.buyDate,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose>
<choose>
<when test="item.depreciationDate != null">#{item.depreciationDate,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose>
<choose>
<when test="item.depreciationPeriod != null">#{item.depreciationPeriod,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.acquisitionValue != null">#{item.acquisitionValue,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.adjustmentValue != null">#{item.adjustmentValue,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.disposedDate != null">#{item.disposedDate,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose>
<choose>
<when test="item.residualRate != null">#{item.residualRate,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.yearDepreciationAmount != null">#{item.yearDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.yearAdjustmentAmount != null">#{item.yearAdjustmentAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.yearEndValue != null">#{item.yearEndValue,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.status != null">#{item.status,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.accountAcquisitionValue != null">#{item.accountAcquisitionValue,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.accountMonthDepreciationAmount != null">#{item.accountMonthDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.accountYearDepreciationAmount != null">#{item.accountYearDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.accountTotalDepreciationAmount != null">#{item.accountTotalDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxDepreciationPeriod != null">#{item.taxDepreciationPeriod,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxToLastYearDepreciationPeriod != null">#{item.taxToLastYearDepreciationPeriod,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxToCurrentYearDepreciationPeriod != null">#{item.taxToCurrentYearDepreciationPeriod,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxYearDepreciationPeriod != null">#{item.taxYearDepreciationPeriod,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxMonthDepreciationAmount != null">#{item.taxMonthDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxToCurrentYearDepreciationAmount != null">#{item.taxToCurrentYearDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxCurrentYearDepreciationAmount != null">#{item.taxCurrentYearDepreciationAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.totalDifferenceAmount != null">#{item.totalDifferenceAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.yearDifferenceAmount != null">#{item.yearDifferenceAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.isRetain != null">#{item.isRetain,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.assetType != null">#{item.assetType,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.createTime != null">#{item.createTime,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose>
<choose>
<when test="item.updateTime != null">#{item.updateTime,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose>
<choose>
<when test="item.taxAccountCompare != null">#{item.taxAccountCompare,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxGroupName != null">#{item.taxGroupName,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.scrapType != null">#{item.scrapType,jdbcType=VARCHAR},</when>
<otherwise>'',</otherwise>
</choose>
<choose>
<when test="item.compensationSaleAmount != null">#{item.compensationSaleAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.saleAmount != null">#{item.saleAmount,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.disposalProfitAndLoss != null">#{item.disposalProfitAndLoss,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.taxNetValue != null">#{item.taxNetValue,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.disposalTaxBenefit != null">#{item.disposalTaxBenefit,jdbcType=DECIMAL},</when>
<otherwise>0,</otherwise>
</choose>
</trim>
</foreach>;
SELECT 1 FROM DUAL;
</insert>
</mapper>
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<!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="pwc.taxtech.atms.dao.CitAssetsListMapper"> <mapper namespace="pwc.taxtech.atms.dao.CitAssetsListMapper">
<resultMap id="assetEamMap" type="pwc.taxtech.atms.dpo.CitAssetEamMappingDto"> <resultMap id="assetEamMap" type="pwc.taxtech.atms.entity.CitAssetEamMapping">
<!-- <!--
WARNING - @mbg.generated WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify. This element is automatically generated by MyBatis Generator, do not modify.
...@@ -218,7 +218,8 @@ ...@@ -218,7 +218,8 @@
<select id="getAssetEamMapping" parameterType="map" resultMap="assetEamMap"> <select id="getAssetEamMapping" parameterType="map" resultMap="assetEamMap">
select select
assets_list.* , cit_eam_assets_disposal.compensation_sale_amount assets_list.* , cit_eam_assets_disposal.compensation_sale_amount
from assets_list join cit_eam_assets_disposal on serial_number = asset_label_number where scrap_type='完全报废' from assets_list join cit_eam_assets_disposal on serial_number = asset_label_number
where scrap_type='完全报废' and assets_list.project_id = #{projectId,jdbcType=VARCHAR}
</select> </select>
<resultMap id="citAssetDetailResultDto" type="pwc.taxtech.atms.dpo.CitAssetDetailResultDto"> <resultMap id="citAssetDetailResultDto" type="pwc.taxtech.atms.dpo.CitAssetDetailResultDto">
......
...@@ -190,7 +190,7 @@ from trial_balance balance ...@@ -190,7 +190,7 @@ from trial_balance balance
and and
balance.segment10 = last_adjustment.segment10 balance.segment10 = last_adjustment.segment10
where balance.project_id = #{projectId} where balance.project_id = #{projectId}
and balance.period = #{perioid} and balance.period = #{period}
......
...@@ -1148,5 +1148,6 @@ ...@@ -1148,5 +1148,6 @@
"TotalAssets": "Total Assets", "TotalAssets": "Total Assets",
"DistributionRatio": "Distribution Ratio", "DistributionRatio": "Distribution Ratio",
"DistributionAmount": "Distribution Amount", "DistributionAmount": "Distribution Amount",
"Subtotal": "Total" "Subtotal": "Total",
"AssetEamMapping": "Asset Eam Mapping"
} }
\ No newline at end of file
...@@ -1201,7 +1201,8 @@ ...@@ -1201,7 +1201,8 @@
"EmployeeRemuneration": "职工薪酬", "EmployeeRemuneration": "职工薪酬",
"TotalAssets": "资产总额", "TotalAssets": "资产总额",
"DistributionRatio": "分配比例", "DistributionRatio": "分配比例",
"DistributionAmount": "分配税额" "DistributionAmount": "分配税额",
"AssetEamMapping": "固资损失计算"
......
...@@ -245,6 +245,18 @@ ...@@ -245,6 +245,18 @@
}); });
}; };
$scope.startCalculateData = function () {
citReportService.generateAssetEamMapping($scope.queryParams).success(function (data) {
debugger;
loadJournalEntryDataFromDB(1);
// if(status===204){
// SweetAlert.warning("没有数据可以下载");
// return;
// }
}).error(function () {
SweetAlert.error($translate.instant('PleaseContactAdministrator'));
});
};
(function initialize() { (function initialize() {
$log.debug('VatPreviewInputInvoiceController.ctor()...'); $log.debug('VatPreviewInputInvoiceController.ctor()...');
......
<div class="cit-asset-eam-mapping" id="mainPreviewDiv"> <div class="cit-asset-eam-mapping" id="mainPreviewDiv">
<div class="top-area-wrapper" style="margin-top: 10px"> <div class="nav-wrapper">
<div class="nav-header">{{'AssetEamMapping' | translate}}</div>
<div class="nav-tab">
<span style="width: auto" ng-click="startCalculateData()">{{'startCaculateData' | translate}}</span>
<span ng-click="downloadJE()" style="float: right;"><i class="fa fa-file-excel-o" aria-hidden="true"></i>{{'ExportBtn' | translate}}</span>
</div>
</div>
<div class="top-area-wrapper" style="margin-top: 10px;display: none">
<span translate="JournalTitle" class="text-bold"></span> &nbsp;&nbsp;|&nbsp;&nbsp; <span translate="JournalTitle" class="text-bold"></span> &nbsp;&nbsp;|&nbsp;&nbsp;
<span class="text-bold" translate="InvoiceQJ" style="display: none"></span> <span class="text-bold" translate="InvoiceQJ" style="display: none"></span>
<input type="text" class="form-control input-width-middle periodInput" style="position: relative; top: -30px; left: 180px;display: none" id="input-invoice-period-picker" /> <input type="text" class="form-control input-width-middle periodInput" style="position: relative; top: -30px; left: 180px;display: none" id="input-invoice-period-picker" />
......
...@@ -163,3 +163,41 @@ ...@@ -163,3 +163,41 @@
width: 217px; width: 217px;
} }
} }
.nav-wrapper {
padding-bottom: 10px;
border-bottom: 1px solid #DBD8D3;
.nav-header {
height: 54px;
line-height: 54px;
font-family: "Microsoft YaHei Bold", "Microsoft YaHei Regular", "Microsoft YaHei";
font-weight: 700;
font-style: normal;
font-size: 15px;
color: #333;
}
.nav-tab {
/*display: inline-block;*/
span {
display: inline-block;
height: 34px;
width: 80px;
text-align: center;
line-height: 34px;
padding: 0 10px;
background-color: #B90808;
color: #FFF;
font-family: "Microsoft YaHei";
font-weight: 400;
font-style: normal;
font-size: 14px;
cursor: pointer;
}
.active {
background-color: #F91000;
}
}
}
vatModule.controller('citDistributionTableController', ['$rootScope','$scope', '$log', '$filter','$translate', '$timeout', 'SweetAlert', '$q', 'uiGridConstants', '$interval', 'citPreviewService', 'citReportService','browserService', 'vatSessionService', 'region', 'enums', 'vatExportService', citModule.controller('citDistributionTableController', ['$rootScope','$scope', '$log', '$filter','$translate', '$timeout', 'SweetAlert', '$q', 'uiGridConstants', '$interval', 'citPreviewService', 'citReportService','browserService', 'vatSessionService', 'region', 'enums', 'vatExportService',
function ($rootScope,$scope, $log,$filter, $translate, $timeout, SweetAlert, $q, uiGridConstants, $interval, citPreviewService, citReportService, browserService, vatSessionService, region, enums, vatExportService) { function ($rootScope,$scope, $log,$filter, $translate, $timeout, SweetAlert, $q, uiGridConstants, $interval, citPreviewService, citReportService, browserService, vatSessionService, region, enums, vatExportService) {
'use strict'; 'use strict';
...@@ -9,6 +9,10 @@ ...@@ -9,6 +9,10 @@
$scope.endMonth = vatSessionService.month; $scope.endMonth = vatSessionService.month;
$scope.totalMoneyAmount = 0; $scope.totalMoneyAmount = 0;
$scope.totalTaxAmount = 0; $scope.totalTaxAmount = 0;
$scope.totalBusinessIncome = 0;
$scope.totalEmployeeRemuneration = 0;
$scope.totalTotalAssets = 0;
var minDate = [1, vatSessionService.project.year]; var minDate = [1, vatSessionService.project.year];
// var minDate = moment().startOf('month').subtract(0, 'months'); // var minDate = moment().startOf('month').subtract(0, 'months');
...@@ -25,11 +29,9 @@ ...@@ -25,11 +29,9 @@
pageInfo: {}, pageInfo: {},
periodStart: '', periodStart: '',
periodEnd: '', periodEnd: '',
subjectCode: null, totalBusinessIncome: $scope.totalBusinessIncome,
subjectName: null, totalEmployeeRemuneration:$scope.totalEmployeeRemuneration,
orgCode: null, totalTotalAssets:$scope.totalEmployeeRemuneration,
orgName: null,
documentDate: null,
projectId: vatSessionService.project.id projectId: vatSessionService.project.id
}; };
}; };
...@@ -40,17 +42,26 @@ ...@@ -40,17 +42,26 @@
$scope.curJournalEntryPage = pageIndex; $scope.curJournalEntryPage = pageIndex;
//初始化查询信息 //初始化查询信息
$scope.queryParams.pageInfo = { $scope.queryParams = {
totalCount: $scope.queryJournalEntryResult.pageInfo.totalCount, pageInfo: {
pageIndex: pageIndex, totalCount: $scope.queryJournalEntryResult.pageInfo.totalCount,
pageSize: $scope.queryJournalEntryResult.pageInfo.pageSize, pageIndex: pageIndex,
totalPage: 0 pageSize: $scope.queryJournalEntryResult.pageInfo.pageSize,
totalPage: 0
},
periodStart: '',
periodEnd: '',
totalBusinessIncome: $scope.totalBusinessIncome,
totalEmployeeRemuneration:$scope.totalEmployeeRemuneration,
totalTotalAssets:$scope.totalEmployeeRemuneration,
projectId: vatSessionService.project.id
}; };
$scope.getDataFromDatabase($scope.queryParams); $scope.getDataFromDatabase($scope.queryParams);
}; };
$scope.getDataFromDatabase = function (queryParams){ $scope.getDataFromDatabase = function (queryParams){
citReportService.getAssetEamMappings(queryParams).success(function (resp) { citReportService.getDistributionTables(queryParams).success(function (resp) {
debugger; debugger;
if (resp.data) { if (resp.data) {
// minDate = data. // minDate = data.
...@@ -146,21 +157,21 @@ ...@@ -146,21 +157,21 @@
removeItem.forEach(function (v) { removeItem.forEach(function (v) {
$scope.queryParams[v] = null; $scope.queryParams[v] = null;
if ($scope.queryParams.subjectCode === null) { // if ($scope.queryParams.subjectCode === null) {
$scope.queryParams.subjectCode = ''; // $scope.queryParams.subjectCode = '';
} // }
if ($scope.queryParams.subjectName === null) { // if ($scope.queryParams.subjectName === null) {
$scope.queryParams.subjectName = ''; // $scope.queryParams.subjectName = '';
} // }
if ($scope.queryParams.orgCode === null) { // if ($scope.queryParams.orgCode === null) {
$scope.queryParams.orgCode = ''; // $scope.queryParams.orgCode = '';
} // }
if ($scope.queryParams.orgName === null) { // if ($scope.queryParams.orgName === null) {
$scope.queryParams.orgName = ''; // $scope.queryParams.orgName = '';
} // }
if ($scope.queryParams.documentDate === null) { // if ($scope.queryParams.documentDate === null) {
$scope.queryParams.documentDate = ''; // $scope.queryParams.documentDate = '';
} // }
}); });
} }
...@@ -234,7 +245,7 @@ ...@@ -234,7 +245,7 @@
}; };
var downloadJE = function () { var downloadJE = function () {
citReportService.initExportAEMData($scope.queryParams).success(function (data, status, headers) { citReportService.initExportDTData($scope.queryParams).success(function (data, status, headers) {
if(status===204){ if(status===204){
SweetAlert.warning("没有数据可以下载"); SweetAlert.warning("没有数据可以下载");
return; return;
...@@ -246,7 +257,11 @@ ...@@ -246,7 +257,11 @@
}; };
$scope.startCalculateData = function () { $scope.startCalculateData = function () {
citReportService.generateDistributionTable(vatSessionService.project.id).success(function (data, status, headers) { citReportService.generateDistributionTable($scope.queryParams).success(function (data) {
debugger;
$scope.totalBusinessIncome = data.data.totalBusinessIncome;
$scope.totalEmployeeRemuneration = data.data.totalEmployeeRemuneration;
$scope.totalTotalAssets = data.data.totalTotalAssets;
loadJournalEntryDataFromDB(1); loadJournalEntryDataFromDB(1);
// if(status===204){ // if(status===204){
// SweetAlert.warning("没有数据可以下载"); // SweetAlert.warning("没有数据可以下载");
...@@ -258,7 +273,7 @@ ...@@ -258,7 +273,7 @@
}; };
(function initialize() { (function initialize() {
$log.debug('VatPreviewInputInvoiceController.ctor()...'); $log.debug('citDistributionTableController.ctor()...');
$('#input-invoice-period-picker').focus(function () { $('#input-invoice-period-picker').focus(function () {
$('.filter-button').popover("hide"); $('.filter-button').popover("hide");
}); });
...@@ -283,9 +298,10 @@ ...@@ -283,9 +298,10 @@
loadJournalEntryDataFromDB(1); loadJournalEntryDataFromDB(1);
}); });
//格式化Grid
$scope.gridOptions = { $scope.gridOptions = {
rowHeight: constant.UIGrid.rowHeight, rowHeight: constant.UIGrid.rowHeight,
showColumnFooter: true,
selectionRowHeaderWidth: constant.UIGrid.rowHeight, selectionRowHeaderWidth: constant.UIGrid.rowHeight,
// expandableRowTemplate: '<div ui-grid="row.entity.subGridOptions" style="height:150px;"></div>', // expandableRowTemplate: '<div ui-grid="row.entity.subGridOptions" style="height:150px;"></div>',
virtualizationThreshold: 50,//默认加载50条数据,避免在数据展示时,只显示前面4条 virtualizationThreshold: 50,//默认加载50条数据,避免在数据展示时,只显示前面4条
...@@ -295,17 +311,17 @@ ...@@ -295,17 +311,17 @@
columnDefs: [ columnDefs: [
{ name: $translate.instant('TaxPayerNumber'), width: 250, cellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.taxPayerNumber}}<span></div>' }, { name: $translate.instant('TaxPayerNumber'), width: 250, cellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.taxPayerNumber}}<span></div>' },
{ name: $translate.instant('OrgName'), width: 350,cellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>' { name: $translate.instant('OrgName'), width: 350,cellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents">$translate.instant("Subtotal"): </div>'}, , footerCellTemplate: '<div class="ui-grid-cell-contents" translate="Subtotal"> </div>'},
{ name: $translate.instant('BusinessIncome'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.businessIncome}}</span></div>' { name: $translate.instant('BusinessIncome'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.businessIncome}}</span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'}, , footerCellTemplate: '<div class="ui-grid-cell-contents">'+$scope.totalBusinessIncome+'</div>'},
{ name: $translate.instant('EmployeeRemuneration'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.employeeRemuneration}}</span></div>' { name: $translate.instant('EmployeeRemuneration'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.employeeRemuneration}}</span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'}, , footerCellTemplate: '<div class="ui-grid-cell-contents">'+$scope.totalEmployeeRemuneration+'</div>'},
{ name: $translate.instant('TotalAssets'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.totalAssets}}</span></div>' { name: $translate.instant('TotalAssets'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.totalAssets}}</span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'}, , footerCellTemplate: '<div class="ui-grid-cell-contents">'+$scope.totalTotalAssets+'</div>'},
{ name: $translate.instant('DistributionRatio'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.distributionRatio}}</span></div>' { name: $translate.instant('DistributionRatio'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.distributionRatio}}</span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'}, , footerCellTemplate: '<div class="ui-grid-cell-contents"><span>100<span></div>'},
{ name: $translate.instant('DistributionAmount'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.distributionAmount}}</span></div>' // { name: $translate.instant('DistributionAmount'), width: 200,cellTemplate: '<div class="ui-grid-cell-contents"><span >{{row.entity.distributionAmount}}</span></div>'
, footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'}, // , footerCellTemplate: '<div class="ui-grid-cell-contents"><span>{{row.entity.orgName}}<span></div>'},
] ]
}; };
......
...@@ -3,15 +3,15 @@ ...@@ -3,15 +3,15 @@
<div class="nav-header">{{'DistributionTable' | translate}}</div> <div class="nav-header">{{'DistributionTable' | translate}}</div>
<div class="nav-tab"> <div class="nav-tab">
<span style="width: auto" ng-click="startCalculateData()">{{'startCaculateData' | translate}}</span> <span style="width: auto" ng-click="startCalculateData()">{{'startCaculateData' | translate}}</span>
<span ng-click="downloadJE()" style="position: relative; top: -61px; left: 95%;"><i class="fa fa-file-excel-o" aria-hidden="true"></i>{{'ExportBtn' | translate}}</span> <span ng-click="downloadJE()" style="float: right;"><i class="fa fa-file-excel-o" aria-hidden="true"></i>{{'ExportBtn' | translate}}</span>
</div> </div>
</div> </div>
<!--<div class="top-area-wrapper" style="margin-top: 10px">--> <div class="top-area-wrapper" style="margin-top: 10px;display: none">
<!--<span translate="DistributionTable" class="text-bold"></span> &nbsp;&nbsp;|&nbsp;&nbsp;--> <span translate="DistributionTable" class="text-bold"></span> &nbsp;&nbsp;|&nbsp;&nbsp;
<!--<span class="text-bold" translate="InvoiceQJ" style="display: none"></span>--> <span class="text-bold" translate="InvoiceQJ" style="display: none"></span>
<!--<input type="text" class="form-control input-width-middle periodInput" style="position: relative; top: -30px; left: 180px;display: none" id="input-invoice-period-picker" />--> <input type="text" class="form-control input-width-middle periodInput" style="position: relative; top: -30px; left: 180px;display: none" id="input-invoice-period-picker" />
<!--<span ng-click="downloadJE()" style="position: relative; top: -61px; left: 95%;"><i class="fa fa-file-excel-o" aria-hidden="true"></i>{{'ExportBtn' | translate}}</span>--> <span ng-click="downloadJE()" style="position: relative; top: -61px; left: 95%;"><i class="fa fa-file-excel-o" aria-hidden="true"></i>{{'ExportBtn' | translate}}</span>
<!--</div>--> </div>
<!--<div style="margin-bottom: 8px;margin-left: 30px">--> <!--<div style="margin-bottom: 8px;margin-left: 30px">-->
<!--{{'EnterpriseAccountSetName' | translate}}<span class="numAmount">{{ledgerName}}</span>&nbsp;&nbsp;&nbsp;--> <!--{{'EnterpriseAccountSetName' | translate}}<span class="numAmount">{{ledgerName}}</span>&nbsp;&nbsp;&nbsp;-->
......
...@@ -2973,13 +2973,14 @@ ...@@ -2973,13 +2973,14 @@
// } // }
// }); // });
if ($scope.templateCode === 'BS001' || $scope.templateCode === 'PL001') { // if ($scope.templateCode === 'BS001' || $scope.templateCode === 'PL001') {
//show cell detail panel // //show cell detail panel
$scope.isBSPL = true; // $scope.isBSPL = true;
$scope.moduleid = enums.vatModuleEnum.Report_BSPL; // $scope.moduleid = enums.vatModuleEnum.Report_BSPL;
} else { // } else {
$scope.isBSPL = false; // $scope.isBSPL = false;
} // }
$scope.isBSPL = false;
//load cell data //load cell data
loadCellData(getActualPeriod()); loadCellData(getActualPeriod());
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
'vatSessionService', 'vatSessionService',
function ($q, $log, $http, $translate, apiConfig, enums, SweetAlert, vatOperationLogService, vatSessionService) { function ($q, $log, $http, $translate, apiConfig, enums, SweetAlert, vatOperationLogService, vatSessionService) {
'use strict'; 'use strict';
$log.debug('vatReportService.ctor()...'); $log.debug('citReportService.ctor()...');
return { return {
// 修改保存机制后,需要添加缓存机制的方法: // 修改保存机制后,需要添加缓存机制的方法:
...@@ -211,6 +211,13 @@ ...@@ -211,6 +211,13 @@
return $http.get('/Report/deleteAttach?id=' + id, apiConfig.create(config)); return $http.get('/Report/deleteAttach?id=' + id, apiConfig.create(config));
}, },
/**
生成固定资产及EAM对应的数据
*/
generateAssetEamMapping : function(citAssetsListDto){
debugger;
return $http.post('/citReport/generateAssetEamMapping', citAssetsListDto, apiConfig.create());
},
/** /**
获取固定资产及EAM对应的数据 获取固定资产及EAM对应的数据
*/ */
...@@ -234,8 +241,17 @@ ...@@ -234,8 +241,17 @@
/** /**
生成所得税分配表的 生成所得税分配表的
*/ */
generateDistributionTable : function(projectId){ generateDistributionTable : function(citAssetsListDto){
return $http.post('/citReport/generateDistributionTable/' + projectId, apiConfig.create()); debugger;
return $http.post('/citReport/generateDistributionTable', citAssetsListDto, apiConfig.create());
},
/**
* 导出生成所得税分配表
* @param citAssetsListDto
* @returns {HttpPromise}
*/
initExportDTData: function (citAssetsListDto) {
return $http.post('/citReport/exportDTData', citAssetsListDto, apiConfig.create({ responseType: 'arraybuffer' }));
}, },
}; };
......
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