Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
L
luna
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
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
ops
luna
Commits
ae90036c
Unverified
Commit
ae90036c
authored
Feb 26, 2018
by
liuzheng712
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into test
parents
65f1bb37
7fa4d6b3
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
5 deletions
+5
-5
mock.py
mock.py
+2
-2
proxy.conf.json
proxy.conf.json
+1
-1
app.service.ts
src/app/app.service.ts
+1
-1
nav.component.ts
src/app/elements/nav/nav.component.ts
+1
-1
No files found.
mock.py
View file @
ae90036c
...
@@ -233,9 +233,9 @@ def replay():
...
@@ -233,9 +233,9 @@ def replay():
return
redirect
(
"http://jps.ilz.me/media/2017-12-24/ec87a486-0344-4f12-b27a-620321944f7f.gz"
)
return
redirect
(
"http://jps.ilz.me/media/2017-12-24/ec87a486-0344-4f12-b27a-620321944f7f.gz"
)
@app.route
(
'/i18n/<i18n>'
)
@app.route
(
'/
luna/
i18n/<i18n>'
)
def
i18n
(
i18n
):
def
i18n
(
i18n
):
return
send_file
(
'./i18n/'
+
i18n
+
'.json'
)
return
send_file
(
'./i18n/'
+
i18n
)
def
read_file
(
filename
,
charset
=
'utf-8'
):
def
read_file
(
filename
,
charset
=
'utf-8'
):
...
...
proxy.conf.json
View file @
ae90036c
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
"target"
:
"http://127.0.0.1:5000"
,
"target"
:
"http://127.0.0.1:5000"
,
"secure"
:
false
"secure"
:
false
},
},
"/i18n"
:
{
"/
luna/
i18n"
:
{
"target"
:
"http://127.0.0.1:5000"
,
"target"
:
"http://127.0.0.1:5000"
,
"secure"
:
false
"secure"
:
false
},
},
...
...
src/app/app.service.ts
View file @
ae90036c
...
@@ -198,7 +198,7 @@ export class AppService implements OnInit {
...
@@ -198,7 +198,7 @@ export class AppService implements OnInit {
}
}
if
(
this
.
lang
!==
'en'
)
{
if
(
this
.
lang
!==
'en'
)
{
this
.
_http
.
get
(
'/
i18n/'
+
this
.
lang
).
subscribe
(
this
.
_http
.
get
(
'/
luna/i18n/'
+
this
.
lang
+
'.json'
).
subscribe
(
data
=>
{
data
=>
{
this
.
_localStorage
.
set
(
'lang'
,
JSON
.
stringify
(
data
));
this
.
_localStorage
.
set
(
'lang'
,
JSON
.
stringify
(
data
));
}
}
...
...
src/app/elements/nav/nav.component.ts
View file @
ae90036c
...
@@ -280,7 +280,7 @@ export class ElementNavComponent implements OnInit {
...
@@ -280,7 +280,7 @@ export class ElementNavComponent implements OnInit {
}
}
Language
(
lan
:
string
)
{
Language
(
lan
:
string
)
{
this
.
_http
.
get
(
'/
i18n/'
+
lan
).
subscribe
(
this
.
_http
.
get
(
'/
luna/i18n/'
+
lan
+
'.json'
).
subscribe
(
data
=>
{
data
=>
{
this
.
_localStorage
.
set
(
'lang'
,
JSON
.
stringify
(
data
));
this
.
_localStorage
.
set
(
'lang'
,
JSON
.
stringify
(
data
));
}
}
...
...
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