Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
ry-crm
Project
Project
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
田光明
ry-crm
Commits
36e343d0
Commit
36e343d0
authored
Feb 26, 2025
by
EDY
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化
parent
e6d9e20f
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
107 additions
and
3 deletions
+107
-3
BaseInvoiceInfoController.java
...yi/web/controller/business/BaseInvoiceInfoController.java
+9
-0
BaseInvoiceInfo.java
...ava/com/ruoyi/system/domain/business/BaseInvoiceInfo.java
+47
-0
IBaseInvoiceInfoService.java
...uoyi/system/service/business/IBaseInvoiceInfoService.java
+3
-0
BaseInvoiceInfoServiceImpl.java
...tem/service/business/impl/BaseInvoiceInfoServiceImpl.java
+25
-0
BaseContractInfoMapper.xml
...main/resources/mapper/business/BaseContractInfoMapper.xml
+2
-2
BaseInvoiceInfoMapper.xml
.../main/resources/mapper/business/BaseInvoiceInfoMapper.xml
+21
-1
No files found.
ruoyi-admin/src/main/java/com/ruoyi/web/controller/business/BaseInvoiceInfoController.java
View file @
36e343d0
...
...
@@ -3,6 +3,7 @@ package com.ruoyi.web.controller.business;
import
java.util.List
;
import
javax.servlet.http.HttpServletResponse
;
import
com.ruoyi.system.domain.business.BaseContractInfo
;
import
com.ruoyi.system.domain.business.BaseInvoiceInfo
;
import
com.ruoyi.system.service.business.IBaseInvoiceInfoService
;
import
org.springframework.security.access.prepost.PreAuthorize
;
...
...
@@ -81,6 +82,14 @@ public class BaseInvoiceInfoController extends BaseController
return
toAjax
(
baseInvoiceInfoService
.
insertBaseInvoiceInfo
(
baseInvoiceInfo
));
}
@GetMapping
(
value
=
"/audit/list"
)
public
TableDataInfo
getInfo
(
BaseInvoiceInfo
baseInvoiceInfo
)
{
startPage
();
List
<
BaseInvoiceInfo
>
baseInvoiceInfos
=
baseInvoiceInfoService
.
selectBaseInvoiceAuditList
(
baseInvoiceInfo
,
getLoginUser
());
return
getDataTable
(
baseInvoiceInfos
);
}
/**
* 修改开票信息
*/
...
...
ruoyi-system/src/main/java/com/ruoyi/system/domain/business/BaseInvoiceInfo.java
View file @
36e343d0
...
...
@@ -83,6 +83,14 @@ public class BaseInvoiceInfo extends BaseEntity
@Excel
(
name
=
"纳税人识别号"
)
private
String
nsrsbh
;
/** 发票代码 */
@Excel
(
name
=
"发票代码"
)
private
String
fpdm
;
/** 发票号码 */
@Excel
(
name
=
"发票号码"
)
private
String
fphm
;
/** 地址 */
@Excel
(
name
=
"地址"
)
private
String
dz
;
...
...
@@ -123,6 +131,12 @@ public class BaseInvoiceInfo extends BaseEntity
@Excel
(
name
=
"申请人"
)
private
String
sqr
;
/** 审核人id */
private
Long
shrId
;
/** 审核人 */
private
String
shrName
;
/** 开票时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@Excel
(
name
=
"开票时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd HH:mm:ss"
)
...
...
@@ -460,4 +474,37 @@ public class BaseInvoiceInfo extends BaseEntity
public
void
setBaseInvoiceAuditRecords
(
List
<
BaseInvoiceAuditRecord
>
baseInvoiceAuditRecords
)
{
this
.
baseInvoiceAuditRecords
=
baseInvoiceAuditRecords
;
}
public
Long
getShrId
()
{
return
shrId
;
}
public
void
setShrId
(
Long
shrId
)
{
this
.
shrId
=
shrId
;
}
public
String
getShrName
()
{
return
shrName
;
}
public
void
setShrName
(
String
shrName
)
{
this
.
shrName
=
shrName
;
}
public
String
getFpdm
()
{
return
fpdm
;
}
public
void
setFpdm
(
String
fpdm
)
{
this
.
fpdm
=
fpdm
;
}
public
String
getFphm
()
{
return
fphm
;
}
public
void
setFphm
(
String
fphm
)
{
this
.
fphm
=
fphm
;
}
}
ruoyi-system/src/main/java/com/ruoyi/system/service/business/IBaseInvoiceInfoService.java
View file @
36e343d0
package
com
.
ruoyi
.
system
.
service
.
business
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.core.domain.model.LoginUser
;
import
com.ruoyi.system.domain.business.BaseInvoiceInfo
;
import
java.util.List
;
...
...
@@ -61,4 +62,6 @@ public interface IBaseInvoiceInfoService
* @return 结果
*/
public
int
deleteBaseInvoiceInfoById
(
Long
id
);
List
<
BaseInvoiceInfo
>
selectBaseInvoiceAuditList
(
BaseInvoiceInfo
baseInvoiceInfo
,
LoginUser
loginUser
);
}
ruoyi-system/src/main/java/com/ruoyi/system/service/business/impl/BaseInvoiceInfoServiceImpl.java
View file @
36e343d0
package
com
.
ruoyi
.
system
.
service
.
business
.
impl
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.List
;
import
com.ruoyi.common.core.domain.entity.SysRole
;
import
com.ruoyi.common.core.domain.entity.SysUser
;
import
com.ruoyi.common.core.domain.model.LoginUser
;
import
com.ruoyi.common.utils.DateUtils
;
import
com.ruoyi.system.domain.business.BaseContractInfo
;
import
com.ruoyi.system.domain.business.BaseInvoiceAuditRecord
;
import
com.ruoyi.system.domain.business.BaseInvoiceInfo
;
import
com.ruoyi.system.mapper.SysRoleMapper
;
import
com.ruoyi.system.mapper.business.BaseInvoiceAuditRecordMapper
;
import
com.ruoyi.system.mapper.business.BaseInvoiceInfoMapper
;
import
com.ruoyi.system.service.business.IBaseInvoiceInfoService
;
...
...
@@ -28,6 +33,9 @@ public class BaseInvoiceInfoServiceImpl implements IBaseInvoiceInfoService
@Autowired
private
BaseInvoiceAuditRecordMapper
baseInvoiceAuditRecordMapper
;
@Autowired
private
SysRoleMapper
sysRoleMapper
;
/**
* 查询开票信息
*
...
...
@@ -142,4 +150,21 @@ public class BaseInvoiceInfoServiceImpl implements IBaseInvoiceInfoService
{
return
baseInvoiceInfoMapper
.
deleteBaseInvoiceInfoById
(
id
);
}
@Override
public
List
<
BaseInvoiceInfo
>
selectBaseInvoiceAuditList
(
BaseInvoiceInfo
baseInvoiceInfo
,
LoginUser
loginUser
)
{
List
<
BaseInvoiceInfo
>
baseInvoiceInfos
=
new
ArrayList
<>();
if
(
baseInvoiceInfo
.
getShrId
()
!=
null
)
{
baseInvoiceInfos
=
baseInvoiceInfoMapper
.
selectBaseInvoiceInfoList
(
baseInvoiceInfo
);
}
else
{
List
<
Long
>
longs
=
sysRoleMapper
.
selectRoleListByUserId
(
loginUser
.
getUserId
());
for
(
Long
aLong
:
longs
)
{
SysRole
sysRole
=
sysRoleMapper
.
selectRoleById
(
aLong
);
if
(
sysRole
.
getRoleKey
().
equals
(
"audit"
))
{
baseInvoiceInfos
=
baseInvoiceInfoMapper
.
selectBaseInvoiceInfoList
(
baseInvoiceInfo
);
}
}
}
return
baseInvoiceInfos
;
}
}
ruoyi-system/src/main/resources/mapper/business/BaseContractInfoMapper.xml
View file @
36e343d0
...
...
@@ -123,7 +123,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
sum(hkje) toTheAmount
from base_contract_info where htzt != 5
<if
test=
"contractId != null"
>
and
contract_
id = #{contractId}
and id = #{contractId}
</if>
</select>
...
...
@@ -210,7 +210,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"ztdw != null"
>
#{ztdw},
</if>
<if
test=
"htfj != null"
>
#{htfj},
</if>
<if
test=
"shrId != null"
>
#{shrId},
</if>
<if
test=
"shrName != null"
>
#{shr},
</if>
<if
test=
"shrName != null"
>
#{shr
Name
},
</if>
<if
test=
"shzt != null"
>
#{shzt},
</if>
<if
test=
"bz != null"
>
#{bz},
</if>
<if
test=
"deleteFlag != null"
>
#{deleteFlag},
</if>
...
...
ruoyi-system/src/main/resources/mapper/business/BaseInvoiceInfoMapper.xml
View file @
36e343d0
...
...
@@ -21,6 +21,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"kpje"
column=
"kpje"
/>
<result
property=
"fpse"
column=
"fpse"
/>
<result
property=
"nsrsbh"
column=
"nsrsbh"
/>
<result
property=
"fpdm"
column=
"fpdm"
/>
<result
property=
"fphm"
column=
"fphm"
/>
<result
property=
"dz"
column=
"dz"
/>
<result
property=
"sjh"
column=
"sjh"
/>
<result
property=
"khh"
column=
"khh"
/>
...
...
@@ -31,6 +33,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"bz"
column=
"bz"
/>
<result
property=
"fpzt"
column=
"fpzt"
/>
<result
property=
"sqr"
column=
"sqr"
/>
<result
property=
"shrId"
column=
"shr_id"
/>
<result
property=
"shrName"
column=
"shr"
/>
<result
property=
"kpsj"
column=
"kpsj"
/>
<result
property=
"dfkxy"
column=
"dfkxy"
/>
<result
property=
"dzhd"
column=
"dzhd"
/>
...
...
@@ -42,7 +46,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql
id=
"selectBaseInvoiceInfoVo"
>
select id, contract_id, htbh, bm_id, bm, kh_id, khmc, htmc, hkje, hkqs, fpnr, fplx, fpsl, kpje, fpse, nsrsbh,
dz, sjh, khh, yhzh, sprxm, sprdh, spryx, bz, fpzt, sq
r, kpsj, dfkxy, dzhd, fpfj, create_time, create_by, update_time, update_by from base_invoice_info
select id, contract_id, htbh, bm_id, bm, kh_id, khmc, htmc, hkje, hkqs, fpnr, fplx, fpsl, kpje, fpse, nsrsbh,
fpdm,fphm, dz, sjh, khh, yhzh, sprxm, sprdh, spryx, bz, fpzt, sqr,shr_id,sh
r, kpsj, dfkxy, dzhd, fpfj, create_time, create_by, update_time, update_by from base_invoice_info
</sql>
<select
id=
"selectBaseInvoiceInfoList"
parameterType=
"BaseInvoiceInfo"
resultMap=
"BaseInvoiceInfoResult"
>
...
...
@@ -63,6 +67,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"kpje != null "
>
and kpje = #{kpje}
</if>
<if
test=
"fpse != null "
>
and fpse = #{fpse}
</if>
<if
test=
"nsrsbh != null and nsrsbh != ''"
>
and nsrsbh = #{nsrsbh}
</if>
<if
test=
"fpdm != null and fpdm != ''"
>
and fpdm = #{fpdm}
</if>
<if
test=
"fphm != null and fphm != ''"
>
and fphm = #{fphm}
</if>
<if
test=
"dz != null and dz != ''"
>
and dz = #{dz}
</if>
<if
test=
"sjh != null and sjh != ''"
>
and sjh = #{sjh}
</if>
<if
test=
"khh != null and khh != ''"
>
and khh = #{khh}
</if>
...
...
@@ -73,6 +79,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"bz != null and bz != ''"
>
and bz = #{bz}
</if>
<if
test=
"fpzt != null "
>
and fpzt = #{fpzt}
</if>
<if
test=
"sqr != null and sqr != ''"
>
and sqr = #{sqr}
</if>
<if
test=
"shrId != null"
>
and shr_id = #{shrId}
</if>
<if
test=
"shrName != null and shrName != ''"
>
and shr = #{shrName}
</if>
<if
test=
"kpsj != null "
>
and kpsj = #{kpsj}
</if>
<if
test=
"dfkxy != null and dfkxy != ''"
>
and dfkxy = #{dfkxy}
</if>
<if
test=
"dzhd != null and dzhd != ''"
>
and dzhd = #{dzhd}
</if>
...
...
@@ -115,6 +123,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"kpje != null"
>
kpje,
</if>
<if
test=
"fpse != null"
>
fpse,
</if>
<if
test=
"nsrsbh != null"
>
nsrsbh,
</if>
<if
test=
"fpdm != null"
>
fpdm,
</if>
<if
test=
"fphm != null"
>
fphm,
</if>
<if
test=
"dz != null"
>
dz,
</if>
<if
test=
"sjh != null"
>
sjh,
</if>
<if
test=
"khh != null"
>
khh,
</if>
...
...
@@ -125,6 +135,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"bz != null"
>
bz,
</if>
<if
test=
"fpzt != null"
>
fpzt,
</if>
<if
test=
"sqr != null"
>
sqr,
</if>
<if
test=
"shrId != null"
>
shr_id,
</if>
<if
test=
"shrName != null"
>
shr,
</if>
<if
test=
"kpsj != null"
>
kpsj,
</if>
<if
test=
"dfkxy != null"
>
dfkxy,
</if>
<if
test=
"dzhd != null"
>
dzhd,
</if>
...
...
@@ -151,6 +163,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"kpje != null"
>
#{kpje},
</if>
<if
test=
"fpse != null"
>
#{fpse},
</if>
<if
test=
"nsrsbh != null"
>
#{nsrsbh},
</if>
<if
test=
"fpdm != null"
>
#{fpdm},
</if>
<if
test=
"fphm != null"
>
#{fphm},
</if>
<if
test=
"dz != null"
>
#{dz},
</if>
<if
test=
"sjh != null"
>
#{sjh},
</if>
<if
test=
"khh != null"
>
#{khh},
</if>
...
...
@@ -161,6 +175,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"bz != null"
>
#{bz},
</if>
<if
test=
"fpzt != null"
>
#{fpzt},
</if>
<if
test=
"sqr != null"
>
#{sqr},
</if>
<if
test=
"shrId != null"
>
#{shrId},
</if>
<if
test=
"shrName != null"
>
#{shrName},
</if>
<if
test=
"kpsj != null"
>
#{kpsj},
</if>
<if
test=
"dfkxy != null"
>
#{dfkxy},
</if>
<if
test=
"dzhd != null"
>
#{dzhd},
</if>
...
...
@@ -190,6 +206,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"kpje != null"
>
kpje = #{kpje},
</if>
<if
test=
"fpse != null"
>
fpse = #{fpse},
</if>
<if
test=
"nsrsbh != null"
>
nsrsbh = #{nsrsbh},
</if>
<if
test=
"fpdm != null"
>
fpdm = #{fpdm},
</if>
<if
test=
"fphm != null"
>
fphm = #{fphm},
</if>
<if
test=
"dz != null"
>
dz = #{dz},
</if>
<if
test=
"sjh != null"
>
sjh = #{sjh},
</if>
<if
test=
"khh != null"
>
khh = #{khh},
</if>
...
...
@@ -200,6 +218,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"bz != null"
>
bz = #{bz},
</if>
<if
test=
"fpzt != null"
>
fpzt = #{fpzt},
</if>
<if
test=
"sqr != null"
>
sqr = #{sqr},
</if>
<if
test=
"shrId != null"
>
shr_id = #{shrId},
</if>
<if
test=
"shrName != null"
>
shr = #{shrName},
</if>
<if
test=
"kpsj != null"
>
kpsj = #{kpsj},
</if>
<if
test=
"dfkxy != null"
>
dfkxy = #{dfkxy},
</if>
<if
test=
"dzhd != null"
>
dzhd = #{dzhd},
</if>
...
...
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