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
Show 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
...
@@ -30,11 +30,11 @@ public class ActSuppliesCleaningRuleController extends BaseController
* 获取所有历史数据
* 获取所有历史数据
*/
*/
@PreAuthorize
(
"@ss.hasPermi('system:cleaningrule:queryAll')"
)
@PreAuthorize
(
"@ss.hasPermi('system:cleaningrule:queryAll')"
)
@GetMapping
(
"/queryAll"
)
@GetMapping
(
"/queryAll
/{tylkStatus}
"
)
public
AjaxResult
selectActSuppliesHistorydata
()
public
AjaxResult
selectActSuppliesHistorydata
(
@PathVariable
(
"tylkStatus"
)
Integer
tylkStatus
)
{
{
List
<
ActSuppliesHistorydata
>
s
=
actSuppliesHistorydataService
.
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
s
=
actSuppliesHistorydataService
.
selectActSuppliesHistorydata
(
tylkStatus
);
return
AjaxResult
.
success
(
s
);
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
...
@@ -115,7 +115,7 @@ public class ActSuppliesHistorydataController extends BaseController
}
}
/**
/**
* 数据清洗
历史数据 生成
* 数据清洗
六矿生成表数据
*/
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert1')"
)
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert1')"
)
@PostMapping
(
"/addInsert1"
)
@PostMapping
(
"/addInsert1"
)
...
@@ -127,7 +127,7 @@ public class ActSuppliesHistorydataController extends BaseController
...
@@ -127,7 +127,7 @@ public class ActSuppliesHistorydataController extends BaseController
}
}
/**
/**
* 数据清洗
历史数据 导入
* 数据清洗
六矿导入表数据
*/
*/
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert2')"
)
@PreAuthorize
(
"@ss.hasPermi('system:historydata:addInsert2')"
)
@PostMapping
(
"/addInsert2"
)
@PostMapping
(
"/addInsert2"
)
...
@@ -139,6 +139,31 @@ public class ActSuppliesHistorydataController extends BaseController
...
@@ -139,6 +139,31 @@ public class ActSuppliesHistorydataController extends BaseController
return
toAjax
(
1
);
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
...
@@ -59,6 +59,9 @@ public class ActSuppliesHistorydata extends BaseEntity
@Excel
(
name
=
"状态"
)
@Excel
(
name
=
"状态"
)
private
Long
status
;
private
Long
status
;
/** 通用or六矿 */
private
Long
tylkStatus
;
/** 是否清洗 */
/** 是否清洗 */
private
Long
cleanStatus
;
private
Long
cleanStatus
;
...
@@ -170,6 +173,14 @@ public class ActSuppliesHistorydata extends BaseEntity
...
@@ -170,6 +173,14 @@ public class ActSuppliesHistorydata extends BaseEntity
return
status
;
return
status
;
}
}
public
Long
getTylkStatus
()
{
return
tylkStatus
;
}
public
void
setTylkStatus
(
Long
tylkStatus
)
{
this
.
tylkStatus
=
tylkStatus
;
}
public
Long
getCleanStatus
()
{
public
Long
getCleanStatus
()
{
return
cleanStatus
;
return
cleanStatus
;
}
}
...
...
ruoyi-supplies/src/main/java/com/ruoyi/system/mapper/ActSuppliesCleaningRuleMapper.java
View file @
a9907806
...
@@ -23,4 +23,8 @@ public interface ActSuppliesCleaningRuleMapper
...
@@ -23,4 +23,8 @@ public interface ActSuppliesCleaningRuleMapper
int
deleteActSuppliesSixMinesSummaryTable
(
Long
hId
);
int
deleteActSuppliesSixMinesSummaryTable
(
Long
hId
);
int
deleteActSuppliesImportTable
(
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
...
@@ -66,12 +66,13 @@ public interface ActSuppliesHistorydataMapper
void
insertActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata1
);
void
insertActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata1
);
void
updateActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata
);
void
updateActSuppliesHistorydatas
(
ActSuppliesHistorydata
actSuppliesHistorydata
);
/**
/**
* 获取所有历史数据
* 获取所有历史数据
*
*
* @return 结果
* @return 结果
*/
*/
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
(
Integer
tylkStatus
);
int
updateActSuppliesHistorydataStatusById
(
Long
gethId
);
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
...
@@ -67,7 +67,7 @@ public interface IActSuppliesHistorydataService
*
*
* @return 结果
* @return 结果
*/
*/
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
();
List
<
ActSuppliesHistorydata
>
selectActSuppliesHistorydata
(
Integer
tylkStatus
);
/**
/**
* 修改历史数据通过id
* 修改历史数据通过id
*
*
...
@@ -78,4 +78,8 @@ public interface IActSuppliesHistorydataService
...
@@ -78,4 +78,8 @@ public interface IActSuppliesHistorydataService
void
addInsertImport
(
List
<
ActOperation1
>
actOperation2s
);
void
addInsertImport
(
List
<
ActOperation1
>
actOperation2s
);
void
addInsertImportss
(
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"
...
@@ -16,6 +16,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"historyContent"
column=
"history_content"
/>
<result
property=
"historyContent"
column=
"history_content"
/>
<result
property=
"identifyingCode"
column=
"identifying_code"
/>
<result
property=
"identifyingCode"
column=
"identifying_code"
/>
<result
property=
"cleanStatus"
column=
"clean_status"
/>
<result
property=
"cleanStatus"
column=
"clean_status"
/>
<result
property=
"tylkStatus"
column=
"tylk_status"
/>
<result
property=
"status"
column=
"status"
/>
<result
property=
"status"
column=
"status"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"createTime"
column=
"create_time"
/>
...
@@ -60,6 +61,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -60,6 +61,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
history_content,
</if>
<if
test=
"historyContent != null"
>
history_content,
</if>
<if
test=
"identifyingCode != null"
>
identifying_code,
</if>
<if
test=
"identifyingCode != null"
>
identifying_code,
</if>
clean_status,
clean_status,
<if
test=
"tylkStatus != null"
>
tylk_status,
</if>
<if
test=
"status != null"
>
status,
</if>
<if
test=
"status != null"
>
status,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
...
@@ -75,6 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -75,6 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
#{historyContent},
</if>
<if
test=
"historyContent != null"
>
#{historyContent},
</if>
<if
test=
"identifyingCode != null"
>
#{identifyingCode},
</if>
<if
test=
"identifyingCode != null"
>
#{identifyingCode},
</if>
0,
0,
<if
test=
"tylkStatus != null"
>
#{tylkStatus},
</if>
<if
test=
"status != null"
>
#{status},
</if>
<if
test=
"status != null"
>
#{status},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
...
@@ -133,6 +136,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -133,6 +136,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"historyContent != null"
>
history_content = #{historyContent},
</if>
<if
test=
"historyContent != null"
>
history_content = #{historyContent},
</if>
<if
test=
"identifyingCode != null"
>
identifying_code = #{identifyingCode},
</if>
<if
test=
"identifyingCode != null"
>
identifying_code = #{identifyingCode},
</if>
clean_status = 0,
clean_status = 0,
<if
test=
"tylkStatus != null"
>
tylk_status = #{tylkStatus},
</if>
<if
test=
"status != null"
>
status = #{status},
</if>
<if
test=
"status != null"
>
status = #{status},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
...
@@ -147,17 +151,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -147,17 +151,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
</where>
</update>
</update>
<select
id=
"selectActSuppliesHistorydata"
resultMap=
"ActSuppliesHistorydataResult"
>
<select
id=
"selectActSuppliesHistorydata"
parameterType=
"java.lang.Integer"
resultMap=
"ActSuppliesHistorydataResult"
>
<include
refid=
"selectActSuppliesHistorydataVo"
/>
<include
refid=
"selectActSuppliesHistorydataVo"
/>
where clean_status = 0
where clean_status = 0
and tylk_status =#{tylkStatus}
</select>
</select>
<update
id=
"updateActSuppliesHistorydataStatusById"
parameterType=
"java.lang.Long"
>
<update
id=
"updateActSuppliesHistorydataStatusById"
parameterType=
"java.lang.Long"
>
update act_supplies_historydata
update act_supplies_historydata
set clean_status = 1
set clean_status = 1
<where>
<where>
<if
test=
"hId != null"
>
and id = #{hId}
</if>
<if
test=
"gethId != null"
>
and id = #{gethId}
</if>
</where>
</where>
</update>
</update>
</mapper>
</mapper>
...
...
ruoyi-ui/src/api/Actsupplies/cleaning_rule.js
View file @
a9907806
import
request
from
'
@/utils/request
'
import
request
from
'
@/utils/request
'
// 查询六矿汇总表数据
// 查询六矿汇总表数据
export
function
selectActSuppliesHistorydata
()
{
export
function
selectActSuppliesHistorydata
(
tylkStatus
)
{
return
request
({
return
request
({
url
:
'
/system/cleaningrule/queryAll
'
,
url
:
'
/system/cleaningrule/queryAll
/
'
+
tylkStatus
,
method
:
'
get
'
method
:
'
get
'
})
})
...
...
ruoyi-ui/src/api/system/historydata.js
View file @
a9907806
...
@@ -79,3 +79,21 @@ export function addInsert2(data) {
...
@@ -79,3 +79,21 @@ export function addInsert2(data) {
data
:
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 {
...
@@ -1725,6 +1725,7 @@ export default {
this
.
dfrom
.
historyName
=
name
+
'
(导入文件)
'
;
this
.
dfrom
.
historyName
=
name
+
'
(导入文件)
'
;
this
.
dfrom
.
historyContent
=
str
;
this
.
dfrom
.
historyContent
=
str
;
this
.
dfrom
.
identifyingCode
=
0
;
this
.
dfrom
.
identifyingCode
=
0
;
this
.
dfrom
.
tylkStatus
=
1
;
let
date
=
new
Date
(
this
.
date
);
let
date
=
new
Date
(
this
.
date
);
...
@@ -1739,6 +1740,8 @@ export default {
...
@@ -1739,6 +1740,8 @@ export default {
this
.
from
.
historyContent
=
strsheet
;
this
.
from
.
historyContent
=
strsheet
;
this
.
from
.
identifyingCode
=
1
;
this
.
from
.
identifyingCode
=
1
;
this
.
from
.
date
=
datastr
;
this
.
from
.
date
=
datastr
;
this
.
from
.
tylkStatus
=
1
;
this
.
from
.
mining
=
this
.
mining
list
.
push
(
this
.
from
);
list
.
push
(
this
.
from
);
addInsert
(
list
).
then
(
response
=>
{
addInsert
(
list
).
then
(
response
=>
{
...
@@ -1756,7 +1759,7 @@ export default {
...
@@ -1756,7 +1759,7 @@ export default {
exportExcel
(
luckysheet
.
getAllSheets
(),
fileName
,
trueORfalse
);
exportExcel
(
luckysheet
.
getAllSheets
(),
fileName
,
trueORfalse
);
// 清洗数据
// 清洗数据
selectActSuppliesHistorydata
().
then
(
response
=>
{
selectActSuppliesHistorydata
(
1
).
then
(
response
=>
{
var
data
=
response
.
data
;
var
data
=
response
.
data
;
let
list
=
[];
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