Commit 885a43f0 authored by chase's avatar chase

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

parents 10e45fe6 ebc495dd
...@@ -7,6 +7,7 @@ import org.slf4j.LoggerFactory; ...@@ -7,6 +7,7 @@ import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.scheduling.quartz.QuartzJobBean; import org.springframework.scheduling.quartz.QuartzJobBean;
import pwc.taxtech.atms.analysis.entity.AnalysisMaster;
import pwc.taxtech.atms.common.util.DateUtils; import pwc.taxtech.atms.common.util.DateUtils;
import pwc.taxtech.atms.constant.enums.EnumTbImportType; import pwc.taxtech.atms.constant.enums.EnumTbImportType;
import pwc.taxtech.atms.dao.OrganizationMapper; import pwc.taxtech.atms.dao.OrganizationMapper;
......
...@@ -171,9 +171,9 @@ public class DateUtils { ...@@ -171,9 +171,9 @@ public class DateUtils {
* @param dateStr * @param dateStr
* @return * @return
*/ */
public static Integer strToPeriodYM(String dateStr) { public static Integer strToPeriodM(String dateStr) {
dateStr = dateStr.replace("-","").replace(" ","").replace("年","").replace("月",""); dateStr = dateStr.replace("-","").replace(" ","").replace("年","").replace("月","");
Integer period = Integer.valueOf(dateStr); Integer period = Integer.valueOf(dateStr.substring(4,6));
return period; return period;
} }
......
package pwc.taxtech.atms.controller; package pwc.taxtech.atms.controller;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.apache.poi.ss.usermodel.Workbook;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.MediaType; import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity; import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import pwc.taxtech.atms.common.message.ErrorMessage;
import pwc.taxtech.atms.constant.enums.EnumServiceType; import pwc.taxtech.atms.constant.enums.EnumServiceType;
import pwc.taxtech.atms.dpo.ReportDto; import pwc.taxtech.atms.dpo.ReportDto;
import pwc.taxtech.atms.dto.*; import pwc.taxtech.atms.dto.*;
import pwc.taxtech.atms.dto.periodReport.PeriodReportDataParam;
import pwc.taxtech.atms.dto.vatdto.ManualDataSourceDto; import pwc.taxtech.atms.dto.vatdto.ManualDataSourceDto;
import pwc.taxtech.atms.dto.vatdto.PeriodJobDto; import pwc.taxtech.atms.dto.vatdto.PeriodJobDto;
import pwc.taxtech.atms.dto.vatdto.ReportDataDto; import pwc.taxtech.atms.dto.vatdto.ReportDataDto;
import pwc.taxtech.atms.service.impl.CitReportServiceImpl; import pwc.taxtech.atms.service.impl.CitReportServiceImpl;
import pwc.taxtech.atms.service.impl.CitReportUploadService;
import pwc.taxtech.atms.service.impl.ReportUploadService;
import pwc.taxtech.atms.vat.entity.PeriodJob; import pwc.taxtech.atms.vat.entity.PeriodJob;
import pwc.taxtech.atms.vat.entity.ReportUpload;
import pwc.taxtech.atms.vat.service.impl.ReportServiceImpl; import pwc.taxtech.atms.vat.service.impl.ReportServiceImpl;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.ByteArrayOutputStream;
import java.util.List; import java.util.List;
import java.util.Optional; import java.util.Optional;
...@@ -35,9 +42,10 @@ public class CitReportController { ...@@ -35,9 +42,10 @@ public class CitReportController {
@Autowired @Autowired
CitReportServiceImpl reportService; CitReportServiceImpl reportService;
@Autowired @Autowired
CitReportServiceImpl citReportService; CitReportServiceImpl citReportService;
@Autowired
CitReportUploadService citReportUploadService;
/** /**
* 获取CIT所有要生成的报表模板相关信息, * 获取CIT所有要生成的报表模板相关信息,
...@@ -243,4 +251,34 @@ public class CitReportController { ...@@ -243,4 +251,34 @@ public class CitReportController {
return ResponseEntity.ok(reportService.addCellManualDataSource(data, from)); return ResponseEntity.ok(reportService.addCellManualDataSource(data, from));
} }
@RequestMapping(value = "uploadReportData/{projectId}/{period}", method = RequestMethod.POST,
produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
@ResponseBody
public OperationResultDto uploadReportData(@RequestBody PeriodReportDataParam param,
@PathVariable(name = "period", required = false) Integer period,
@PathVariable(name = "projectId", required = false) String projectId) {
ByteArrayOutputStream bout = new ByteArrayOutputStream();
try {
Workbook tWorkbook = citReportService.generateReportData(param.getReportIds(), projectId, period);
tWorkbook.write(bout);
ReportUpload data = new ReportUpload();
data.setProjectId(projectId);
data.setPeriod(period);
citReportUploadService.saveData(bout.toByteArray(), data);
return OperationResultDto.success();
} catch (Exception e) {
e.printStackTrace();
} finally {
try {
if (bout != null) {
bout.close();
}
} catch (Exception e) {
e.printStackTrace();
}
}
return OperationResultDto.error(ErrorMessage.SystemError);
}
} }
\ No newline at end of file
package pwc.taxtech.atms.controller;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import pwc.taxtech.atms.common.message.ErrorMessage;
import pwc.taxtech.atms.dto.OperationResultDto;
import pwc.taxtech.atms.dto.input.CamelPagingResultDto;
import pwc.taxtech.atms.dto.reportFileUpload.ReportFileUploadParam;
import pwc.taxtech.atms.dto.reportFileUpload.ReportFileUploadResult;
import pwc.taxtech.atms.dto.reportUpload.ReportUploadParam;
import pwc.taxtech.atms.dto.reportUpload.ReportUploadResult;
import pwc.taxtech.atms.exception.ServiceException;
import pwc.taxtech.atms.service.impl.CitReportUploadService;
import pwc.taxtech.atms.service.impl.ReportFileUploadService;
import pwc.taxtech.atms.service.impl.ReportUploadService;
import pwc.taxtech.atms.vat.entity.ReportFileUpload;
import javax.annotation.Resource;
import java.util.List;
@RestController
@RequestMapping(value = "api/v1/citReportUploadDetail")
public class CitReportUploadDetailController extends BaseController {
@Resource
private CitReportUploadService citReportUploadService;
@Resource
private ReportFileUploadService reportFileUploadService;
@PostMapping("queryPage")
public CamelPagingResultDto<ReportUploadResult> queryPage(@RequestBody ReportUploadParam param) {
return new CamelPagingResultDto<>(citReportUploadService.queryPage(param));
}
@PostMapping("queryFileUpload")
public List<ReportFileUploadResult> queryFileUpload(@RequestBody ReportFileUploadParam param) {
return reportFileUploadService.queryData(param);
}
@ResponseBody
@PostMapping("saveFileUpload")
public OperationResultDto saveFileUpload(@RequestParam MultipartFile file, @RequestParam String sourceType,@RequestParam String reportType,@RequestParam String projectId, @RequestParam Integer period) {
try {
ReportFileUpload data = new ReportFileUpload();
data.setPeriod(period);
data.setProjectId(projectId);
data.setReportType(reportType);
data.setSourceType(sourceType);
reportFileUploadService.saveData(file,data);
return OperationResultDto.success();
} catch (ServiceException e) {
return OperationResultDto.error(e.getMessage());
} catch (Exception e) {
logger.error("upload file error.", e);
return OperationResultDto.error(ErrorMessage.SystemError);
}
}
}
...@@ -98,8 +98,8 @@ public class AnalysisJobServiceImpl extends BaseService { ...@@ -98,8 +98,8 @@ public class AnalysisJobServiceImpl extends BaseService {
private final static List<Integer> MONTH_LIST = Lists.newArrayList(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12); private final static List<Integer> MONTH_LIST = Lists.newArrayList(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12);
private final static List<Integer> Q_LIST = Lists.newArrayList(3, 6, 9, 12); private final static List<Integer> Q_LIST = Lists.newArrayList(1, 4, 7, 10);
private final static List<Integer> ZZS_DATE_LIST = Lists.newArrayList(1, 4, 7, 10); //private final static List<Integer> ZZS_DATE_LIST = Lists.newArrayList(1, 4, 7, 10);
/** /**
...@@ -673,19 +673,17 @@ public class AnalysisJobServiceImpl extends BaseService { ...@@ -673,19 +673,17 @@ public class AnalysisJobServiceImpl extends BaseService {
Organization o = orgMap.get(td.getCompanyId()); Organization o = orgMap.get(td.getCompanyId());
AnalysisFileManagement afm = new AnalysisFileManagement(); AnalysisFileManagement afm = new AnalysisFileManagement();
afm.setId(idService.nextId()); afm.setId(idService.nextId());
afm.setSeqNo(o.getCode() + "" + period); afm.setSeqNo(getSeqNoByPeriod(o.getId(), period));
afm.setFileType(td.getFileType()); afm.setFileType(td.getFileType());
// 周期性上传 校验当年的当前及之前的周期是否有上传文件 // 周期性上传 校验当年的当前及之前的周期是否有上传文件
if (StringUtils.isNotEmpty(td.getTaxType()) && null != td.getOwnTime()) { if (StringUtils.isNotEmpty(td.getTaxType()) && null != td.getOwnTime()) {
List<OrganizationTaxRule> otrs = ruleMap.get(td.getTaxType()); List<OrganizationTaxRule> otrs = ruleMap.get(td.getTaxType());
Optional<OrganizationTaxRule> otrOP= otrs.stream().filter(otr->otr.getGroupName().equals(td.getTaxType())).map(OrganizationTaxRule::getUpdateTime).max(new ComparatorDate()); Optional<OrganizationTaxRule> otrOP= otrs.stream().filter(otr->otr.getGroupName().equals(td.getTaxType())).map(OrganizationTaxRule::getUpdateTime).max(new ComparatorDate());
OrganizationTaxRule rule = otrOP.get(); OrganizationTaxRule rule = otrOP.get();
if(null==rule){ if(null==rule){
break; break;
} }
afm.setReportingFrequency(rule.getTaxDecCycle()); afm.setReportingFrequency(rule.getTaxDecCycle());
String archivingStatus = "未归档"; String archivingStatus = "未归档";
TaxDocumentExample example = new TaxDocumentExample(); TaxDocumentExample example = new TaxDocumentExample();
......
...@@ -394,7 +394,13 @@ public class AnalysisServiceImpl extends BaseService { ...@@ -394,7 +394,13 @@ public class AnalysisServiceImpl extends BaseService {
//通过公司名称查询orgId //通过公司名称查询orgId
OrganizationExample example = new OrganizationExample(); OrganizationExample example = new OrganizationExample();
example.createCriteria().andNameEqualTo(getCellStringValue(sheet.getRow(j).getCell(0))); example.createCriteria().andNameEqualTo(getCellStringValue(sheet.getRow(j).getCell(0)));
model.setSeqNo(getSeqNoByPeriod(organizationMapper.selectByExample(example).get(0).getId(), Integer.parseInt(periodDate))); /* if(organizationMapper.selectByExample(example).size() == 0)
continue;*/
try{
model.setSeqNo(getSeqNoByPeriod(organizationMapper.selectByExample(example).get(0).getId(), DateUtils.strToPeriod(periodDate)));
}catch (Exception e){
System.out.println(getCellStringValue(sheet.getRow(j).getCell(0)));
}
lists.add(model); lists.add(model);
} }
AnalysisEmployeeNumExample example = new AnalysisEmployeeNumExample(); AnalysisEmployeeNumExample example = new AnalysisEmployeeNumExample();
...@@ -409,6 +415,7 @@ public class AnalysisServiceImpl extends BaseService { ...@@ -409,6 +415,7 @@ public class AnalysisServiceImpl extends BaseService {
}catch (ServiceException se){ }catch (ServiceException se){
throw se; throw se;
}catch (Exception e){ }catch (Exception e){
e.printStackTrace();
throw new ServiceException(e); throw new ServiceException(e);
} }
} }
...@@ -490,6 +497,12 @@ public class AnalysisServiceImpl extends BaseService { ...@@ -490,6 +497,12 @@ public class AnalysisServiceImpl extends BaseService {
model.setRightPublicAmount(getCellBigDecimalValue(cell2)); model.setRightPublicAmount(getCellBigDecimalValue(cell2));
} }
} }
AnalysisMasterExample example2 = new AnalysisMasterExample();
//todo 这里先写死滴滴出行科技有限公司
example2.createCriteria().andNameEqualTo("滴滴出行科技有限公司");
List<AnalysisMaster> size = analysisMasterMapper.selectByExample(example2);
if(size.size() != 0)
model.setSeqNo(size.get(0).getSeqNo());
AnalysisDriverNumExample example = new AnalysisDriverNumExample(); AnalysisDriverNumExample example = new AnalysisDriverNumExample();
example.createCriteria().andPeriodEqualTo(selectedPer); example.createCriteria().andPeriodEqualTo(selectedPer);
analysisDriverNumMapper.deleteByExample(example); analysisDriverNumMapper.deleteByExample(example);
...@@ -578,6 +591,12 @@ public class AnalysisServiceImpl extends BaseService { ...@@ -578,6 +591,12 @@ public class AnalysisServiceImpl extends BaseService {
model.setSubsidyC(getCellBigDecimalValue(sheet.getRow(j).getCell(3))); model.setSubsidyC(getCellBigDecimalValue(sheet.getRow(j).getCell(3)));
model.setRevenue(getCellBigDecimalValue(sheet.getRow(j).getCell(4))); model.setRevenue(getCellBigDecimalValue(sheet.getRow(j).getCell(4)));
model.setProfit(getCellBigDecimalValue(sheet.getRow(j).getCell(5))); model.setProfit(getCellBigDecimalValue(sheet.getRow(j).getCell(5)));
model.setRef1(getCellBigDecimalValue(sheet.getRow(j).getCell(6)));
model.setRef2(getCellBigDecimalValue(sheet.getRow(j).getCell(7)));
model.setRef3(getCellBigDecimalValue(sheet.getRow(j).getCell(8)));
model.setRef4(getCellBigDecimalValue(sheet.getRow(j).getCell(9)));
model.setRef5(getCellBigDecimalValue(sheet.getRow(j).getCell(10)));
model.setRef6(getCellBigDecimalValue(sheet.getRow(j).getCell(11)));
lists.add(model); lists.add(model);
} }
AnalysisInternationalBusinessDataExample example = new AnalysisInternationalBusinessDataExample(); AnalysisInternationalBusinessDataExample example = new AnalysisInternationalBusinessDataExample();
......
...@@ -254,9 +254,6 @@ public class AssetListServiceImpl extends BaseService { ...@@ -254,9 +254,6 @@ public class AssetListServiceImpl extends BaseService {
} }
//循环存储新的资产 //循环存储新的资产
int insertBatch = assetListMapper.insertBatch(citAssetsLists); int insertBatch = assetListMapper.insertBatch(citAssetsLists);
// for (CitAssetsList citAsset : citAssetsLists){
// assetListMapper.insertSelective(citAsset);
// }
//处理资产类别 //处理资产类别
//1、根据projectId查询数据库中已有的资产类别,并和新导入的资产类别进行比较 //1、根据projectId查询数据库中已有的资产类别,并和新导入的资产类别进行比较
// for (CitAssetGroupResult groupResult : citAssetGroupResults) { // for (CitAssetGroupResult groupResult : citAssetGroupResults) {
...@@ -428,6 +425,8 @@ public class AssetListServiceImpl extends BaseService { ...@@ -428,6 +425,8 @@ public class AssetListServiceImpl extends BaseService {
List<CitAssetsList> citAssetsLists = selectAssetsList(projectId, assetGroupResult.getAssetName(),saveGroupType); List<CitAssetsList> citAssetsLists = selectAssetsList(projectId, assetGroupResult.getAssetName(),saveGroupType);
citAssetsLists.stream().forEach(citAsset -> { citAssetsLists.stream().forEach(citAsset -> {
setCitAssetTaxData(citAsset,assetGroupResult,assetDetailGroup); setCitAssetTaxData(citAsset,assetGroupResult,assetDetailGroup);
//根据主键修改资产清单数据
assetListMapper.updateByPrimaryKeySelective(citAsset);
}); });
} }
...@@ -494,7 +493,7 @@ public class AssetListServiceImpl extends BaseService { ...@@ -494,7 +493,7 @@ public class AssetListServiceImpl extends BaseService {
//更改资产状态,已进行分类并有效 //更改资产状态,已进行分类并有效
citAsset.setStatus(1); citAsset.setStatus(1);
//根据主键修改资产清单数据 //根据主键修改资产清单数据
assetListMapper.updateByPrimaryKeySelective(citAsset); // assetListMapper.updateByPrimaryKeySelective(citAsset);
} }
public ApiResultDto updateAssetResultList(List<CitAssetsList> assetsLists, String projectId){ public ApiResultDto updateAssetResultList(List<CitAssetsList> assetsLists, String projectId){
......
...@@ -114,8 +114,8 @@ public class CitImportExcelServiceImpl extends BaseService { ...@@ -114,8 +114,8 @@ public class CitImportExcelServiceImpl extends BaseService {
break; break;
case SalaryAdvance: case SalaryAdvance:
//目前只有预提费用需要月份 //目前只有预提费用需要月份
period = DateUtils.strToPeriodYM(periodDate); Integer month = DateUtils.strToPeriodM(periodDate);
operationResultDto = importSalaryAdvance(input, orgList, fileName, period, importType); operationResultDto = importSalaryAdvance(input, orgList, fileName, period, month, importType);
break; break;
} }
return operationResultDto; return operationResultDto;
...@@ -1036,7 +1036,7 @@ public class CitImportExcelServiceImpl extends BaseService { ...@@ -1036,7 +1036,7 @@ public class CitImportExcelServiceImpl extends BaseService {
* @throws InvalidFormatException * @throws InvalidFormatException
* @throws ParseException * @throws ParseException
*/ */
public OperationResultDto importSalaryAdvance(InputStream inputStream, List<String> orgList, String fileName, Integer period, Integer importType) throws IOException, InvalidFormatException, ParseException { public OperationResultDto importSalaryAdvance(InputStream inputStream, List<String> orgList, String fileName, Integer period, Integer month, Integer importType) throws IOException, InvalidFormatException, ParseException {
OperationResultDto<Object> saveResult = new OperationResultDto<>(); OperationResultDto<Object> saveResult = new OperationResultDto<>();
Workbook workbook = fileService.getWorkbook(inputStream, fileName, "citTrialBalance"); Workbook workbook = fileService.getWorkbook(inputStream, fileName, "citTrialBalance");
if (workbook == null) { if (workbook == null) {
...@@ -1062,7 +1062,7 @@ public class CitImportExcelServiceImpl extends BaseService { ...@@ -1062,7 +1062,7 @@ public class CitImportExcelServiceImpl extends BaseService {
Map<String, Integer> noProjectMap = new HashMap(); Map<String, Integer> noProjectMap = new HashMap();
String currentUserName = authUserHelper.getCurrentAuditor().get(); String currentUserName = authUserHelper.getCurrentAuditor().get();
//通过循环来完成sheet获取每一行每一列数据并进行相关逻辑处理 //通过循环来完成sheet获取每一行每一列数据并进行相关逻辑处理
for (int rowNum = sheet.getFirstRowNum() + 2; rowNum <= sheet.getLastRowNum(); rowNum++) { for (int rowNum = sheet.getFirstRowNum() + 3; rowNum <= sheet.getLastRowNum(); rowNum++) {
DecimalFormat df=new DecimalFormat("0"); DecimalFormat df=new DecimalFormat("0");
//获取该行数据 //获取该行数据
...@@ -1107,8 +1107,7 @@ public class CitImportExcelServiceImpl extends BaseService { ...@@ -1107,8 +1107,7 @@ public class CitImportExcelServiceImpl extends BaseService {
continue; continue;
} }
//因预提传过来的时间带着月份,所以要算出年份来查询卡片 projectId = getProjectId(orgId, period);
projectId = getProjectId(orgId, period/100);
if(StringUtils.isBlank(projectId)){ if(StringUtils.isBlank(projectId)){
noProjectMap.put(sb.toString(),noProjectMap.containsKey(sb.toString())?noProjectMap.get(sb.toString())+1:1); noProjectMap.put(sb.toString(),noProjectMap.containsKey(sb.toString())?noProjectMap.get(sb.toString())+1:1);
continue; continue;
...@@ -1125,6 +1124,7 @@ public class CitImportExcelServiceImpl extends BaseService { ...@@ -1125,6 +1124,7 @@ public class CitImportExcelServiceImpl extends BaseService {
citSalaryAdvance.setOrganizationId(orgId); citSalaryAdvance.setOrganizationId(orgId);
citSalaryAdvance.setProjectId(projectId); citSalaryAdvance.setProjectId(projectId);
citSalaryAdvance.setPeriod(period); citSalaryAdvance.setPeriod(period);
citSalaryAdvance.setMonth(month);
citSalaryAdvance.setCreatedBy(currentUserName); citSalaryAdvance.setCreatedBy(currentUserName);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
......
...@@ -46,6 +46,7 @@ import pwc.taxtech.atms.vat.service.impl.report.functions.FormulaHelper; ...@@ -46,6 +46,7 @@ import pwc.taxtech.atms.vat.service.impl.report.functions.FormulaHelper;
import javax.annotation.Resource; import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.ByteArrayOutputStream;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.*; import java.util.*;
import java.util.regex.Matcher; import java.util.regex.Matcher;
...@@ -233,7 +234,7 @@ public class CitReportServiceImpl extends BaseService { ...@@ -233,7 +234,7 @@ public class CitReportServiceImpl extends BaseService {
setStatus(genJob, STATUS_END); setStatus(genJob, STATUS_END);
periodJobMapper.updateByPrimaryKey(genJob); periodJobMapper.updateByPrimaryKey(genJob);
reportGenerator.updateWorkbookCaclsValueToDb(projectId, periodParam, workbook, resources, isMergeManualData, genJob); reportGenerator.citUpdateWorkbookCaclsValueToDb(projectId, periodParam, workbook, resources, isMergeManualData, genJob);
//===============================================start validation compute========================================================== //===============================================start validation compute==========================================================
//todo: 1.get the data from workbook, then put the data into new workbook //todo: 1.get the data from workbook, then put the data into new workbook
...@@ -1245,7 +1246,7 @@ public class CitReportServiceImpl extends BaseService { ...@@ -1245,7 +1246,7 @@ public class CitReportServiceImpl extends BaseService {
} }
cellData.setData(sumValue); cellData.setData(sumValue);
cellData.setUpdateTime(new Date()); cellData.setUpdateTime(new Date());
int i = periodCellDataMapper.updateByPrimaryKeySelective(cellData); periodCellDataMapper.updateByPrimaryKeySelective(cellData);
/*kevin insert */ // TODO: 3/21/2019 需要验证 /*kevin insert */ // TODO: 3/21/2019 需要验证
if(sumValue !=null){ if(sumValue !=null){
...@@ -1476,12 +1477,12 @@ public class CitReportServiceImpl extends BaseService { ...@@ -1476,12 +1477,12 @@ public class CitReportServiceImpl extends BaseService {
BeanUtils.copyProperties(citAssetsListDto, citAssetsList); BeanUtils.copyProperties(citAssetsListDto, citAssetsList);
List<CitAssetEamMapping> citAssetEamMappings = assetsListMapper.getAssetEamMapping(citAssetsList); List<CitAssetEamMapping> citAssetEamMappings = assetsListMapper.getAssetEamMapping(citAssetsList);
for (CitAssetEamMapping temp : citAssetEamMappings) { for (CitAssetEamMapping temp : citAssetEamMappings) {
//计算处置损益 处置/赔偿收入-账面净值(年终剩余价值) //计算处置损益 账面净值(年终剩余价值)-处置/赔偿收入
temp.setDisposalProfitAndLoss(temp.getCompensationSaleAmount().subtract(temp.getYearEndValue())); temp.setDisposalProfitAndLoss(temp.getYearEndValue().subtract(temp.getCompensationSaleAmount()));
//计算资产的税务净值 taxNetValue 原值-累计税务折旧/摊销 //计算资产的税务净值 taxNetValue 原值-累计税务折旧/摊销
temp.setTaxNetValue(temp.getAcquisitionValue().subtract(temp.getTaxToCurrentYearDepreciationAmount())); temp.setTaxNetValue(temp.getAcquisitionValue().subtract(temp.getTaxToCurrentYearDepreciationAmount()));
//处置的税收损益 处置/赔偿收入-资产的税务净值 //处置的税收损益 资产的税务净值-处置/赔偿收入
temp.setDisposalTaxBenefit(temp.getCompensationSaleAmount().subtract(temp.getTaxNetValue())); temp.setDisposalTaxBenefit(temp.getTaxNetValue().subtract(temp.getCompensationSaleAmount()));
temp.setId(idService.nextId()); temp.setId(idService.nextId());
temp.setCreateTime(null); temp.setCreateTime(null);
temp.setUpdateTime(null); temp.setUpdateTime(null);
...@@ -1690,4 +1691,32 @@ public class CitReportServiceImpl extends BaseService { ...@@ -1690,4 +1691,32 @@ public class CitReportServiceImpl extends BaseService {
} }
return citDistributionDto; return citDistributionDto;
} }
public Workbook generateReportData(List<Long> reportIds, String projectId, Integer period) {
PeriodReportExample reportExample = new PeriodReportExample();
reportExample.createCriteria().andIdIn(reportIds);
List<PeriodReport> reports = periodReportMapper.selectByExample(reportExample);
PeriodTemplateExample example = new PeriodTemplateExample();
example.createCriteria().andTemplateIdIn(reports.stream().map(m -> m.getTemplateId()).collect(Collectors.toList())).andProjectIdEqualTo(projectId).andPeriodEqualTo(period);
List<PeriodTemplate> dataList = periodTemplateMapper.selectByExample(example);
ByteArrayOutputStream bout = new ByteArrayOutputStream();
Workbook tWorkbook = null;
try {
tWorkbook = reportGenerator.createWorkBookByPeriodTemplate(dataList);
tWorkbook.write(bout);
// FileUpload fileUpload = didiFileUploadService.uploadFile(bout.toByteArray(), "demo.xlsx", FileUploadEnum.BizSource.PERIOD_REPORT_TEMPLATE_UPLOAD.name());
} catch (Exception e) {
e.printStackTrace();
} finally {
try {
bout.close();
} catch (Exception e) {
e.printStackTrace();
}
}
return tWorkbook;
}
} }
package pwc.taxtech.atms.service.impl;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import pwc.taxtech.atms.common.AuthUserHelper;
import pwc.taxtech.atms.common.CommonUtils;
import pwc.taxtech.atms.constant.enums.EnumServiceType;
import pwc.taxtech.atms.constant.enums.FileUploadEnum;
import pwc.taxtech.atms.dao.ProjectMapper;
import pwc.taxtech.atms.dao.UserMapper;
import pwc.taxtech.atms.dto.didiFileUpload.DidiFileIUploadParam;
import pwc.taxtech.atms.dto.didiFileUpload.DidiFileUploadDetailResult;
import pwc.taxtech.atms.dto.reportUpload.ReportUploadParam;
import pwc.taxtech.atms.dto.reportUpload.ReportUploadResult;
import pwc.taxtech.atms.entity.Project;
import pwc.taxtech.atms.entity.User;
import pwc.taxtech.atms.vat.dao.ReportUploadMapper;
import pwc.taxtech.atms.vat.entity.FileUpload;
import pwc.taxtech.atms.vat.entity.ReportUpload;
import pwc.taxtech.atms.vat.entity.ReportUploadExample;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
@Service
public class CitReportUploadService extends BaseService {
@Resource
private ReportUploadMapper reportUploadMapper;
@Autowired
protected AuthUserHelper authUserHelper;
@Resource
private UserMapper userMapper;
@Resource
private ProjectMapper projectMapper;
@Autowired
DidiFileUploadService didiFileUploadService;
public PageInfo<ReportUploadResult> queryPage(ReportUploadParam param) {
Page page = PageHelper.startPage(param.getPageInfo().getPageIndex(), param.getPageInfo().getPageSize());
ReportUploadExample example = new ReportUploadExample();
example.createCriteria().andProjectIdEqualTo(param.getProjectId()).andPeriodEqualTo(param.getPeriod()).andServiceTypeEqualTo(EnumServiceType.CIT.getCode());
example.setOrderByClause(" create_time DESC ");
List<ReportUpload> dataList = reportUploadMapper.selectByExample(example);
DidiFileIUploadParam fileParam = new DidiFileIUploadParam();
fileParam.setUuids(dataList.stream()
.map(o -> o.getFileUploadId()).collect(Collectors.toList()));
PageInfo<DidiFileUploadDetailResult> uploadDetail = didiFileUploadService.queryPage(fileParam);
Map<String,String> urlMap = null;
if(CollectionUtils.isNotEmpty(uploadDetail.getList())){
urlMap = uploadDetail.getList().stream().collect(Collectors.toMap(DidiFileUploadDetailResult::getUid, didiFileUploadDetailResult -> didiFileUploadDetailResult.getViewHttpUrl()));
}
List<ReportUploadResult> resultList = new ArrayList<ReportUploadResult>();
for(ReportUpload data:dataList){
ReportUploadResult result = beanUtil.copyProperties(data, new ReportUploadResult());
result.setFileUrl(urlMap.get(data.getFileUploadId()));
resultList.add(result);
}
PageInfo<ReportUploadResult> pageInfo = new PageInfo<>(resultList);
pageInfo.setTotal(page.getTotal());
return pageInfo;
}
public void saveData(MultipartFile file, ReportUpload data) {
String uid = authUserHelper.getCurrentUserId();
User user = userMapper.selectByPrimaryKey(uid);
data.setCreator(user.getUserName());
String fileName = "";
Project project = projectMapper.selectByPrimaryKey(data.getProjectId());
data.setOrgId(project.getOrganizationId());
fileName += project.getName();
fileName += "-";
fileName += data.getPeriod();
fileName += "-V";
ReportUploadExample example = new ReportUploadExample();
example.createCriteria().andProjectIdEqualTo(data.getProjectId()).andPeriodEqualTo(data.getPeriod());
example.setOrderByClause("version desc");
List<ReportUpload> dataList = reportUploadMapper.selectByExample(example);
if (CollectionUtils.isNotEmpty(dataList)) {
fileName += (dataList.get(0).getVersion() + 1);
data.setVersion(dataList.get(0).getVersion() + 1);
} else {
fileName += 1;
data.setVersion(1);
}
fileName += ".xlsx";
data.setReportName(fileName);
FileUpload fileUpload = didiFileUploadService.uploadFile(file, fileName, FileUploadEnum.BizSource.REPORT_UPLOAD.name());
data.setFileUploadId(fileUpload.getUid());
data.setUid(CommonUtils.getUUID());
data.setCreateTime(new Date());
reportUploadMapper.insert(data);
}
public void saveData(byte[] bytes, ReportUpload data) {
String uid = authUserHelper.getCurrentUserId();
User user = userMapper.selectByPrimaryKey(uid);
data.setCreator(user.getUserName());
String fileName = "";
Project project = projectMapper.selectByPrimaryKey(data.getProjectId());
data.setOrgId(project.getOrganizationId());
String period = ""+project.getYear()+(data.getPeriod()>9?data.getPeriod():("0"+data.getPeriod()));
data.setPeriod(Integer.valueOf(period));
fileName += project.getName();
fileName += "-";
fileName += data.getPeriod();
fileName += "-V";
ReportUploadExample example = new ReportUploadExample();
example.createCriteria().andProjectIdEqualTo(data.getProjectId()).andPeriodEqualTo(data.getPeriod());
example.setOrderByClause("version desc");
List<ReportUpload> dataList = reportUploadMapper.selectByExample(example);
if (CollectionUtils.isNotEmpty(dataList)) {
fileName += (dataList.get(0).getVersion() + 1);
data.setVersion(dataList.get(0).getVersion() + 1);
} else {
fileName += 1;
data.setVersion(1);
}
fileName += ".xlsx";
data.setReportName(fileName);
FileUpload fileUpload = didiFileUploadService.uploadFile(bytes, fileName, FileUploadEnum.BizSource.REPORT_UPLOAD.name());
data.setFileUploadId(fileUpload.getUid());
data.setUid(CommonUtils.getUUID());
data.setCreateTime(new Date());
data.setServiceType(EnumServiceType.CIT.getCode());
reportUploadMapper.insert(data);
}
}
...@@ -9,6 +9,7 @@ import org.springframework.stereotype.Service; ...@@ -9,6 +9,7 @@ import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import pwc.taxtech.atms.common.AuthUserHelper; import pwc.taxtech.atms.common.AuthUserHelper;
import pwc.taxtech.atms.common.CommonUtils; import pwc.taxtech.atms.common.CommonUtils;
import pwc.taxtech.atms.constant.enums.EnumServiceType;
import pwc.taxtech.atms.constant.enums.FileUploadEnum; import pwc.taxtech.atms.constant.enums.FileUploadEnum;
import pwc.taxtech.atms.dao.ProjectMapper; import pwc.taxtech.atms.dao.ProjectMapper;
import pwc.taxtech.atms.dao.UserMapper; import pwc.taxtech.atms.dao.UserMapper;
...@@ -52,7 +53,7 @@ public class ReportUploadService extends BaseService { ...@@ -52,7 +53,7 @@ public class ReportUploadService extends BaseService {
public PageInfo<ReportUploadResult> queryPage(ReportUploadParam param) { public PageInfo<ReportUploadResult> queryPage(ReportUploadParam param) {
Page page = PageHelper.startPage(param.getPageInfo().getPageIndex(), param.getPageInfo().getPageSize()); Page page = PageHelper.startPage(param.getPageInfo().getPageIndex(), param.getPageInfo().getPageSize());
ReportUploadExample example = new ReportUploadExample(); ReportUploadExample example = new ReportUploadExample();
example.createCriteria().andProjectIdEqualTo(param.getProjectId()).andPeriodEqualTo(param.getPeriod()); example.createCriteria().andProjectIdEqualTo(param.getProjectId()).andPeriodEqualTo(param.getPeriod()).andServiceTypeEqualTo(EnumServiceType.VAT.getCode());
example.setOrderByClause(" create_time DESC "); example.setOrderByClause(" create_time DESC ");
List<ReportUpload> dataList = reportUploadMapper.selectByExample(example); List<ReportUpload> dataList = reportUploadMapper.selectByExample(example);
DidiFileIUploadParam fileParam = new DidiFileIUploadParam(); DidiFileIUploadParam fileParam = new DidiFileIUploadParam();
...@@ -135,6 +136,7 @@ public class ReportUploadService extends BaseService { ...@@ -135,6 +136,7 @@ public class ReportUploadService extends BaseService {
data.setFileUploadId(fileUpload.getUid()); data.setFileUploadId(fileUpload.getUid());
data.setUid(CommonUtils.getUUID()); data.setUid(CommonUtils.getUUID());
data.setCreateTime(new Date()); data.setCreateTime(new Date());
data.setServiceType(EnumServiceType.VAT.getCode());
reportUploadMapper.insert(data); reportUploadMapper.insert(data);
} }
} }
...@@ -397,11 +397,10 @@ public class TemplateGroupServiceImpl extends AbstractService { ...@@ -397,11 +397,10 @@ public class TemplateGroupServiceImpl extends AbstractService {
config.setUpdateTime(now); config.setUpdateTime(now);
config.setUpdateBy(authUserHelper.getCurrentUserId()); config.setUpdateBy(authUserHelper.getCurrentUserId());
cellTemplateConfigList.add(config); cellTemplateConfigList.add(config);
//只允许单元格内容为${KeyIn}的才允许手工收入,所以此处注释 update by zhikai.z.wei start if (allowManual) {
// if (allowManual) { addManualConfig(cellTemplate, template, cell, now, cellTemplateConfigList);
// addManualConfig(cellTemplate, template, cell, now, cellTemplateConfigList); }
// }
//只允许单元格内容为${KeyIn}的才允许手工收入,所以此处注释 update by zhikai.z.wei end
PeriodDataSource pds = new PeriodDataSource(); PeriodDataSource pds = new PeriodDataSource();
pds.setAmount(BigDecimal.ZERO); pds.setAmount(BigDecimal.ZERO);
pds.setUpdateBy("Admin"); pds.setUpdateBy("Admin");
...@@ -557,11 +556,9 @@ public class TemplateGroupServiceImpl extends AbstractService { ...@@ -557,11 +556,9 @@ public class TemplateGroupServiceImpl extends AbstractService {
config.setUpdateBy(authUserHelper.getCurrentUserId()); config.setUpdateBy(authUserHelper.getCurrentUserId());
cellTemplateConfigList.add(config); cellTemplateConfigList.add(config);
//noinspection Duplicates //noinspection Duplicates
//只允许单元格内容为${KeyIn}的才允许手工收入,所以此处注释 update by zhikai.z.wei start if (allowManual) {
// if (allowManual) { addManualConfig(cellTemplate, template, cell, now, cellTemplateConfigList);
// addManualConfig(cellTemplate, template, cell, now, cellTemplateConfigList); }
// }
//只允许单元格内容为${KeyIn}的才允许手工收入,所以此处注释 update by zhikai.z.wei end
PeriodDataSource pds = new PeriodDataSource(); PeriodDataSource pds = new PeriodDataSource();
pds.setAmount(BigDecimal.ZERO); pds.setAmount(BigDecimal.ZERO);
pds.setUpdateBy("Admin"); pds.setUpdateBy("Admin");
......
...@@ -108,6 +108,21 @@ public class FormulaAgent { ...@@ -108,6 +108,21 @@ public class FormulaAgent {
} }
/**
* 查询所有的数据源,来用作判断当前单元格是只有手工数据源还是还有别的数据源 create by zhikai.z.wei at 20190411 20:44
* @param templateId
* @param projectId
* @param period
* @return
*/
public List<PeriodDataSource> queryNoManualDataSource(Long templateId, String projectId, Integer period) {
PeriodDataSourceExample example = new PeriodDataSourceExample();
example.createCriteria().andProjectIdEqualTo(projectId).andPeriodEqualTo(period)
.andCellTemplateIdEqualTo(templateId);
return periodDataSourceMapper.selectByExample(example);
}
private PeriodReport getReportByTemplate(String templateId, Integer periodId, String projectId) { private PeriodReport getReportByTemplate(String templateId, Integer periodId, String projectId) {
PeriodReportExample example = new PeriodReportExample(); PeriodReportExample example = new PeriodReportExample();
example.createCriteria().andProjectIdEqualTo(projectId).andTemplateIdEqualTo(Long.valueOf(templateId)) example.createCriteria().andProjectIdEqualTo(projectId).andTemplateIdEqualTo(Long.valueOf(templateId))
......
...@@ -125,8 +125,16 @@ public class BB extends FunctionBase implements FreeRefFunction { ...@@ -125,8 +125,16 @@ public class BB extends FunctionBase implements FreeRefFunction {
cellValue = new BigDecimal(cellData.getData()).setScale(4, cellValue = new BigDecimal(cellData.getData()).setScale(4,
BigDecimal.ROUND_HALF_DOWN); BigDecimal.ROUND_HALF_DOWN);
} else if (cellData.getData() != null && !dss.isEmpty()) { } else if (cellData.getData() != null && !dss.isEmpty()) {
cellValue = dss.get(0).getAmount().add(new BigDecimal(cellData.getData()).setScale(4, //查询所有的数据源,来用作判断当前单元格是只有手工数据源还是还有别的数据源 create by zhikai.z.wei at 20190411 20:44
BigDecimal.ROUND_HALF_DOWN)); List<PeriodDataSource> allDataSource = agent.queryNoManualDataSource(Long.parseLong(cellTemplateData.getCellTemplateId()),
project == null ? formulaContext.getProjectId() : project.getId(), curPeriod.getCurPeriod());
if(!allDataSource.isEmpty() && allDataSource.size()>1){
cellValue = dss.get(0).getAmount().add(new BigDecimal(cellData.getData()).setScale(4,
BigDecimal.ROUND_HALF_DOWN));
}else{
cellValue = new BigDecimal(cellData.getData()).setScale(4,
BigDecimal.ROUND_HALF_DOWN);
}
} else throw Exceptions.BB_CELL_DATA_NULL; } else throw Exceptions.BB_CELL_DATA_NULL;
nullCellDto.setAmount(cellValue); nullCellDto.setAmount(cellValue);
if (rootBo != null) { if (rootBo != null) {
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<property name="rootInterface" value="pwc.taxtech.atms.MyAnalysisMapper" /> <property name="rootInterface" value="pwc.taxtech.atms.MyAnalysisMapper" />
</javaClientGenerator> </javaClientGenerator>
<table tableName="analysis_expected_tax_return" domainObjectName="AnalysisExpectedTaxReturn"> <table tableName="analysis_international_business_data" domainObjectName="AnalysisInternationalBusinessData">
<property name="useActualColumnNames" value="false"/> <property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/> <property name="ignoreQualifiersAtRuntime" value="true"/>
</table> </table>
......
...@@ -101,6 +101,60 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser ...@@ -101,6 +101,60 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser
*/ */
private BigDecimal profit; private BigDecimal profit;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_1
*
* @mbg.generated
*/
private BigDecimal ref1;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_2
*
* @mbg.generated
*/
private BigDecimal ref2;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_3
*
* @mbg.generated
*/
private BigDecimal ref3;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_4
*
* @mbg.generated
*/
private BigDecimal ref4;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_5
*
* @mbg.generated
*/
private BigDecimal ref5;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column analysis_international_business_data.ref_6
*
* @mbg.generated
*/
private BigDecimal ref6;
/** /**
* *
* This field was generated by MyBatis Generator. * This field was generated by MyBatis Generator.
...@@ -376,6 +430,150 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser ...@@ -376,6 +430,150 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser
this.profit = profit; this.profit = profit;
} }
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_1
*
* @return the value of analysis_international_business_data.ref_1
*
* @mbg.generated
*/
public BigDecimal getRef1() {
return ref1;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_1
*
* @param ref1 the value for analysis_international_business_data.ref_1
*
* @mbg.generated
*/
public void setRef1(BigDecimal ref1) {
this.ref1 = ref1;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_2
*
* @return the value of analysis_international_business_data.ref_2
*
* @mbg.generated
*/
public BigDecimal getRef2() {
return ref2;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_2
*
* @param ref2 the value for analysis_international_business_data.ref_2
*
* @mbg.generated
*/
public void setRef2(BigDecimal ref2) {
this.ref2 = ref2;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_3
*
* @return the value of analysis_international_business_data.ref_3
*
* @mbg.generated
*/
public BigDecimal getRef3() {
return ref3;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_3
*
* @param ref3 the value for analysis_international_business_data.ref_3
*
* @mbg.generated
*/
public void setRef3(BigDecimal ref3) {
this.ref3 = ref3;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_4
*
* @return the value of analysis_international_business_data.ref_4
*
* @mbg.generated
*/
public BigDecimal getRef4() {
return ref4;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_4
*
* @param ref4 the value for analysis_international_business_data.ref_4
*
* @mbg.generated
*/
public void setRef4(BigDecimal ref4) {
this.ref4 = ref4;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_5
*
* @return the value of analysis_international_business_data.ref_5
*
* @mbg.generated
*/
public BigDecimal getRef5() {
return ref5;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_5
*
* @param ref5 the value for analysis_international_business_data.ref_5
*
* @mbg.generated
*/
public void setRef5(BigDecimal ref5) {
this.ref5 = ref5;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.ref_6
*
* @return the value of analysis_international_business_data.ref_6
*
* @mbg.generated
*/
public BigDecimal getRef6() {
return ref6;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column analysis_international_business_data.ref_6
*
* @param ref6 the value for analysis_international_business_data.ref_6
*
* @mbg.generated
*/
public void setRef6(BigDecimal ref6) {
this.ref6 = ref6;
}
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method returns the value of the database column analysis_international_business_data.exchange_rate * This method returns the value of the database column analysis_international_business_data.exchange_rate
...@@ -564,6 +762,12 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser ...@@ -564,6 +762,12 @@ public class AnalysisInternationalBusinessData extends BaseEntity implements Ser
sb.append(", subsidyC=").append(subsidyC); sb.append(", subsidyC=").append(subsidyC);
sb.append(", revenue=").append(revenue); sb.append(", revenue=").append(revenue);
sb.append(", profit=").append(profit); sb.append(", profit=").append(profit);
sb.append(", ref1=").append(ref1);
sb.append(", ref2=").append(ref2);
sb.append(", ref3=").append(ref3);
sb.append(", ref4=").append(ref4);
sb.append(", ref5=").append(ref5);
sb.append(", ref6=").append(ref6);
sb.append(", exchangeRate=").append(exchangeRate); sb.append(", exchangeRate=").append(exchangeRate);
sb.append(", createTime=").append(createTime); sb.append(", createTime=").append(createTime);
sb.append(", updateTime=").append(updateTime); sb.append(", updateTime=").append(updateTime);
......
...@@ -540,6 +540,17 @@ public class CitSalaryAdvance extends BaseEntity implements Serializable { ...@@ -540,6 +540,17 @@ public class CitSalaryAdvance 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_salary_advance.month
*
* @mbg.generated
*/
private Integer month;
/** /**
* This field was generated by MyBatis Generator. * This field was generated by MyBatis Generator.
* This field corresponds to the database table cit_salary_advance * This field corresponds to the database table cit_salary_advance
...@@ -1700,6 +1711,30 @@ public class CitSalaryAdvance extends BaseEntity implements Serializable { ...@@ -1700,6 +1711,30 @@ public class CitSalaryAdvance 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_salary_advance.month
*
* @return the value of cit_salary_advance.month
*
* @mbg.generated
*/
public Integer getMonth() {
return month;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column cit_salary_advance.month
*
* @param month the value for cit_salary_advance.month
*
* @mbg.generated
*/
public void setMonth(Integer month) {
this.month = month;
}
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method corresponds to the database table cit_salary_advance * This method corresponds to the database table cit_salary_advance
...@@ -1760,6 +1795,7 @@ public class CitSalaryAdvance extends BaseEntity implements Serializable { ...@@ -1760,6 +1795,7 @@ public class CitSalaryAdvance extends BaseEntity implements Serializable {
sb.append(", updatedBy=").append(updatedBy); sb.append(", updatedBy=").append(updatedBy);
sb.append(", createTime=").append(createTime); sb.append(", createTime=").append(createTime);
sb.append(", updateTime=").append(updateTime); sb.append(", updateTime=").append(updateTime);
sb.append(", month=").append(month);
sb.append("]"); sb.append("]");
return sb.toString(); return sb.toString();
} }
......
...@@ -3405,6 +3405,66 @@ public class CitSalaryAdvanceExample { ...@@ -3405,6 +3405,66 @@ public class CitSalaryAdvanceExample {
addCriterion("update_time not between", value1, value2, "updateTime"); addCriterion("update_time not between", value1, value2, "updateTime");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andMonthIsNull() {
addCriterion("month is null");
return (Criteria) this;
}
public Criteria andMonthIsNotNull() {
addCriterion("month is not null");
return (Criteria) this;
}
public Criteria andMonthEqualTo(Integer value) {
addCriterion("month =", value, "month");
return (Criteria) this;
}
public Criteria andMonthNotEqualTo(Integer value) {
addCriterion("month <>", value, "month");
return (Criteria) this;
}
public Criteria andMonthGreaterThan(Integer value) {
addCriterion("month >", value, "month");
return (Criteria) this;
}
public Criteria andMonthGreaterThanOrEqualTo(Integer value) {
addCriterion("month >=", value, "month");
return (Criteria) this;
}
public Criteria andMonthLessThan(Integer value) {
addCriterion("month <", value, "month");
return (Criteria) this;
}
public Criteria andMonthLessThanOrEqualTo(Integer value) {
addCriterion("month <=", value, "month");
return (Criteria) this;
}
public Criteria andMonthIn(List<Integer> values) {
addCriterion("month in", values, "month");
return (Criteria) this;
}
public Criteria andMonthNotIn(List<Integer> values) {
addCriterion("month not in", values, "month");
return (Criteria) this;
}
public Criteria andMonthBetween(Integer value1, Integer value2) {
addCriterion("month between", value1, value2, "month");
return (Criteria) this;
}
public Criteria andMonthNotBetween(Integer value1, Integer value2) {
addCriterion("month not between", value1, value2, "month");
return (Criteria) this;
}
} }
/** /**
......
...@@ -26,6 +26,14 @@ public interface ReportUploadMapper extends MyVatMapper { ...@@ -26,6 +26,14 @@ public interface ReportUploadMapper extends MyVatMapper {
*/ */
int deleteByExample(ReportUploadExample example); int deleteByExample(ReportUploadExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload
*
* @mbg.generated
*/
int deleteByPrimaryKey(String uid);
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload * This method corresponds to the database table report_upload
...@@ -58,6 +66,14 @@ public interface ReportUploadMapper extends MyVatMapper { ...@@ -58,6 +66,14 @@ public interface ReportUploadMapper extends MyVatMapper {
*/ */
List<ReportUpload> selectByExample(ReportUploadExample example); List<ReportUpload> selectByExample(ReportUploadExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload
*
* @mbg.generated
*/
ReportUpload selectByPrimaryKey(String uid);
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload * This method corresponds to the database table report_upload
...@@ -73,4 +89,20 @@ public interface ReportUploadMapper extends MyVatMapper { ...@@ -73,4 +89,20 @@ public interface ReportUploadMapper extends MyVatMapper {
* @mbg.generated * @mbg.generated
*/ */
int updateByExample(@Param("record") ReportUpload record, @Param("example") ReportUploadExample example); int updateByExample(@Param("record") ReportUpload record, @Param("example") ReportUploadExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(ReportUpload record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload
*
* @mbg.generated
*/
int updateByPrimaryKey(ReportUpload record);
} }
\ No newline at end of file
...@@ -109,6 +109,17 @@ public class ReportUpload extends BaseEntity implements Serializable { ...@@ -109,6 +109,17 @@ public class ReportUpload extends BaseEntity implements Serializable {
*/ */
private String fileUploadId; private String fileUploadId;
/**
* Database Column Remarks:
* 税务类型(2代表VAT,6代表CIT)
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column report_upload.service_type
*
* @mbg.generated
*/
private Integer serviceType;
/** /**
* This field was generated by MyBatis Generator. * This field was generated by MyBatis Generator.
* This field corresponds to the database table report_upload * This field corresponds to the database table report_upload
...@@ -333,6 +344,30 @@ public class ReportUpload extends BaseEntity implements Serializable { ...@@ -333,6 +344,30 @@ public class ReportUpload extends BaseEntity implements Serializable {
this.fileUploadId = fileUploadId == null ? null : fileUploadId.trim(); this.fileUploadId = fileUploadId == null ? null : fileUploadId.trim();
} }
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column report_upload.service_type
*
* @return the value of report_upload.service_type
*
* @mbg.generated
*/
public Integer getServiceType() {
return serviceType;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column report_upload.service_type
*
* @param serviceType the value for report_upload.service_type
*
* @mbg.generated
*/
public void setServiceType(Integer serviceType) {
this.serviceType = serviceType;
}
/** /**
* This method was generated by MyBatis Generator. * This method was generated by MyBatis Generator.
* This method corresponds to the database table report_upload * This method corresponds to the database table report_upload
...@@ -354,6 +389,7 @@ public class ReportUpload extends BaseEntity implements Serializable { ...@@ -354,6 +389,7 @@ public class ReportUpload extends BaseEntity implements Serializable {
sb.append(", reportName=").append(reportName); sb.append(", reportName=").append(reportName);
sb.append(", version=").append(version); sb.append(", version=").append(version);
sb.append(", fileUploadId=").append(fileUploadId); sb.append(", fileUploadId=").append(fileUploadId);
sb.append(", serviceType=").append(serviceType);
sb.append("]"); sb.append("]");
return sb.toString(); return sb.toString();
} }
......
...@@ -794,6 +794,66 @@ public class ReportUploadExample { ...@@ -794,6 +794,66 @@ public class ReportUploadExample {
addCriterion("file_upload_id not between", value1, value2, "fileUploadId"); addCriterion("file_upload_id not between", value1, value2, "fileUploadId");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andServiceTypeIsNull() {
addCriterion("service_type is null");
return (Criteria) this;
}
public Criteria andServiceTypeIsNotNull() {
addCriterion("service_type is not null");
return (Criteria) this;
}
public Criteria andServiceTypeEqualTo(Integer value) {
addCriterion("service_type =", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeNotEqualTo(Integer value) {
addCriterion("service_type <>", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeGreaterThan(Integer value) {
addCriterion("service_type >", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeGreaterThanOrEqualTo(Integer value) {
addCriterion("service_type >=", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeLessThan(Integer value) {
addCriterion("service_type <", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeLessThanOrEqualTo(Integer value) {
addCriterion("service_type <=", value, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeIn(List<Integer> values) {
addCriterion("service_type in", values, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeNotIn(List<Integer> values) {
addCriterion("service_type not in", values, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeBetween(Integer value1, Integer value2) {
addCriterion("service_type between", value1, value2, "serviceType");
return (Criteria) this;
}
public Criteria andServiceTypeNotBetween(Integer value1, Integer value2) {
addCriterion("service_type not between", value1, value2, "serviceType");
return (Criteria) this;
}
} }
/** /**
......
...@@ -14,6 +14,12 @@ ...@@ -14,6 +14,12 @@
<result column="subsidy_c" jdbcType="DECIMAL" property="subsidyC" /> <result column="subsidy_c" jdbcType="DECIMAL" property="subsidyC" />
<result column="revenue" jdbcType="DECIMAL" property="revenue" /> <result column="revenue" jdbcType="DECIMAL" property="revenue" />
<result column="profit" jdbcType="DECIMAL" property="profit" /> <result column="profit" jdbcType="DECIMAL" property="profit" />
<result column="ref_1" jdbcType="DECIMAL" property="ref1" />
<result column="ref_2" jdbcType="DECIMAL" property="ref2" />
<result column="ref_3" jdbcType="DECIMAL" property="ref3" />
<result column="ref_4" jdbcType="DECIMAL" property="ref4" />
<result column="ref_5" jdbcType="DECIMAL" property="ref5" />
<result column="ref_6" jdbcType="DECIMAL" property="ref6" />
<result column="exchange_rate" jdbcType="DECIMAL" property="exchangeRate" /> <result column="exchange_rate" jdbcType="DECIMAL" property="exchangeRate" />
<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" />
...@@ -93,8 +99,9 @@ ...@@ -93,8 +99,9 @@
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.
--> -->
id, seq_no, gmv, trips, subsidy_b, subsidy_c, revenue, profit, exchange_rate, create_time, id, seq_no, gmv, trips, subsidy_b, subsidy_c, revenue, profit, ref_1, ref_2, ref_3,
update_time, organization_id, company_name, period, country ref_4, ref_5, ref_6, exchange_rate, create_time, update_time, organization_id, company_name,
period, country
</sql> </sql>
<select id="selectByExample" parameterType="pwc.taxtech.atms.analysis.entity.AnalysisInternationalBusinessDataExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="pwc.taxtech.atms.analysis.entity.AnalysisInternationalBusinessDataExample" resultMap="BaseResultMap">
<!-- <!--
...@@ -149,16 +156,18 @@ ...@@ -149,16 +156,18 @@
--> -->
insert into analysis_international_business_data (id, seq_no, gmv, insert into analysis_international_business_data (id, seq_no, gmv,
trips, subsidy_b, subsidy_c, trips, subsidy_b, subsidy_c,
revenue, profit, exchange_rate, revenue, profit, ref_1,
create_time, update_time, organization_id, ref_2, ref_3, ref_4, ref_5,
company_name, period, country ref_6, exchange_rate, create_time,
) update_time, organization_id, company_name,
period, country)
values (#{id,jdbcType=BIGINT}, #{seqNo,jdbcType=VARCHAR}, #{gmv,jdbcType=DECIMAL}, values (#{id,jdbcType=BIGINT}, #{seqNo,jdbcType=VARCHAR}, #{gmv,jdbcType=DECIMAL},
#{trips,jdbcType=DECIMAL}, #{subsidyB,jdbcType=DECIMAL}, #{subsidyC,jdbcType=DECIMAL}, #{trips,jdbcType=DECIMAL}, #{subsidyB,jdbcType=DECIMAL}, #{subsidyC,jdbcType=DECIMAL},
#{revenue,jdbcType=DECIMAL}, #{profit,jdbcType=DECIMAL}, #{exchangeRate,jdbcType=DECIMAL}, #{revenue,jdbcType=DECIMAL}, #{profit,jdbcType=DECIMAL}, #{ref1,jdbcType=DECIMAL},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{organizationId,jdbcType=VARCHAR}, #{ref2,jdbcType=DECIMAL}, #{ref3,jdbcType=DECIMAL}, #{ref4,jdbcType=DECIMAL}, #{ref5,jdbcType=DECIMAL},
#{companyName,jdbcType=VARCHAR}, #{period,jdbcType=INTEGER}, #{country,jdbcType=VARCHAR} #{ref6,jdbcType=DECIMAL}, #{exchangeRate,jdbcType=DECIMAL}, #{createTime,jdbcType=TIMESTAMP},
) #{updateTime,jdbcType=TIMESTAMP}, #{organizationId,jdbcType=VARCHAR}, #{companyName,jdbcType=VARCHAR},
#{period,jdbcType=INTEGER}, #{country,jdbcType=VARCHAR})
</insert> </insert>
<insert id="insertSelective" parameterType="pwc.taxtech.atms.analysis.entity.AnalysisInternationalBusinessData"> <insert id="insertSelective" parameterType="pwc.taxtech.atms.analysis.entity.AnalysisInternationalBusinessData">
<!-- <!--
...@@ -191,6 +200,24 @@ ...@@ -191,6 +200,24 @@
<if test="profit != null"> <if test="profit != null">
profit, profit,
</if> </if>
<if test="ref1 != null">
ref_1,
</if>
<if test="ref2 != null">
ref_2,
</if>
<if test="ref3 != null">
ref_3,
</if>
<if test="ref4 != null">
ref_4,
</if>
<if test="ref5 != null">
ref_5,
</if>
<if test="ref6 != null">
ref_6,
</if>
<if test="exchangeRate != null"> <if test="exchangeRate != null">
exchange_rate, exchange_rate,
</if> </if>
...@@ -238,6 +265,24 @@ ...@@ -238,6 +265,24 @@
<if test="profit != null"> <if test="profit != null">
#{profit,jdbcType=DECIMAL}, #{profit,jdbcType=DECIMAL},
</if> </if>
<if test="ref1 != null">
#{ref1,jdbcType=DECIMAL},
</if>
<if test="ref2 != null">
#{ref2,jdbcType=DECIMAL},
</if>
<if test="ref3 != null">
#{ref3,jdbcType=DECIMAL},
</if>
<if test="ref4 != null">
#{ref4,jdbcType=DECIMAL},
</if>
<if test="ref5 != null">
#{ref5,jdbcType=DECIMAL},
</if>
<if test="ref6 != null">
#{ref6,jdbcType=DECIMAL},
</if>
<if test="exchangeRate != null"> <if test="exchangeRate != null">
#{exchangeRate,jdbcType=DECIMAL}, #{exchangeRate,jdbcType=DECIMAL},
</if> </if>
...@@ -302,6 +347,24 @@ ...@@ -302,6 +347,24 @@
<if test="record.profit != null"> <if test="record.profit != null">
profit = #{record.profit,jdbcType=DECIMAL}, profit = #{record.profit,jdbcType=DECIMAL},
</if> </if>
<if test="record.ref1 != null">
ref_1 = #{record.ref1,jdbcType=DECIMAL},
</if>
<if test="record.ref2 != null">
ref_2 = #{record.ref2,jdbcType=DECIMAL},
</if>
<if test="record.ref3 != null">
ref_3 = #{record.ref3,jdbcType=DECIMAL},
</if>
<if test="record.ref4 != null">
ref_4 = #{record.ref4,jdbcType=DECIMAL},
</if>
<if test="record.ref5 != null">
ref_5 = #{record.ref5,jdbcType=DECIMAL},
</if>
<if test="record.ref6 != null">
ref_6 = #{record.ref6,jdbcType=DECIMAL},
</if>
<if test="record.exchangeRate != null"> <if test="record.exchangeRate != null">
exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL}, exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL},
</if> </if>
...@@ -342,6 +405,12 @@ ...@@ -342,6 +405,12 @@
subsidy_c = #{record.subsidyC,jdbcType=DECIMAL}, subsidy_c = #{record.subsidyC,jdbcType=DECIMAL},
revenue = #{record.revenue,jdbcType=DECIMAL}, revenue = #{record.revenue,jdbcType=DECIMAL},
profit = #{record.profit,jdbcType=DECIMAL}, profit = #{record.profit,jdbcType=DECIMAL},
ref_1 = #{record.ref1,jdbcType=DECIMAL},
ref_2 = #{record.ref2,jdbcType=DECIMAL},
ref_3 = #{record.ref3,jdbcType=DECIMAL},
ref_4 = #{record.ref4,jdbcType=DECIMAL},
ref_5 = #{record.ref5,jdbcType=DECIMAL},
ref_6 = #{record.ref6,jdbcType=DECIMAL},
exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL}, exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL},
create_time = #{record.createTime,jdbcType=TIMESTAMP}, create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP}, update_time = #{record.updateTime,jdbcType=TIMESTAMP},
...@@ -381,6 +450,24 @@ ...@@ -381,6 +450,24 @@
<if test="profit != null"> <if test="profit != null">
profit = #{profit,jdbcType=DECIMAL}, profit = #{profit,jdbcType=DECIMAL},
</if> </if>
<if test="ref1 != null">
ref_1 = #{ref1,jdbcType=DECIMAL},
</if>
<if test="ref2 != null">
ref_2 = #{ref2,jdbcType=DECIMAL},
</if>
<if test="ref3 != null">
ref_3 = #{ref3,jdbcType=DECIMAL},
</if>
<if test="ref4 != null">
ref_4 = #{ref4,jdbcType=DECIMAL},
</if>
<if test="ref5 != null">
ref_5 = #{ref5,jdbcType=DECIMAL},
</if>
<if test="ref6 != null">
ref_6 = #{ref6,jdbcType=DECIMAL},
</if>
<if test="exchangeRate != null"> <if test="exchangeRate != null">
exchange_rate = #{exchangeRate,jdbcType=DECIMAL}, exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
</if> </if>
...@@ -418,6 +505,12 @@ ...@@ -418,6 +505,12 @@
subsidy_c = #{subsidyC,jdbcType=DECIMAL}, subsidy_c = #{subsidyC,jdbcType=DECIMAL},
revenue = #{revenue,jdbcType=DECIMAL}, revenue = #{revenue,jdbcType=DECIMAL},
profit = #{profit,jdbcType=DECIMAL}, profit = #{profit,jdbcType=DECIMAL},
ref_1 = #{ref1,jdbcType=DECIMAL},
ref_2 = #{ref2,jdbcType=DECIMAL},
ref_3 = #{ref3,jdbcType=DECIMAL},
ref_4 = #{ref4,jdbcType=DECIMAL},
ref_5 = #{ref5,jdbcType=DECIMAL},
ref_6 = #{ref6,jdbcType=DECIMAL},
exchange_rate = #{exchangeRate,jdbcType=DECIMAL}, exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
create_time = #{createTime,jdbcType=TIMESTAMP}, create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP}, update_time = #{updateTime,jdbcType=TIMESTAMP},
......
...@@ -54,6 +54,7 @@ ...@@ -54,6 +54,7 @@
<result column="updated_by" jdbcType="VARCHAR" property="updatedBy" /> <result column="updated_by" jdbcType="VARCHAR" property="updatedBy" />
<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="month" jdbcType="INTEGER" property="month" />
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<!-- <!--
...@@ -134,7 +135,7 @@ ...@@ -134,7 +135,7 @@
subject_description, auxiliary_subject, auxiliary_subject_description, profit_center, subject_description, auxiliary_subject, auxiliary_subject_description, profit_center,
profit_center_description, product, product_description, project, project_description, profit_center_description, product, product_description, project, project_description,
company, company_description, segment1, segment1_description, segment2, segment2_description, company, company_description, segment1, segment1_description, segment2, segment2_description,
created_by, updated_by, create_time, update_time created_by, updated_by, create_time, update_time, month
</sql> </sql>
<select id="selectByExample" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultMap="BaseResultMap">
<!-- <!--
...@@ -203,7 +204,8 @@ ...@@ -203,7 +204,8 @@
project_description, company, company_description, project_description, company, company_description,
segment1, segment1_description, segment2, segment1, segment1_description, segment2,
segment2_description, created_by, updated_by, segment2_description, created_by, updated_by,
create_time, update_time) create_time, update_time, month
)
values (#{id,jdbcType=BIGINT}, #{organizationId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR}, values (#{id,jdbcType=BIGINT}, #{organizationId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR},
#{period,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR}, #{poNo,jdbcType=VARCHAR}, #{period,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR}, #{poNo,jdbcType=VARCHAR},
#{poRow,jdbcType=VARCHAR}, #{poCreateTime,jdbcType=TIMESTAMP}, #{ladingBillPerson,jdbcType=VARCHAR}, #{poRow,jdbcType=VARCHAR}, #{poCreateTime,jdbcType=TIMESTAMP}, #{ladingBillPerson,jdbcType=VARCHAR},
...@@ -220,7 +222,8 @@ ...@@ -220,7 +222,8 @@
#{projectDescription,jdbcType=VARCHAR}, #{company,jdbcType=VARCHAR}, #{companyDescription,jdbcType=VARCHAR}, #{projectDescription,jdbcType=VARCHAR}, #{company,jdbcType=VARCHAR}, #{companyDescription,jdbcType=VARCHAR},
#{segment1,jdbcType=VARCHAR}, #{segment1Description,jdbcType=VARCHAR}, #{segment2,jdbcType=VARCHAR}, #{segment1,jdbcType=VARCHAR}, #{segment1Description,jdbcType=VARCHAR}, #{segment2,jdbcType=VARCHAR},
#{segment2Description,jdbcType=VARCHAR}, #{createdBy,jdbcType=VARCHAR}, #{updatedBy,jdbcType=VARCHAR}, #{segment2Description,jdbcType=VARCHAR}, #{createdBy,jdbcType=VARCHAR}, #{updatedBy,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}) #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{month,jdbcType=INTEGER}
)
</insert> </insert>
<insert id="insertSelective" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvance"> <insert id="insertSelective" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvance">
<!-- <!--
...@@ -373,6 +376,9 @@ ...@@ -373,6 +376,9 @@
<if test="updateTime != null"> <if test="updateTime != null">
update_time, update_time,
</if> </if>
<if test="month != null">
month,
</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null"> <if test="id != null">
...@@ -519,6 +525,9 @@ ...@@ -519,6 +525,9 @@
<if test="updateTime != null"> <if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="month != null">
#{month,jdbcType=INTEGER},
</if>
</trim> </trim>
</insert> </insert>
<select id="countByExample" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultType="java.lang.Long"> <select id="countByExample" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultType="java.lang.Long">
...@@ -682,6 +691,9 @@ ...@@ -682,6 +691,9 @@
<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.month != null">
month = #{record.month,jdbcType=INTEGER},
</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" />
...@@ -740,7 +752,8 @@ ...@@ -740,7 +752,8 @@
created_by = #{record.createdBy,jdbcType=VARCHAR}, created_by = #{record.createdBy,jdbcType=VARCHAR},
updated_by = #{record.updatedBy,jdbcType=VARCHAR}, updated_by = #{record.updatedBy,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},
month = #{record.month,jdbcType=INTEGER}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
...@@ -893,6 +906,9 @@ ...@@ -893,6 +906,9 @@
<if test="updateTime != null"> <if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP}, update_time = #{updateTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="month != null">
month = #{month,jdbcType=INTEGER},
</if>
</set> </set>
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
...@@ -948,7 +964,8 @@ ...@@ -948,7 +964,8 @@
created_by = #{createdBy,jdbcType=VARCHAR}, created_by = #{createdBy,jdbcType=VARCHAR},
updated_by = #{updatedBy,jdbcType=VARCHAR}, updated_by = #{updatedBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP}, create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP} update_time = #{updateTime,jdbcType=TIMESTAMP},
month = #{month,jdbcType=INTEGER}
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
<select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultMap="BaseResultMap"> <select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.entity.CitSalaryAdvanceExample" resultMap="BaseResultMap">
......
...@@ -364,6 +364,9 @@ ...@@ -364,6 +364,9 @@
<if test="subjectName != null and subjectName != ''"> <if test="subjectName != null and subjectName != ''">
and subject_name LIKE CONCAT('%' ,#{subjectName},'%') and subject_name LIKE CONCAT('%' ,#{subjectName},'%')
</if> </if>
<if test="description != null and description != ''">
and description LIKE CONCAT('%' ,#{description},'%')
</if>
<if test="periodStart!=null"> <if test="periodStart!=null">
AND account_period >= #{periodStart,jdbcType=INTEGER} AND account_period >= #{periodStart,jdbcType=INTEGER}
</if> </if>
...@@ -393,6 +396,9 @@ ...@@ -393,6 +396,9 @@
<if test="subjectName != null and subjectName != ''"> <if test="subjectName != null and subjectName != ''">
and segment3_name LIKE CONCAT('%' ,#{segment3_name},'%') and segment3_name LIKE CONCAT('%' ,#{segment3_name},'%')
</if> </if>
<if test="description != null and description != ''">
and description LIKE CONCAT('%' ,#{description},'%')
</if>
<if test="periodStart!=null"> <if test="periodStart!=null">
AND period &gt;= #{periodStart,jdbcType=INTEGER} AND period &gt;= #{periodStart,jdbcType=INTEGER}
</if> </if>
......
...@@ -218,6 +218,10 @@ ...@@ -218,6 +218,10 @@
<when test="item.updateTime != null">#{item.updateTime,jdbcType=TIMESTAMP},</when> <when test="item.updateTime != null">#{item.updateTime,jdbcType=TIMESTAMP},</when>
<otherwise>CURRENT_TIMESTAMP,</otherwise> <otherwise>CURRENT_TIMESTAMP,</otherwise>
</choose> </choose>
<choose>
<when test="item.month != null">#{item.month,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
</trim> </trim>
</foreach>; </foreach>;
SELECT 1 FROM DUAL; SELECT 1 FROM DUAL;
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
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.
--> -->
<result column="uid" jdbcType="VARCHAR" property="uid" /> <id column="uid" jdbcType="VARCHAR" property="uid" />
<result column="org_id" jdbcType="VARCHAR" property="orgId" /> <result column="org_id" jdbcType="VARCHAR" property="orgId" />
<result column="project_id" jdbcType="VARCHAR" property="projectId" /> <result column="project_id" jdbcType="VARCHAR" property="projectId" />
<result column="period" jdbcType="INTEGER" property="period" /> <result column="period" jdbcType="INTEGER" property="period" />
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<result column="report_name" jdbcType="VARCHAR" property="reportName" /> <result column="report_name" jdbcType="VARCHAR" property="reportName" />
<result column="version" jdbcType="INTEGER" property="version" /> <result column="version" jdbcType="INTEGER" property="version" />
<result column="file_upload_id" jdbcType="VARCHAR" property="fileUploadId" /> <result column="file_upload_id" jdbcType="VARCHAR" property="fileUploadId" />
<result column="service_type" jdbcType="INTEGER" property="serviceType" />
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<!-- <!--
...@@ -87,7 +88,8 @@ ...@@ -87,7 +88,8 @@
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.
--> -->
`uid`, org_id, project_id, period, creator, create_time, report_name, version, file_upload_id `uid`, org_id, project_id, period, creator, create_time, report_name, version, file_upload_id,
service_type
</sql> </sql>
<select id="selectByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultMap="BaseResultMap">
<!-- <!--
...@@ -107,6 +109,24 @@ ...@@ -107,6 +109,24 @@
order by ${orderByClause} order by ${orderByClause}
</if> </if>
</select> </select>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
select
<include refid="Base_Column_List" />
from report_upload
where `uid` = #{uid,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
delete from report_upload
where `uid` = #{uid,jdbcType=VARCHAR}
</delete>
<delete id="deleteByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample"> <delete id="deleteByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample">
<!-- <!--
WARNING - @mbg.generated WARNING - @mbg.generated
...@@ -124,12 +144,12 @@ ...@@ -124,12 +144,12 @@
--> -->
insert into report_upload (`uid`, org_id, project_id, insert into report_upload (`uid`, org_id, project_id,
period, creator, create_time, period, creator, create_time,
report_name, version, file_upload_id report_name, version, file_upload_id,
) service_type)
values (#{uid,jdbcType=VARCHAR}, #{orgId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR}, values (#{uid,jdbcType=VARCHAR}, #{orgId,jdbcType=VARCHAR}, #{projectId,jdbcType=VARCHAR},
#{period,jdbcType=INTEGER}, #{creator,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{period,jdbcType=INTEGER}, #{creator,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{reportName,jdbcType=VARCHAR}, #{version,jdbcType=INTEGER}, #{fileUploadId,jdbcType=VARCHAR} #{reportName,jdbcType=VARCHAR}, #{version,jdbcType=INTEGER}, #{fileUploadId,jdbcType=VARCHAR},
) #{serviceType,jdbcType=INTEGER})
</insert> </insert>
<insert id="insertSelective" parameterType="pwc.taxtech.atms.vat.entity.ReportUpload"> <insert id="insertSelective" parameterType="pwc.taxtech.atms.vat.entity.ReportUpload">
<!-- <!--
...@@ -165,6 +185,9 @@ ...@@ -165,6 +185,9 @@
<if test="fileUploadId != null"> <if test="fileUploadId != null">
file_upload_id, file_upload_id,
</if> </if>
<if test="serviceType != null">
service_type,
</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="uid != null"> <if test="uid != null">
...@@ -194,6 +217,9 @@ ...@@ -194,6 +217,9 @@
<if test="fileUploadId != null"> <if test="fileUploadId != null">
#{fileUploadId,jdbcType=VARCHAR}, #{fileUploadId,jdbcType=VARCHAR},
</if> </if>
<if test="serviceType != null">
#{serviceType,jdbcType=INTEGER},
</if>
</trim> </trim>
</insert> </insert>
<select id="countByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultType="java.lang.Long"> <select id="countByExample" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultType="java.lang.Long">
...@@ -240,6 +266,9 @@ ...@@ -240,6 +266,9 @@
<if test="record.fileUploadId != null"> <if test="record.fileUploadId != null">
file_upload_id = #{record.fileUploadId,jdbcType=VARCHAR}, file_upload_id = #{record.fileUploadId,jdbcType=VARCHAR},
</if> </if>
<if test="record.serviceType != null">
service_type = #{record.serviceType,jdbcType=INTEGER},
</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" />
...@@ -259,11 +288,66 @@ ...@@ -259,11 +288,66 @@
create_time = #{record.createTime,jdbcType=TIMESTAMP}, create_time = #{record.createTime,jdbcType=TIMESTAMP},
report_name = #{record.reportName,jdbcType=VARCHAR}, report_name = #{record.reportName,jdbcType=VARCHAR},
version = #{record.version,jdbcType=INTEGER}, version = #{record.version,jdbcType=INTEGER},
file_upload_id = #{record.fileUploadId,jdbcType=VARCHAR} file_upload_id = #{record.fileUploadId,jdbcType=VARCHAR},
service_type = #{record.serviceType,jdbcType=INTEGER}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
</update> </update>
<update id="updateByPrimaryKeySelective" parameterType="pwc.taxtech.atms.vat.entity.ReportUpload">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update report_upload
<set>
<if test="orgId != null">
org_id = #{orgId,jdbcType=VARCHAR},
</if>
<if test="projectId != null">
project_id = #{projectId,jdbcType=VARCHAR},
</if>
<if test="period != null">
period = #{period,jdbcType=INTEGER},
</if>
<if test="creator != null">
creator = #{creator,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="reportName != null">
report_name = #{reportName,jdbcType=VARCHAR},
</if>
<if test="version != null">
version = #{version,jdbcType=INTEGER},
</if>
<if test="fileUploadId != null">
file_upload_id = #{fileUploadId,jdbcType=VARCHAR},
</if>
<if test="serviceType != null">
service_type = #{serviceType,jdbcType=INTEGER},
</if>
</set>
where `uid` = #{uid,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="pwc.taxtech.atms.vat.entity.ReportUpload">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update report_upload
set org_id = #{orgId,jdbcType=VARCHAR},
project_id = #{projectId,jdbcType=VARCHAR},
period = #{period,jdbcType=INTEGER},
creator = #{creator,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
report_name = #{reportName,jdbcType=VARCHAR},
version = #{version,jdbcType=INTEGER},
file_upload_id = #{fileUploadId,jdbcType=VARCHAR},
service_type = #{serviceType,jdbcType=INTEGER}
where `uid` = #{uid,jdbcType=VARCHAR}
</update>
<select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultMap="BaseResultMap"> <select id="selectByExampleWithRowbounds" parameterType="pwc.taxtech.atms.vat.entity.ReportUploadExample" resultMap="BaseResultMap">
<!-- <!--
WARNING - @mbg.generated WARNING - @mbg.generated
......
...@@ -1100,6 +1100,23 @@ init-row="initRow" init-col="initCol" service-type="\'6\'" is-document-list="tru ...@@ -1100,6 +1100,23 @@ init-row="initRow" init-col="initCol" service-type="\'6\'" is-document-list="tru
sticky: false sticky: false
}); });
$stateProvider.state({
name: 'cit.generateReport.reportUploadView',
url: '/reportUploadView',
views: {
'@cit.generateReport': {
controller: ['$scope', '$stateParams', 'appTranslation',
function ($scope, $stateParams, appTranslation) {
appTranslation.load([appTranslation.cit]);
}],
template: '<cit-report-upload-detail></cit-report-upload-detail>',
}
},
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.cit),
deepStateRedirect: true,
sticky: true
});
// TODO: DCH Demo // TODO: DCH Demo
$stateProvider.state({ $stateProvider.state({
name: 'cit.generateReport.performOCR', name: 'cit.generateReport.performOCR',
......
...@@ -314,6 +314,42 @@ ...@@ -314,6 +314,42 @@
allowHeaderFiltering: false, allowHeaderFiltering: false,
width: '16%', width: '16%',
caption: 'Profit' caption: 'Profit'
},
{
dataField: "ref1",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref1'
},
{
dataField: "ref2",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref2'
},
{
dataField: "ref3",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref3'
},
{
dataField: "ref4",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref4'
},
{
dataField: "ref5",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref5'
},
{
dataField: "ref6",
allowHeaderFiltering: false,
width: '16%',
caption: 'ref6'
}], }],
onContentReady: function (e) { onContentReady: function (e) {
$scope.accountingRateListInstance = e.component; $scope.accountingRateListInstance = e.component;
...@@ -606,14 +642,14 @@ ...@@ -606,14 +642,14 @@
case 100: case 100:
$scope.showInternationalBUDataGrid = true; $scope.showInternationalBUDataGrid = true;
loadinternationalBUDatagrid(); loadinternationalBUDatagrid();
$scope.selectCountry = ''; /*$scope.selectCountry = '';
$scope.selectCompany = ''; $scope.selectCompany = '';*/
break; break;
case 101: case 101:
$scope.showInternationalTaxDataGrid = true; $scope.showInternationalTaxDataGrid = true;
loadInternationalTaxDataGrid(); loadInternationalTaxDataGrid();
$scope.selectCountry = ''; /* $scope.selectCountry = '';
$scope.selectCompany = ''; $scope.selectCompany = '';*/
break; break;
default: default:
break; break;
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
<i class="fa fa-calendar imp-subheader red-color" style="width:20px;"></i> <i class="fa fa-calendar imp-subheader red-color" style="width:20px;"></i>
</div> </div>
</div> </div>
<div class="col-sm-5 rightNav" style="width:46%;padding-left: 0px; left: 20%;"> <div class="col-sm-5 rightNav" style="width:46%;padding-left: 0px; left: 14%;">
<button type="button" <button type="button"
ngf-select="" type="file" ng-model="importExcelFile" ngf-drag-over-class="'dragover'" accept=".xls,.xlsx" ngf-multiple="false" ngf-select="" type="file" ng-model="importExcelFile" ngf-drag-over-class="'dragover'" accept=".xls,.xlsx" ngf-multiple="false"
ngf-allow-dir="false" class="btn btn-vat-third" > ngf-allow-dir="false" class="btn btn-vat-third" >
......
...@@ -15,6 +15,12 @@ ...@@ -15,6 +15,12 @@
<input class="form-control input-width-middle" type="text" id="subjectName" ng-model="queryParams.subjectName" /> <input class="form-control input-width-middle" type="text" id="subjectName" ng-model="queryParams.subjectName" />
</td> </td>
</tr> </tr>
<tr>
<td>
<span translate="Summary"></span>
<input class="form-control input-width-middle" type="text" id="description" ng-model="queryParams.description" />
</td>
</tr>
<tr style="display: none"> <tr style="display: none">
<td> <td>
<span translate="orgCode"></span> <span translate="orgCode"></span>
......
...@@ -41,6 +41,7 @@ ...@@ -41,6 +41,7 @@
periodEnd: '', periodEnd: '',
subjectCode: null, subjectCode: null,
subjectName: null, subjectName: null,
description: null,
orgCode: null, orgCode: null,
orgName: null, orgName: null,
documentDate: null, documentDate: null,
...@@ -93,6 +94,7 @@ ...@@ -93,6 +94,7 @@
periodEnd: '', periodEnd: '',
subjectCode: null, subjectCode: null,
subjectName: null, subjectName: null,
description: null,
orgCode: null, orgCode: null,
orgName: null, orgName: null,
documentDate: null, documentDate: null,
......
...@@ -504,6 +504,7 @@ ...@@ -504,6 +504,7 @@
// 根据已有信息通过spreadJS计算各单元格的值 // 根据已有信息通过spreadJS计算各单元格的值
var setData = function () { var setData = function () {
debugger;
var sheet = scope.spread.sheets[0]; var sheet = scope.spread.sheets[0];
var isExportData = false; var isExportData = false;
if (angular.isArray(scope.reportSource)) { if (angular.isArray(scope.reportSource)) {
......
<div class="cit-report-upload-detail">
<div class="header-title">
<div style="display:inline-block"><span class="title-name">{{'ReportUploadDetail' | translate }}</span></div>
</div>
<div class="content-container" style="height: 60%">
<div class="body">
<div class="grid-container">
<div id="invoiceGridContainer" dx-data-grid="reportOneGridOptions">
<div data-options="dxTemplate:{ name:'editCellTemplate' }">
</div>
</div>
</div>
<div class="page-footer">
<ack-pagination page-options="pagingOptions"
refresh-table="refreshGrid()"></ack-pagination>
</div>
</div>
</div>
<div style="height: 40%">
<div class="content-container-other" style="float:left;width:49%;">
<div class="body">
<div class="grid-container">
<div id="invoiceGridContainer1" dx-data-grid="reportTwoGridOptions">
<div data-options="dxTemplate:{ name:'editCellTemplate' }">
</div>
</div>
</div>
</div>
</div>
<div class="content-container-other" style="float:right;width:49%;">
<div class="body">
<div class="grid-container">
<div id="invoiceGridContainer2" dx-data-grid="reportThreeGridOptions">
<div data-options="dxTemplate:{ name:'editCellTemplate' }">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
citModule.directive('citReportUploadDetail', ['$log',
function ($log) {
$log.debug('citReportUploadDetail.ctor()...');
return {
restrict: 'E',
templateUrl: 'app/cit/report/cit-report-upload-view/cit-report-upload-detail.html' + '?_=' + Math.random(),
scope: {},
controller: 'citReportUploadDetailController'
}
}
]);
\ No newline at end of file

@border-color: #d4d4d4;
@margin-left: 60px;
@container-width: 970px;
@control-width: 120px;
//sharing
.header {
padding: 15px;
img {
margin-top: 3px;
}
.search-panel {
border: 1px solid #CDCDCD;
border-radius: 5px;
padding: 5px;
.row {
margin: 10px 0;
.filter-item {
display: inline-block;
vertical-align: middle;
height: 32px;
}
.fileter-label {
text-align: right;
height: 32px;
padding-top: 5px;
}
.col-xs-1, .col-sm-1, .col-md-1, .col-lg-1, .col-xs-2, .col-sm-2, .col-md-2, .col-lg-2, .col-xs-3, .col-sm-3, .col-md-3, .col-lg-3, .col-xs-4, .col-sm-4, .col-md-4, .col-lg-4, .col-xs-5, .col-sm-5, .col-md-5, .col-lg-5, .col-xs-6, .col-sm-6, .col-md-6, .col-lg-6, .col-xs-7, .col-sm-7, .col-md-7, .col-lg-7, .col-xs-8, .col-sm-8, .col-md-8, .col-lg-8, .col-xs-9, .col-sm-9, .col-md-9, .col-lg-9, .col-xs-10, .col-sm-10, .col-md-10, .col-lg-10, .col-xs-11, .col-sm-11, .col-md-11, .col-lg-11, .col-xs-12, .col-sm-12, .col-md-12, .col-lg-12 {
padding-left: 0;
}
.invoice-btn {
min-width: 90px;
height: 34px;
}
}
.table-bottom {
margin-bottom: 0px !important;
.lbl-name {
word-break: keep-all;
}
td {
vertical-align: middle;
}
}
}
}
.table-bottom {
margin-bottom: 0px !important;
.lbl-name {
word-break: keep-all;
}
td {
vertical-align: middle;
}
}
.red-color {
color: #d04a02;
/*vertical-align: middle;*/
}
.dx-widget {
font-size: 13px;
}
//share
.header-title {
padding: 10px;
.sub-title {
font-family: "Microsoft YaHei";
font-weight: 400;
font-size: 12px;
color: rgb(153, 153, 153);
}
.title-name {
font-family: "Microsoft YaHei Bold", "Microsoft YaHei Regular", "Microsoft YaHei";
font-weight: 700;
font-style: normal;
}
}
.inline-block {
display: inline-block;
.left-side {
display: inline-block;
}
.right-side {
float: right;
display: inline-block;
}
}
.invoice-btn {
min-width: 80px;
height: 28px;
margin-right: 10px;
font-weight: normal;
font-size: 13px;
font-family: 'Microsoft YaHei';
}
.invoice-card {
width: 120px;
height: 130px;
border: 1px dashed @border-color;
border: 1px dashed rgba(0, 0, 0, 0.2);
border-radius: 5px;
background-color: #fff; /*#fbfbfb;*/
text-align: center;
cursor: pointer;
float: left;
margin: 10px;
position: relative;
&:hover {
background-color: #fff !important;
box-shadow: #a06748 1px 1px;
}
//卡片顶部的绝对定位
.dx-checkbox-container {
position: absolute;
left: 59px;
top: -8px;
}
}
.span-btn {
color: #6699CC;
padding: 0px 4px;
cursor: pointer;
font-size: 12px;
}
.borderless td, .borderless th {
border: none !important;
vertical-align: middle !important;
}
.page-footer {
display: inline-block;
float: right;
/*padding-right: 20px;*/
}
.invoice-table-dialog {
.modal-dialog {
min-width: 650px;
.modal-title {
color: red;
}
}
}
.invoiceNumber-link {
cursor: pointer;
/*color:#6699cc;*/
}
.cit-report-upload-detail {
height: 100% !important;
padding-top: 0px !important;
position: relative;
font-size: 13px;
.period-picker {
width: 150px;
border: 1px solid #c7c5c0;
display: inline-block;
line-height: 20px;
margin-top: 7px;
}
.imp-subheader {
display: inline-block;
font-size: 15px;
height: 30px;
line-height: 30px;
vertical-align: middle;
border: none;
select {
appearance: none;
-moz-appearance: none;
-webkit-appearance: none;
background: transparent;
}
}
.dx-datagrid-group-closed:before {
/* font-family: "ui-grid"; */
font-style: normal;
font-weight: normal;
speak: none;
display: inline-block;
text-decoration: inherit;
width: 1em;
margin-right: .2em;
text-align: center;
font-variant: normal;
text-transform: none;
line-height: 1em;
margin-left: .2em;
content: inherit!important;
}
.header-title {
padding: 10px;
.title-name {
font-family: "Microsoft YaHei Bold", "Microsoft YaHei Regular", "Microsoft YaHei";
font-weight: 700;
font-style: normal;
}
}
.custom-control {
width: @control-width !important;
height: 25px;
line-height: 25px;
}
.btn-search {
width: @control-width !important;
}
.content-container {
height: calc(~'100% - 40px');
position: relative;
.body {
.buttom-row {
padding: 15px;
display: inline-block;
width: 100%;
.left-side {
display: inline-block;
/*padding-left:5px;*/
.select-title {
margin-left: 20px;
}
.select-number {
padding: 0 1px;
color: red;
}
}
.right-side {
float: right;
display: inline-block;
/*padding-right:5px;*/
.btn {
margin-left: 20px;
}
}
}
.grid-container {
padding: 0px 15px;
/*height: 350px;*/
/*height:100%;*/
#invoiceGridContainer {
max-height: 100%;
}
.dx-datagrid-rowsview .dx-row > .dx-master-detail-cell {
padding: 0px !important;
}
.dx-datagrid-nowrap.dx-datagrid-headers .dx-header-row > td > .dx-datagrid-text-content {
white-space: normal !important;
}
.internal-grid-container {
padding: 10px 10px 10px 0;
& > div:first-child {
padding: 0 0 5px 10px;
font-size: 13px;
/*font-weight: bold;*/
}
}
}
}
}
.content-container-other {
height: calc(~'100% - 40px');
position: relative;
.body {
.buttom-row {
padding: 15px;
display: inline-block;
width: 100%;
.left-side {
display: inline-block;
/*padding-left:5px;*/
.select-title {
margin-left: 20px;
}
.select-number {
padding: 0 1px;
color: red;
}
}
.right-side {
float: right;
display: inline-block;
/*padding-right:5px;*/
.btn {
margin-left: 20px;
}
}
}
.grid-container {
padding: 0px 15px;
/*height: 350px;*/
/*height:100%;*/
#invoiceGridContainer {
max-height: 100%;
}
.dx-datagrid-rowsview .dx-row > .dx-master-detail-cell {
padding: 0px !important;
}
.dx-datagrid-nowrap.dx-datagrid-headers .dx-header-row > td > .dx-datagrid-text-content {
white-space: normal !important;
}
.internal-grid-container {
padding: 10px 10px 10px 0;
& > div:first-child {
padding: 0 0 5px 10px;
font-size: 13px;
/*font-weight: bold;*/
}
}
}
}
}
.importVerifyInvoiceModal {
.modal-dialog {
height: 200px;
width: 610px;
}
.modal-footer {
text-align: left;
}
}
}
...@@ -916,6 +916,14 @@ ...@@ -916,6 +916,14 @@
//打开导出文件弹出框 //打开导出文件弹出框
$scope.openExportPop = function (evenType) { $scope.openExportPop = function (evenType) {
$scope.evenType = evenType; $scope.evenType = evenType;
if ('export' == $scope.evenType) {
$scope.viewTitle = $translate.instant('SelectExportReport');
}
if ('upload' == $scope.evenType) {
$scope.viewTitle = $translate.instant('SelectUploadReport');
}
var grp = _.find($scope.$parent.$parent.groups, function (g) { var grp = _.find($scope.$parent.$parent.groups, function (g) {
return g.name == 'TaxReturnType'; return g.name == 'TaxReturnType';
}); });
...@@ -993,6 +1001,37 @@ debugger; ...@@ -993,6 +1001,37 @@ debugger;
SweetAlert.warning($translate.instant('ExportReportRequiredCheck')); SweetAlert.warning($translate.instant('ExportReportRequiredCheck'));
return; return;
} }
var reportIds = [];
angular.forEach($scope.selectedReportIds, function (reportId) {
var node = _.first(_.where(grp.children, {reportId: reportId}));
if (node) {
reportIds.push(node.reportId);
}else{
node = _.first(_.where(grp2.children, {reportId: reportId}));
if (node) {
reportIds.push(node.reportId);
}
}
});
if ('upload' == $scope.evenType) {
var xhr = new XMLHttpRequest();
xhr.onload = function (e) {
if(xhr.status === 200){
SweetAlert.success('', $translate.instant('FileUploadSuccess'));
}else{
SweetAlert.success('', $translate.instant('FileUploadFailed'));
}
$('#busy-indicator-container').hide();
};
xhr.open("POST", apiInterceptor.webApiHostUrl + '/citReport/uploadReportData/' + vatSessionService.project.id + '/' + 0, true);
xhr.setRequestHeader("Authorization", apiInterceptor.tokenType + ' ' + apiInterceptor.apiToken());
xhr.setRequestHeader("Content-Type", 'application/json;charset=UTF-8');
xhr.responseType = "arraybuffer";
xhr.send(JSON.stringify({
reportIds: reportIds
}));
return;
}
//设置报表的排序号,用于对导出的报表sheet进行排序 //设置报表的排序号,用于对导出的报表sheet进行排序
var orderIndex = 0; var orderIndex = 0;
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<!--<span ng-if="!isBSPL" ng-click="upLoadManual();"><i--> <!--<span ng-if="!isBSPL" ng-click="upLoadManual();"><i-->
<!--class="fa fa-floppy-o"></i>&nbsp;{{'上传手工数据'}}--> <!--class="fa fa-floppy-o"></i>&nbsp;{{'上传手工数据'}}-->
<!--</span>--> <!--</span>-->
<!--<span ng-if="!isBSPL" ng-click="openExportPop('upload');"><i class="fa fa-upload"></i>&nbsp;{{'UploadExcel' | translate}}</span>--> <span ng-if="!isBSPL" ng-click="openExportPop('upload');"><i class="fa fa-upload"></i>&nbsp;{{'UploadExcel' | translate}}</span>
<!--<span ng-if="!isBSPL" ng-click="saveReportCache();"><i--> <!--<span ng-if="!isBSPL" ng-click="saveReportCache();"><i-->
<!--class="fa fa-floppy-o"></i>&nbsp;{{'Save' | translate}}</span>--> <!--class="fa fa-floppy-o"></i>&nbsp;{{'Save' | translate}}</span>-->
</div> </div>
......
...@@ -5,9 +5,13 @@ ...@@ -5,9 +5,13 @@
$log.debug('vatReportUploadDetailController.ctor()...'); $log.debug('vatReportUploadDetailController.ctor()...');
//表格配置 //表格配置
$scope.reportOneGridOptions = $.extend(true, {}, dxDataGridService.BASIC_GRID_OPTIONS, { $scope.reportOneGridOptions = {
selection: {
mode: "single"
},
hoverStateEnabled: true,
showBorders: true,
columns: [ columns: [
{ {
dataField: 'serialNo', dataField: 'serialNo',
caption: $translate.instant('RepUploadDtlColSerialNo'), caption: $translate.instant('RepUploadDtlColSerialNo'),
...@@ -59,12 +63,16 @@ ...@@ -59,12 +63,16 @@
bindingOptions: { bindingOptions: {
dataSource: 'reportOneDataSource' dataSource: 'reportOneDataSource'
} }
}); };
$scope.reportTwoGridOptions = $.extend(true, {}, dxDataGridService.BASIC_GRID_OPTIONS, { $scope.reportTwoGridOptions = {
selection: {
mode: "single"
},
hoverStateEnabled: true,
showBorders: true,
columns: [ columns: [
{ {
caption: $translate.instant('RepUploadDtlColSerialNo'), caption: $translate.instant('RepUploadDtlColSerialNo'),
fixed: true, fixed: true,
...@@ -159,12 +167,16 @@ ...@@ -159,12 +167,16 @@
bindingOptions: { bindingOptions: {
dataSource: 'reportTwoDataSource' dataSource: 'reportTwoDataSource'
} }
}); };
$scope.reportThreeGridOptions = $.extend(true, {}, dxDataGridService.BASIC_GRID_OPTIONS, { $scope.reportThreeGridOptions = {
selection: {
mode: "single"
},
hoverStateEnabled: true,
showBorders: true,
columns: [ columns: [
{ {
caption: $translate.instant('RepUploadDtlColSerialNo'), caption: $translate.instant('RepUploadDtlColSerialNo'),
fixed: true, fixed: true,
...@@ -259,7 +271,7 @@ ...@@ -259,7 +271,7 @@
bindingOptions: { bindingOptions: {
dataSource: 'reportThreeDataSource' dataSource: 'reportThreeDataSource'
} }
}); };
var uploadFile = function (file, reportType) { var uploadFile = function (file, reportType) {
var month = vatSessionService.month < 10 ? ("0" + vatSessionService.month) : vatSessionService.month; var month = vatSessionService.month < 10 ? ("0" + vatSessionService.month) : vatSessionService.month;
......
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