Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
E
ec-report-refactor
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
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
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lihuizhen
ec-report-refactor
Commits
4eeb712e
Commit
4eeb712e
authored
Oct 28, 2022
by
leon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:remove local storage
parent
37973c96
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
14 additions
and
12 deletions
+14
-12
HorizontalBar.vue
components/HorizontalBar/HorizontalBar.vue
+0
-1
LineMixBar.vue
components/LineMixBar/LineMixBar.vue
+0
-3
NormalLine.vue
components/NormalLine/NormalLine.vue
+0
-1
Table.vue
components/Table/Table.vue
+0
-2
details.vue
pages/details/details.vue
+0
-2
index.vue
pages/index/index.vue
+14
-3
No files found.
components/HorizontalBar/HorizontalBar.vue
View file @
4eeb712e
...
...
@@ -158,7 +158,6 @@
if
(
!
formatter
||
!
formatter
.
length
)
{
return
}
console
.
log
(
this
.
elementInfo
.
dataZoom
)
var
arr
=
[]
// 当前显示的label,formatter需要阻塞线程
var
all
=
[]
// 除当前显示label之外的值,formatter可以在异步线程请求处理
const
count
=
this
.
elementData
.
dataList
.
categories
.
length
...
...
components/LineMixBar/LineMixBar.vue
View file @
4eeb712e
...
...
@@ -171,7 +171,6 @@
}
})
})
console
.
log
(
all
)
// all的线程可以异步处理
all
.
forEach
(
item
=>
{
if
(
!
this
.
formatter
.
hasOwnProperty
(
item
.
value
))
{
...
...
@@ -187,7 +186,6 @@
})
}
})
console
.
log
(
this
.
formatter
)
},
/**
...
...
@@ -202,7 +200,6 @@
return
{
...
tooltip
,
formatter
:
(
val
,
ticket
,
callback
)
=>
{
console
.
log
(
val
)
const
params
=
{
script
:
tooltip
.
formatter
,
data
:
JSON
.
stringify
(
val
)
...
...
components/NormalLine/NormalLine.vue
View file @
4eeb712e
...
...
@@ -162,7 +162,6 @@
})
})
console
.
log
(
all
)
// all的线程可以异步处理
all
.
forEach
(
item
=>
{
if
(
!
this
.
formatter
.
hasOwnProperty
(
item
.
value
))
{
...
...
components/Table/Table.vue
View file @
4eeb712e
...
...
@@ -137,8 +137,6 @@
// that.cacheImages(item.dataIndex)
}
}
)
console
.
log
(
that
.
chartTables
)
console
.
log
(
that
.
elementInfo
.
table
.
column
)
}
)
}
,
cellClick
(
e
)
{
...
...
pages/details/details.vue
View file @
4eeb712e
...
...
@@ -106,7 +106,6 @@
this
.
pageSize
=
option
.
pageSize
//如果是最后一个元素,需要提前加载后面列表数据
if
(
this
.
indexs
==
this
.
idList
.
length
-
1
)
{
console
.
log
(
"xiayiye"
)
this
.
getReportIdList
()
}
this
.
getReportCharts
()
...
...
@@ -276,7 +275,6 @@
handlePage
()
{
var
idstr
=
this
.
idList
[
this
.
indexs
]
const
url
=
"/pages/details/details?id="
+
idstr
+
"&idList="
+
this
.
idList
console
.
log
(
url
)
uni
.
redirectTo
({
url
:
url
})
...
...
pages/index/index.vue
View file @
4eeb712e
...
...
@@ -104,9 +104,9 @@
// detail页面也会监听这两个事件,所有index页面需要在onShow里面增加监听,在onHide里面移除监听
onShow
()
{
const
that
=
this
if
(
uni
.
getStorageSync
(
'reportInfo'
))
{
this
.
reportInfo
=
JSON
.
parse
(
uni
.
getStorageSync
(
'reportInfo'
))
}
//
if(uni.getStorageSync('reportInfo')) {
//
this.reportInfo = JSON.parse(uni.getStorageSync('reportInfo'))
//
}
/**
* 组件交互 - 参数
*/
...
...
@@ -225,6 +225,17 @@
}
}
that
.
reportInfo
=
res
.
data
.
Result
// 清除数据
if
(
uni
.
getStorageSync
(
'reportInfo'
))
{
let
info
=
JSON
.
parse
(
uni
.
getStorageSync
(
'reportInfo'
))
info
.
list
.
forEach
(
item
=>
{
// 如果本地缓存的数组在接口请求的数组中不存在,则删除
if
(
!
that
.
reportInfo
.
list
.
some
(
idx
=>
idx
.
id
==
item
.
id
))
{
uni
.
removeStorageSync
(
item
.
id
)
}
})
}
uni
.
setStorageSync
(
'reportInfo'
,
JSON
.
stringify
(
res
.
data
.
Result
))
that
.
getStickyTables
()
}
...
...
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