Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
sun
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
1
Merge Requests
1
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
alpha
sun
Commits
7c2f2970
Commit
7c2f2970
authored
Jan 07, 2019
by
Davve
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加用户是否在线和用户下线相关逻辑 以及统一上下线推荐逻辑
parent
ba55ba85
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
85 additions
and
111 deletions
+85
-111
account.py
api/account.py
+3
-7
face_star.py
api/face_star.py
+3
-8
group.py
api/group.py
+2
-9
pick.py
api/pick.py
+2
-9
star.py
api/star.py
+2
-8
tag.py
api/tag.py
+4
-13
topic.py
api/topic.py
+3
-7
user.py
api/user.py
+1
-8
list.vue
vu/src/views/account/list.vue
+6
-3
list.vue
vu/src/views/face/list.vue
+6
-3
list.vue
vu/src/views/group/list.vue
+8
-4
list.vue
vu/src/views/pick/list.vue
+5
-2
list.vue
vu/src/views/star/list.vue
+6
-3
list.vue
vu/src/views/tag/list.vue
+6
-3
list.vue
vu/src/views/tag_type/list.vue
+6
-6
list.vue
vu/src/views/topic/list.vue
+6
-3
list.vue
vu/src/views/user/list.vue
+16
-15
No files found.
api/account.py
View file @
7c2f2970
...
...
@@ -2,6 +2,7 @@
# -*- coding: utf-8 -*-
# __author__ = "chenwei"
# Date: 2018/11/16
import
json
from
django.conf
import
settings
from
utils.base
import
APIView
from
utils.user_util
import
make_password_own
...
...
@@ -21,13 +22,8 @@ class AccountList(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
type
=
request
.
POST
.
get
(
'type'
,
''
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
0
else
:
updates
[
'is_online'
]
=
1
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/account/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/face_star.py
View file @
7c2f2970
...
...
@@ -3,6 +3,7 @@
# __author__ = "chenwei"
# Date: 2018/12/11
import
json
from
utils.base
import
APIView
from
utils.logger
import
error_logger
...
...
@@ -60,15 +61,9 @@ class StarListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
(
)
tp
=
request
.
POST
.
get
(
'type'
,
''
)
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
)
)
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
)
)
updates
=
{}
if
tp
==
'offline'
:
updates
[
'is_online'
]
=
0
else
:
updates
[
'is_online'
]
=
1
try
:
self
.
rpc
[
'mercury/face/batch/update'
](
ids
=
ids
,
updates
=
updates
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/group.py
View file @
7c2f2970
...
...
@@ -27,15 +27,8 @@ class GroupListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
type
=
request
.
POST
.
get
(
'type'
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
False
elif
type
==
'is_recommend'
:
updates
[
'is_recommend'
]
=
True
else
:
updates
[
'is_online'
]
=
True
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'updates'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/group/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/pick.py
View file @
7c2f2970
...
...
@@ -22,15 +22,8 @@ class PickListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
type
=
request
.
POST
.
get
(
'type'
,
''
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
0
else
:
updates
[
'is_online'
]
=
1
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/pick/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/star.py
View file @
7c2f2970
...
...
@@ -21,15 +21,9 @@ class CelebrityListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
(
)
type
=
request
.
POST
.
get
(
'type'
,
''
)
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
)
)
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
)
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
0
else
:
updates
[
'is_online'
]
=
1
try
:
self
.
rpc
[
'venus/sun/celebrity/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/tag.py
View file @
7c2f2970
...
...
@@ -21,13 +21,8 @@ class TagListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
type
=
request
.
POST
.
get
(
'type'
,
''
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
False
else
:
updates
[
'is_online'
]
=
True
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/tag/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
@@ -87,12 +82,8 @@ class TagTypeListView(APIView):
return
data
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
update
=
int
(
request
.
POST
.
get
(
'update'
,
''
))
updates
=
{
'is_online'
:
bool
(
update
)
}
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'updates'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/tag/tagtype/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
...
...
api/topic.py
View file @
7c2f2970
...
...
@@ -117,13 +117,9 @@ class ReplyCreate(APIView):
class
TopicListBatchUpdate
(
APIView
):
def
post
(
self
,
request
):
ids
=
request
.
POST
.
get
(
'ids'
,
''
)
.
split
()
type
=
request
.
POST
.
get
(
'type'
)
updates
=
{}
if
type
==
'offline'
:
updates
[
'is_online'
]
=
False
else
:
updates
[
'is_online'
]
=
True
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
updates
=
json
.
loads
(
request
.
POST
.
get
(
'update'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/topic/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
api/user.py
View file @
7c2f2970
...
...
@@ -27,14 +27,7 @@ class UserListView(APIView):
def
post
(
self
,
request
):
ids
=
json
.
loads
(
request
.
POST
.
get
(
'ids'
,
'[]'
))
type
=
request
.
POST
.
get
(
'type'
,
''
)
updates
=
{}
if
type
==
'recommend'
:
updates
[
'is_recommend'
]
=
1
else
:
pass
updates
=
json
.
loads
(
request
.
POST
.
get
(
'updates'
,
'{}'
))
try
:
self
.
rpc
[
'venus/sun/user/batch/update'
](
updates
=
updates
,
ids
=
ids
)
.
unwrap
()
except
Exception
as
e
:
...
...
vu/src/views/account/list.vue
View file @
7c2f2970
...
...
@@ -138,17 +138,20 @@
},
handleOfflineOrOnline
(
val
)
{
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
)
{
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
this
.
$router
.
go
(
0
)
...
...
vu/src/views/face/list.vue
View file @
7c2f2970
...
...
@@ -198,17 +198,20 @@ export default {
},
handleOfflineOrOnline
(
val
)
{
const
length
=
this
.
multipleSelection
.
length
let
str
=
''
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
)
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
)
{
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[]
this
.
$message
.
success
(
response
.
data
.
data
.
message
)
this
.
$router
.
go
(
0
)
...
...
vu/src/views/group/list.vue
View file @
7c2f2970
...
...
@@ -172,20 +172,24 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
if
(
val
==
'is_recommend'
){
this
.
multipleSelection
[
i
].
is_recommend
=
1
this
.
multipleSelection
[
i
].
is_recommend
=
1
updates
[
'is_recommend'
]
=
1
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
...
...
vu/src/views/pick/list.vue
View file @
7c2f2970
...
...
@@ -149,17 +149,20 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
})
...
...
vu/src/views/star/list.vue
View file @
7c2f2970
...
...
@@ -130,17 +130,20 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
setTimeout
(()
=>
{
...
...
vu/src/views/tag/list.vue
View file @
7c2f2970
...
...
@@ -115,17 +115,20 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
})
...
...
vu/src/views/tag_type/list.vue
View file @
7c2f2970
...
...
@@ -114,20 +114,20 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
update
=
''
var
ids
=
[]
;
var
update
s
=
''
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
update
=
0
;
update
s
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
update
=
1
;
update
s
[
'is_online'
]
=
0
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
update
:
update
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
update
s
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
})
...
...
vu/src/views/topic/list.vue
View file @
7c2f2970
...
...
@@ -187,17 +187,20 @@ export default {
},
handleOfflineOrOnline
(
val
){
const
length
=
this
.
multipleSelection
.
length
;
let
str
=
''
;
var
ids
=
[]
var
updates
=
{}
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
){
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
str
+=
this
.
multipleSelection
[
i
].
id
+
' '
;
ids
.
push
(
this
.
multipleSelection
[
i
].
id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
str
}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
),
ids
:
JSON
.
stringify
(
ids
)
}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
this
.
$router
.
go
(
0
)
...
...
vu/src/views/user/list.vue
View file @
7c2f2970
...
...
@@ -11,9 +11,6 @@
style=
"width: 110px"
>
<el-option
v-for=
"item in UserTypeOptions"
:key=
"item.key"
:label=
"item.display_name"
:value=
"item.key"
/>
</el-select>
<!--
<el-select
v-model=
"listQuery.filter.group_type"
:placeholder=
"'组内身份'"
clearable
class=
"filter-item"
style=
"width: 110px"
>
-->
<!--
<el-option
v-for=
"item in IdentifyTypeOptions"
:key=
"item.key"
:label=
"item.display_name"
:value=
"item.key"
/>
-->
<!--
</el-select>
-->
<el-select
v-model=
"listQuery.filter.is_recommend"
:placeholder=
"'推荐'"
clearable
class=
"filter-item"
style=
"width: 100px"
>
<el-option
v-for=
"item in ReBooleanTypeOptions"
:key=
"item.key"
:label=
"item.display_name"
:value=
"item.key"
/>
...
...
@@ -25,6 +22,12 @@
<el-button
class=
"filter-item"
style=
"margin-left: 10px;"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"handleOfflineOrOnline('recommend')"
>
推荐
</el-button>
<el-button
class=
"filter-item"
style=
"margin-left: 10px;"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"handleOfflineOrOnline('offline')"
>
下线
</el-button>
<el-button
class=
"filter-item"
style=
"margin-left: 10px;"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"handleOfflineOrOnline('online')"
>
上线
</el-button>
</div>
<el-table
v-loading=
"listLoading"
:data=
"list"
border
fit
highlight-current-row
style=
"width: 100%"
ref=
"multipleTable"
@
selection-change=
"handleSelectionChange"
>
...
...
@@ -50,9 +53,9 @@
</
template
>
</el-table-column>
<el-table-column
align=
"center"
label=
"
联系电话
"
>
<el-table-column
align=
"center"
label=
"
是否在线
"
>
<
template
slot-scope=
"scope"
>
<
span>
{{
scope
.
row
.
phone
}}
</span
>
<
el-tag
:type=
"scope.row.is_online | isOnlineFilter"
>
{{
scope
.
row
.
is_online
==
true
?
'是'
:
'否'
}}
</el-tag
>
</
template
>
</el-table-column>
...
...
@@ -79,12 +82,6 @@
</
template
>
</el-table-column>
<!--<el-table-column width="150px" align="center" label="组内身份">-->
<!--<template slot-scope="scope">-->
<!--<span>{{ scope.row.group_identify }}</span>-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column
align=
"center"
label=
"用户身份"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
user_identify
}}
</span>
...
...
@@ -93,7 +90,7 @@
<el-table-column
align=
"center"
label=
"是否推荐"
>
<
template
slot-scope=
"scope"
>
<el-tag
:type=
"scope.row.is_recommend | isOnlineFilter"
>
{{
scope
.
row
.
is_recommend
==
1
?
'是'
:
'否'
}}
</el-tag>
<el-tag
:type=
"scope.row.is_recommend | isOnlineFilter"
>
{{
scope
.
row
.
is_recommend
==
true
?
'是'
:
'否'
}}
</el-tag>
</
template
>
</el-table-column>
is_recommend
...
...
@@ -118,8 +115,8 @@
filters
:
{
isOnlineFilter
(
status
)
{
const
statusMap
=
{
1
:
'success'
,
0
:
'info'
,
true
:
'success'
,
false
:
'info'
,
}
return
statusMap
[
status
]
},
...
...
@@ -205,18 +202,22 @@
handleOfflineOrOnline
(
val
)
{
const
length
=
this
.
multipleSelection
.
length
;
var
ids
=
[];
var
updates
=
{};
this
.
del_list
=
this
.
del_list
.
concat
(
this
.
multipleSelection
);
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
if
(
val
===
'offline'
)
{
this
.
multipleSelection
[
i
].
is_online
=
0
updates
[
'is_online'
]
=
0
}
else
if
(
val
===
'recommend'
)
{
this
.
multipleSelection
[
i
].
is_recommend
=
0
updates
[
'is_recommend'
]
=
0
}
else
{
this
.
multipleSelection
[
i
].
is_online
=
1
updates
[
'is_online'
]
=
1
}
ids
.
push
(
this
.
multipleSelection
[
i
].
user_id
)
}
OffLineOrOnLine
({
type
:
val
,
ids
:
JSON
.
stringify
(
ids
)}).
then
(
response
=>
{
OffLineOrOnLine
({
updates
:
JSON
.
stringify
(
updates
)
,
ids
:
JSON
.
stringify
(
ids
)}).
then
(
response
=>
{
this
.
multipleSelection
=
[];
this
.
$message
.
success
(
response
.
data
.
data
.
message
);
setTimeout
(()
=>
{
...
...
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