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
2dd7b7da
Commit
2dd7b7da
authored
Jul 16, 2024
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复 api 兼容人大金仓
parent
eac01e5a
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
90 additions
and
15 deletions
+90
-15
BaseEntity.java
...a/com/yeejoin/amos/boot/biz/common/entity/BaseEntity.java
+4
-1
BitTypeHandler.java
...java/com/yeejoin/amos/boot/biz/config/BitTypeHandler.java
+35
-0
BasicGridAcceptanceController.java
...le/hygf/biz/controller/BasicGridAcceptanceController.java
+1
-1
ContractTemplateController.java
...odule/hygf/biz/controller/ContractTemplateController.java
+1
-1
FinancingInfoController.java
...t/module/hygf/biz/controller/FinancingInfoController.java
+1
-1
HouseholdContractController.java
...dule/hygf/biz/controller/HouseholdContractController.java
+1
-1
HygfPreparationMoneyAuditingController.java
...iz/controller/HygfPreparationMoneyAuditingController.java
+1
-1
HygfReplenishmentController.java
...dule/hygf/biz/controller/HygfReplenishmentController.java
+1
-1
PowerStationController.java
...ot/module/hygf/biz/controller/PowerStationController.java
+1
-1
QiyuesuoController.java
...s/boot/module/hygf/biz/controller/QiyuesuoController.java
+18
-1
RegionalCompaniesController.java
...dule/hygf/biz/controller/RegionalCompaniesController.java
+1
-1
SealDictionaryController.java
.../module/hygf/biz/controller/SealDictionaryController.java
+1
-1
UnitInfoServiceImpl.java
...oot/module/hygf/biz/service/impl/UnitInfoServiceImpl.java
+0
-1
application-dev1.properties
...e-hygf-biz/src/main/resources/application-dev1.properties
+22
-2
MonitorFanIdxController.java
.../module/jxiop/biz/controller/MonitorFanIdxController.java
+2
-1
No files found.
amos-boot-biz-common/src/main/java/com/yeejoin/amos/boot/biz/common/entity/BaseEntity.java
View file @
2dd7b7da
...
...
@@ -4,7 +4,10 @@ import com.baomidou.mybatisplus.annotation.FieldFill;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.yeejoin.amos.boot.biz.config.BitTypeHandler
;
import
lombok.Data
;
import
org.apache.ibatis.type.BigDecimalTypeHandler
;
import
org.apache.ibatis.type.BigIntegerTypeHandler
;
import
java.io.Serializable
;
import
java.util.Date
;
...
...
@@ -34,7 +37,7 @@ public class BaseEntity implements Serializable{
/**
* 是否删除
*/
@TableField
(
value
=
"is_delete"
)
@TableField
(
value
=
"is_delete"
,
typeHandler
=
BitTypeHandler
.
class
)
public
Boolean
isDelete
=
false
;
}
amos-boot-biz-common/src/main/java/com/yeejoin/amos/boot/biz/config/BitTypeHandler.java
0 → 100644
View file @
2dd7b7da
package
com
.
yeejoin
.
amos
.
boot
.
biz
.
config
;
import
java.sql.PreparedStatement
;
import
java.sql.ResultSet
;
import
java.sql.SQLException
;
import
org.apache.ibatis.type.BaseTypeHandler
;
import
org.apache.ibatis.type.JdbcType
;
import
org.apache.ibatis.type.MappedJdbcTypes
;
@MappedJdbcTypes
(
JdbcType
.
BIT
)
public
class
BitTypeHandler
extends
BaseTypeHandler
<
Boolean
>
{
@Override
public
void
setNonNullParameter
(
PreparedStatement
ps
,
int
i
,
Boolean
parameter
,
JdbcType
jdbcType
)
throws
SQLException
{
//原生的boolean会再sql上加上引号比如'0'或者'1',人大金仓不支持,支持不带引号的
//ps.setBoolean(i, parameter);
ps
.
setInt
(
i
,
parameter
?
1
:
0
);
}
@Override
public
Boolean
getNullableResult
(
ResultSet
rs
,
String
columnName
)
throws
SQLException
{
return
rs
.
getBoolean
(
columnName
);
}
@Override
public
Boolean
getNullableResult
(
ResultSet
rs
,
int
columnIndex
)
throws
SQLException
{
return
rs
.
getBoolean
(
columnIndex
);
}
@Override
public
Boolean
getNullableResult
(
java
.
sql
.
CallableStatement
cs
,
int
columnIndex
)
throws
SQLException
{
return
cs
.
getBoolean
(
columnIndex
);
}
}
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/BasicGridAcceptanceController.java
View file @
2dd7b7da
...
...
@@ -31,7 +31,7 @@ import java.util.List;
* @date 2024-01-16
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
并网
Api"
)
@RequestMapping
(
value
=
"/basic-grid-acceptance"
)
public
class
BasicGridAcceptanceController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/ContractTemplateController.java
View file @
2dd7b7da
...
...
@@ -28,7 +28,7 @@ import java.util.List;
* @date 2023-08-22
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
合同模板
Api"
)
@RequestMapping
(
value
=
"/contract-template"
)
public
class
ContractTemplateController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/FinancingInfoController.java
View file @
2dd7b7da
...
...
@@ -33,7 +33,7 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
* @date 2024-04-01
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
投融资
Api"
)
@RequestMapping
(
value
=
"/financing-info"
)
public
class
FinancingInfoController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/HouseholdContractController.java
View file @
2dd7b7da
...
...
@@ -46,7 +46,7 @@ import java.util.stream.Collectors;
* @date 2023-08-21
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
农户合同
Api"
)
@RequestMapping
(
value
=
"/household-contract"
)
@Slf4j
public
class
HouseholdContractController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/HygfPreparationMoneyAuditingController.java
View file @
2dd7b7da
...
...
@@ -24,7 +24,7 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
* @date 2024-06-18
*/
@RestController
@Api
(
tags
=
"
投融
审核表Api"
)
@Api
(
tags
=
"
发货管理
审核表Api"
)
@RequestMapping
(
value
=
"/hygf-preparation-money-auditing"
)
public
class
HygfPreparationMoneyAuditingController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/HygfReplenishmentController.java
View file @
2dd7b7da
...
...
@@ -24,7 +24,7 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
* @date 2024-07-02
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
发货管理 补货单
Api"
)
@RequestMapping
(
value
=
"/hygf-replenishment"
)
public
class
HygfReplenishmentController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/PowerStationController.java
View file @
2dd7b7da
...
...
@@ -27,7 +27,7 @@ import java.util.Map;
* @date 2023-07-15
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
电站管理
Api"
)
@RequestMapping
(
value
=
"/power-station"
)
public
class
PowerStationController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/QiyuesuoController.java
View file @
2dd7b7da
...
...
@@ -88,6 +88,8 @@ public class QiyuesuoController extends BaseController {
ContractFillMapper
contractFillMapper
;
@Autowired
PeasantHouseholdServiceImpl
peasantHouseholdServiceImpl
;
@Autowired
HygfContractCallRecordMapper
hygfContractCallRecordMapper
;
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"个人token"
,
notes
=
"个人token"
)
...
...
@@ -168,6 +170,16 @@ public class QiyuesuoController extends BaseController {
String
data
=
this
.
aesDerypt
(
content
,
secretKey
);
System
.
out
.
println
(
"契约锁回调接口解析数据"
+
data
);
CallbackDto
CallbackDto
=
JSON
.
parseObject
(
data
,
CallbackDto
.
class
);
HygfContractCallRecord
hygfContractCallRecord
=
new
HygfContractCallRecord
();
try
{
hygfContractCallRecord
.
setContractId
(
CallbackDto
.
getContractId
());
hygfContractCallRecord
.
setRecDate
(
new
Date
());
hygfContractCallRecord
.
setData
(
JSON
.
toJSONString
(
CallbackDto
));
hygfContractCallRecordMapper
.
insert
(
hygfContractCallRecord
);
}
catch
(
Exception
e
){
log
.
info
(
"合同记录表保存失败,合同id"
+
CallbackDto
.
getContractId
());
}
if
(
"PERSONAL"
.
equals
(
CallbackDto
.
getCallbackType
()))
{
...
...
@@ -228,7 +240,12 @@ public class QiyuesuoController extends BaseController {
}
}
try
{
hygfContractCallRecord
.
setStatus
(
"success"
);
hygfContractCallRecordMapper
.
updateById
(
hygfContractCallRecord
);
}
catch
(
Exception
e
){
log
.
info
(
"状态更新失败,合同id:"
+
CallbackDto
.
getContractId
());
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
throw
new
BadRequest
(
"契约锁回调失败"
);
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/RegionalCompaniesController.java
View file @
2dd7b7da
...
...
@@ -36,7 +36,7 @@ import java.util.List;
* @date 2023-08-29
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
区域公司
Api"
)
@RequestMapping
(
value
=
"/regional-companies"
)
public
class
RegionalCompaniesController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/SealDictionaryController.java
View file @
2dd7b7da
...
...
@@ -23,7 +23,7 @@ import java.util.List;
* @date 2023-08-23
*/
@RestController
@Api
(
tags
=
"Api"
)
@Api
(
tags
=
"
盖章信息
Api"
)
@RequestMapping
(
value
=
"/seal-dictionary"
)
public
class
SealDictionaryController
extends
BaseController
{
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/UnitInfoServiceImpl.java
View file @
2dd7b7da
...
...
@@ -162,7 +162,6 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto,UnitInfo,UnitIn
}
@Override
@Transactional
public
UnitRegisterDto
registerUnit
(
UnitRegisterDto
model
)
{
UnitInfoDto
regUnitInfo
=
model
.
getUnitInfoDto
();
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/resources/application-dev1.properties
View file @
2dd7b7da
...
...
@@ -226,4 +226,24 @@ cheduled.crons=0 10 0 * * ?
dealer.appcode.manage
=
studio_normalapp_5155413,studio_normalapp_5133538
dealer.appcode.role
=
1767363928842571777
dealer.amosDealerId
=
1767820997374775298
\ No newline at end of file
dealer.amosDealerId
=
1767820997374775298
#Seata Config
seata.tx-service-group
=
hygf-seata
seata.service.grouplist.hygf-seata
=
47.92.234.253:8091
# Seata 配置
seata.enabled
=
true
seata.enable-auto-data-source-proxy
=
false
seata.datasource.autoproxy.datasource-proxy-mode
=
original
seata.datasource.autoproxy.enabled
=
true
seata.datasource.autoproxy.data-source-names
=
mysql
## 47环境 排除es报错引进无用配置 业务未实际使用es
spring.elasticsearch.rest.uris
=
http://47.92.234.253:9200
spring.elasticsearch.rest.connection-timeout
=
30000
spring.elasticsearch.rest.username
=
elastic
spring.elasticsearch.rest.password
=
123456
spring.elasticsearch.rest.read-timeout
=
30000
\ No newline at end of file
amos-boot-system-jxiop/amos-boot-module-jxiop-bigscreen-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/controller/MonitorFanIdxController.java
View file @
2dd7b7da
...
...
@@ -490,9 +490,10 @@ public class MonitorFanIdxController extends BaseController {
SimpleDateFormat
myFmt2
=
new
SimpleDateFormat
(
"yyyy"
);
String
monthy
=
myFmt2
.
format
(
new
Date
());
QueryWrapper
<
StationPlan
>
wrapper
=
new
QueryWrapper
<>();
wrapper
.
select
(
"
monthly ,sum(value) value
"
);
wrapper
.
select
(
"
sum(value) as value ,monthly
"
);
wrapper
.
eq
(
"year"
,
monthy
);
wrapper
.
eq
(
"station_basic_id"
,
stationBasic
.
getSequenceNbr
());
wrapper
.
groupBy
(
"monthly"
);
List
<
Map
<
String
,
Object
>>
list1
=
StationPlanMapper
.
selectMaps
(
wrapper
);
Double
sumValue
=
list1
!=
null
&&
!
list1
.
isEmpty
()
?
(
Double
)
list1
.
get
(
0
).
get
(
"value"
)
:
0
;
...
...
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