Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
h5-watch
Overview
Overview
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
苏文标
h5-watch
Commits
c9214edc
Commit
c9214edc
authored
Oct 19, 2022
by
suwenbiao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
处理冲突
parent
36315d54
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
289 additions
and
101 deletions
+289
-101
App.vue
App.vue
+4
-19
index.js
api/index.js
+15
-1
login.vue
components/login/login.vue
+270
-81
No files found.
App.vue
View file @
c9214edc
<
script
>
export
default
{
onLaunch
()
{
let
status
=
navigator
.
userAgent
.
toLowerCase
();
if
(
status
.
match
(
/MicroMessenger/i
)
==
"micromessenger"
)
{
//微信浏览器
uni
.
setStorageSync
(
'browser_type'
,
'1'
)
}
else
{
//其他浏览器
uni
.
setStorageSync
(
'browser_type'
,
'0'
)
if
(
window
.
location
.
href
.
slice
(
window
.
location
.
href
.
indexOf
(
'/'
,
10
)
+
1
,
9999
).
length
>
5
&&
window
.
location
.
href
.
indexOf
(
"&code="
==
-
1
)){
uni
.
setStorageSync
(
'room_id'
,
window
.
location
.
href
.
slice
(
window
.
location
.
href
.
indexOf
(
'/'
,
10
)
+
1
,
9999
))
window
.
location
.
href
=
window
.
location
.
href
.
slice
(
0
,
window
.
location
.
href
.
indexOf
(
'/'
,
10
));
}
},
onShow
()
{
...
...
@@ -21,18 +17,7 @@
<
style
>
/*每个页面公共css */
.contents
{
.contents
{
overflow-x
:
hidden
;
}
uni-scroll-view
.uni-scroll-view
::-webkit-scrollbar
{
/* 隐藏滚动条,但依旧具备可以滚动的功能 */
display
:
none
;
width
:
0
!important
;
height
:
0
!important
;
-webkit-appearance
:
none
;
background
:
transparent
;
color
:
transparent
;
}
</
style
>
api/index.js
View file @
c9214edc
...
...
@@ -246,7 +246,19 @@ function delwatchtype() {
return
request
(
'/LiveRoomWatchType/delWatchType'
,
"POST"
,
{
})
}
//获取appid
function
getappid
()
{
return
request
(
'/ocLogin/getAppid'
,
"GET"
,
{
})
}
//wx登录
function
loginbywx
(
code
)
{
return
request
(
'/ocLogin/loginByWx'
,
"GET"
,
{
code
})
}
export
default
{
loginbywx
,
sendsms
,
getverification
,
loginforphone
,
...
...
@@ -287,5 +299,6 @@ export default {
livechatinfo
,
livechecktoken
,
livewatchurl
,
delwatchtype
delwatchtype
,
getappid
}
\ No newline at end of file
components/login/login.vue
View file @
c9214edc
This diff is collapsed.
Click to expand it.
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