Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
schedule
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
fengzhaoyu
schedule
Commits
23c8a1a4
Commit
23c8a1a4
authored
Apr 20, 2020
by
xiexiaoqin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
线上地址
parent
48fe10cc
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
71 deletions
+5
-71
binding.js
api/binding.js
+0
-66
app.js
app.js
+4
-4
index.js
pages/index/index.js
+1
-1
No files found.
api/binding.js
deleted
100644 → 0
View file @
48fe10cc
import
{
login
}
from
"./login"
;
export
default
function
http
(
data
)
{
if
(
getApp
().
globalData
.
token
!==
""
)
{
return
new
Promise
((
resolve
,
rejects
)
=>
{
dd
.
httpRequest
({
headers
:
{
"Content-Type"
:
"application/json;charset=UTF-8"
,
Authorization
:
`Bearer
${
getApp
().
globalData
.
token
}
`
},
url
:
`
${
getApp
().
globalData
.
globalUrl2
}${
data
.
url
}
`
,
method
:
data
.
method
,
dataType
:
"json"
,
data
:
data
.
data
,
success
:
function
(
res
)
{
if
(
res
.
data
.
code
==
0
)
{
resolve
(
res
);
}
else
{
dd
.
alert
({
content
:
"网络异常"
,
buttonText
:
"确定"
});
}
},
fail
:
function
(
res
)
{
dd
.
alert
({
content
:
"网络异常"
,
buttonText
:
"确定"
});
rejects
(
res
);
}
});
});
}
else
{
return
new
Promise
((
resolve
,
rejects
)
=>
{
login
().
then
(
res
=>
{
// const { oapiUser } = res.data.data;
// getApp().globalData.token = res.data.data.accessToken.access_token;
// getApp().globalData.name = res.data.data.oapiUser.name;
// getApp().globalData.userid = res.data.data.oapiUser.userid;
// getApp().globalData.avatar = res.data.data.oapiUser.avatar;
// getApp().globalData.userInfo = JSON.stringify({
// username: oapiUser.name,
// userId: oapiUser.userid,
// headUrl: oapiUser.avatar,
// platform: "dingtalk"
// });
dd
.
httpRequest
({
headers
:
{
"Content-Type"
:
"application/json"
,
Authorization
:
`Bearer
${
getApp
().
globalData
.
token
}
`
},
url
:
`
${
getApp
().
globalData
.
globalUrl
}${
data
.
url
}
`
,
method
:
data
.
method
,
data
:
data
.
data
,
dataType
:
"json"
,
success
:
function
(
res
)
{
resolve
(
res
);
},
fail
:
function
(
res
)
{
rejects
(
res
);
}
});
});
});
}
}
app.js
View file @
23c8a1a4
...
@@ -23,9 +23,9 @@ App({
...
@@ -23,9 +23,9 @@ App({
userid
:
""
,
userid
:
""
,
name
:
""
,
name
:
""
,
userInfo
:
""
,
userInfo
:
""
,
globalUrl
:
"https://gateway-beta.mingwork.com"
,
//beta地址
//
globalUrl: "https://gateway-beta.mingwork.com", //beta地址
globalUrl2
:
"https://third-authentication-beta.mingwork.com"
//
globalUrl2: "https://third-authentication-beta.mingwork.com"
//
globalUrl: "https://gateway2.mingwork.com", // 线上地址
globalUrl
:
"https://gateway2.mingwork.com"
,
// 线上地址
// globalUrl2: "https://third-authentication.mingwork.com" //beta
地址
globalUrl2
:
"https://third-authentication.mingwork.com"
//线上
地址
}
}
});
});
pages/index/index.js
View file @
23c8a1a4
...
@@ -782,7 +782,7 @@ create.Page({
...
@@ -782,7 +782,7 @@ create.Page({
maxClickCount
--
;
maxClickCount
--
;
if
(
maxClickCount
==
0
)
{
if
(
maxClickCount
==
0
)
{
dd
.
alert
({
dd
.
alert
({
content
:
"版本号22
0
"
content
:
"版本号22
2
"
});
});
maxClickCount
=
5
;
maxClickCount
=
5
;
}
}
...
...
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