Commit 17215322 authored by neo's avatar neo

[dev] fix approavel js and api param for dto

parent cda7ee83
......@@ -8,7 +8,7 @@ import lombok.Setter;
public class ApprovalDto {
private String projectId;
private Long reportId;
private Integer period;
private String periodDate;
private String instaceId;
private String status;//committed,agreed,disagreed
......@@ -17,7 +17,7 @@ public class ApprovalDto {
return "ApprovalDto{" +
"projectId='" + projectId + '\'' +
", reportId=" + reportId +
", period=" + period +
", period=" + periodDate +
", instaceId='" + instaceId + '\'' +
", status='" + status + '\'' +
'}';
......
webservices.factory('vatApproveService', ['$http', 'apiConfig', function ($http, apiConfig) {
'use strict';
return {
sample: function () {
return $http.get('url', apiConfig.createVat());
},
commitNewApproval: function (param) {
return $http.post('/approval/commit',{
projectId: param.projectId,
periodDate: param.periodDate
}, apiConfig.createVat());
},
queryOutputInvoiceItemList: function (invoiceID) {
return $http.get('/outputInvoiceImport/queryOutputInvoiceItemList/' + invoiceID, apiConfig.createVat());
},
getExportOutputInvoiceList: function (param) {
return $http.post('/outputInvoiceImport/getExportOutputInvoiceList', {
PageInfo: param.pageInfo,
PeriodStart: param.periodStart,
PeriodEnd: param.periodEnd,
InvoiceType: param.invoiceType,
StartInvoiceDate: param.invoiceDateStart,
EndInvoiceDate: param.invoiceDateEnd,
ClassCode: param.classCode,
InvoiceNumber: param.invoiceNumber,
BuyerName: param.buyerName,
ProductName: param.productName,
AmountStart: param.amountStart,
AmountEnd: param.amountEnd,
TaxAmountStart: param.taxAmountStart,
TaxAmountEnd: param.taxAmountEnd,
}, apiConfig.createVat({ responseType: 'arraybuffer' }));
},
queryInputInvoiceList: function (param) {
return $http.post('/inputInvoiceImport/inputInvoicePreviewList', {
PageInfo: param.pageInfo,
PeriodStart: param.periodStart,
PeriodEnd: param.periodEnd,
CertificationDateStart: param.certificationDateStart,
CertificationDateEnd: param.certificationDateEnd,
InvoiceCode: param.invoiceCode,
InvoiceNumber: param.invoiceNumber,
SellerTaxNumber: param.sellerTaxNumber,
AmountStart: param.amountStart,
AmountEnd: param.amountEnd,
InvoiceType: param.invoiceType,
TaxAmountStart: param.taxAmountStart,
TaxAmountEnd: param.taxAmountEnd,
CertificationStatus: param.certificationStatus
}, apiConfig.createVat());
},
queryInputInvoiceItemList: function (inputInvoiceID) {
return $http.get('/inputInvoiceImport/inputInvoiceItemPreviewList/' + inputInvoiceID, apiConfig.createVat());
},
//导出进项发票数据
getExportInputInvoiceList: function (param) {
return $http.post('/inputInvoiceImport/exportQueryData/get', {
PageInfo: param.pageInfo,
PeriodStart: param.periodStart,
PeriodEnd: param.periodEnd,
CertificationDateStart: param.certificationDateStart,
CertificationDateEnd: param.certificationDateEnd,
InvoiceCode: param.invoiceCode,
InvoiceNumber: param.invoiceNumber,
SellerTaxNumber: param.sellerTaxNumber,
AmountStart: param.amountStart,
AmountEnd: param.amountEnd,
InvoiceType: param.invoiceType,
TaxAmountStart: param.taxAmountStart,
TaxAmountEnd: param.taxAmountEnd,
CertificationStatus: param.certificationStatus
}, apiConfig.createVat({ responseType: 'arraybuffer' }));
},
voucherSelectAdvancedByEntry: function (mainRelation, allJe, pagingInfo, listQueryCondition) {
return $http.post('/voucher/voucherSelectAdvancedByEntry', {
MainRelation: mainRelation,
AllJe: allJe,
PagingInfo: pagingInfo,
ListQueryCondition: listQueryCondition
}, apiConfig.create());
},
voucherSelectAdvancedByVoucher: function (mainRelation, allJe, pagingInfo, listQueryCondition) {
return $http.post('/voucher/voucherSelectAdvancedByVoucher', {
MainRelation: mainRelation,
AllJe: allJe,
PagingInfo: pagingInfo,
ListQueryCondition: listQueryCondition
}, apiConfig.create());
},
voucherSelectAdvancedCount: function (mainRelation, isEntryShow, allJe, listQueryCondition) {
return $http.post('/voucher/voucherSelectAdvancedCount', {
MainRelation: mainRelation,
AllJe: allJe,
IsEntryShow: isEntryShow,
ListQueryCondition: listQueryCondition
}, apiConfig.create());
},
getVoucherByConditon: function (mainRelation, allJe, period, vID, group, listQueryCondition) {
return $http.post('/voucher/getVoucherByConditon', {
MainRelation: mainRelation,
AllJe: allJe,
Period: period,
VID: vID,
Group: group,
ListQueryCondition: listQueryCondition
}, apiConfig.create());
},
getSelectWhereString: function (mainRelation, allJe, listQueryCondition) {
return $http.post('/voucher/getSelectWhereString', {
MainRelation: mainRelation,
AllJe: allJe,
ListQueryCondition: listQueryCondition
}, apiConfig.create());
},
getEnterpriseAccount: function () {
return $http.get('/voucher/getEnterpriseAccount', apiConfig.create());
}
};
}]);
\ No newline at end of file
vatModule.controller('VatLayoutController', ['$scope', '$rootScope', '$q', '$log', '$timeout', '$state', '$translate', 'projectService', 'SweetAlert', 'loginContext'
, 'vatSessionService', 'vatCommonService', 'vatWorkflowService', 'application', 'enums', '$uibModal',
, 'vatSessionService', 'vatCommonService', 'vatWorkflowService', 'application', 'enums', '$uibModal','vatApproveService',
function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectService, SweetAlert, loginContext
, vatSessionService, vatCommonService, vatWorkflowService, application, enums, $uibModal) {
, vatSessionService, vatCommonService, vatWorkflowService, application, enums, $uibModal, vatApproveService) {
'use strict';
$log.debug('VatLayoutController.ctor()...');
......@@ -430,9 +430,11 @@ function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectSer
}
}
$scope.approve = function approve(){
alert(vatSessionService.project.id);
alert(vatSessionService.project.period);
$scope.approve = function(){
var approveParam={};
approveParam.projectId = vatSessionService.project.id;
approveParam.periodDate = vatSessionService.project.periodDate;
vatApproveService.commitNewApproval(approveParam);
}
$scope.showProjectStatus = function () {
......
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