Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-zx-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
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
Jobs
Commits
Open sidebar
项目统一框架
一体化_户用光伏项目代码
amos-boot-zx-biz
Commits
42e3e5f8
Commit
42e3e5f8
authored
Nov 19, 2024
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
补充注解
parent
b6f1c2f8
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
661 additions
and
255 deletions
+661
-255
application.properties
...data-housepvapi/src/main/resources/application.properties
+1
-1
FinancingInfoDto.java
...ejoin/amos/boot/module/hygf/api/dto/FinancingInfoDto.java
+15
-12
AcceptanceCheck.java
...oin/amos/boot/module/hygf/api/entity/AcceptanceCheck.java
+20
-1
FileUtils.java
...com/yeejoin/amos/boot/module/hygf/api/util/FileUtils.java
+178
-0
RSASignUtils.java
.../yeejoin/amos/boot/module/hygf/api/util/RSASignUtils.java
+191
-0
pom.xml
amos-boot-system-jxiop/amos-boot-module-hygf-biz/pom.xml
+13
-0
AcceptanceController.java
...boot/module/hygf/biz/controller/AcceptanceController.java
+77
-77
AllPowerController.java
...s/boot/module/hygf/biz/controller/AllPowerController.java
+114
-114
BasicGridAcceptanceController.java
...le/hygf/biz/controller/BasicGridAcceptanceController.java
+51
-49
FinancingInfoController.java
...t/module/hygf/biz/controller/FinancingInfoController.java
+1
-1
No files found.
amos-boot-data/amos-boot-data-housepvapi/src/main/resources/application.properties
View file @
42e3e5f8
spring.application.name
=
AMOS-API-ACCESSAPI
server.servlet.context-path
=
/housepvapi
server.port
=
11006
spring.profiles.active
=
kingbase8
spring.profiles.active
=
dev
server.compression.enabled
=
true
spring.jackson.dateFormat
=
yyyy-MM-dd HH:mm:ss
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/dto/FinancingInfoDto.java
View file @
42e3e5f8
...
...
@@ -28,48 +28,51 @@ public class FinancingInfoDto extends BaseDto {
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"所属融资公司id"
)
@ApiModelProperty
(
value
=
"所属融资公司id"
,
example
=
"1844212763006627841"
)
private
Long
financingCompaniesSeq
;
@ApiModelProperty
(
value
=
"所属融资公司名称"
)
@ApiModelProperty
(
value
=
"所属融资公司名称"
,
example
=
"江苏金融租赁股份有限公司"
)
private
String
financingCompaniesName
;
@ApiModelProperty
(
value
=
"所属融资公司code"
)
@ApiModelProperty
(
value
=
"所属融资公司code"
,
example
=
"86*355*714*908"
)
private
String
financingCompaniesCode
;
@ApiModelProperty
(
value
=
"农户id"
)
@ApiModelProperty
(
value
=
"农户id"
,
example
=
"1826216671409369089"
)
private
Long
peasantHouseholdId
;
@ApiModelProperty
(
value
=
"区域公司Id"
)
@ApiModelProperty
(
value
=
"区域公司Id"
,
example
=
"1703949560172277762"
)
private
Long
regionalCompaniesSeq
;
@ApiModelProperty
(
value
=
"放款时间"
)
@ApiModelProperty
(
value
=
"放款时间"
,
example
=
"2024-04-11"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
"yyyy-MM-dd"
)
private
Date
disbursementTime
;
@ApiModelProperty
(
value
=
"元"
)
@ApiModelProperty
(
value
=
"元"
,
example
=
"500"
)
private
Double
disbursementMoney
;
@ApiModelProperty
(
value
=
"附件"
)
private
String
file
;
@ApiModelProperty
(
value
=
"状态"
)
@ApiModelProperty
(
value
=
"状态"
,
example
=
"待推送"
)
private
String
status
;
@ApiModelProperty
(
value
=
"
农户id
"
)
@ApiModelProperty
(
value
=
"
批量推送时使用"
,
example
=
"[1703949560172277762,1703949560172277762,1703949560172277762]
"
)
private
String
peasantHouseholdIds
;
@ApiModelProperty
(
value
=
"工作流示例id"
,
example
=
"187314"
)
private
String
instanceId
;
@ApiModelProperty
(
value
=
"批次号"
)
@ApiModelProperty
(
value
=
"批次号"
,
example
=
"1729584315664"
)
private
String
batchNo
;
@ApiModelProperty
(
value
=
"附件"
)
private
List
<
Object
>
files
;
@ApiModelProperty
(
value
=
"单价"
)
@ApiModelProperty
(
value
=
"单价"
,
example
=
"0.65"
)
private
String
unitPrice
;
@ApiModelProperty
(
value
=
"投融创建时间"
)
@ApiModelProperty
(
value
=
"投融创建时间"
,
example
=
"2024-11-19"
)
private
Date
trCreateTime
;
@ApiModelProperty
(
value
=
"批量放款录入使用"
,
example
=
"[1703949560172277762,1703949560172277762,1703949560172277762]"
)
List
<
PeasantHousehold
>
peasantHouseholds
;
}
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/entity/AcceptanceCheck.java
View file @
42e3e5f8
...
...
@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.hygf.api.entity;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yeejoin.amos.boot.biz.common.entity.BaseEntity
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
...
...
@@ -27,64 +28,75 @@ public class AcceptanceCheck extends BaseEntity {
* 施工单id
*/
@TableField
(
"work_order_id"
)
@ApiModelProperty
(
value
=
"施工单id"
,
example
=
"1703949560172277760"
)
private
Long
workOrderId
;
/**
* 施工电站id
*/
@TableField
(
"work_order_power_station_id"
)
@ApiModelProperty
(
value
=
"施工电站id"
,
example
=
"1703949560172277760"
)
@TableField
(
"work_order_power_station_id"
)
private
Long
workOrderPowerStationId
;
/**
* 农户id
*/
@ApiModelProperty
(
value
=
"农户id"
,
example
=
"1703949560172277760"
)
@TableField
(
"peasant_household_id"
)
private
Long
peasantHouseholdId
;
/**
* 验收状态
*/
@ApiModelProperty
(
value
=
"验收状态"
,
example
=
"2"
)
@TableField
(
"acceptance_check_status"
)
private
String
acceptanceCheckStatus
;
/**
* 节点标识
*/
@ApiModelProperty
(
value
=
"节点标识"
,
example
=
"jxsAudit"
)
@TableField
(
"basic_grid_node"
)
private
String
basicGridNode
;
/**
* 片区审核
*/
@ApiModelProperty
(
value
=
"片区审核"
,
example
=
"通过"
)
@TableField
(
"power_station_area_status"
)
private
String
powerStationAreaStatus
;
/**
* 法务审核
*/
@ApiModelProperty
(
value
=
"法务审核"
,
example
=
"通过"
)
@TableField
(
"power_station_legal_status"
)
private
String
powerStationLegalStatus
;
/**
* 投融审核
*/
@ApiModelProperty
(
value
=
"投融审核"
,
example
=
"通过"
)
@TableField
(
"power_station_financing_status"
)
private
String
powerStationFinancingStatus
;
/**
* 资产审核
*/
@ApiModelProperty
(
value
=
"资产审核"
,
example
=
"通过"
)
@TableField
(
"power_station_assets_status"
)
private
String
powerStationAssetsStatus
;
/**
* 实例id
*/
@ApiModelProperty
(
value
=
"实例id"
,
example
=
"1254785"
)
@TableField
(
"instance_Id"
)
private
String
instanceId
;
/**
* 整改单状态
*/
@ApiModelProperty
(
value
=
"整改单状态 废弃字段"
)
@TableField
(
"rectification_status"
)
private
String
rectificationStatus
;
...
...
@@ -92,6 +104,7 @@ public class AcceptanceCheck extends BaseEntity {
/**
* 验收时间
*/
@ApiModelProperty
(
value
=
"验收时间"
,
example
=
"2021-01-22 00:00:03"
)
@TableField
(
"acceptance_time"
)
private
String
acceptanceTime
;
...
...
@@ -99,35 +112,41 @@ public class AcceptanceCheck extends BaseEntity {
/**
* 片区整改单
*/
@ApiModelProperty
(
value
=
"片区整改单"
)
@TableField
(
exist
=
false
)
private
List
<
HygfRectificationOrder
>
areaOrders
;
/**
* 投融整改单
*/
@ApiModelProperty
(
value
=
"投融整改单"
)
@TableField
(
exist
=
false
)
private
List
<
HygfRectificationOrder
>
financeOrders
;
/**
* 法务整改单
*/
@ApiModelProperty
(
value
=
"法务整改单"
)
@TableField
(
exist
=
false
)
private
List
<
HygfRectificationOrder
>
legalOrders
;
/**
* 资产整改单
*/
@ApiModelProperty
(
value
=
"资产整改单"
)
@TableField
(
exist
=
false
)
private
List
<
HygfRectificationOrder
>
propertyOrders
;
/**
* 验收创建时间
*/
@ApiModelProperty
(
value
=
"验收创建时间"
,
example
=
"2021-01-21 00:00:03"
)
@TableField
(
"ys_create_time"
)
private
Date
ysCreateTime
;
/**
* 验收结束时间
*/
@ApiModelProperty
(
value
=
"验收结束时间"
,
example
=
"2021-01-22 00:00:03"
)
@TableField
(
"ys_end_time"
)
private
Date
ysEndTime
;
}
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/util/FileUtils.java
0 → 100644
View file @
42e3e5f8
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
api
.
util
;
import
java.io.*
;
import
java.nio.ByteBuffer
;
import
java.nio.MappedByteBuffer
;
import
java.nio.channels.FileChannel
;
import
java.nio.channels.FileChannel.MapMode
;
public
class
FileUtils
{
public
byte
[]
getContent
(
String
filePath
)
throws
IOException
{
File
file
=
new
File
(
filePath
);
long
fileSize
=
file
.
length
();
if
(
fileSize
>
Integer
.
MAX_VALUE
)
{
System
.
out
.
println
(
"file too big..."
);
return
null
;
}
FileInputStream
fi
=
new
FileInputStream
(
file
);
byte
[]
buffer
=
new
byte
[(
int
)
fileSize
];
int
offset
=
0
;
int
numRead
=
0
;
while
(
offset
<
buffer
.
length
&&
(
numRead
=
fi
.
read
(
buffer
,
offset
,
buffer
.
length
-
offset
))
>=
0
)
{
offset
+=
numRead
;
}
// 确保所有数据均被读取
if
(
offset
!=
buffer
.
length
)
{
throw
new
IOException
(
"Could not completely read file "
+
file
.
getName
());
}
fi
.
close
();
return
buffer
;
}
/**
* the traditional io way
*
* @param filename
* @return
* @throws IOException
*/
public
static
byte
[]
toByteArray
(
String
filename
)
throws
IOException
{
File
f
=
new
File
(
filename
);
if
(!
f
.
exists
())
{
throw
new
FileNotFoundException
(
filename
);
}
ByteArrayOutputStream
bos
=
new
ByteArrayOutputStream
((
int
)
f
.
length
());
BufferedInputStream
in
=
null
;
try
{
in
=
new
BufferedInputStream
(
new
FileInputStream
(
f
));
int
buf_size
=
1024
;
byte
[]
buffer
=
new
byte
[
buf_size
];
int
len
=
0
;
while
(-
1
!=
(
len
=
in
.
read
(
buffer
,
0
,
buf_size
)))
{
bos
.
write
(
buffer
,
0
,
len
);
}
return
bos
.
toByteArray
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
throw
e
;
}
finally
{
try
{
in
.
close
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
bos
.
close
();
}
}
/**
* NIO way
*
* @param filename
* @return
* @throws IOException
*/
public
static
byte
[]
toByteArray2
(
String
filename
)
throws
IOException
{
File
f
=
new
File
(
filename
);
if
(!
f
.
exists
())
{
throw
new
FileNotFoundException
(
filename
);
}
FileChannel
channel
=
null
;
FileInputStream
fs
=
null
;
try
{
fs
=
new
FileInputStream
(
f
);
channel
=
fs
.
getChannel
();
ByteBuffer
byteBuffer
=
ByteBuffer
.
allocate
((
int
)
channel
.
size
());
while
((
channel
.
read
(
byteBuffer
))
>
0
)
{
// do nothing
// System.out.println("reading");
}
return
byteBuffer
.
array
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
throw
e
;
}
finally
{
try
{
channel
.
close
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
try
{
fs
.
close
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
}
}
/**
* Mapped File way MappedByteBuffer 可以在处理大文件时,提升性能
*
* @param filename
* @return
* @throws IOException
*/
public
static
byte
[]
toByteArray3
(
String
filename
)
throws
IOException
{
FileChannel
fc
=
null
;
try
{
fc
=
new
RandomAccessFile
(
filename
,
"r"
).
getChannel
();
MappedByteBuffer
byteBuffer
=
fc
.
map
(
MapMode
.
READ_ONLY
,
0
,
fc
.
size
()).
load
();
System
.
out
.
println
(
byteBuffer
.
isLoaded
());
byte
[]
result
=
new
byte
[(
int
)
fc
.
size
()];
if
(
byteBuffer
.
remaining
()
>
0
)
{
// System.out.println("remain");
byteBuffer
.
get
(
result
,
0
,
byteBuffer
.
remaining
());
}
return
result
;
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
throw
e
;
}
finally
{
try
{
fc
.
close
();
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
}
}
public
static
boolean
save2File
(
String
fname
,
byte
[]
msg
){
OutputStream
fos
=
null
;
try
{
File
file
=
new
File
(
fname
);
File
parent
=
file
.
getParentFile
();
boolean
bool
;
if
((!
parent
.
exists
())
&&
(!
parent
.
mkdirs
()))
{
return
false
;
}
fos
=
new
FileOutputStream
(
file
);
fos
.
write
(
msg
);
fos
.
flush
();
return
true
;
}
catch
(
FileNotFoundException
e
){
return
false
;
}
catch
(
IOException
e
){
File
parent
;
return
false
;
}
finally
{
if
(
fos
!=
null
)
{
try
{
fos
.
close
();
}
catch
(
IOException
e
)
{}
}
}
}
}
\ No newline at end of file
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/util/RSASignUtils.java
0 → 100644
View file @
42e3e5f8
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
api
.
util
;
import
java.io.FileInputStream
;
import
java.io.InputStreamReader
;
import
java.nio.charset.StandardCharsets
;
import
java.security.KeyFactory
;
import
java.security.PrivateKey
;
import
java.security.PublicKey
;
import
java.security.Signature
;
import
java.security.cert.CertificateFactory
;
import
java.security.cert.X509Certificate
;
import
java.security.interfaces.RSAPublicKey
;
import
java.security.spec.PKCS8EncodedKeySpec
;
import
java.security.spec.X509EncodedKeySpec
;
import
org.apache.commons.codec.binary.Base64
;
import
org.bouncycastle.util.io.pem.PemReader
;
/**
* SHA256WithRSA签名、验签工具
*
* @FileName: RSASignUtils.java
*/
public
class
RSASignUtils
{
/**
* 日志
*/
private
static
final
String
SIGN_SHA256RSA_ALGORITHMS
=
"SHA256WithRSA"
;
private
static
final
String
SIGN_SHA1RSA_ALGORITHMS
=
"SHA1WithRSA"
;
/**
* 签名
*
* @param content
* @param privateKey
* @return
* @throws Exception
*/
public
static
String
sign
(
String
content
,
PrivateKey
privateKey
)
throws
Exception
{
Signature
signature
=
Signature
.
getInstance
(
SIGN_SHA256RSA_ALGORITHMS
);
signature
.
initSign
(
privateKey
);
signature
.
update
(
content
.
getBytes
(
StandardCharsets
.
UTF_8
));
// 签名使用Base64编码后得到的值即为请求数据中signature字段的值
return
Base64
.
encodeBase64String
(
signature
.
sign
());
}
public
static
String
signWithByte
(
byte
[]
content
,
PrivateKey
privateKey
)
throws
Exception
{
Signature
signature
=
Signature
.
getInstance
(
SIGN_SHA256RSA_ALGORITHMS
);
signature
.
initSign
(
privateKey
);
signature
.
update
(
content
);
// 签名使用Base64编码后得到的值即为请求数据中signature字段的值
return
Base64
.
encodeBase64String
(
signature
.
sign
());
}
public
static
byte
[]
signWithByte_New
(
byte
[]
content
,
PrivateKey
privateKey
)
throws
Exception
{
Signature
signature
=
Signature
.
getInstance
(
SIGN_SHA256RSA_ALGORITHMS
);
signature
.
initSign
(
privateKey
);
signature
.
update
(
content
);
// 签名使用Base64编码后得到的值即为请求数据中signature字段的值
return
signature
.
sign
();
}
/**
* 验签
*
* @param content
* @param signature
* @param publicKey
* @return
*/
public
static
Boolean
checkSign
(
String
content
,
String
signature
,
PublicKey
publicKey
)
{
try
{
Signature
signatureTool
=
Signature
.
getInstance
(
SIGN_SHA256RSA_ALGORITHMS
);
signatureTool
.
initVerify
(
publicKey
);
signatureTool
.
update
(
content
.
getBytes
(
StandardCharsets
.
UTF_8
));
byte
[]
signbyte
=
Base64
.
decodeBase64
(
signature
.
getBytes
());
return
signatureTool
.
verify
(
signbyte
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
return
false
;
}
public
static
Boolean
checkSignWithBytes
(
byte
[]
src_Bytes
,
byte
[]
signBytes
,
PublicKey
publicKey
)
{
try
{
Signature
signatureTool
=
Signature
.
getInstance
(
SIGN_SHA1RSA_ALGORITHMS
);
signatureTool
.
initVerify
(
publicKey
);
signatureTool
.
update
(
src_Bytes
);
byte
[]
signbyte
=
(
signBytes
);
return
signatureTool
.
verify
(
signbyte
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
return
false
;
}
public
static
Boolean
checkSignWithBytes256
(
byte
[]
src_Bytes
,
byte
[]
signBytes
,
PublicKey
publicKey
)
{
try
{
Signature
signatureTool
=
Signature
.
getInstance
(
SIGN_SHA256RSA_ALGORITHMS
);
signatureTool
.
initVerify
(
publicKey
);
signatureTool
.
update
(
src_Bytes
);
byte
[]
signbyte
=
(
signBytes
);
return
signatureTool
.
verify
(
signbyte
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
return
false
;
}
/**
* 加载 pkcs8 格式私钥
*
* @param path
* @return
* @throws Exception
*/
public
static
PrivateKey
loadPrivateKey
(
String
path
)
throws
Exception
{
PemReader
pemReader
=
new
PemReader
(
new
InputStreamReader
(
new
FileInputStream
(
path
)));
PKCS8EncodedKeySpec
pkcs8EncodedKeySpec
=
new
PKCS8EncodedKeySpec
(
pemReader
.
readPemObject
().
getContent
());
pemReader
.
close
();
KeyFactory
keyFactory
=
KeyFactory
.
getInstance
(
"RSA"
);
return
keyFactory
.
generatePrivate
(
pkcs8EncodedKeySpec
);
}
/**
* 从证书加载公钥
*
* @param path
* @return
* @throws Exception
*/
public
static
PublicKey
loadPublicKey
(
String
path
)
throws
Exception
{
CertificateFactory
fact
=
CertificateFactory
.
getInstance
(
"X.509"
);
FileInputStream
is
=
new
FileInputStream
(
path
);
X509Certificate
cer
=
(
X509Certificate
)
fact
.
generateCertificate
(
is
);
return
cer
.
getPublicKey
();
}
/**
* 从文件加载 PKCS8 格式的 RSA 公钥
*/
public
static
RSAPublicKey
readPublicKeyFromFile
(
String
path
)
throws
Exception
{
String
publicKeyPEM
=
"-----BEGIN PUBLIC KEY-----\n"
+
"MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwFgHD4kzEVPdOj03ctKM7KV+1\n"
+
"6bWZ5BMNgvEeuEQwfQYkRVwI9HFOGkwNTMn5hiJXHnlXYCX+zp5r6R52MY0O7BsT\n"
+
"CLT7aHaxsANsvI9ABGx3OaTVlPB59M6GPbJh0uXvio0m1r/lTW3Z60RU6Q3oid/r\n"
+
"NhP3CiNgg0W6O3AGqwIDAQAB\n"
+
"-----END PUBLIC KEY-----"
;
publicKeyPEM
=
publicKeyPEM
.
replace
(
"-----BEGIN PUBLIC KEY-----"
,
""
)
.
replace
(
"-----END PUBLIC KEY-----"
,
""
)
.
replaceAll
(
"\\r"
,
""
).
replaceAll
(
"\\n"
,
""
);
byte
[]
publicKeyDER
=
java
.
util
.
Base64
.
getDecoder
().
decode
(
publicKeyPEM
);
KeyFactory
keyFactory
=
KeyFactory
.
getInstance
(
"RSA"
);
return
(
RSAPublicKey
)
keyFactory
.
generatePublic
(
new
X509EncodedKeySpec
(
publicKeyDER
));
}
public
static
void
main
(
String
[]
args
)
throws
Exception
{
// FileUtils.save2File(
// "/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1_New.sign",
// RSASignUtils.signWithByte_New( FileUtils.toByteArray("/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1.zip"),
// RSASignUtils .loadPrivateKey("/Users/cyzx-mengxr/Downloads/private.pem")));
//String signSrc = RSAUtil.byte2Hex(FileUtils.toByteArray("/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1.sign"));
//String signSrc = RSAUtil(FileUtils.toByteArray("/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1.sign"));
/*验证网关文件*/
// System.out.println( RSASignUtils.checkSignWithBytes(
// FileUtils.toByteArray("/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1.zip"),
// FileUtils.toByteArray("/Users/cyzx-mengxr/Downloads/00008_0202202280000000579_0200003309088104357_001_20220930_acc_1_1.sign"),
// RSASignUtils.readPublicKeyFromFile("/Users/cyzx-mengxr/Downloads/public.pem")));
System
.
out
.
println
(
RSASignUtils
.
checkSignWithBytes256
(
FileUtils
.
toByteArray
(
"/Users/cyzx-mengxr/Library/Containers/com.tencent.xinWeChat/Data/Library/Application Support/com.tencent.xinWeChat/2.0b4.0.9/dc1430eae477f5ad06811d277af61ff6/Message/MessageTemp/bb418fb928671a5accdc29aba40c4b42/File/ENTRUSTRES-20240331JB00400003.bin"
),
FileUtils
.
toByteArray
(
"/Users/cyzx-mengxr/Library/Containers/com.tencent.xinWeChat/Data/Library/Application Support/com.tencent.xinWeChat/2.0b4.0.9/dc1430eae477f5ad06811d277af61ff6/Message/MessageTemp/bb418fb928671a5accdc29aba40c4b42/File/ENTRUSTRES-20240331JB00400003.sign"
),
RSASignUtils
.
readPublicKeyFromFile
(
"/Users/cyzx-mengxr/Downloads/public.pem"
)));
}
}
\ No newline at end of file
amos-boot-system-jxiop/amos-boot-module-hygf-biz/pom.xml
View file @
42e3e5f8
...
...
@@ -26,6 +26,19 @@
<!-- <version>${amos-biz-boot.version}</version>-->
<!-- </dependency>-->
<dependency>
<groupId>
org.apache.directory.studio
</groupId>
<artifactId>
org.apache.commons.codec
</artifactId>
<version>
1.8
</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk15on -->
<dependency>
<groupId>
org.bouncycastle
</groupId>
<artifactId>
bcprov-jdk15on
</artifactId>
<version>
1.70
</version>
</dependency>
<dependency>
<groupId>
org.typroject
</groupId>
<artifactId>
tyboot-component-emq
</artifactId>
<version>
1.1.20
</version>
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/AcceptanceController.java
View file @
42e3e5f8
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
biz
.
controller
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.github.pagehelper.PageHelper
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.hygf.api.config.UserLimits
;
import
com.yeejoin.amos.boot.module.hygf.api.dto.AcceptanceDto
;
import
com.yeejoin.amos.boot.module.hygf.api.dto.UserUnitInformationDto
;
import
com.yeejoin.amos.boot.module.hygf.api.entity.AcceptanceCheckItem
;
import
com.yeejoin.amos.boot.module.hygf.api.mapper.PersonnelBusinessMapper
;
import
com.yeejoin.amos.boot.module.hygf.api.service.IAcceptanceService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.util.Map
;
@RestController
@Api
(
tags
=
"验收管理"
)
@RequestMapping
(
value
=
"/acceptance"
)
public
class
AcceptanceController
extends
BaseController
{
@Autowired
PersonnelBusinessMapper
personnelBusinessMapper
;
@Autowired
private
IAcceptanceService
acceptanceService
;
@PostMapping
(
value
=
"/page"
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"Get"
,
value
=
"获取验收单列表"
,
notes
=
"获取验收单列表"
)
@UserLimits
public
ResponseModel
<
Page
<
AcceptanceDto
>>
page
(
@RequestParam
(
value
=
"current"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
current
,
@RequestParam
(
value
=
"size"
,
required
=
false
,
defaultValue
=
"20"
)
Integer
size
,
@RequestBody
AcceptanceDto
param
)
{
// UserUnitInformationDto userUnitInformationDto = personnelBusinessMapper.getUserUnitInformationDto(getUserInfo().getUserId());
// if(userUnitInformationDto!=null){
// param.setRegionCompanyId(userUnitInformationDto.getRegionalCompaniesSeq());
// param.setAmosDealerId(userUnitInformationDto.getAmosDealerId());
// }
return
ResponseHelper
.
buildResponse
(
acceptanceService
.
page
(
current
,
size
,
param
));
}
@GetMapping
(
"/acceptance-details"
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"Get"
,
value
=
"获取验收单列表"
,
notes
=
"获取验收单列表"
)
public
ResponseModel
<
Map
<
String
,
Object
>>
offlineAcceptanceDetails
(
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
acceptanceService
.
acceptanceDetails
(
sequenceNbr
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"检查项新增"
,
notes
=
"检查项新增"
)
public
ResponseModel
save
(
@RequestBody
AcceptanceCheckItem
model
,
@RequestParam
(
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
acceptanceService
.
saveEntity
(
model
,
sequenceNbr
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/checkAccept"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"提交验收"
,
notes
=
"提交验收"
)
public
ResponseModel
checkAccept
(
@RequestParam
Long
basicGridAcceptanceId
)
{
acceptanceService
.
checkAccept
(
basicGridAcceptanceId
,
getUserId
());
return
ResponseHelper
.
buildResponse
(
null
);
}
}
//
package com.yeejoin.amos.boot.module.hygf.biz.controller;
//
//
import com.baomidou.mybatisplus.core.metadata.IPage;
//
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
//
import com.github.pagehelper.PageHelper;
//
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
//
import com.yeejoin.amos.boot.module.hygf.api.config.UserLimits;
//
import com.yeejoin.amos.boot.module.hygf.api.dto.AcceptanceDto;
//
import com.yeejoin.amos.boot.module.hygf.api.dto.UserUnitInformationDto;
//
import com.yeejoin.amos.boot.module.hygf.api.entity.AcceptanceCheckItem;
//
import com.yeejoin.amos.boot.module.hygf.api.mapper.PersonnelBusinessMapper;
//
import com.yeejoin.amos.boot.module.hygf.api.service.IAcceptanceService;
//
import io.swagger.annotations.Api;
//
import io.swagger.annotations.ApiOperation;
//
import org.springframework.beans.factory.annotation.Autowired;
//
import org.springframework.web.bind.annotation.*;
//
import org.typroject.tyboot.core.foundation.enumeration.UserType;
//
import org.typroject.tyboot.core.restful.doc.TycloudOperation;
//
import org.typroject.tyboot.core.restful.utils.ResponseHelper;
//
import org.typroject.tyboot.core.restful.utils.ResponseModel;
//
//
import java.util.Map;
//
//
@RestController
//
@Api(tags = "验收管理")
//
@RequestMapping(value = "/acceptance")
//
public class AcceptanceController extends BaseController {
//
//
@Autowired
//
PersonnelBusinessMapper personnelBusinessMapper;
//
@Autowired
//
private IAcceptanceService acceptanceService;
//
//
@PostMapping(value = "/page")
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@ApiOperation(httpMethod = "Get", value = "获取验收单列表", notes = "获取验收单列表")
//
@UserLimits
//
public ResponseModel<Page<AcceptanceDto>> page(
//
@RequestParam(value = "current", required = false, defaultValue = "1") Integer current,
//
@RequestParam(value = "size", required = false, defaultValue = "20") Integer size,
//
@RequestBody AcceptanceDto param
//
) {
//
//
UserUnitInformationDto userUnitInformationDto = personnelBusinessMapper.getUserUnitInformationDto(getUserInfo().getUserId());
//
//
if(userUnitInformationDto!=null){
//
//
param.setRegionCompanyId(userUnitInformationDto.getRegionalCompaniesSeq());
//
//
param.setAmosDealerId(userUnitInformationDto.getAmosDealerId());
//
//
}
//
//
//
return ResponseHelper.buildResponse( acceptanceService.page(current, size, param));
//
}
//
//
@GetMapping("/acceptance-details")
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@ApiOperation(httpMethod = "Get", value = "获取验收单列表", notes = "获取验收单列表")
//
public ResponseModel<Map<String, Object>> offlineAcceptanceDetails(@RequestParam("sequenceNbr") Long sequenceNbr) {
//
return ResponseHelper.buildResponse(acceptanceService.acceptanceDetails(sequenceNbr));
//
}
//
//
//
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/save")
//
@ApiOperation(httpMethod = "POST", value = "检查项新增", notes = "检查项新增")
//
public ResponseModel save(@RequestBody AcceptanceCheckItem model, @RequestParam("sequenceNbr") Long sequenceNbr) {
//
return ResponseHelper.buildResponse(acceptanceService.saveEntity(model, sequenceNbr));
//
}
//
//
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/checkAccept")
//
@ApiOperation(httpMethod = "POST", value = "提交验收", notes = "提交验收")
//
public ResponseModel checkAccept(@RequestParam Long basicGridAcceptanceId) {
//
acceptanceService.checkAccept(basicGridAcceptanceId,getUserId());
//
return ResponseHelper.buildResponse(null);
//
}
//
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/AllPowerController.java
View file @
42e3e5f8
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
biz
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.hygf.api.dto.AllPowerDto
;
import
com.yeejoin.amos.boot.module.hygf.biz.service.impl.AllPowerServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
javax.servlet.http.HttpServletRequest
;
import
java.util.List
;
/**
* 统计所有功率
*
* @author system_generator
* @date 2023-09-20
*/
@RestController
@Api
(
tags
=
"统计所有功率Api"
)
@RequestMapping
(
value
=
"/all-power"
)
public
class
AllPowerController
extends
BaseController
{
@Autowired
AllPowerServiceImpl
allPowerServiceImpl
;
/**
* 新增统计所有功率
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增统计所有功率"
,
notes
=
"新增统计所有功率"
)
public
ResponseModel
<
AllPowerDto
>
save
(
@RequestBody
AllPowerDto
model
)
{
model
=
allPowerServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新统计所有功率"
,
notes
=
"根据sequenceNbr更新统计所有功率"
)
public
ResponseModel
<
AllPowerDto
>
updateBySequenceNbrAllPower
(
@RequestBody
AllPowerDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
allPowerServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除统计所有功率"
,
notes
=
"根据sequenceNbr删除统计所有功率"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
){
return
ResponseHelper
.
buildResponse
(
allPowerServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个统计所有功率"
,
notes
=
"根据sequenceNbr查询单个统计所有功率"
)
public
ResponseModel
<
AllPowerDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
allPowerServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"统计所有功率分页查询"
,
notes
=
"统计所有功率分页查询"
)
public
ResponseModel
<
Page
<
AllPowerDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
AllPowerDto
>
page
=
new
Page
<
AllPowerDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
allPowerServiceImpl
.
queryForAllPowerPage
(
page
));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"统计所有功率列表全部数据查询"
,
notes
=
"统计所有功率列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
AllPowerDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
allPowerServiceImpl
.
queryForAllPowerList
());
}
}
//
package com.yeejoin.amos.boot.module.hygf.biz.controller;
//
//
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
//
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
//
import com.yeejoin.amos.boot.module.hygf.api.dto.AllPowerDto;
//
import com.yeejoin.amos.boot.module.hygf.biz.service.impl.AllPowerServiceImpl;
//
import io.swagger.annotations.Api;
//
import io.swagger.annotations.ApiOperation;
//
import org.springframework.beans.factory.annotation.Autowired;
//
import org.springframework.web.bind.annotation.*;
//
import org.typroject.tyboot.core.foundation.enumeration.UserType;
//
import org.typroject.tyboot.core.restful.doc.TycloudOperation;
//
import org.typroject.tyboot.core.restful.utils.ResponseHelper;
//
import org.typroject.tyboot.core.restful.utils.ResponseModel;
//
//
import javax.servlet.http.HttpServletRequest;
//
import java.util.List;
//
/
//
**
//
* 统计所有功率
//
*
//
* @author system_generator
//
* @date 2023-09-20
//
*/
//
@RestController
//
@Api(tags = "统计所有功率Api")
//
@RequestMapping(value = "/all-power")
//
public class AllPowerController extends BaseController {
//
//
@Autowired
//
AllPowerServiceImpl allPowerServiceImpl;
//
//
/**
//
* 新增统计所有功率
//
*
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/save")
//
@ApiOperation(httpMethod = "POST", value = "新增统计所有功率", notes = "新增统计所有功率")
//
public ResponseModel<AllPowerDto> save(@RequestBody AllPowerDto model) {
//
model = allPowerServiceImpl.createWithModel(model);
//
return ResponseHelper.buildResponse(model);
//
}
//
//
/**
//
* 根据sequenceNbr更新
//
*
//
* @param sequenceNbr 主键
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PutMapping(value = "/{sequenceNbr}")
//
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新统计所有功率", notes = "根据sequenceNbr更新统计所有功率")
//
public ResponseModel<AllPowerDto> updateBySequenceNbrAllPower(@RequestBody AllPowerDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
//
return ResponseHelper.buildResponse(allPowerServiceImpl.updateWithModel(model));
//
}
//
//
/**
//
* 根据sequenceNbr删除
//
*
//
* @param sequenceNbr 主键
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@DeleteMapping(value = "/{sequenceNbr}")
//
@ApiOperation(httpMethod = "DELETE", value = "根据sequenceNbr删除统计所有功率", notes = "根据sequenceNbr删除统计所有功率")
//
public ResponseModel<Boolean> deleteBySequenceNbr(HttpServletRequest request, @PathVariable(value = "sequenceNbr") Long sequenceNbr){
//
return ResponseHelper.buildResponse(allPowerServiceImpl.removeById(sequenceNbr));
//
}
//
//
/**
//
* 根据sequenceNbr查询
//
*
//
* @param sequenceNbr 主键
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@GetMapping(value = "/{sequenceNbr}")
//
@ApiOperation(httpMethod = "GET",value = "根据sequenceNbr查询单个统计所有功率", notes = "根据sequenceNbr查询单个统计所有功率")
//
public ResponseModel<AllPowerDto> selectOne(@PathVariable Long sequenceNbr) {
//
return ResponseHelper.buildResponse(allPowerServiceImpl.queryBySeq(sequenceNbr));
//
}
//
//
/**
//
* 列表分页查询
//
*
//
* @param current 当前页
//
* @param current 每页大小
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@GetMapping(value = "/page")
//
@ApiOperation(httpMethod = "GET",value = "统计所有功率分页查询", notes = "统计所有功率分页查询")
//
public ResponseModel<Page<AllPowerDto>> queryForPage(@RequestParam(value = "current") int current,@RequestParam
//
(value = "size") int size) {
//
Page<AllPowerDto> page = new Page<AllPowerDto>();
//
page.setCurrent(current);
//
page.setSize(size);
//
return ResponseHelper.buildResponse(allPowerServiceImpl.queryForAllPowerPage(page));
//
}
//
//
/**
//
* 列表全部数据查询
//
*
//
* @return
//
*/
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@ApiOperation(httpMethod = "GET",value = "统计所有功率列表全部数据查询", notes = "统计所有功率列表全部数据查询")
//
@GetMapping(value = "/list")
//
public ResponseModel<List<AllPowerDto>> selectForList() {
//
return ResponseHelper.buildResponse(allPowerServiceImpl.queryForAllPowerList());
//
}
//
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/BasicGridAcceptanceController.java
View file @
42e3e5f8
...
...
@@ -20,7 +20,9 @@ import com.yeejoin.amos.boot.module.hygf.biz.service.impl.BasicGridAcceptanceSer
import
com.yeejoin.amos.boot.module.hygf.biz.service.impl.WorkflowImpl
;
import
com.yeejoin.amos.component.robot.BadRequest
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.transaction.annotation.Transactional
;
...
...
@@ -101,7 +103,7 @@ public class BasicGridAcceptanceController extends BaseController {
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新"
,
notes
=
"根据sequenceNbr更新"
)
public
ResponseModel
updateBySequenceNbrBasicGridAcceptance
(
@RequestBody
HygfOnGrid
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
@ApiParam
(
value
=
"主键"
,
example
=
"1805040753609568257"
)
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
basicGridAcceptanceServiceImpl
.
modifyEntity
(
model
));
}
...
...
@@ -115,7 +117,7 @@ public class BasicGridAcceptanceController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除"
,
notes
=
"根据sequenceNbr删除"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
@RequestParam
(
"sequenceNbrs"
)
Long
[]
sequenceNbrs
)
{
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
@
ApiParam
(
value
=
"主键"
,
example
=
"1805040753609568257"
)
@
RequestParam
(
"sequenceNbrs"
)
Long
[]
sequenceNbrs
)
{
return
ResponseHelper
.
buildResponse
(
basicGridAcceptanceServiceImpl
.
deleteForBatch
(
sequenceNbrs
));
}
...
...
@@ -128,7 +130,7 @@ public class BasicGridAcceptanceController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个"
,
notes
=
"根据sequenceNbr查询单个"
)
public
ResponseModel
<
BasicGridAcceptanceDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
public
ResponseModel
<
BasicGridAcceptanceDto
>
selectOne
(
@
ApiParam
(
value
=
"主键"
,
example
=
"1805040753609568257"
)
@
PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
basicGridAcceptanceServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
...
...
@@ -143,19 +145,19 @@ public class BasicGridAcceptanceController extends BaseController {
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"分页查询"
,
notes
=
"分页查询"
)
@UserLimits
public
ResponseModel
<
Page
<
BasicGridRecordDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
required
=
false
,
value
=
"projectAddress"
)
String
projectAddress
,
@RequestParam
(
required
=
false
,
value
=
"powerStationCode"
)
String
powerStationCode
,
@RequestParam
(
required
=
false
,
value
=
"ownersName"
)
String
ownersName
,
@RequestParam
(
required
=
false
,
value
=
"gridStatus"
)
String
gridStatus
,
@RequestParam
(
required
=
false
,
value
=
"type"
)
String
type
,
@RequestParam
(
required
=
false
,
value
=
"gridConnectionTime"
)
String
gridConnectionTime
,
@RequestParam
(
required
=
false
,
value
=
"province"
)
String
province
,
@RequestParam
(
required
=
false
,
value
=
"developerName"
)
String
developerName
,
@RequestParam
(
required
=
false
,
value
=
"regionalCompaniesName"
)
String
regionalCompaniesName
,
@RequestParam
(
required
=
false
,
value
=
"startTime"
)
String
startTime
,
@RequestParam
(
required
=
false
,
value
=
"endTime"
)
String
endTime
)
throws
Exception
{
public
ResponseModel
<
Page
<
BasicGridRecordDto
>>
queryForPage
(
@
ApiParam
(
value
=
"当前页"
,
example
=
"1"
)
@
RequestParam
(
value
=
"current"
)
int
current
,
@ApiParam
(
value
=
"分页条数"
,
example
=
"20"
)
@RequestParam
(
value
=
"size"
)
int
size
,
@ApiParam
(
value
=
"当前页"
,
example
=
"1"
)
@RequestParam
(
required
=
false
,
value
=
"projectAddress"
)
String
projectAddress
,
@ApiParam
(
value
=
"当前页"
,
example
=
"1"
)
@RequestParam
(
required
=
false
,
value
=
"powerStationCode"
)
String
powerStationCode
,
@ApiParam
(
value
=
"当前页"
,
example
=
"1"
)
@RequestParam
(
required
=
false
,
value
=
"ownersName"
)
String
ownersName
,
@
ApiParam
(
value
=
"并网状态"
,
example
=
"1"
)
@
RequestParam
(
required
=
false
,
value
=
"gridStatus"
)
String
gridStatus
,
@
ApiParam
(
value
=
"区分经销商端或管理端 为null则为经销商端 反之管理端"
,
example
=
"1"
)
@
RequestParam
(
required
=
false
,
value
=
"type"
)
String
type
,
@
ApiParam
(
value
=
"并网时间"
,
example
=
"2024-01-03"
)
@
RequestParam
(
required
=
false
,
value
=
"gridConnectionTime"
)
String
gridConnectionTime
,
@
ApiParam
(
value
=
"省份"
,
example
=
"陕西省"
)
@
RequestParam
(
required
=
false
,
value
=
"province"
)
String
province
,
@
ApiParam
(
value
=
"经销商公司名称"
,
example
=
"xxxxx公司"
)
@
RequestParam
(
required
=
false
,
value
=
"developerName"
)
String
developerName
,
@
ApiParam
(
value
=
"区域公司"
,
example
=
"xxxxx公司"
)
@
RequestParam
(
required
=
false
,
value
=
"regionalCompaniesName"
)
String
regionalCompaniesName
,
@
ApiParam
(
value
=
"第一次提交时间 筛选用开始时间"
,
example
=
"2024-03-02 23:12:23"
)
@
RequestParam
(
required
=
false
,
value
=
"startTime"
)
String
startTime
,
@
ApiParam
(
value
=
"第一次提交时间 筛选用结束时间"
,
example
=
"2024-04-02 23:12:23"
)
@
RequestParam
(
required
=
false
,
value
=
"endTime"
)
String
endTime
)
throws
Exception
{
// 当前登录人所属场站
// UserUnitInformationDto userUnitInformationDto=personnelBusinessMapper.getUserUnitInformationDto( getUserInfo().getUserId());
...
...
@@ -212,13 +214,13 @@ public class BasicGridAcceptanceController extends BaseController {
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"分页查询"
,
notes
=
"分页查询"
)
@UserLimits
public
ResponseModel
<
Page
<
BasicGridRecordDto
>>
queryForCheckPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
required
=
false
,
value
=
"projectAddress"
)
String
projectAddress
,
@RequestParam
(
required
=
false
,
value
=
"powerStationCode"
)
String
powerStationCode
,
@RequestParam
(
required
=
false
,
value
=
"ownersName"
)
String
ownersName
,
@RequestParam
(
required
=
false
,
value
=
"gridStatus"
)
String
gridStatus
,
@RequestParam
(
required
=
false
,
value
=
"gridConnectionTime"
)
String
gridConnectionTime
,
@RequestParam
(
required
=
false
,
value
=
"province"
)
String
province
)
throws
Exception
{
@
ApiParam
(
value
=
"分页条数"
,
example
=
"20"
)
@
RequestParam
(
value
=
"size"
)
int
size
,
@
ApiParam
(
value
=
"项目地址"
,
example
=
"xx市"
)
@
RequestParam
(
required
=
false
,
value
=
"projectAddress"
)
String
projectAddress
,
@
ApiParam
(
value
=
"并网状态"
,
example
=
"1"
)
@
RequestParam
(
required
=
false
,
value
=
"powerStationCode"
)
String
powerStationCode
,
@
ApiParam
(
value
=
"业主姓名"
,
example
=
"曹德文"
)
@
RequestParam
(
required
=
false
,
value
=
"ownersName"
)
String
ownersName
,
@
ApiParam
(
value
=
"并网状态"
,
example
=
"2"
)
@
RequestParam
(
required
=
false
,
value
=
"gridStatus"
)
String
gridStatus
,
@ApiParam
(
value
=
"并网时间"
,
example
=
"2024-01-03"
)
@RequestParam
(
required
=
false
,
value
=
"gridConnectionTime"
)
String
gridConnectionTime
,
@
ApiParam
(
value
=
"省份"
,
example
=
"陕西省"
)
@
RequestParam
(
required
=
false
,
value
=
"province"
)
String
province
)
throws
Exception
{
// 当前登录人所属场站
Page
<
BasicGridRecordDto
>
page
=
basicGridAcceptanceServiceImpl
.
selectPage
(
null
,
null
,
current
,
size
,
...
...
@@ -237,16 +239,16 @@ public class BasicGridAcceptanceController extends BaseController {
public
ResponseModel
<
List
<
BasicGridAcceptanceDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
Collections
.
emptyList
());
}
// 并网审核
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/execute"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"执行工作流"
,
notes
=
"执行工作流"
)
public
ResponseModel
execute
(
@RequestBody
AcceptanceCheckItem
dto
)
{
basicGridAcceptanceServiceImpl
.
execute
(
dto
,
getUserId
());
return
ResponseHelper
.
buildResponse
(
null
);
}
//
//
// 并网审核
//
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/execute")
//
@ApiOperation(httpMethod = "POST", value = "执行工作流", notes = "执行工作流")
//
public ResponseModel execute(@RequestBody AcceptanceCheckItem dto) {
//
basicGridAcceptanceServiceImpl.execute(dto, getUserId());
//
return ResponseHelper.buildResponse(null);
//
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"完工自审-经销商管理"
,
notes
=
"完工自审经销商管理"
)
...
...
@@ -297,25 +299,25 @@ public class BasicGridAcceptanceController extends BaseController {
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"整改单作废"
,
notes
=
"整改单作废"
)
@PutMapping
(
value
=
"/rollback"
)
@Transactional
public
ResponseModel
rollback
(
@RequestParam
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
public
ResponseModel
rollback
(
@
ApiParam
(
value
=
"主键"
,
example
=
"1805040753609568257"
)
@
RequestParam
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
basicGridAcceptanceServiceImpl
.
rollback
(
sequenceNbr
);
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/test1"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"执行工作流"
,
notes
=
"执行工作流"
)
public
ResponseModel
test
()
{
basicGridAcceptanceServiceImpl
.
testKAIQI
();
return
ResponseHelper
.
buildResponse
(
null
);
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/test2"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"执行工作流"
,
notes
=
"执行工作流"
)
public
ResponseModel
test
(
String
approvalStatus
,
String
comment
)
{
basicGridAcceptanceServiceImpl
.
zhixing
(
approvalStatus
,
comment
);
return
ResponseHelper
.
buildResponse
(
null
);
}
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/test1")
//
@ApiOperation(httpMethod = "POST", value = "执行工作流", notes = "执行工作流")
//
public ResponseModel test() {
//
basicGridAcceptanceServiceImpl.testKAIQI();
//
return ResponseHelper.buildResponse(null);
//
}
//
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
//
@PostMapping(value = "/test2")
//
@ApiOperation(httpMethod = "POST", value = "执行工作流", notes = "执行工作流")
//
public ResponseModel test(String approvalStatus, String comment) {
//
basicGridAcceptanceServiceImpl.zhixing(approvalStatus, comment);
//
return ResponseHelper.buildResponse(null);
//
}
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/FinancingInfoController.java
View file @
42e3e5f8
...
...
@@ -50,7 +50,7 @@ public class FinancingInfoController extends BaseController {
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"
新增"
,
notes
=
"新增
"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"
投融推送"
,
notes
=
"投融推送
"
)
@Transactional
public
ResponseModel
<
FinancingInfoDto
>
save
(
@RequestBody
FinancingInfoDto
model
)
{
model
=
financingInfoServiceImpl
.
saveModel
(
model
);
...
...
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