Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
solo-1
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
solo-1
Commits
069d11a6
Commit
069d11a6
authored
Jul 08, 2017
by
Liang Ding
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🎨
升级 Lakte 2.3.13
parent
7d44435d
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
12 deletions
+11
-12
pom.xml
pom.xml
+2
-2
src/main/java/org/b3log/solo/Starter.java
src/main/java/org/b3log/solo/Starter.java
+1
-1
src/main/java/org/b3log/solo/dev/ArticleGenerator.java
src/main/java/org/b3log/solo/dev/ArticleGenerator.java
+1
-1
src/main/java/org/b3log/solo/processor/console/AdminConsole.java
...n/java/org/b3log/solo/processor/console/AdminConsole.java
+6
-7
src/main/java/org/b3log/solo/service/InitService.java
src/main/java/org/b3log/solo/service/InitService.java
+1
-1
No files found.
pom.xml
View file @
069d11a6
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<!--
<!--
Description: Solo POM.
Description: Solo POM.
Version: 3.17.1.4
1, Jun 27
, 2017
Version: 3.17.1.4
2, Jul 8
, 2017
Author: <a href="http://88250.b3log.org">Liang Ding</a>
Author: <a href="http://88250.b3log.org">Liang Ding</a>
Author: <a href="http://www.annpeter.cn">Ann Peter</a>
Author: <a href="http://www.annpeter.cn">Ann Peter</a>
Author: <a href="http://vanessa.b3log.org">Vanessa</a>
Author: <a href="http://vanessa.b3log.org">Vanessa</a>
...
@@ -74,7 +74,7 @@
...
@@ -74,7 +74,7 @@
<properties>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<org.b3log.latke.version>
2.3.1
2
</org.b3log.latke.version>
<org.b3log.latke.version>
2.3.1
3
</org.b3log.latke.version>
<servlet.version>
3.1.0
</servlet.version>
<servlet.version>
3.1.0
</servlet.version>
<slf4j.version>
1.7.5
</slf4j.version>
<slf4j.version>
1.7.5
</slf4j.version>
...
...
src/main/java/org/b3log/solo/Starter.java
View file @
069d11a6
...
@@ -138,7 +138,7 @@ public final class Starter {
...
@@ -138,7 +138,7 @@ public final class Starter {
Latkes
.
setStaticServerPort
(
staticServerPort
);
Latkes
.
setStaticServerPort
(
staticServerPort
);
String
runtimeMode
=
commandLine
.
getOptionValue
(
"runtime_mode"
);
String
runtimeMode
=
commandLine
.
getOptionValue
(
"runtime_mode"
);
if
(
null
!=
runtimeMode
)
{
if
(
null
!=
runtimeMode
)
{
Latkes
.
setRuntimeMode
(
RuntimeMode
.
valueOf
(
runtimeMode
));
Latkes
.
setRuntimeMode
(
Latkes
.
RuntimeMode
.
valueOf
(
runtimeMode
));
}
}
Latkes
.
setScanPath
(
"org.b3log.solo"
);
// For Latke IoC
Latkes
.
setScanPath
(
"org.b3log.solo"
);
// For Latke IoC
...
...
src/main/java/org/b3log/solo/dev/ArticleGenerator.java
View file @
069d11a6
...
@@ -77,7 +77,7 @@ public class ArticleGenerator {
...
@@ -77,7 +77,7 @@ public class ArticleGenerator {
@RequestProcessing
(
value
=
"/dev/articles/gen/*"
,
method
=
HTTPRequestMethod
.
GET
)
@RequestProcessing
(
value
=
"/dev/articles/gen/*"
,
method
=
HTTPRequestMethod
.
GET
)
public
void
genArticles
(
final
HTTPRequestContext
context
,
final
HttpServletRequest
request
,
final
HttpServletResponse
response
)
public
void
genArticles
(
final
HTTPRequestContext
context
,
final
HttpServletRequest
request
,
final
HttpServletResponse
response
)
throws
IOException
{
throws
IOException
{
if
(
RuntimeMode
.
DEVELOPMENT
!=
Latkes
.
getRuntimeMode
())
{
if
(
Latkes
.
RuntimeMode
.
DEVELOPMENT
!=
Latkes
.
getRuntimeMode
())
{
LOGGER
.
log
(
Level
.
WARN
,
"Article generation just for development mode, "
+
"current runtime mode is [{0}]"
,
LOGGER
.
log
(
Level
.
WARN
,
"Article generation just for development mode, "
+
"current runtime mode is [{0}]"
,
Latkes
.
getRuntimeMode
());
Latkes
.
getRuntimeMode
());
response
.
sendRedirect
(
Latkes
.
getServePath
());
response
.
sendRedirect
(
Latkes
.
getServePath
());
...
...
src/main/java/org/b3log/solo/processor/console/AdminConsole.java
View file @
069d11a6
...
@@ -233,8 +233,8 @@ public class AdminConsole {
...
@@ -233,8 +233,8 @@ public class AdminConsole {
final
Map
<
String
,
String
>
langs
=
langPropsService
.
getAll
(
locale
);
final
Map
<
String
,
String
>
langs
=
langPropsService
.
getAll
(
locale
);
final
Map
<
String
,
Object
>
dataModel
=
renderer
.
getDataModel
();
final
Map
<
String
,
Object
>
dataModel
=
renderer
.
getDataModel
();
dataModel
.
put
(
"supportExport"
,
RuntimeDatabase
.
MYSQL
==
Latkes
.
getRuntimeDatabase
()
dataModel
.
put
(
"supportExport"
,
Latkes
.
RuntimeDatabase
.
MYSQL
==
Latkes
.
getRuntimeDatabase
()
||
RuntimeDatabase
.
H2
==
Latkes
.
getRuntimeDatabase
());
||
Latkes
.
RuntimeDatabase
.
H2
==
Latkes
.
getRuntimeDatabase
());
dataModel
.
putAll
(
langs
);
dataModel
.
putAll
(
langs
);
Keys
.
fillRuntime
(
dataModel
);
Keys
.
fillRuntime
(
dataModel
);
dataModel
.
put
(
Option
.
ID_C_LOCALE_STRING
,
locale
.
toString
());
dataModel
.
put
(
Option
.
ID_C_LOCALE_STRING
,
locale
.
toString
());
...
@@ -310,9 +310,8 @@ public class AdminConsole {
...
@@ -310,9 +310,8 @@ public class AdminConsole {
return
;
return
;
}
}
final
RuntimeDatabase
runtimeDatabase
=
Latkes
.
getRuntimeDatabase
();
final
Latkes
.
RuntimeDatabase
runtimeDatabase
=
Latkes
.
getRuntimeDatabase
();
if
(
Latkes
.
RuntimeDatabase
.
H2
!=
runtimeDatabase
&&
Latkes
.
RuntimeDatabase
.
MYSQL
!=
runtimeDatabase
)
{
if
(
RuntimeDatabase
.
H2
!=
runtimeDatabase
&&
RuntimeDatabase
.
MYSQL
!=
runtimeDatabase
)
{
context
.
renderJSON
().
renderMsg
(
"Just support MySQL/H2 export now"
);
context
.
renderJSON
().
renderMsg
(
"Just support MySQL/H2 export now"
);
return
;
return
;
...
@@ -323,7 +322,7 @@ public class AdminConsole {
...
@@ -323,7 +322,7 @@ public class AdminConsole {
final
String
dbURL
=
Latkes
.
getLocalProperty
(
"jdbc.URL"
);
final
String
dbURL
=
Latkes
.
getLocalProperty
(
"jdbc.URL"
);
String
sql
;
// exported SQL script
String
sql
;
// exported SQL script
if
(
RuntimeDatabase
.
MYSQL
==
runtimeDatabase
)
{
if
(
Latkes
.
RuntimeDatabase
.
MYSQL
==
runtimeDatabase
)
{
String
db
=
StringUtils
.
substringAfterLast
(
dbURL
,
"/"
);
String
db
=
StringUtils
.
substringAfterLast
(
dbURL
,
"/"
);
db
=
StringUtils
.
substringBefore
(
db
,
"?"
);
db
=
StringUtils
.
substringBefore
(
db
,
"?"
);
...
@@ -339,7 +338,7 @@ public class AdminConsole {
...
@@ -339,7 +338,7 @@ public class AdminConsole {
return
;
return
;
}
}
}
else
if
(
RuntimeDatabase
.
H2
==
runtimeDatabase
)
{
}
else
if
(
Latkes
.
RuntimeDatabase
.
H2
==
runtimeDatabase
)
{
final
Connection
connection
=
Connections
.
getConnection
();
final
Connection
connection
=
Connections
.
getConnection
();
final
Statement
statement
=
connection
.
createStatement
();
final
Statement
statement
=
connection
.
createStatement
();
...
...
src/main/java/org/b3log/solo/service/InitService.java
View file @
069d11a6
...
@@ -204,7 +204,7 @@ public class InitService {
...
@@ -204,7 +204,7 @@ public class InitService {
LOGGER
.
log
(
Level
.
INFO
,
"Solo is running with database [{0}], creates all tables"
,
Latkes
.
getRuntimeDatabase
());
LOGGER
.
log
(
Level
.
INFO
,
"Solo is running with database [{0}], creates all tables"
,
Latkes
.
getRuntimeDatabase
());
if
(
RuntimeDatabase
.
H2
==
Latkes
.
getRuntimeDatabase
())
{
if
(
Latkes
.
RuntimeDatabase
.
H2
==
Latkes
.
getRuntimeDatabase
())
{
String
dataDir
=
Latkes
.
getLocalProperty
(
"jdbc.URL"
);
String
dataDir
=
Latkes
.
getLocalProperty
(
"jdbc.URL"
);
dataDir
=
dataDir
.
replace
(
"~"
,
System
.
getProperty
(
"user.home"
));
dataDir
=
dataDir
.
replace
(
"~"
,
System
.
getProperty
(
"user.home"
));
LOGGER
.
log
(
Level
.
INFO
,
"YOUR DATA will be stored in directory ["
+
dataDir
+
"], "
LOGGER
.
log
(
Level
.
INFO
,
"YOUR DATA will be stored in directory ["
+
dataDir
+
"], "
...
...
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