Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
E
EIP-Integration
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
李炎
EIP-Integration
Commits
74dc332b
提交
74dc332b
authored
8月 21, 2021
作者:
许俊
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改
上级
effaff73
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
44 行增加
和
14 行删除
+44
-14
ProductionSchedulingServiceImpl.java
...ost/API/service/impl/ProductionSchedulingServiceImpl.java
+27
-13
SalesOrderServiceImpl.java
.../modules/iost/API/service/impl/SalesOrderServiceImpl.java
+17
-1
没有找到文件。
jeecg-boot-module-system/src/main/java/org/jeecg/modules/iost/API/service/impl/ProductionSchedulingServiceImpl.java
浏览文件 @
74dc332b
...
...
@@ -5,10 +5,14 @@ import lombok.extern.slf4j.Slf4j;
import
net.sf.json.JSONObject
;
import
org.jeecg.modules.iost.API.Util.JsonUtil
;
import
org.jeecg.modules.iost.API.entity.Materialinventoryerror
;
import
org.jeecg.modules.iost.API.entity.pojo.Productionscheduling
;
import
org.jeecg.modules.iost.API.mapper.ProductionSchedulingMapper
;
import
org.jeecg.modules.iost.API.ExternalInterface.ProductionSchedulingApi
;
import
org.jeecg.modules.iost.API.entity.Productionschedulingerror
;
import
org.jeecg.modules.iost.API.mapper.pojo.ProductionschedulingPojoMapper
;
import
org.jeecg.modules.iost.API.service.IProductionSchedulingService
;
import
org.jeecg.modules.iost.API.service.pojo.ProductionOrderPojoService
;
import
org.jeecg.modules.iost.API.service.pojo.ProductionschedulingService
;
import
org.jeecg.modules.iost.API.webapi.ProductionSchedulingWebapi
;
import
org.jeecg.modules.iost.API.webapi.Util.WebApiLog
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -23,7 +27,7 @@ import java.util.Map;
/**
* @Description: 排产计划
* @Author: jeecg-boot
* @Date:
2021-07-14
* @Date: 2021-07-14
* @Version: V1.0
*/
@Service
...
...
@@ -35,10 +39,11 @@ public class ProductionSchedulingServiceImpl extends ServiceImpl<ProductionSched
ProductionSchedulingWebapi
productionSchedulingWebapi
;
@Autowired
WebApiLog
webApiLog
;
@Autowired
ProductionschedulingService
productionschedulingService
;
@Override
public
String
add
(
Map
<
String
,
String
>
map
)
{
public
String
add
(
Map
<
String
,
String
>
map
)
{
return
null
;
}
...
...
@@ -49,28 +54,38 @@ public class ProductionSchedulingServiceImpl extends ServiceImpl<ProductionSched
/**
* 同步-(从金蝶云同步数据到国网端,并且对两方操作创建同步日志)
*
* @param
* @return
*/
@Override
@Override
public
void
synchronization
()
{
List
<
Object
>
select
=
productionSchedulingWebapi
.
selectObject
(
null
,
null
);
String
content
=
(
String
)
select
.
get
(
0
);
List
<
Map
<
String
,
String
>>
list
=(
List
<
Map
<
String
,
String
>>)
select
.
get
(
1
);
List
<
Object
>
select
=
productionSchedulingWebapi
.
selectObject
(
null
,
null
);
String
content
=
(
String
)
select
.
get
(
0
);
List
<
Map
<
String
,
String
>>
list
=
(
List
<
Map
<
String
,
String
>>)
select
.
get
(
1
);
ArrayList
<
Productionschedulingerror
>
productionschedulingerrors
=
new
ArrayList
<>();
addKingdeeJournalProductionScheduling
(
content
,
list
);
addKingdeeJournalProductionScheduling
(
content
,
list
);
for
(
Map
<
String
,
String
>
stringStringMap
:
list
)
{
String
rs
=
productionSchedulingApi
.
add
(
stringStringMap
);
//待修改
addProductionscheduling
(
rs
,
stringStringMap
,
productionschedulingerrors
);
addProductionscheduling
(
rs
,
stringStringMap
,
productionschedulingerrors
);
pojosave
(
stringStringMap
);
//保存明细实体
}
this
.
saveBatch
(
productionschedulingerrors
);
}
//明细实体保存
public
void
pojosave
(
Map
<
String
,
String
>
stringStringMap
)
{
Productionscheduling
s
=
new
Productionscheduling
();
s
.
setPurchaserhqcode
(
"SGCC"
);
productionschedulingService
.
save
(
s
);
}
//保存国网操作的日志记录
public
void
addProductionscheduling
(
String
rs
,
Map
<
String
,
String
>
stringStringMap
,
ArrayList
<
Productionschedulingerror
>
productionschedulingerrors
)
{
public
void
addProductionscheduling
(
String
rs
,
Map
<
String
,
String
>
stringStringMap
,
ArrayList
<
Productionschedulingerror
>
productionschedulingerrors
)
{
JSONObject
jsonObject
=
JSONObject
.
fromObject
(
rs
);
if
(!
jsonObject
.
get
(
"message"
).
equals
(
"数据库中已存在该记录"
))
{
Productionschedulingerror
productionschedulingerror
=
new
Productionschedulingerror
();
...
...
@@ -84,10 +99,9 @@ public class ProductionSchedulingServiceImpl extends ServiceImpl<ProductionSched
}
//保存金蝶云操作的日志记录
public
void
addKingdeeJournalProductionScheduling
(
String
content
,
List
<
Map
<
String
,
String
>>
list
)
{
public
void
addKingdeeJournalProductionScheduling
(
String
content
,
List
<
Map
<
String
,
String
>>
list
)
{
try
{
webApiLog
.
setKingdeeJournalAnotherParm
(
content
,
"推送排产计划"
,
list
);
webApiLog
.
setKingdeeJournalAnotherParm
(
content
,
"推送排产计划"
,
list
);
}
catch
(
ParseException
e
)
{
e
.
printStackTrace
();
}
...
...
jeecg-boot-module-system/src/main/java/org/jeecg/modules/iost/API/service/impl/SalesOrderServiceImpl.java
浏览文件 @
74dc332b
...
...
@@ -6,10 +6,12 @@ import lombok.val;
import
net.sf.json.JSON
;
import
net.sf.json.JSONObject
;
import
org.jeecg.modules.iost.API.Util.JsonUtil
;
import
org.jeecg.modules.iost.API.entity.pojo.Salesorder
;
import
org.jeecg.modules.iost.API.mapper.SalesOrderMapper
;
import
org.jeecg.modules.iost.API.ExternalInterface.SalesOrderApi
;
import
org.jeecg.modules.iost.API.entity.Salesordererror
;
import
org.jeecg.modules.iost.API.service.ISalesOrderService
;
import
org.jeecg.modules.iost.API.service.pojo.SalesorderPojoService
;
import
org.jeecg.modules.iost.API.webapi.SalesOrderWebapi
;
import
org.jeecg.modules.iost.API.webapi.Util.WebApiLog
;
import
org.jeecg.modules.system.entity.SysPosition
;
...
...
@@ -38,6 +40,8 @@ public class SalesOrderServiceImpl extends ServiceImpl<SalesOrderMapper, Salesor
private
SalesOrderWebapi
salesOrderWebapi
;
@Autowired
WebApiLog
webApiLog
;
@Autowired
SalesorderPojoService
salesorderPojoService
;
//添加单个数据到国网-销售订单
@Override
...
...
@@ -86,8 +90,9 @@ public class SalesOrderServiceImpl extends ServiceImpl<SalesOrderMapper, Salesor
for
(
Map
<
String
,
String
>
stringStringMap
:
list
)
{
String
rs
=
salesOrderApi
.
add
(
stringStringMap
);
//待修改
addSalesOrder
(
rs
,
stringStringMap
,
salesordererrors
);
pojosave
(
stringStringMap
);
//保存明细实体
}
this
.
saveBatch
(
salesordererrors
);
boolean
b
=
this
.
saveBatch
(
salesordererrors
);
}
//保存国网操作的日志记录
public
void
addSalesOrder
(
String
rs
,
Map
<
String
,
String
>
stringStringMap
,
ArrayList
<
Salesordererror
>
salesordererrors
)
{
...
...
@@ -113,4 +118,15 @@ public class SalesOrderServiceImpl extends ServiceImpl<SalesOrderMapper, Salesor
}
}
//明细实体保存
public
void
pojosave
(
Map
<
String
,
String
>
stringStringMap
)
{
Salesorder
p
=
new
Salesorder
();
p
.
setPurchaserhqcode
(
"SGCC"
);
salesorderPojoService
.
save
(
p
);
}
}
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论