Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Z
zeroing-editor
Project
Project
Details
Activity
Releases
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
劳工
zeroing-editor
Commits
f911b66d
Commit
f911b66d
authored
Jan 13, 2020
by
bianlongting
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
get test env ticket
parent
618f0629
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
project.js
src/api/project.js
+5
-1
ProjectxOptions.vue
src/views/Editor/dialogs/ProjectxOptions.vue
+12
-1
No files found.
src/api/project.js
View file @
f911b66d
...
@@ -123,9 +123,13 @@ export async function getProjectSkins(projectId, env) {
...
@@ -123,9 +123,13 @@ export async function getProjectSkins(projectId, env) {
params
:
{
params
:
{
cookie
:
{
cookie
:
{
dev
:
getCookie
(
'sso_ticket'
),
dev
:
getCookie
(
'sso_ticket'
),
test
:
getCookie
(
'test_
ticket'
),
test
:
localStorage
.
getItem
(
'
ticket'
),
prod
:
getCookie
(
'prod_ticket'
),
prod
:
getCookie
(
'prod_ticket'
),
}
}
}
}
})
})
}
export
async
function
getTestEnvTicket
()
{
return
await
fetchApi
(
`/polaris/getTestEnvTicket`
,
{
method
:
'get'
})
}
}
\ No newline at end of file
src/views/Editor/dialogs/ProjectxOptions.vue
View file @
f911b66d
...
@@ -62,7 +62,11 @@
...
@@ -62,7 +62,11 @@
<
script
>
<
script
>
import
{
mapState
}
from
"vuex"
;
import
{
mapState
}
from
"vuex"
;
import
copy
from
"copy-to-clipboard"
;
import
copy
from
"copy-to-clipboard"
;
import
{
getProjectSkins
,
saveSkins
}
from
"../../../../src/api/project"
;
import
{
getProjectSkins
,
saveSkins
,
getTestEnvTicket
}
from
"../../../../src/api/project"
;
export
default
{
export
default
{
name
:
"ProjectxOptions"
,
name
:
"ProjectxOptions"
,
props
:
{
props
:
{
...
@@ -200,6 +204,13 @@ export default {
...
@@ -200,6 +204,13 @@ export default {
const
projectId
=
projectxConfig
[
this
.
currentEnv
];
const
projectId
=
projectxConfig
[
this
.
currentEnv
];
this
.
projectId
=
projectId
;
this
.
projectId
=
projectId
;
this
.
getSkinsList
(
projectId
);
this
.
getSkinsList
(
projectId
);
},
async
created
()
{
let
ticket
=
localStorage
.
getItem
(
"ticket"
);
if
(
!
ticket
)
{
ticket
=
await
getTestEnvTicket
();
localStorage
.
setItem
(
"ticket"
,
ticket
);
}
}
}
};
};
</
script
>
</
script
>
...
...
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