Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-platform-finance
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
base_platform_enterprise
gic-platform-finance
Commits
63d59c19
Commit
63d59c19
authored
Jul 02, 2020
by
陶光胜
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' into 'master'
Developer See merge request
!6
parents
9e31853f
63133826
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
237 additions
and
19 deletions
+237
-19
InvoiceStatusEnum.java
...main/java/com/gic/finance/constant/InvoiceStatusEnum.java
+3
-1
InvoiceTypeEnum.java
...c/main/java/com/gic/finance/constant/InvoiceTypeEnum.java
+1
-1
InvoiceManageDTO.java
...i/src/main/java/com/gic/finance/dto/InvoiceManageDTO.java
+30
-4
InvoiceCallbackDTO.java
...java/com/gic/finance/dto/callback/InvoiceCallbackDTO.java
+28
-0
InvoiceManageApiService.java
...java/com/gic/finance/service/InvoiceManageApiService.java
+10
-1
TabInvoiceManage.java
...rc/main/java/com/gic/finance/entity/TabInvoiceManage.java
+30
-1
InvoiceManageApiServiceImpl.java
...nance/service/outer/impl/InvoiceManageApiServiceImpl.java
+42
-5
TabInvoiceManageMapper.xml
...vice/src/main/resources/mapper/TabInvoiceManageMapper.xml
+27
-4
InvoiceManageController.java
...m/gic/finance/web/controller/InvoiceManageController.java
+19
-1
InvoiceManageListVO.java
...main/java/com/gic/finance/web/vo/InvoiceManageListVO.java
+14
-0
InvoiceManagerDetailVO.java
...n/java/com/gic/finance/web/vo/InvoiceManagerDetailVO.java
+33
-1
No files found.
gic-platform-finance-api/src/main/java/com/gic/finance/constant/InvoiceStatusEnum.java
View file @
63d59c19
...
@@ -11,7 +11,9 @@ public enum InvoiceStatusEnum {
...
@@ -11,7 +11,9 @@ public enum InvoiceStatusEnum {
TO_BE_MAILED
(
2
,
"待邮寄"
),
TO_BE_MAILED
(
2
,
"待邮寄"
),
MAILED
(
3
,
"已邮寄"
),
MAILED
(
3
,
"已邮寄"
),
REJECT
(
4
,
"已驳回"
),
REJECT
(
4
,
"已驳回"
),
CANCEL
(
5
,
"已取消"
);
CANCEL
(
5
,
"已取消"
),
TO_BE_SEND
(
6
,
"待发送"
),
SEND
(
7
,
"已发送"
);
private
int
code
;
private
int
code
;
private
String
message
;
private
String
message
;
...
...
gic-platform-finance-api/src/main/java/com/gic/finance/constant/InvoiceTypeEnum.java
View file @
63d59c19
...
@@ -7,7 +7,7 @@ package com.gic.finance.constant;
...
@@ -7,7 +7,7 @@ package com.gic.finance.constant;
* @date 2019/8/14 2:35 PM
* @date 2019/8/14 2:35 PM
*/
*/
public
enum
InvoiceTypeEnum
{
public
enum
InvoiceTypeEnum
{
NORMAL
(
1
,
"
纸质
普通发票"
),
NORMAL
(
1
,
"
电子
普通发票"
),
VAT_INVOICE
(
2
,
"纸质增值税专用发票"
);
VAT_INVOICE
(
2
,
"纸质增值税专用发票"
);
private
int
code
;
private
int
code
;
...
...
gic-platform-finance-api/src/main/java/com/gic/finance/dto/InvoiceManageDTO.java
View file @
63d59c19
...
@@ -43,7 +43,7 @@ public class InvoiceManageDTO implements Serializable {
...
@@ -43,7 +43,7 @@ public class InvoiceManageDTO implements Serializable {
private
Integer
platformType
;
private
Integer
platformType
;
/**
/**
* (发票类型)1:
纸质
普通发票 2: 纸质增值税专用发票
* (发票类型)1:
电子
普通发票 2: 纸质增值税专用发票
*/
*/
@NotNull
(
message
=
"发票类型不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
@NotNull
(
message
=
"发票类型不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
@Size
(
message
=
"发票类型值不规范"
,
min
=
1
,
max
=
2
)
@Size
(
message
=
"发票类型值不规范"
,
min
=
1
,
max
=
2
)
...
@@ -145,19 +145,16 @@ public class InvoiceManageDTO implements Serializable {
...
@@ -145,19 +145,16 @@ public class InvoiceManageDTO implements Serializable {
/**
/**
* 收货人
* 收货人
*/
*/
@NotBlank
(
message
=
"收货人不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
private
String
shippingName
;
private
String
shippingName
;
/**
/**
* 收货电话
* 收货电话
*/
*/
@NotBlank
(
message
=
"收货电话不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
private
String
shippingPhone
;
private
String
shippingPhone
;
/**
/**
* 收货地址
* 收货地址
*/
*/
@NotBlank
(
message
=
"收货地址不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
private
String
shippingAddress
;
private
String
shippingAddress
;
/**
/**
...
@@ -195,6 +192,17 @@ public class InvoiceManageDTO implements Serializable {
...
@@ -195,6 +192,17 @@ public class InvoiceManageDTO implements Serializable {
*/
*/
private
Integer
initiateType
;
private
Integer
initiateType
;
/**
* 电子发票类型,接收人邮箱
*/
private
String
email
;
/**
* 营业执照 图片地址
*/
@NotBlank
(
message
=
"营业执照不能为空"
,
groups
=
{
ApplyInvoiceValid
.
class
})
private
String
businessLicense
;
public
Integer
getInvoiceManageId
()
{
public
Integer
getInvoiceManageId
()
{
return
invoiceManageId
;
return
invoiceManageId
;
}
}
...
@@ -450,4 +458,22 @@ public class InvoiceManageDTO implements Serializable {
...
@@ -450,4 +458,22 @@ public class InvoiceManageDTO implements Serializable {
public
void
setInitiateType
(
Integer
initiateType
)
{
public
void
setInitiateType
(
Integer
initiateType
)
{
this
.
initiateType
=
initiateType
;
this
.
initiateType
=
initiateType
;
}
}
public
String
getEmail
()
{
return
email
;
}
public
InvoiceManageDTO
setEmail
(
String
email
)
{
this
.
email
=
email
;
return
this
;
}
public
String
getBusinessLicense
()
{
return
businessLicense
;
}
public
InvoiceManageDTO
setBusinessLicense
(
String
businessLicense
)
{
this
.
businessLicense
=
businessLicense
;
return
this
;
}
}
}
gic-platform-finance-api/src/main/java/com/gic/finance/dto/callback/InvoiceCallbackDTO.java
View file @
63d59c19
...
@@ -93,6 +93,16 @@ public class InvoiceCallbackDTO implements Serializable{
...
@@ -93,6 +93,16 @@ public class InvoiceCallbackDTO implements Serializable{
*/
*/
private
String
initiator
;
private
String
initiator
;
/**
* 电子发票类型,接收人邮箱
*/
private
String
email
;
/**
* 营业执照 图片地址
*/
private
String
businessLicense
;
public
String
getInvoiceApplySerial
()
{
public
String
getInvoiceApplySerial
()
{
return
invoiceApplySerial
;
return
invoiceApplySerial
;
}
}
...
@@ -220,4 +230,22 @@ public class InvoiceCallbackDTO implements Serializable{
...
@@ -220,4 +230,22 @@ public class InvoiceCallbackDTO implements Serializable{
public
void
setInitiator
(
String
initiator
)
{
public
void
setInitiator
(
String
initiator
)
{
this
.
initiator
=
initiator
;
this
.
initiator
=
initiator
;
}
}
public
String
getEmail
()
{
return
email
;
}
public
InvoiceCallbackDTO
setEmail
(
String
email
)
{
this
.
email
=
email
;
return
this
;
}
public
String
getBusinessLicense
()
{
return
businessLicense
;
}
public
InvoiceCallbackDTO
setBusinessLicense
(
String
businessLicense
)
{
this
.
businessLicense
=
businessLicense
;
return
this
;
}
}
}
gic-platform-finance-api/src/main/java/com/gic/finance/service/InvoiceManageApiService.java
View file @
63d59c19
...
@@ -38,7 +38,7 @@ public interface InvoiceManageApiService {
...
@@ -38,7 +38,7 @@ public interface InvoiceManageApiService {
ServiceResponse
<
String
>
applyInvoiceForApp
(
InvoiceManageDTO
invoiceManageDTO
);
ServiceResponse
<
String
>
applyInvoiceForApp
(
InvoiceManageDTO
invoiceManageDTO
);
/**
/**
* 开票。待邮寄/邮寄
* 开票。待邮寄/邮寄
(纸质)
* @Title: invoice
* @Title: invoice
* @Description:
* @Description:
* @author guojuxing
* @author guojuxing
...
@@ -50,6 +50,15 @@ public interface InvoiceManageApiService {
...
@@ -50,6 +50,15 @@ public interface InvoiceManageApiService {
ServiceResponse
<
Void
>
invoice
(
Integer
invoiceManageId
,
String
expressMailName
,
String
expressMailNumber
,
OperationUserInfoDTO
dto
);
ServiceResponse
<
Void
>
invoice
(
Integer
invoiceManageId
,
String
expressMailName
,
String
expressMailNumber
,
OperationUserInfoDTO
dto
);
/**
/**
* 发送发票(电子发票)
* @param invoiceManageId
* @param sendStatus InvoiceStatusEnum枚举
* @param dto
* @return
*/
ServiceResponse
<
Void
>
invoiceOfElectronic
(
Integer
invoiceManageId
,
Integer
sendStatus
,
OperationUserInfoDTO
dto
);
/**
* 驳回
* 驳回
* @Title: rejectInvoice
* @Title: rejectInvoice
* @Description:
* @Description:
...
...
gic-platform-finance-service/src/main/java/com/gic/finance/entity/TabInvoiceManage.java
View file @
63d59c19
...
@@ -22,7 +22,7 @@ public class TabInvoiceManage {
...
@@ -22,7 +22,7 @@ public class TabInvoiceManage {
private
Integer
platformType
;
private
Integer
platformType
;
/**
/**
* (发票类型)1:
纸质
普通发票 2: 纸质增值税专用发票
* (发票类型)1:
电子
普通发票 2: 纸质增值税专用发票
*/
*/
private
Integer
invoiceType
;
private
Integer
invoiceType
;
...
@@ -166,6 +166,16 @@ public class TabInvoiceManage {
...
@@ -166,6 +166,16 @@ public class TabInvoiceManage {
*/
*/
private
Integer
initiateType
;
private
Integer
initiateType
;
/**
* 电子发票类型,接收人邮箱
*/
private
String
email
;
/**
* 营业执照 图片地址
*/
private
String
businessLicense
;
public
Integer
getInvoiceManageId
()
{
public
Integer
getInvoiceManageId
()
{
return
invoiceManageId
;
return
invoiceManageId
;
}
}
...
@@ -421,4 +431,22 @@ public class TabInvoiceManage {
...
@@ -421,4 +431,22 @@ public class TabInvoiceManage {
public
void
setInitiateType
(
Integer
initiateType
)
{
public
void
setInitiateType
(
Integer
initiateType
)
{
this
.
initiateType
=
initiateType
;
this
.
initiateType
=
initiateType
;
}
}
public
String
getEmail
()
{
return
email
;
}
public
TabInvoiceManage
setEmail
(
String
email
)
{
this
.
email
=
email
;
return
this
;
}
public
String
getBusinessLicense
()
{
return
businessLicense
;
}
public
TabInvoiceManage
setBusinessLicense
(
String
businessLicense
)
{
this
.
businessLicense
=
businessLicense
;
return
this
;
}
}
}
\ No newline at end of file
gic-platform-finance-service/src/main/java/com/gic/finance/service/outer/impl/InvoiceManageApiServiceImpl.java
View file @
63d59c19
...
@@ -4,6 +4,7 @@ import java.util.Date;
...
@@ -4,6 +4,7 @@ import java.util.Date;
import
com.gic.auth.dto.UserDTO
;
import
com.gic.auth.dto.UserDTO
;
import
com.gic.auth.service.UserApiService
;
import
com.gic.auth.service.UserApiService
;
import
com.gic.finance.constant.InvoiceTypeEnum
;
import
com.gic.marketing.process.api.service.sms.SmsSendApiService
;
import
com.gic.marketing.process.api.service.sms.SmsSendApiService
;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.LogManager
;
...
@@ -57,6 +58,15 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
...
@@ -57,6 +58,15 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
invoiceManageDTO
.
setUpdateTime
(
new
Date
());
invoiceManageDTO
.
setUpdateTime
(
new
Date
());
invoiceManageDTO
.
setInvoiceStatus
(
InvoiceStatusEnum
.
TO_BE_ISSUED
.
getCode
());
invoiceManageDTO
.
setInvoiceStatus
(
InvoiceStatusEnum
.
TO_BE_ISSUED
.
getCode
());
invoiceManageDTO
.
setInvoiceApplySerial
(
CreateRandomUtils
.
createSerialNumber
());
invoiceManageDTO
.
setInvoiceApplySerial
(
CreateRandomUtils
.
createSerialNumber
());
//电子发票
boolean
isElectronicInvoice
=
invoiceManageDTO
.
getInvoiceType
().
intValue
()
==
InvoiceTypeEnum
.
NORMAL
.
getCode
();
if
(
isElectronicInvoice
)
{
if
(
StringUtils
.
isBlank
(
invoiceManageDTO
.
getEmail
()))
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"接收人邮箱不能为空"
);
}
}
if
(
StringUtils
.
isBlank
(
invoiceManageDTO
.
getEnterpriseName
()))
{
if
(
StringUtils
.
isBlank
(
invoiceManageDTO
.
getEnterpriseName
()))
{
invoiceManageDTO
.
setEnterpriseName
(
"暂无商户名称"
);
invoiceManageDTO
.
setEnterpriseName
(
"暂无商户名称"
);
}
}
...
@@ -96,6 +106,7 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
...
@@ -96,6 +106,7 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
}
}
InvoiceManageDTO
invoiceManageDTO
=
new
InvoiceManageDTO
();
InvoiceManageDTO
invoiceManageDTO
=
new
InvoiceManageDTO
();
invoiceManageDTO
.
setInvoiceManageId
(
invoiceManageId
);
invoiceManageDTO
.
setInvoiceManageId
(
invoiceManageId
);
if
(
StringUtils
.
isBlank
(
expressMailName
)
||
StringUtils
.
isBlank
(
expressMailNumber
))
{
if
(
StringUtils
.
isBlank
(
expressMailName
)
||
StringUtils
.
isBlank
(
expressMailNumber
))
{
//待邮寄
//待邮寄
invoiceManageDTO
.
setInvoiceStatus
(
InvoiceStatusEnum
.
TO_BE_MAILED
.
getCode
());
invoiceManageDTO
.
setInvoiceStatus
(
InvoiceStatusEnum
.
TO_BE_MAILED
.
getCode
());
...
@@ -113,11 +124,11 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
...
@@ -113,11 +124,11 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
getOperationUserInfo
(
invoiceManageDTO
,
dto
);
getOperationUserInfo
(
invoiceManageDTO
,
dto
);
//开票户信息插入
//开票户信息插入
TabInvoiceAccount
account
=
invoiceAccountService
.
getEnable
();
//
TabInvoiceAccount account = invoiceAccountService.getEnable();
if
(
account
==
null
)
{
//
if (account == null) {
return
ServiceResponse
.
failure
(
ErrorCode
.
SYSTEM_ERROR
.
getCode
(),
"没有启用的开票户信息,请启用"
);
//
return ServiceResponse.failure(ErrorCode.SYSTEM_ERROR.getCode(), "没有启用的开票户信息,请启用");
}
//
}
invoiceManageDTO
.
setInvoicerId
(
account
.
getInvoiceAccountId
());
//
invoiceManageDTO.setInvoicerId(account.getInvoiceAccountId());
invoiceManageService
.
update
(
invoiceManageDTO
);
invoiceManageService
.
update
(
invoiceManageDTO
);
//回调
//回调
...
@@ -132,6 +143,32 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
...
@@ -132,6 +143,32 @@ public class InvoiceManageApiServiceImpl implements InvoiceManageApiService {
}
}
@Override
@Override
public
ServiceResponse
<
Void
>
invoiceOfElectronic
(
Integer
invoiceManageId
,
Integer
sendStatus
,
OperationUserInfoDTO
dto
)
{
TabInvoiceManage
tabInvoiceManage
=
invoiceManageService
.
getById
(
invoiceManageId
);
if
(
tabInvoiceManage
==
null
)
{
return
ServiceResponse
.
failure
(
ErrorCode
.
PARAMETER_ERROR
.
getCode
(),
"发票管理主键有误"
);
}
InvoiceManageDTO
invoiceManageDTO
=
new
InvoiceManageDTO
();
invoiceManageDTO
.
setInvoiceManageId
(
invoiceManageId
);
invoiceManageDTO
.
setInvoiceStatus
(
sendStatus
);
tabInvoiceManage
.
setInvoiceStatus
(
sendStatus
);
getOperationUserInfo
(
invoiceManageDTO
,
dto
);
invoiceManageService
.
update
(
invoiceManageDTO
);
//回调
if
(
tabInvoiceManage
.
getInitiateType
().
intValue
()
==
InvoiceInitiateTypeConstants
.
APP
)
{
InvoiceCallbackDTO
callbackDTO
=
EntityUtil
.
changeEntityNew
(
InvoiceCallbackDTO
.
class
,
tabInvoiceManage
);
AsyncCallbackUtils
.
callBack
(
callbackDTO
,
"com.gic.open.api.service.market.InvoiceCallbackApiService"
,
"invoiceCallback"
);
}
return
ServiceResponse
.
success
();
}
@Override
public
ServiceResponse
<
Void
>
rejectInvoice
(
Integer
invoiceManageId
,
String
rejectReason
,
OperationUserInfoDTO
dto
)
{
public
ServiceResponse
<
Void
>
rejectInvoice
(
Integer
invoiceManageId
,
String
rejectReason
,
OperationUserInfoDTO
dto
)
{
TabInvoiceManage
tabInvoiceManage
=
invoiceManageService
.
getById
(
invoiceManageId
);
TabInvoiceManage
tabInvoiceManage
=
invoiceManageService
.
getById
(
invoiceManageId
);
if
(
tabInvoiceManage
==
null
)
{
if
(
tabInvoiceManage
==
null
)
{
...
...
gic-platform-finance-service/src/main/resources/mapper/TabInvoiceManageMapper.xml
View file @
63d59c19
...
@@ -34,6 +34,8 @@
...
@@ -34,6 +34,8 @@
<result
column=
"update_time"
jdbcType=
"TIMESTAMP"
property=
"updateTime"
/>
<result
column=
"update_time"
jdbcType=
"TIMESTAMP"
property=
"updateTime"
/>
<result
column=
"initiator"
jdbcType=
"VARCHAR"
property=
"initiator"
/>
<result
column=
"initiator"
jdbcType=
"VARCHAR"
property=
"initiator"
/>
<result
column=
"initiate_type"
jdbcType=
"INTEGER"
property=
"initiateType"
/>
<result
column=
"initiate_type"
jdbcType=
"INTEGER"
property=
"initiateType"
/>
<result
column=
"email"
jdbcType=
"VARCHAR"
property=
"email"
/>
<result
column=
"business_license"
jdbcType=
"VARCHAR"
property=
"businessLicense"
/>
</resultMap>
</resultMap>
<sql
id=
"Base_Column_List"
>
<sql
id=
"Base_Column_List"
>
invoice_manage_id, invoice_apply_serial, platform_type, invoice_type, billing_amount,
invoice_manage_id, invoice_apply_serial, platform_type, invoice_type, billing_amount,
...
@@ -41,7 +43,7 @@
...
@@ -41,7 +43,7 @@
operator_phone_area_code, enterprise_id, enterprise_name, company_name, logo, account_name,
operator_phone_area_code, enterprise_id, enterprise_name, company_name, logo, account_name,
tax_number, address, bank, account_phone, bank_account, shipping_name, shipping_phone,
tax_number, address, bank, account_phone, bank_account, shipping_name, shipping_phone,
shipping_address, invoicer_id, express_mail_name, express_mail_number, create_time,
shipping_address, invoicer_id, express_mail_name, express_mail_number, create_time,
update_time, initiator, initiate_type
update_time, initiator, initiate_type
, email, business_license
</sql>
</sql>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Integer"
resultMap=
"BaseResultMap"
>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.Integer"
resultMap=
"BaseResultMap"
>
select
select
...
@@ -64,7 +66,7 @@
...
@@ -64,7 +66,7 @@
account_phone, bank_account, shipping_name,
account_phone, bank_account, shipping_name,
shipping_phone, shipping_address, invoicer_id,
shipping_phone, shipping_address, invoicer_id,
express_mail_name, express_mail_number, create_time,
express_mail_name, express_mail_number, create_time,
update_time, initiator, initiate_type
update_time, initiator, initiate_type
, email, business_license
)
)
values (#{invoiceManageId,jdbcType=INTEGER}, #{invoiceApplySerial,jdbcType=VARCHAR},
values (#{invoiceManageId,jdbcType=INTEGER}, #{invoiceApplySerial,jdbcType=VARCHAR},
#{platformType,jdbcType=INTEGER}, #{invoiceType,jdbcType=INTEGER}, #{billingAmount,jdbcType=DOUBLE},
#{platformType,jdbcType=INTEGER}, #{invoiceType,jdbcType=INTEGER}, #{billingAmount,jdbcType=DOUBLE},
...
@@ -76,7 +78,8 @@
...
@@ -76,7 +78,8 @@
#{accountPhone,jdbcType=VARCHAR}, #{bankAccount,jdbcType=VARCHAR}, #{shippingName,jdbcType=VARCHAR},
#{accountPhone,jdbcType=VARCHAR}, #{bankAccount,jdbcType=VARCHAR}, #{shippingName,jdbcType=VARCHAR},
#{shippingPhone,jdbcType=VARCHAR}, #{shippingAddress,jdbcType=VARCHAR}, #{invoicerId,jdbcType=INTEGER},
#{shippingPhone,jdbcType=VARCHAR}, #{shippingAddress,jdbcType=VARCHAR}, #{invoicerId,jdbcType=INTEGER},
#{expressMailName,jdbcType=VARCHAR}, #{expressMailNumber,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{expressMailName,jdbcType=VARCHAR}, #{expressMailNumber,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP}, #{initiator,jdbcType=VARCHAR}, #{initiateType,jdbcType=INTEGER}
#{updateTime,jdbcType=TIMESTAMP}, #{initiator,jdbcType=VARCHAR}, #{initiateType,jdbcType=INTEGER},
#{email,jdbcType=VARCHAR}, #{businessLicense,jdbcType=VARCHAR}
)
)
</insert>
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.gic.finance.entity.TabInvoiceManage"
>
<insert
id=
"insertSelective"
parameterType=
"com.gic.finance.entity.TabInvoiceManage"
>
...
@@ -178,6 +181,12 @@
...
@@ -178,6 +181,12 @@
<if
test=
"initiateType != null"
>
<if
test=
"initiateType != null"
>
initiate_type,
initiate_type,
</if>
</if>
<if
test=
"email != null"
>
email,
</if>
<if
test=
"businessLicense != null"
>
business_license,
</if>
</trim>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"invoiceManageId != null"
>
<if
test=
"invoiceManageId != null"
>
...
@@ -276,6 +285,12 @@
...
@@ -276,6 +285,12 @@
<if
test=
"initiateType != null"
>
<if
test=
"initiateType != null"
>
#{initiateType,jdbcType=INTEGER},
#{initiateType,jdbcType=INTEGER},
</if>
</if>
<if
test=
"email != null"
>
#{email,jdbcType=VARCHAR},
</if>
<if
test=
"businessLicense != null"
>
#{businessLicense,jdbcType=VARCHAR},
</if>
</trim>
</trim>
</insert>
</insert>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.gic.finance.entity.TabInvoiceManage"
>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"com.gic.finance.entity.TabInvoiceManage"
>
...
@@ -374,6 +389,12 @@
...
@@ -374,6 +389,12 @@
<if
test=
"initiateType != null"
>
<if
test=
"initiateType != null"
>
initiate_type = #{initiateType,jdbcType=INTEGER},
initiate_type = #{initiateType,jdbcType=INTEGER},
</if>
</if>
<if
test=
"email != null"
>
email = #{email,jdbcType=VARCHAR},
</if>
<if
test=
"businessLicense != null"
>
business_license = #{businessLicense,jdbcType=VARCHAR},
</if>
</set>
</set>
where invoice_manage_id = #{invoiceManageId,jdbcType=INTEGER}
where invoice_manage_id = #{invoiceManageId,jdbcType=INTEGER}
</update>
</update>
...
@@ -409,7 +430,9 @@
...
@@ -409,7 +430,9 @@
create_time = #{createTime,jdbcType=TIMESTAMP},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
initiator = #{initiator,jdbcType=VARCHAR},
initiator = #{initiator,jdbcType=VARCHAR},
initiate_type = #{initiateType,jdbcType=INTEGER}
initiate_type = #{initiateType,jdbcType=INTEGER},
email = #{email,jdbcType=VARCHAR},
business_license = #{businessLicense,jdbcType=VARCHAR}
where invoice_manage_id = #{invoiceManageId,jdbcType=INTEGER}
where invoice_manage_id = #{invoiceManageId,jdbcType=INTEGER}
</update>
</update>
...
...
gic-platform-finance-web/src/main/java/com/gic/finance/web/controller/InvoiceManageController.java
View file @
63d59c19
...
@@ -3,6 +3,8 @@ package com.gic.finance.web.controller;
...
@@ -3,6 +3,8 @@ package com.gic.finance.web.controller;
import
com.gic.api.base.commons.ServiceResponse
;
import
com.gic.api.base.commons.ServiceResponse
;
import
com.gic.commons.util.EntityUtil
;
import
com.gic.commons.util.EntityUtil
;
import
com.gic.enterprise.response.EnterpriseRestResponse
;
import
com.gic.enterprise.response.EnterpriseRestResponse
;
import
com.gic.finance.constant.InvoiceStatusEnum
;
import
com.gic.finance.constant.InvoiceTypeEnum
;
import
com.gic.finance.dto.InvoiceAccountDTO
;
import
com.gic.finance.dto.InvoiceAccountDTO
;
import
com.gic.finance.service.InvoiceAccountApiService
;
import
com.gic.finance.service.InvoiceAccountApiService
;
import
com.gic.finance.web.utils.UserInfoUtils
;
import
com.gic.finance.web.utils.UserInfoUtils
;
...
@@ -47,7 +49,7 @@ public class InvoiceManageController {
...
@@ -47,7 +49,7 @@ public class InvoiceManageController {
}
}
/**
/**
* 同意审批
* 同意审批
(纸质)
* @param dto
* @param dto
* @return
* @return
*/
*/
...
@@ -58,6 +60,22 @@ public class InvoiceManageController {
...
@@ -58,6 +60,22 @@ public class InvoiceManageController {
}
}
/**
/**
* 审批(电子发票)
* @param dto
* @param isSend true:已发送
* @return
*/
@RequestMapping
(
"/invoice-of-electronic"
)
public
RestResponse
invoiceOfElectronic
(
InvoiceManageDTO
dto
,
boolean
isSend
)
{
Integer
sendStatus
=
InvoiceStatusEnum
.
TO_BE_SEND
.
getCode
();
if
(
isSend
)
{
sendStatus
=
InvoiceStatusEnum
.
SEND
.
getCode
();
}
return
ResultControllerUtils
.
commonResult
(
invoiceManageApiService
.
invoiceOfElectronic
(
dto
.
getInvoiceManageId
(),
sendStatus
,
UserInfoUtils
.
getOpertaionUserInfo
()));
}
/**
* 驳回审批
* 驳回审批
* @param dto
* @param dto
* @return
* @return
...
...
gic-platform-finance-web/src/main/java/com/gic/finance/web/vo/InvoiceManageListVO.java
View file @
63d59c19
...
@@ -78,6 +78,11 @@ public class InvoiceManageListVO implements Serializable{
...
@@ -78,6 +78,11 @@ public class InvoiceManageListVO implements Serializable{
*/
*/
private
String
expressMailNumber
;
private
String
expressMailNumber
;
/**
* 发票类型)1:电子普通发票 2: 纸质增值税专用发票
*/
private
Integer
invoiceType
;
public
Integer
getInvoiceManageId
()
{
public
Integer
getInvoiceManageId
()
{
return
invoiceManageId
;
return
invoiceManageId
;
}
}
...
@@ -174,4 +179,13 @@ public class InvoiceManageListVO implements Serializable{
...
@@ -174,4 +179,13 @@ public class InvoiceManageListVO implements Serializable{
public
void
setExpressMailNumber
(
String
expressMailNumber
)
{
public
void
setExpressMailNumber
(
String
expressMailNumber
)
{
this
.
expressMailNumber
=
expressMailNumber
;
this
.
expressMailNumber
=
expressMailNumber
;
}
}
public
Integer
getInvoiceType
()
{
return
invoiceType
;
}
public
InvoiceManageListVO
setInvoiceType
(
Integer
invoiceType
)
{
this
.
invoiceType
=
invoiceType
;
return
this
;
}
}
}
gic-platform-finance-web/src/main/java/com/gic/finance/web/vo/InvoiceManagerDetailVO.java
View file @
63d59c19
...
@@ -22,7 +22,7 @@ public class InvoiceManagerDetailVO implements Serializable{
...
@@ -22,7 +22,7 @@ public class InvoiceManagerDetailVO implements Serializable{
private
Integer
invoiceManageId
;
private
Integer
invoiceManageId
;
/**
/**
* (发票类型)1:
纸质
普通发票 2: 纸质增值税专用发票
* (发票类型)1:
电子
普通发票 2: 纸质增值税专用发票
*/
*/
private
Integer
invoiceType
;
private
Integer
invoiceType
;
...
@@ -141,6 +141,16 @@ public class InvoiceManagerDetailVO implements Serializable{
...
@@ -141,6 +141,16 @@ public class InvoiceManagerDetailVO implements Serializable{
*/
*/
private
String
shippingAddress
;
private
String
shippingAddress
;
/**
* 电子发票类型,接收人邮箱
*/
private
String
email
;
/**
* 营业执照 图片地址
*/
private
String
businessLicense
;
public
Integer
getInvoiceManageId
()
{
public
Integer
getInvoiceManageId
()
{
return
invoiceManageId
;
return
invoiceManageId
;
}
}
...
@@ -153,6 +163,10 @@ public class InvoiceManagerDetailVO implements Serializable{
...
@@ -153,6 +163,10 @@ public class InvoiceManagerDetailVO implements Serializable{
this
.
invoiceType
=
invoiceType
;
this
.
invoiceType
=
invoiceType
;
}
}
public
Integer
getInvoiceType
()
{
return
invoiceType
;
}
public
String
getInvoiceTypeStr
()
{
public
String
getInvoiceTypeStr
()
{
return
InvoiceTypeEnum
.
getMessageByCode
(
invoiceType
);
return
InvoiceTypeEnum
.
getMessageByCode
(
invoiceType
);
}
}
...
@@ -344,4 +358,22 @@ public class InvoiceManagerDetailVO implements Serializable{
...
@@ -344,4 +358,22 @@ public class InvoiceManagerDetailVO implements Serializable{
public
void
setShippingAddress
(
String
shippingAddress
)
{
public
void
setShippingAddress
(
String
shippingAddress
)
{
this
.
shippingAddress
=
shippingAddress
;
this
.
shippingAddress
=
shippingAddress
;
}
}
public
String
getEmail
()
{
return
email
;
}
public
InvoiceManagerDetailVO
setEmail
(
String
email
)
{
this
.
email
=
email
;
return
this
;
}
public
String
getBusinessLicense
()
{
return
businessLicense
;
}
public
InvoiceManagerDetailVO
setBusinessLicense
(
String
businessLicense
)
{
this
.
businessLicense
=
businessLicense
;
return
this
;
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment