Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
html
/
poolin_app
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Wiki
Members
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
3cfdebab
authored
Feb 04, 2018
by
zhanghui1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完善矿机列表一期需求
parent
2d57f0de
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
125 additions
and
100 deletions
+125
-100
package-lock.json
+45
-31
src/components/Miners/index.vue
+72
-61
src/main.js
+1
-1
src/utils/function.js
+7
-7
No files found.
package-lock.json
View file @
3cfdebab
{
{
"name"
:
"poolin_app"
,
"name"
:
"poolin_app
_new
"
,
"version"
:
"1.0.0"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"requires"
:
true
,
"dependencies"
:
{
"dependencies"
:
{
"@tweenjs/tween.js"
:
{
"version"
:
"17.2.0"
,
"resolved"
:
"https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-17.2.0.tgz"
,
"integrity"
:
"sha1-IfibcJuvxLMDra56g7TzWg2eR5Y="
},
"accepts"
:
{
"accepts"
:
{
"version"
:
"1.3.4"
,
"version"
:
"1.3.4"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.4.tgz"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.4.tgz"
,
...
@@ -72,6 +77,11 @@
...
@@ -72,6 +77,11 @@
"integrity"
:
"sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM="
,
"integrity"
:
"sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM="
,
"dev"
:
true
"dev"
:
true
},
},
"animate.css"
:
{
"version"
:
"3.5.2"
,
"resolved"
:
"https://registry.npmjs.org/animate.css/-/animate.css-3.5.2.tgz"
,
"integrity"
:
"sha1-keZo3AaagI5eSZUUhnuXquAWbDY="
},
"ansi-html"
:
{
"ansi-html"
:
{
"version"
:
"0.0.7"
,
"version"
:
"0.0.7"
,
"resolved"
:
"https://registry.npmjs.org/ansi-html/-/ansi-html-0.0.7.tgz"
,
"resolved"
:
"https://registry.npmjs.org/ansi-html/-/ansi-html-0.0.7.tgz"
,
...
@@ -2623,11 +2633,18 @@
...
@@ -2623,11 +2633,18 @@
}
}
},
},
"echarts"
:
{
"echarts"
:
{
"version"
:
"
3.8.5
"
,
"version"
:
"
4.0.2
"
,
"resolved"
:
"https://registry.npmjs.org/echarts/-/echarts-
3.8.5
.tgz"
,
"resolved"
:
"https://registry.npmjs.org/echarts/-/echarts-
4.0.2
.tgz"
,
"integrity"
:
"sha512-
E+nnROMfCeiLeoT/fZyX8SE8mKzwkTjyemyoBF543oqjRtjTSKQAVDEihMXy4oC6pJS0tYGdMqCA2ATk8onyRg
=="
,
"integrity"
:
"sha512-
2kLhHvSAVbJ6QYVDxuySFp/+LfJxlYTYyPaOfwqydiFMAL9Wx7jzarfR1P4P6DFzLCZi4U4mv6EcZhH9BantKQ
=="
,
"requires"
:
{
"requires"
:
{
"zrender"
:
"3.7.4"
"zrender"
:
"4.0.1"
},
"dependencies"
:
{
"zrender"
:
{
"version"
:
"4.0.1"
,
"resolved"
:
"https://registry.npmjs.org/zrender/-/zrender-4.0.1.tgz"
,
"integrity"
:
"sha512-VC9bTAZwd5OVgryysxBgNvIZuwBsRJbIDkSyK9PAk7e9wE/M0k4R3eylVYc1IAcDXvccSFnj4/NkzCteh/YSpA=="
}
}
}
},
},
"ee-first"
:
{
"ee-first"
:
{
...
@@ -2657,14 +2674,6 @@
...
@@ -2657,14 +2674,6 @@
"electron-releases"
:
"2.1.0"
"electron-releases"
:
"2.1.0"
}
}
},
},
"element-resize-detector"
:
{
"version"
:
"1.1.12"
,
"resolved"
:
"https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.1.12.tgz"
,
"integrity"
:
"sha1-iz/W7t2hf5wAs2Cg6i35knroC6I="
,
"requires"
:
{
"batch-processor"
:
"1.0.0"
}
},
"element-ui"
:
{
"element-ui"
:
{
"version"
:
"2.0.11"
,
"version"
:
"2.0.11"
,
"resolved"
:
"https://registry.npmjs.org/element-ui/-/element-ui-2.0.11.tgz"
,
"resolved"
:
"https://registry.npmjs.org/element-ui/-/element-ui-2.0.11.tgz"
,
...
@@ -4444,11 +4453,6 @@
...
@@ -4444,11 +4453,6 @@
"integrity"
:
"sha1-soqmKIorn8ZRA1x3EfZathkDMaY="
,
"integrity"
:
"sha1-soqmKIorn8ZRA1x3EfZathkDMaY="
,
"dev"
:
true
"dev"
:
true
},
},
"lodash.debounce"
:
{
"version"
:
"4.0.8"
,
"resolved"
:
"https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz"
,
"integrity"
:
"sha1-gteb/zCmfEAF/9XiUVMArZyk168="
},
"lodash.memoize"
:
{
"lodash.memoize"
:
{
"version"
:
"4.1.2"
,
"version"
:
"4.1.2"
,
"resolved"
:
"https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz"
,
"resolved"
:
"https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz"
,
...
@@ -8998,9 +9002,9 @@
...
@@ -8998,9 +9002,9 @@
"integrity"
:
"sha512-3D+lY7HTkKbtswDM4BBHgqyq+qo8IAEE8lz8va1dz3LLmttjgo0FxairO4r1iN2OBqk8o1FyL4hvzzTFEdQSEw=="
"integrity"
:
"sha512-3D+lY7HTkKbtswDM4BBHgqyq+qo8IAEE8lz8va1dz3LLmttjgo0FxairO4r1iN2OBqk8o1FyL4hvzzTFEdQSEw=="
},
},
"vue-awesome-swiper"
:
{
"vue-awesome-swiper"
:
{
"version"
:
"3.1.
0
"
,
"version"
:
"3.1.
2
"
,
"resolved"
:
"https://registry.npmjs.org/vue-awesome-swiper/-/vue-awesome-swiper-3.1.
0
.tgz"
,
"resolved"
:
"https://registry.npmjs.org/vue-awesome-swiper/-/vue-awesome-swiper-3.1.
2
.tgz"
,
"integrity"
:
"sha512-
w81WiG7Hh51ygtuZyDgnQ0lHOmrAMObWLLWj2kExUj1WaRQZJSfMG54SuL0zSHXzojVnqbwaVzh4loywibiryA
=="
,
"integrity"
:
"sha512-
A0ZrKo0JM0jltb4bz33l3pOKfaIMJiKI+74OzeCc7rQi6gYCoZQsAc3wn1iT64VlkwqtmiN9a1s5dEUoxcbwSg
=="
,
"requires"
:
{
"requires"
:
{
"object-assign"
:
"4.1.1"
,
"object-assign"
:
"4.1.1"
,
"swiper"
:
"4.0.7"
"swiper"
:
"4.0.7"
...
@@ -9016,12 +9020,27 @@
...
@@ -9016,12 +9020,27 @@
}
}
},
},
"vue-echarts-v3"
:
{
"vue-echarts-v3"
:
{
"version"
:
"1.0.18"
,
"version"
:
"1.0.19"
,
"resolved"
:
"https://registry.npmjs.org/vue-echarts-v3/-/vue-echarts-v3-1.0.18.tgz"
,
"resolved"
:
"https://registry.npmjs.org/vue-echarts-v3/-/vue-echarts-v3-1.0.19.tgz"
,
"integrity"
:
"sha512-Kz6NT5lWJSUBqTKxgCFrnB2ujHKREbI8rWWrq6bm2mcPk3Cj+ukdMfgjcSAEAr2UKcLXXo0DKnLVUddE0cWRJA=="
,
"integrity"
:
"sha512-BjHsJ069q/B+Py7ZwPhGpQKak8nCJR1eYCZFI3hG9aeifGxcW9pWnaSbFjhh4TF1UtKKGF33x+v9xdR1fyLh9A=="
,
"requires"
:
{
"element-resize-detector"
:
"1.1.13"
,
"lodash"
:
"4.17.5"
},
"dependencies"
:
{
"element-resize-detector"
:
{
"version"
:
"1.1.13"
,
"resolved"
:
"https://registry.npmjs.org/element-resize-detector/-/element-resize-detector-1.1.13.tgz"
,
"integrity"
:
"sha1-9hkH6YqRsa0hX5J5C8FRE99oRE0="
,
"requires"
:
{
"requires"
:
{
"element-resize-detector"
:
"1.1.12"
,
"batch-processor"
:
"1.0.0"
"lodash.debounce"
:
"4.0.8"
}
},
"lodash"
:
{
"version"
:
"4.17.5"
,
"resolved"
:
"https://registry.npmjs.org/lodash/-/lodash-4.17.5.tgz"
,
"integrity"
:
"sha512-svL3uiZf1RwhH+cWrfZn3A4+U58wbP0tGVTLQPbjplZxZ8ROD9VLuNgsRniTlLe7OlSqR79RUehXgpBW/s0IQw=="
}
}
}
},
},
"vue-hot-reload-api"
:
{
"vue-hot-reload-api"
:
{
...
@@ -9681,11 +9700,6 @@
...
@@ -9681,11 +9700,6 @@
"dev"
:
true
"dev"
:
true
}
}
}
}
},
"zrender"
:
{
"version"
:
"3.7.4"
,
"resolved"
:
"https://registry.npmjs.org/zrender/-/zrender-3.7.4.tgz"
,
"integrity"
:
"sha512-5Nz7+L1wIoL0+Pp/iOP56jD6eD017qC9VRSgUBheXBiAHgOBJZ4uh4/g6e83acIwa8RKSyZf/FlceKu5ntUuxQ=="
}
}
}
}
}
}
src/components/Miners/index.vue
View file @
3cfdebab
...
@@ -64,6 +64,19 @@ export default {
...
@@ -64,6 +64,19 @@ export default {
messageGroup
:
'全部'
,
messageGroup
:
'全部'
,
messageSort
:
'默认排序'
,
messageSort
:
'默认排序'
,
api
:
''
,
group_id
:
0
,
status
:
'ALL'
,
page_size
:
30
,
page
:
1
,
keyword
:
''
,
order_by
:
''
,
sort
:
''
,
workers_active
:
0
,
workers_dead
:
0
,
workers_inactive
:
0
,
i
:
0
,
i
:
0
,
tablist
:
[{
tablist
:
[{
text
:
'全部'
,
text
:
'全部'
,
...
@@ -78,22 +91,15 @@ export default {
...
@@ -78,22 +91,15 @@ export default {
text
:
'失效'
,
text
:
'失效'
,
status
:
'DEAD'
status
:
'DEAD'
}],
}],
workers_active
:
0
,
workers_dead
:
0
,
workers_inactive
:
0
,
order_by
:
''
,
sort
:
''
,
//asc
page
:
1
,
pagesize
:
30
,
sortArray
:
[{
sortArray
:
[{
name
:
'默认排序'
,
name
:
'默认排序'
,
method
:
()
=>
{
method
:
()
=>
{
this
.
messageSort
=
'默认排序'
;
this
.
messageSort
=
'默认排序'
;
// puid=78&status=ALL&order_by=worker_name&sort=desc&page=1&pagesize=30
//console.log(this.status)
console
.
log
(
this
.
status
)
this
.
order_by
=
''
;
this
.
order_by
=
''
;
this
.
sort
=
''
;
this
.
sort
=
''
;
this
.
tableData
=
[];
this
.
getWorker
();
this
.
getWorker
();
}
}
},
},
...
@@ -105,14 +111,8 @@ export default {
...
@@ -105,14 +111,8 @@ export default {
this
.
order_by
=
'shares_24h'
;
this
.
order_by
=
'shares_24h'
;
this
.
sort
=
'asc'
;
this
.
sort
=
'asc'
;
this
.
page
=
1
;
this
.
page
=
1
;
// console.log("排序参数api:",this.api);
this
.
tableData
=
[];
// console.log("排序参数puid:",this.puid);
this
.
sortWorker
();
// console.log("排序参数group_id:",this.group_id);
// console.log("排序参数status:",this.status);
// console.log("排序参数order_by:",this.order_by);
// console.log("排序参数page:",this.page);
// console.log("排序参数page_size:",this.page_size);
this
.
sortWorkder
();
}
}
},
},
{
{
...
@@ -123,7 +123,8 @@ export default {
...
@@ -123,7 +123,8 @@ export default {
this
.
order_by
=
'shares_24h'
;
this
.
order_by
=
'shares_24h'
;
this
.
sort
=
'desc'
;
this
.
sort
=
'desc'
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
sortWorkder
();
this
.
tableData
=
[];
this
.
sortWorker
();
}
}
},
},
{
{
...
@@ -134,7 +135,8 @@ export default {
...
@@ -134,7 +135,8 @@ export default {
this
.
order_by
=
'worker_name'
;
this
.
order_by
=
'worker_name'
;
this
.
sort
=
'desc'
;
this
.
sort
=
'desc'
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
sortWorkder
();
this
.
tableData
=
[];
this
.
sortWorker
();
}
}
},
},
{
{
...
@@ -145,7 +147,8 @@ export default {
...
@@ -145,7 +147,8 @@ export default {
this
.
order_by
=
'reject_rate'
;
this
.
order_by
=
'reject_rate'
;
this
.
sort
=
'desc'
;
this
.
sort
=
'desc'
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
sortWorkder
();
this
.
tableData
=
[];
this
.
sortWorker
();
}
}
},
},
{
{
...
@@ -156,7 +159,8 @@ export default {
...
@@ -156,7 +159,8 @@ export default {
this
.
order_by
=
'reject_rate'
;
this
.
order_by
=
'reject_rate'
;
this
.
sort
=
'asc'
;
this
.
sort
=
'asc'
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
sortWorkder
();
this
.
tableData
=
[];
this
.
sortWorker
();
}
}
},
},
{
{
...
@@ -167,15 +171,11 @@ export default {
...
@@ -167,15 +171,11 @@ export default {
this
.
order_by
=
'last_share_time'
;
this
.
order_by
=
'last_share_time'
;
this
.
sort
=
'desc'
;
this
.
sort
=
'desc'
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
sortWorkder
();
this
.
tableData
=
[];
this
.
sortWorker
();
}
}
}
}
],
],
api
:
''
,
group_id
:
0
,
status
:
'ALL'
,
page_size
:
30
,
page
:
1
,
tableData
:
[],
tableData
:
[],
}
}
},
},
...
@@ -201,17 +201,28 @@ export default {
...
@@ -201,17 +201,28 @@ export default {
this
.
getWorker
();
this
.
getWorker
();
},
},
methods
:
{
methods
:
{
goMinerShow
(
worker_id
)
{
getGroup
()
{
//矿机详情
this
.
showGroup
=
!
this
.
showGroup
;
this
.
$router
.
push
(
'/my/'
+
this
.
puid
+
'/'
+
this
.
coin_type
+
'/'
+
this
.
region_id
+
'/miners/'
+
worker_id
)
this
.
showSort
=
false
;
},
formGroup
(
msg
)
{
this
.
messageGroup
=
msg
.
group_name
;
this
.
showGroup
=
false
;
this
.
group_id
=
msg
.
group_id
;
this
.
status
=
msg
.
status
;
if
(
this
.
order_by
.
length
>
0
)
{
this
.
sortWorker
()
}
else
{
this
.
getWorker
()
}
},
},
tabClick
(
status
,
index
)
{
tabClick
(
status
,
index
)
{
//miners-tab点击切换的选中状态
this
.
$indicator
.
open
({
spinnerType
:
'fading-circle'
})
this
.
$indicator
.
open
({
spinnerType
:
'fading-circle'
})
this
.
status
=
status
;
this
.
status
=
status
;
this
.
page
=
1
;
this
.
page
=
1
;
this
.
tableData
=
[];
if
(
this
.
order_by
.
length
>
0
)
{
if
(
this
.
order_by
.
length
>
0
)
{
this
.
sortWork
d
er
();
this
.
sortWorker
();
}
else
{
}
else
{
this
.
getWorker
();
this
.
getWorker
();
}
}
...
@@ -220,34 +231,23 @@ export default {
...
@@ -220,34 +231,23 @@ export default {
this
.
showSort
=
!
this
.
showSort
;
this
.
showSort
=
!
this
.
showSort
;
this
.
showGroup
=
false
;
this
.
showGroup
=
false
;
},
},
getGroup
()
{
goMinerShow
(
worker_id
)
{
this
.
showGroup
=
!
this
.
showGroup
;
//矿机详情
this
.
showSort
=
false
;
this
.
$router
.
push
(
'/my/'
+
this
.
puid
+
'/'
+
this
.
coin_type
+
'/'
+
this
.
region_id
+
'/miners/'
+
worker_id
)
},
formGroup
(
msg
)
{
// console.log("切换分组信息:", msg)
this
.
messageGroup
=
msg
.
group_name
;
this
.
showGroup
=
false
;
this
.
group_id
=
msg
.
group_id
;
this
.
status
=
msg
.
status
;
if
(
this
.
order_by
.
length
>
0
)
{
this
.
sortWorkder
()
}
else
{
this
.
getWorker
()
}
},
},
getWorker
()
{
getWorker
()
{
//默认排序下的获取矿机列表
//默认排序下的获取矿机列表
let
self
=
this
;
let
self
=
this
;
fn
.
getApiBaseUrl
(
self
.
region_id
,
self
.
coin_type
).
then
(
api
=>
{
fn
.
getApiBaseUrl
(
self
.
region_id
,
self
.
coin_type
).
then
(
api
=>
{
this
.
api
=
api
;
this
.
api
=
api
;
fn
.
getWorker
(
api
,
self
.
puid
,
self
.
group_id
,
self
.
status
,
self
.
page_size
).
then
(
res
=>
{
fn
.
getWorker
(
api
,
self
.
puid
,
self
.
group_id
,
self
.
status
,
self
.
page_size
,
self
.
page
).
then
(
res
=>
{
if
(
res
.
data
.
err_no
==
0
)
{
if
(
res
.
data
.
err_no
==
0
)
{
//console.log("矿机列表", res.data.data.data)
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
self
.
tableData
=
res
.
data
.
data
.
data
;
self
.
tableData
=
self
.
tableData
.
concat
(
res
.
data
.
data
.
data
)
;
this
.
workers_active
=
res
.
data
.
data
.
workers_active
;
this
.
workers_active
=
res
.
data
.
data
.
workers_active
;
this
.
workers_dead
=
res
.
data
.
data
.
workers_dead
;
this
.
workers_dead
=
res
.
data
.
data
.
workers_dead
;
this
.
workers_inactive
=
res
.
data
.
data
.
workers_inactive
;
this
.
workers_inactive
=
res
.
data
.
data
.
workers_inactive
;
}
try
{
try
{
if
(
res
.
data
.
data
.
data
[
0
].
hasOwnProperty
(
"shares_24h"
))
{
if
(
res
.
data
.
data
.
data
[
0
].
hasOwnProperty
(
"shares_24h"
))
{
self
.
hideCol
=
1
;
self
.
hideCol
=
1
;
...
@@ -268,11 +268,14 @@ export default {
...
@@ -268,11 +268,14 @@ export default {
});
});
})
})
},
},
sortWork
d
er
()
{
sortWorker
()
{
//排序方法
//排序方法
fn
.
sortWorkder
(
this
.
api
,
this
.
puid
,
this
.
group_id
,
this
.
status
,
this
.
order_by
,
this
.
sort
,
this
.
page
,
this
.
page_size
).
then
(
res
=>
{
fn
.
sortWorker
(
this
.
api
,
this
.
puid
,
this
.
group_id
,
this
.
status
,
this
.
order_by
,
this
.
sort
,
this
.
page
,
this
.
page_size
).
then
(
res
=>
{
if
(
res
.
data
.
err_no
==
0
)
{
if
(
res
.
data
.
err_no
==
0
)
{
this
.
tableData
=
res
.
data
.
data
.
data
;
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
this
.
tableData
=
this
.
tableData
.
concat
(
res
.
data
.
data
.
data
);
}
}
else
{
}
else
{
this
.
$toast
(
"获取矿工列表列表错误!"
);
this
.
$toast
(
"获取矿工列表列表错误!"
);
}
}
...
@@ -285,18 +288,25 @@ export default {
...
@@ -285,18 +288,25 @@ export default {
pullingUp
()
{
pullingUp
()
{
this
.
search
(
this
.
page
+
1
)
this
.
getTableData
(
this
.
page
+
1
)
},
},
search
(
page
)
{
getTableData
(
page
)
{
fn
.
getPaymentHistory
(
this
.
api
,
this
.
puid
,
page
).
then
(
res
=>
{
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
this
.
page
=
page
;
this
.
page
=
page
;
this
.
paymentList
.
push
(
res
.
data
.
data
)
if
(
this
.
order_by
.
length
>
0
)
{
this
.
scroll
.
forceUpdate
(
true
)
this
.
sortWorker
(
)
}
else
{
}
else
{
this
.
scroll
.
forceUpdate
(
false
)
this
.
getWorker
(
)
}
}
})
this
.
scroll
.
forceUpdate
(
true
)
// fn.getPaymentHistory(this.api, this.puid, page).then(res => {
// if (res.data.data.data.length > 0) {
// this.page = page;
// this.paymentList.push(res.data.data)
// this.scroll.forceUpdate(true)
// } else {
// this.scroll.forceUpdate(false)
// }
// })
},
},
},
},
}
}
...
@@ -309,4 +319,5 @@ export default {
...
@@ -309,4 +319,5 @@ export default {
bottom
:
1rem
!important
;
bottom
:
1rem
!important
;
}
}
}
}
</
style
>
</
style
>
src/main.js
View file @
3cfdebab
...
@@ -48,7 +48,7 @@ axios.interceptors.request.use(config => {
...
@@ -48,7 +48,7 @@ axios.interceptors.request.use(config => {
function
checkToken
()
{
function
checkToken
()
{
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
resolve
(
'eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6IlEwTTBNRUl4UVRVME5qazJNa0ZFT0RCRk56WkJNVGc0TmtFd09UWkNOakZGTlRFMFEwVTJOdyJ9.eyJpc3MiOiJodHRwczovL2Jsb2NraW4uYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDU5ZjE3OTc5ZDljMGM1MzZiZjRhMzVjMSIsImF1ZCI6WyJodHRwczovL3d3dy5wb29saW4uY29tL2FwaSIsImh0dHBzOi8vYmxvY2tpbi5hdXRoMC5jb20vdXNlcmluZm8iXSwiaWF0IjoxNTE3N
TYzNDkwLCJleHAiOjE1MTc1NzA2OTAsImF6cCI6IkZhczI5dWJNNW52NElFMlZUQ3ZEWU5iaWtIeTF0bDBkIiwic2NvcGUiOiJvcGVuaWQgcHJvZmlsZSByZWFkIHdyaXRlIn0.SOvx6Bq09ZSGU57WtjfxiD2qCqevEsHOEl7caRGthcB-hECP3N0L0ugRop2f0ufOjJQYJU730XKi4IhxAExUcrIVYg8ztBL869NLLgJaOZMBosulQvYaE99KQR-j6EyKtQ2hQVDSsRzWg-vvF9axtTYNVGMcd8Mj3cGGJhYmZgtqQ9U5DF8o-FqwMUR4tGNZZPrRSX1CdtucbGQ0LTR5r0uq6XKHDNFd6RgdGYzSg0p8G4xj6ufDSXSU7hiabbxYmZ0hmPrQLvff6Xmw6wXqT1fub9di94e23sCEmKlcKuCLORqnNfNx_EFKZpAF7zm3bdWl2FAciUhi6X4nYBvqEA
'
);
resolve
(
'eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6IlEwTTBNRUl4UVRVME5qazJNa0ZFT0RCRk56WkJNVGc0TmtFd09UWkNOakZGTlRFMFEwVTJOdyJ9.eyJpc3MiOiJodHRwczovL2Jsb2NraW4uYXV0aDAuY29tLyIsInN1YiI6ImF1dGgwfDU5ZjE3OTc5ZDljMGM1MzZiZjRhMzVjMSIsImF1ZCI6WyJodHRwczovL3d3dy5wb29saW4uY29tL2FwaSIsImh0dHBzOi8vYmxvY2tpbi5hdXRoMC5jb20vdXNlcmluZm8iXSwiaWF0IjoxNTE3N
zIzMTI2LCJleHAiOjE1MTc3MzAzMjYsImF6cCI6IkZhczI5dWJNNW52NElFMlZUQ3ZEWU5iaWtIeTF0bDBkIiwic2NvcGUiOiJvcGVuaWQgcHJvZmlsZSByZWFkIHdyaXRlIn0.L2FKCnJVjwMo2urmfnnzFzzNDL2no_HKdMWKO9CBH7DGOh9SydTrugMhEUZKuB3M7QeZTcXuPVSsWcQ2FhrXNUyEsTXAK_SOrRL3Bn2jAzoWemasqs896hJRcLo3KshKVUTwAUR3x-bBKgK0qfm-owgF0a99P9pqFAtKVaG7VrVOPachvm10VyVF1egeA_bSWRbyIxrULsXFNz7JR_yq7TQzjnLYerB6DUD4gjwhyYRJjeZUej3PrKJs4P_ZIPxYCQijQmyFHWxX3_DaRfJZSj2tFSYpM2Ck6P1ZfpIVZPzad1S_sUZiy10K2o5Qzc1Ln540Dc4BG3NiYnDYn2Uy_g
'
);
})
})
}
}
...
...
src/utils/function.js
View file @
3cfdebab
...
@@ -493,12 +493,12 @@ export default {
...
@@ -493,12 +493,12 @@ export default {
* @param {[type]} status [description:ALL、ACTIVE、INACTIVE、DEAD]
* @param {[type]} status [description:ALL、ACTIVE、INACTIVE、DEAD]
* @return {[type]} [description]
* @return {[type]} [description]
*/
*/
getWorker
(
apiBaseUrl
,
puid
,
group
,
status
,
page_size
)
{
getWorker
(
apiBaseUrl
,
puid
,
group
,
status
,
page_size
,
page
)
{
//console.log("getWorker")
//console.log("getWorker")
if
(
group
==
0
)
{
if
(
group
==
0
)
{
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&status='
+
status
+
'&pagesize='
+
page_size
)
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&status='
+
status
+
'&pagesize='
+
page_size
+
'&page='
+
page
)
}
else
{
}
else
{
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&group='
+
group
+
'&status='
+
status
+
'&pagesize='
+
page_size
)
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&group='
+
group
+
'&status='
+
status
+
'&pagesize='
+
page_size
+
'&page='
+
page
)
}
}
// .then(res => { return mock.worker })
// .then(res => { return mock.worker })
},
},
...
@@ -512,12 +512,12 @@ export default {
...
@@ -512,12 +512,12 @@ export default {
* @param {[type]} keyword [description:关键词]
* @param {[type]} keyword [description:关键词]
* @return {[type]} [description]
* @return {[type]} [description]
*/
*/
searchWorker
(
apiBaseUrl
,
puid
,
group
,
keyword
,
page_size
)
{
searchWorker
(
apiBaseUrl
,
puid
,
group
,
keyword
,
page_size
,
page
)
{
//console.log("searchWorker")
//console.log("searchWorker")
if
(
group
==
0
)
{
if
(
group
==
0
)
{
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&keyword='
+
keyword
+
'&pagesize='
+
page_size
)
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&keyword='
+
keyword
+
'&pagesize='
+
page_size
+
'&page='
+
page
)
}
else
{
}
else
{
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&group='
+
group
+
'&keyword='
+
keyword
+
'&pagesize='
+
page_size
)
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&group='
+
group
+
'&keyword='
+
keyword
+
'&pagesize='
+
page_size
+
'&page='
+
page
)
}
}
},
},
/**
/**
...
@@ -532,7 +532,7 @@ export default {
...
@@ -532,7 +532,7 @@ export default {
* @param {[type]} sort [description:asc/desc]
* @param {[type]} sort [description:asc/desc]
* @return {[type]} [description]
* @return {[type]} [description]
*/
*/
sortWork
d
er
(
apiBaseUrl
,
puid
,
group
,
status
,
order_by
,
sort
,
page
,
page_size
)
{
sortWorker
(
apiBaseUrl
,
puid
,
group
,
status
,
order_by
,
sort
,
page
,
page_size
)
{
//console.log("sortWorkder")
//console.log("sortWorkder")
if
(
group
==
0
)
{
if
(
group
==
0
)
{
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&status='
+
status
+
'&order_by='
+
order_by
+
'&sort='
+
sort
+
'&page='
+
page
+
'&pagesize='
+
page_size
)
return
$axios
(
apiBaseUrl
+
'/worker?puid='
+
puid
+
'&status='
+
status
+
'&order_by='
+
order_by
+
'&sort='
+
sort
+
'&page='
+
page
+
'&pagesize='
+
page_size
)
...
...
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