Commit 7daf47a4 authored by gary's avatar gary

1、发票资料、等

parent 87249bb6
......@@ -148,6 +148,33 @@ public class DateUtils {
return strtodate;
}
/**
* 将短时间格式字符串转换为时间 yyyy/MM/dd
*
* @param strDate
* @return
*/
public static Date strToDate2(String strDate) {
SimpleDateFormat formatter = new SimpleDateFormat("yyyy/MM/dd");
ParsePosition pos = new ParsePosition(0);
Date strtodate = formatter.parse(strDate, pos);
return strtodate;
}
/**
* 将yy/MM/dd字符串转换为时间 yyyy/MM/dd
*
* @param strDate
* @return
*/
public static Date strToDate3(String strDate) {
strDate = "20"+strDate;
SimpleDateFormat formatter = new SimpleDateFormat("yyyy/MM/dd");
ParsePosition pos = new ParsePosition(0);
Date strtodate = formatter.parse(strDate, pos);
return strtodate;
}
/**
* 得到现在时间
*
......
......@@ -5,7 +5,10 @@ public enum EnumImportType {
ProfitLoss(1),
BalanceSheet(2),
RedLetterInfoTable(3),
AdjustmentTable(4)
AdjustmentTable(4),
CashFlow(5),
CoupaPurchasingReport(6),
InvoiceData(7)
;
private Integer code;
......
......@@ -112,6 +112,38 @@ public class DataImportController extends BaseController {
}
}
@ResponseBody
@RequestMapping(value = "CFExcelFile", method = RequestMethod.POST)
public OperationResultDto importCFExcelFile(@RequestParam MultipartFile file,@RequestParam String periodDate,@RequestParam Integer importType) {
try {
if (null == file) {
return OperationResultDto.error(ErrorMessage.NoFile);
}
return dataImportService.importCFExcelFile(file, periodDate,importType);
} catch (ServiceException e) {
return OperationResultDto.error(e.getMessage());
} catch (Exception e) {
logger.error("importATExcelFile error.", e);
return OperationResultDto.error(ErrorMessage.SystemError);
}
}
@ResponseBody
@RequestMapping(value = "CPRExcelFile", method = RequestMethod.POST)
public OperationResultDto importCPRExcelFile(@RequestParam MultipartFile file,@RequestParam String periodDate,@RequestParam Integer importType) {
try {
if (null == file) {
return OperationResultDto.error(ErrorMessage.NoFile);
}
return dataImportService.importCPRExcelFile(file, periodDate,importType);
} catch (ServiceException e) {
return OperationResultDto.error(e.getMessage());
} catch (Exception e) {
logger.error("importATExcelFile error.", e);
return OperationResultDto.error(ErrorMessage.SystemError);
}
}
@ResponseBody
@RequestMapping(value = "displayImportLog", method = RequestMethod.GET)
public List<DataImportLogDto> displayImportLog(@RequestParam Integer type) {
......
......@@ -143,6 +143,7 @@ public class MenuServiceImpl {
menuIds.add("a9b1cd87-89ef-4dae-b798-b19e9bbe0821");
menuIds.add("a9b1cd87-89ef-4dae-b798-b19e9bbe0822");
menuIds.add("a9b1cd87-89ef-4dae-b798-b19e9bbe0823");
menuIds.add("a9b1cd87-89ef-4dae-b798-b19e9bbe0824");
menuIds.add("b8c74ee9-e5d7-467b-8565-e77efe6a499f");
// List<MenuDto> menus = getMenus(moduleId).stream().filter(x -> permissionNames.contains(x.getName())).collect(Collectors.toList());
return menuIds;
......
......@@ -41,12 +41,28 @@
<property name="rootInterface" value="pwc.taxtech.atms.MyVatMapper" />
</javaClientGenerator>
<table tableName="invoice_data" domainObjectName="InvoiceData">
<property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/>
<columnOverride column="count_type" javaType="java.lang.Integer" jdbcType="TINYINT"/>
</table>
<!--<table tableName="coupa_purchasing_report" domainObjectName="CoupaPurchasingReport">
<property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/>
</table>
<table tableName="cash_flow" domainObjectName="CashFlow">
<property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/>
</table>
<table tableName="red_letter_info_table" domainObjectName="RedLetterInfoTable">
<property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/>
</table>
<!--<table tableName="adjustment_table" domainObjectName="AdjustmentTable">
<table tableName="adjustment_table" domainObjectName="AdjustmentTable">
<property name="useActualColumnNames" value="false"/>
<property name="ignoreQualifiersAtRuntime" value="true"/>
</table>
......
package pwc.taxtech.atms.vat.dao;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyVatMapper;
import pwc.taxtech.atms.vat.dpo.CashFlowCondition;
import pwc.taxtech.atms.vat.dpo.ProfitLossStatementCondition;
import pwc.taxtech.atms.vat.entity.CashFlow;
import pwc.taxtech.atms.vat.entity.CashFlowExample;
import pwc.taxtech.atms.vat.entity.ProfitLossStatement;
@Mapper
public interface CashFlowMapper extends MyVatMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
long countByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int deleteByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int insert(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int insertSelective(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
List<CashFlow> selectByExampleWithRowbounds(CashFlowExample example, RowBounds rowBounds);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
List<CashFlow> selectByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
CashFlow selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") CashFlow record, @Param("example") CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByExample(@Param("record") CashFlow record, @Param("example") CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByPrimaryKey(CashFlow record);
List<CashFlow> selectByCondition(@Param("cfCondition") CashFlowCondition condition);
package pwc.taxtech.atms.vat.dao;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyVatMapper;
import pwc.taxtech.atms.vat.dpo.CashFlowCondition;
import pwc.taxtech.atms.vat.entity.CashFlow;
import pwc.taxtech.atms.vat.entity.CashFlowExample;
@Mapper
public interface CashFlowMapper extends MyVatMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
long countByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int deleteByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int insert(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int insertSelective(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
List<CashFlow> selectByExampleWithRowbounds(CashFlowExample example, RowBounds rowBounds);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
List<CashFlow> selectByExample(CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
CashFlow selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") CashFlow record, @Param("example") CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByExample(@Param("record") CashFlow record, @Param("example") CashFlowExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(CashFlow record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table cash_flow
*
* @mbg.generated
*/
int updateByPrimaryKey(CashFlow record);
List<CashFlow> selectByCondition(@Param("cfCondition") CashFlowCondition condition);
int insertBatch(List<CashFlow> cfs);
}
\ No newline at end of file
package pwc.taxtech.atms.vat.dao;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyVatMapper;
import pwc.taxtech.atms.vat.entity.CoupaPurchasingReport;
import pwc.taxtech.atms.vat.entity.CoupaPurchasingReportExample;
@Mapper
public interface CoupaPurchasingReportMapper extends MyVatMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
long countByExample(CoupaPurchasingReportExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int deleteByExample(CoupaPurchasingReportExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int insert(CoupaPurchasingReport record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int insertSelective(CoupaPurchasingReport record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
List<CoupaPurchasingReport> selectByExampleWithRowbounds(CoupaPurchasingReportExample example, RowBounds rowBounds);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
List<CoupaPurchasingReport> selectByExample(CoupaPurchasingReportExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
CoupaPurchasingReport selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") CoupaPurchasingReport record, @Param("example") CoupaPurchasingReportExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int updateByExample(@Param("record") CoupaPurchasingReport record, @Param("example") CoupaPurchasingReportExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(CoupaPurchasingReport record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table coupa_purchasing_report
*
* @mbg.generated
*/
int updateByPrimaryKey(CoupaPurchasingReport record);
int insertBatch(List<CoupaPurchasingReport> cprs);
}
\ No newline at end of file
package pwc.taxtech.atms.vat.dao;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.session.RowBounds;
import pwc.taxtech.atms.MyVatMapper;
import pwc.taxtech.atms.vat.entity.InvoiceData;
import pwc.taxtech.atms.vat.entity.InvoiceDataExample;
@Mapper
public interface InvoiceDataMapper extends MyVatMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
long countByExample(InvoiceDataExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int deleteByExample(InvoiceDataExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int insert(InvoiceData record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int insertSelective(InvoiceData record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
List<InvoiceData> selectByExampleWithRowbounds(InvoiceDataExample example, RowBounds rowBounds);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
List<InvoiceData> selectByExample(InvoiceDataExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
InvoiceData selectByPrimaryKey(Long id);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") InvoiceData record, @Param("example") InvoiceDataExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int updateByExample(@Param("record") InvoiceData record, @Param("example") InvoiceDataExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(InvoiceData record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table invoice_data
*
* @mbg.generated
*/
int updateByPrimaryKey(InvoiceData record);
}
\ No newline at end of file
......@@ -1181,7 +1181,7 @@ var dataImpModule = angular.module('app.dataImp', ['ui.grid', 'ui.router','ui.gr
});
$stateProvider.state({
name: 'directMethodCashFlowImportDistribution',
name: 'cashFlowImportDistribution',
url: "/importDistribution/cashFlow",
dsr: true,
views: {
......@@ -1191,7 +1191,7 @@ var dataImpModule = angular.module('app.dataImp', ['ui.grid', 'ui.router','ui.gr
$scope.state = $state;
appTranslation.load([appTranslation.appPart]);
}],
template: '<data-import-direct-method-cash-flow></data-import-direct-method-cash-flow>'
template: '<data-import-cash-flow></data-import-cash-flow>'
}
},
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.dataImp),
......@@ -1234,4 +1234,40 @@ var dataImpModule = angular.module('app.dataImp', ['ui.grid', 'ui.router','ui.gr
sticky: true
});
$stateProvider.state({
name: 'invoiceDataImportDistribution',
url: "/importDistribution/invoiceData",
dsr: true,
views: {
'importContent': {
controller: ['$scope', '$state','appTranslation',
function ($scope, $state, appTranslation) {
$scope.state = $state;
appTranslation.load([appTranslation.appPart]);
}],
template: '<data-import-invoice-data></data-import-invoice-data>'
}
},
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.dataImp),
sticky: true
});
$stateProvider.state({
name: 'citJournalAdjustImportDistribution',
url: "/importDistribution/citJournalAdjust",
dsr: true,
views: {
'importContent': {
controller: ['$scope', '$state','appTranslation',
function ($scope, $state, appTranslation) {
$scope.state = $state;
appTranslation.load([appTranslation.appPart]);
}],
template: '<data-import-cit-journal-adjust></data-import-cit-journal-adjust>'
}
},
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.dataImp),
sticky: true
});
}]);
\ No newline at end of file
......@@ -1821,5 +1821,12 @@
"AddImportBalanceSheet": "Expand import BS",
"TMSPeriod": "TMS Period",
"cashFlow":"Cash Flow",
"CashFlowDDTitle":"Cash Flow",
"InvoiceData": "Invoice Data",
"InvoiceDataTitle": "Invoice Data",
"~MustBeEndOneApp": "I Must be the End One, please!"
}
\ No newline at end of file
......@@ -2067,5 +2067,9 @@
"TMSPeriod": "税务系统期间",
"InvoiceData": "发票资料",
"InvoiceDataTitle": "发票资料",
"~MustBeEndOneApp": "我必须是最后一个!"
}
\ No newline at end of file
commonModule.directive('importCashFlow', ['$log',
function ($log) {
'use strict';
return {
restrict: 'E',
templateUrl: '/app/common/controls/import/import-cash-flow/import-cash-flow.html' + '?_=' + Math.random(),
scope: {
serviceTypeId: "=?",
periodId: "=?",
fileType: "=?"
},
controller: 'importCFController',
link: function (scope, element) {
$('.main-contents')[0].style.width = "260px";
$('.main-contents')[0].style.float = "left";
$('.main-contents')[0].style.styleFloat = "left";
$('.main-contents')[0].style.cssFloat = "left";
}
};
}
]);
\ No newline at end of file
<div class="import-direct-method-cash-flow">
<div class="import-cit-journal-adjust">
<!--标题-->
<div class="nav-wrapper">
<div class="nav-header" translate="DirectMethodCashFlowStatementTitle"></div>
<div class="nav-header" translate="InvoiceDataTitle"></div>
<div class="alert alert-warning" style="width:400px;margin-bottom:5px;" ng-show="ImportErrorTab" ng-click="toggleErrorTab()">
<i class="fa fa-exclamation-circle" aria-hidden="true"></i>{{errorMsg}}
</div>
......
commonModule.directive('importCitJournalAdjust', ['$log',
function ($log) {
'use strict';
$log.debug('importCitJournalAdjust.ctor()...');
return {
restrict: 'E',
templateUrl: '/app/common/controls/import/import-cit-journal-adjust/import-cit-journal-adjust.html' + '?_=' + Math.random(),
scope: {
serviceTypeId: "=?",
periodId: "=?"
},
controller: 'importCitJournalAdjustController',
link: function (scope, element) {
$('.main-contents')[0].style.width = "260px";
$('.main-contents')[0].style.float = "left";
$('.main-contents')[0].style.styleFloat = "left";
$('.main-contents')[0].style.cssFloat = "left";
}
};
}
]);
\ No newline at end of file
@import "~/app-resources/less/theme.less";
.import-direct-method-cash-flow {
.import-cit-journal-adjust {
/*background-color: @color-white;*/
padding-left: 20px;
/*min-height: 800px;*/
......
commonModule.directive('importCoupaPurchasingReport', ['$log',
function ($log) {
'use strict';
'use strict';
return {
restrict: 'E',
templateUrl: '/app/common/controls/import/import-coupa-purchasing-report/import-coupa-purchasing-report.html' + '?_=' + Math.random(),
......@@ -16,6 +16,6 @@
$('.main-contents')[0].style.cssFloat = "left";
}
};
}
]);
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment