Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
K
klck
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
位宇华
klck
Commits
a9907806
Commit
a9907806
authored
Oct 18, 2023
by
lenovo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
通用转换数据清洗
parent
6c9420b5
Changes
13
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
807 additions
and
130 deletions
+807
-130
ruoyi-supplies/src/main/java/com/ruoyi/system/controller/ActSuppliesCleaningRuleController.java
.../system/controller/ActSuppliesCleaningRuleController.java
+3
-3
ruoyi-supplies/src/main/java/com/ruoyi/system/controller/ActSuppliesHistorydataController.java
...i/system/controller/ActSuppliesHistorydataController.java
+27
-2
ruoyi-supplies/src/main/java/com/ruoyi/system/domain/ActSuppliesHistorydata.java
.../java/com/ruoyi/system/domain/ActSuppliesHistorydata.java
+11
-0
ruoyi-supplies/src/main/java/com/ruoyi/system/mapper/ActSuppliesCleaningRuleMapper.java
...om/ruoyi/system/mapper/ActSuppliesCleaningRuleMapper.java
+4
-0
ruoyi-supplies/src/main/java/com/ruoyi/system/mapper/ActSuppliesHistorydataMapper.java
...com/ruoyi/system/mapper/ActSuppliesHistorydataMapper.java
+2
-1
ruoyi-supplies/src/main/java/com/ruoyi/system/service/IActSuppliesHistorydataService.java
.../ruoyi/system/service/IActSuppliesHistorydataService.java
+5
-1
ruoyi-supplies/src/main/java/com/ruoyi/system/service/impl/ActSuppliesHistorydataServiceImpl.java
...ystem/service/impl/ActSuppliesHistorydataServiceImpl.java
+170
-17
ruoyi-supplies/src/main/resources/mapper/system/ActSuppliesCleaningRuleMapper.xml
...resources/mapper/system/ActSuppliesCleaningRuleMapper.xml
+287
-0
ruoyi-supplies/src/main/resources/mapper/system/ActSuppliesHistorydataMapper.xml
.../resources/mapper/system/ActSuppliesHistorydataMapper.xml
+7
-4
ruoyi-ui/src/api/Actsupplies/cleaning_rule.js
ruoyi-ui/src/api/Actsupplies/cleaning_rule.js
+2
-2
ruoyi-ui/src/api/system/historydata.js
ruoyi-ui/src/api/system/historydata.js
+18
-0
ruoyi-ui/src/views/ActSuppliesConvert/convert/indexConvert.vue
...-ui/src/views/ActSuppliesConvert/convert/indexConvert.vue
+267
-99
ruoyi-ui/src/views/system/supplies/index.vue
ruoyi-ui/src/views/system/supplies/index.vue
+4
-1
No files found.
ruoyi-supplies/src/main/java/com/ruoyi/system/controller/ActSuppliesCleaningRuleController.java
View file @
a9907806
...
...
@@ -30,11 +30,11 @@ public class ActSuppliesCleaningRuleController extends BaseController
* 获取所有历史数据
*/
@PreAuthorize
(
"@ss.hasPermi('system:cleaningrule:queryAll')"
)
@GetMapping
(
"/queryAll"
)
public
AjaxResult
selectActSuppliesHistorydata
()
@GetMapping
(
"/queryAll
/{tylkStatus}
"
)
public
AjaxResult
selectActSuppliesHistorydata
(
@PathVariable
(
"tylkStatus"
)
Integer
tylkStatus
)
{
List
<
ActSuppliesHistorydata
>
s
=
actSuppliesHistorydataService
.
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
s
=
actSuppliesHistorydataService
.
selectActSuppliesHistorydata
(
tylkStatus
);
return
AjaxResult
.
success
(
s
);
}
...
...
ruoyi-supplies/src/main/java/com/ruoyi/system/controller/ActSuppliesHistorydataController.java
View file @
a9907806
...
...
@@ -115,7 +115,7 @@ public class ActSuppliesHistorydataController extends BaseController
}
/**
* 数据清洗
历史数据 生成
* 数据清洗
六矿生成表数据
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert1')"
)
@PostMapping
(
"/addInsert1"
)
...
...
@@ -127,7 +127,7 @@ public class ActSuppliesHistorydataController extends BaseController
}
/**
* 数据清洗
历史数据 导入
* 数据清洗
六矿导入表数据
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert2')"
)
@PostMapping
(
"/addInsert2"
)
...
...
@@ -139,6 +139,31 @@ public class ActSuppliesHistorydataController extends BaseController
return
toAjax
(
1
);
}
/**
* 数据清洗 通用生成表数据
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsertConvert1')"
)
@PostMapping
(
"/addInsertConvert1"
)
public
AjaxResult
addInsertConvert1
(
@RequestBody
List
<
ActOperation1
>
actOperation2s
)
{
actSuppliesHistorydataService
.
addInsertConvert1
(
actOperation2s
);
return
toAjax
(
1
);
}
/**
* 数据清洗 通用导入表数据
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsertConvert2')"
)
@PostMapping
(
"/addInsertConvert2"
)
public
AjaxResult
addInsertConvert2
(
@RequestBody
List
<
ActOperation1
>
actOperation2s
)
{
actSuppliesHistorydataService
.
addInsertConvert2
(
actOperation2s
);
return
toAjax
(
1
);
}
}
ruoyi-supplies/src/main/java/com/ruoyi/system/domain/ActSuppliesHistorydata.java
View file @
a9907806
...
...
@@ -59,6 +59,9 @@ public class ActSuppliesHistorydata extends BaseEntity
@Excel
(
name
=
"状态"
)
private
Long
status
;
/** 通用or六矿 */
private
Long
tylkStatus
;
/** 是否清洗 */
private
Long
cleanStatus
;
...
...
@@ -170,6 +173,14 @@ public class ActSuppliesHistorydata extends BaseEntity
return
status
;
}
public
Long
getTylkStatus
()
{
return
tylkStatus
;
}
public
void
setTylkStatus
(
Long
tylkStatus
)
{
this
.
tylkStatus
=
tylkStatus
;
}
public
Long
getCleanStatus
()
{
return
cleanStatus
;
}
...
...
ruoyi-supplies/src/main/java/com/ruoyi/system/mapper/ActSuppliesCleaningRuleMapper.java
View file @
a9907806
...
...
@@ -23,4 +23,8 @@ public interface ActSuppliesCleaningRuleMapper
int
deleteActSuppliesSixMinesSummaryTable
(
Long
hId
);
int
deleteActSuppliesImportTable
(
Long
hId
);
void
addInsertConvert1
(
ActSuppliesImportTable
actSuppliesImportTable
);
void
addInsertConvert2
(
ActSuppliesImportTable
actSuppliesImportTable
);
}
ruoyi-supplies/src/main/java/com/ruoyi/system/mapper/ActSuppliesHistorydataMapper.java
View file @
a9907806
...
...
@@ -66,12 +66,13 @@ public interface ActSuppliesHistorydataMapper
void
insertActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata1
);
void
updateActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata
);
/**
* 获取所有历史数据
*
* @return 结果
*/
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
(
Integer
tylkStatus
);
int
updateActSuppliesHistorydataStatusById
(
Long
gethId
);
}
ruoyi-supplies/src/main/java/com/ruoyi/system/service/IActSuppliesHistorydataService.java
View file @
a9907806
...
...
@@ -67,7 +67,7 @@ public interface IActSuppliesHistorydataService
*
* @return 结果
*/
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
(
Integer
tylkStatus
);
/**
* 修改历史数据通过id
*
...
...
@@ -78,4 +78,8 @@ public interface IActSuppliesHistorydataService
void
addInsertImport
(
List
<
ActOperation1
>
actOperation2s
);
void
addInsertImportss
(
List
<
ActOperation1
>
actOperation2s
);
void
addInsertConvert1
(
List
<
ActOperation1
>
actOperation2s
);
void
addInsertConvert2
(
List
<
ActOperation1
>
actOperation2s
);
}
ruoyi-supplies/src/main/java/com/ruoyi/system/service/impl/ActSuppliesHistorydataServiceImpl.java
View file @
a9907806
This diff is collapsed.
Click to expand it.
ruoyi-supplies/src/main/resources/mapper/system/ActSuppliesCleaningRuleMapper.xml
View file @
a9907806
This diff is collapsed.
Click to expand it.
ruoyi-supplies/src/main/resources/mapper/system/ActSuppliesHistorydataMapper.xml
View file @
a9907806
...
...
@@ -16,6 +16,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"historyContent"
column=
"history_content"
/>
<result
property=
"identifyingCode"
column=
"identifying_code"
/>
<result
property=
"cleanStatus"
column=
"clean_status"
/>
<result
property=
"tylkStatus"
column=
"tylk_status"
/>
<result
property=
"status"
column=
"status"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
...
...
@@ -60,6 +61,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
history_content,
</if>
<if
test=
"identifyingCode != null"
>
identifying_code,
</if>
clean_status,
<if
test=
"tylkStatus != null"
>
tylk_status,
</if>
<if
test=
"status != null"
>
status,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
...
...
@@ -75,6 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
#{historyContent},
</if>
<if
test=
"identifyingCode != null"
>
#{identifyingCode},
</if>
0,
<if
test=
"tylkStatus != null"
>
#{tylkStatus},
</if>
<if
test=
"status != null"
>
#{status},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
...
...
@@ -133,6 +136,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
history_content = #{historyContent},
</if>
<if
test=
"identifyingCode != null"
>
identifying_code = #{identifyingCode},
</if>
clean_status = 0,
<if
test=
"tylkStatus != null"
>
tylk_status = #{tylkStatus},
</if>
<if
test=
"status != null"
>
status = #{status},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
...
...
@@ -147,17 +151,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
</update>
<select
id=
"selectActSuppliesHistorydata"
resultMap=
"ActSuppliesHistorydataResult"
>
<select
id=
"selectActSuppliesHistorydata"
parameterType=
"java.lang.Integer"
resultMap=
"ActSuppliesHistorydataResult"
>
<include
refid=
"selectActSuppliesHistorydataVo"
/>
where clean_status = 0
where clean_status = 0
and tylk_status =#{tylkStatus}
</select>
<update
id=
"updateActSuppliesHistorydataStatusById"
parameterType=
"java.lang.Long"
>
update act_supplies_historydata
set clean_status = 1
<where>
<if
test=
"hId != null"
>
and id = #{hId}
</if>
<if
test=
"gethId != null"
>
and id = #{gethId}
</if>
</where>
</update>
</mapper>
...
...
ruoyi-ui/src/api/Actsupplies/cleaning_rule.js
View file @
a9907806
import
request
from
'
@/utils/request
'
// 查询六矿汇总表数据
export
function
selectActSuppliesHistorydata
()
{
export
function
selectActSuppliesHistorydata
(
tylkStatus
)
{
return
request
({
url
:
'
/system/cleaningrule/queryAll
'
,
url
:
'
/system/cleaningrule/queryAll
/
'
+
tylkStatus
,
method
:
'
get
'
})
...
...
ruoyi-ui/src/api/system/historydata.js
View file @
a9907806
...
...
@@ -79,3 +79,21 @@ export function addInsert2(data) {
data
:
data
})
}
// 数据清洗 历史数据
export
function
addInsertConvert1
(
data
)
{
return
request
({
url
:
'
/system/historydata/addInsertConvert1
'
,
method
:
'
post
'
,
data
:
data
})
}
// 数据清洗 历史数据
export
function
addInsertConvert2
(
data
)
{
return
request
({
url
:
'
/system/historydata/addInsertConvert2
'
,
method
:
'
post
'
,
data
:
data
})
}
ruoyi-ui/src/views/ActSuppliesConvert/convert/indexConvert.vue
View file @
a9907806
This diff is collapsed.
Click to expand it.
ruoyi-ui/src/views/system/supplies/index.vue
View file @
a9907806
...
...
@@ -1725,6 +1725,7 @@ export default {
this
.
dfrom
.
historyName
=
name
+
'
(导入文件)
'
;
this
.
dfrom
.
historyContent
=
str
;
this
.
dfrom
.
identifyingCode
=
0
;
this
.
dfrom
.
tylkStatus
=
1
;
let
date
=
new
Date
(
this
.
date
);
...
...
@@ -1739,6 +1740,8 @@ export default {
this
.
from
.
historyContent
=
strsheet
;
this
.
from
.
identifyingCode
=
1
;
this
.
from
.
date
=
datastr
;
this
.
from
.
tylkStatus
=
1
;
this
.
from
.
mining
=
this
.
mining
list
.
push
(
this
.
from
);
addInsert
(
list
).
then
(
response
=>
{
...
...
@@ -1756,7 +1759,7 @@ export default {
exportExcel
(
luckysheet
.
getAllSheets
(),
fileName
,
trueORfalse
);
// 清洗数据
selectActSuppliesHistorydata
().
then
(
response
=>
{
selectActSuppliesHistorydata
(
1
).
then
(
response
=>
{
var
data
=
response
.
data
;
let
list
=
[];
...
...
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