Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
taskonsite-архив-перенесен
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dmitry Korolev
taskonsite-архив-перенесен
Commits
b735bb20
Commit
b735bb20
authored
Mar 13, 2019
by
john
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
3011
parent
a0747fa1
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
68 additions
and
11 deletions
+68
-11
backend/web/plugins/editormd/editormd.js
backend/web/plugins/editormd/editormd.js
+52
-4
common/modules/documentation/assets/src/js/documentation.js
common/modules/documentation/assets/src/js/documentation.js
+12
-0
common/modules/documentation/controllers/DocumentationAdminController.php
...ocumentation/controllers/DocumentationAdminController.php
+0
-3
frontend/web/.htaccess
frontend/web/.htaccess
+4
-4
No files found.
backend/web/plugins/editormd/editormd.js
View file @
b735bb20
...
...
@@ -159,6 +159,7 @@
tocStartLevel
:
1
,
// Said from H1 to create ToC
htmlDecode
:
false
,
// Open the HTML tag identification
pageBreak
:
true
,
// Enable parse page break [========]
carousel
:
true
,
// Enable parse page break [========]
atLink
:
true
,
// for @link
emailLink
:
true
,
// for email address auto link
taskList
:
false
,
// Enable Github Flavored Markdown task lists
...
...
@@ -1994,6 +1995,7 @@
tocm
:
settings
.
tocm
,
tocStartLevel
:
settings
.
tocStartLevel
,
pageBreak
:
settings
.
pageBreak
,
carousel
:
settings
.
carousel
,
taskList
:
settings
.
taskList
,
emoji
:
settings
.
emoji
,
tex
:
settings
.
tex
,
...
...
@@ -2914,6 +2916,11 @@
},
carousel
:
function
()
{
if
(
!
this
.
settings
.
carousel
)
{
alert
(
"
settings.carousel === false
"
);
return
this
;
}
var
cm
=
this
.
cm
;
var
cursor
=
cm
.
getCursor
();
var
selection
=
cm
.
getSelection
();
...
...
@@ -2921,12 +2928,12 @@
if
(
cursor
.
ch
!==
0
)
{
cm
.
setCursor
(
cursor
.
line
,
0
);
cm
.
replaceSelection
(
"
__CAROUSEL__
"
+
selection
);
cm
.
replaceSelection
(
"
¿¿¿CAROUSEL_BEGIN¿¿¿
\r\n
"
+
selection
+
"
\r\n
¿¿¿CAROUSEL_END¿¿¿
"
);
cm
.
setCursor
(
cursor
.
line
,
cursor
.
ch
+
2
);
}
else
{
cm
.
replaceSelection
(
"
__CAROUSEL__
"
+
selection
);
cm
.
replaceSelection
(
"
¿¿¿CAROUSEL_BEGIN¿¿¿
\r\n
"
+
selection
+
"
\r\n
¿¿¿CAROUSEL_END¿¿¿
"
);
}
},
h1
:
function
()
{
...
...
@@ -3378,7 +3385,8 @@
twemoji
:
/:
(
tw-
([\w]
+
)
-
?(\w
+
)?)
:/g
,
fontAwesome
:
/:
(
fa-
([\w]
+
)(
-
(\w
+
)){0,})
:/g
,
editormdLogo
:
/:
(
editormd-logo-
?(\w
+
)?)
:/g
,
pageBreak
:
/^
\[[
=
]{8,}\]
$/
pageBreak
:
/^
\[[
=
]{8,}\]
$/
,
carousel
:
/^
\[[
=
]{10,}\]
$/
};
// Emoji graphics files url path
...
...
@@ -3407,6 +3415,7 @@
tocm
:
false
,
tocStartLevel
:
1
,
// Said from H1 to create ToC
pageBreak
:
true
,
carousel
:
true
,
atLink
:
true
,
// for @link
emailLink
:
true
,
// for mail address auto link
taskList
:
false
,
// Enable Github Flavored Markdown task lists
...
...
@@ -3430,6 +3439,7 @@
var
faIconReg
=
regexs
.
fontAwesome
;
var
editormdLogoReg
=
regexs
.
editormdLogo
;
var
pageBreakReg
=
regexs
.
pageBreak
;
var
carouselReg
=
regexs
.
carousel
;
markedRenderer
.
emoji
=
function
(
text
)
{
...
...
@@ -3605,6 +3615,7 @@
};
markedRenderer
.
pageBreak
=
function
(
text
)
{
alert
(
text
)
if
(
pageBreakReg
.
test
(
text
)
&&
settings
.
pageBreak
)
{
text
=
"
<hr style=
\"
page-break-after:always;
\"
class=
\"
page-break editormd-page-break
\"
/>
"
;
...
...
@@ -3612,6 +3623,27 @@
return
text
;
};
markedRenderer
.
carousel
=
function
(
text
)
{
alert
(
text
)
// if (settings.carousel)
// {
// text = '\n\
// <div class=\"owl-carousel\" data-owl-carousel=\"{ "nav": true, "dots": true, "loop": true }\">\n\
// <figure><img src=\"img/blog/single/01.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// <figure><img src=\"img/blog/single/02.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// <figure><img src=\"img/blog/single/03.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// </div>\n\
//';
// }
return
text
;
};
markedRenderer
.
paragraph
=
function
(
text
)
{
var
isTeXInline
=
/
\$\$(
.*
)\$\$
/g
.
test
(
text
);
...
...
@@ -3630,7 +3662,21 @@
{
text
=
(
isTeXLine
)
?
text
.
replace
(
/
\$
/g
,
""
)
:
text
;
}
// textCarousel = '\n\
// <div class=\"owl-carousel\" data-owl-carousel=\"{ "nav": true, "dots": true, "loop": true }\">\n\
// <figure><img src=\"img/blog/single/01.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// <figure><img src=\"img/blog/single/02.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// <figure><img src=\"img/blog/single/03.jpg\" alt=\"Image\">\n\
// <figcaption class=\"text-white\">Image Caption</figcaption>\n\
// </figure>\n\
// </div>\n\
//';
text
=
text
.
replace
(
/¿¿¿CAROUSEL_BEGIN¿¿¿/g
,
'
<div class="owl-carousel owl-carousel-need-replace hidden" data-owl-carousel="{ "nav": true, "dots": true, "loop": true }">
'
);
text
=
text
.
replace
(
/¿¿¿CAROUSEL_END¿¿¿/g
,
'
</div>
'
);
var
tocHTML
=
"
<div class=
\"
markdown-toc editormd-markdown-toc
\"
>
"
+
text
+
"
</div>
"
;
return
(
isToC
)
?
(
(
isToCMenu
)
?
"
<div class=
\"
editormd-toc-menu
\"
>
"
+
tocHTML
+
"
</div><br/>
"
:
tocHTML
)
...
...
@@ -3924,6 +3970,7 @@
htmlDecode
:
false
,
autoLoadKaTeX
:
true
,
pageBreak
:
true
,
carousel
:
true
,
atLink
:
true
,
// for @link
emailLink
:
true
,
// for mail address auto link
tex
:
false
,
...
...
@@ -3957,6 +4004,7 @@
emoji
:
settings
.
emoji
,
tex
:
settings
.
tex
,
pageBreak
:
settings
.
pageBreak
,
carousel
:
settings
.
carousel
,
atLink
:
settings
.
atLink
,
// for @link
emailLink
:
settings
.
emailLink
,
// for mail address auto link
flowChart
:
settings
.
flowChart
,
...
...
common/modules/documentation/assets/src/js/documentation.js
View file @
b735bb20
$
(
function
()
{
$
(
'
.owl-carousel-need-replace
'
).
each
(
function
()
{
var
listOfImages
=
[];
$
(
this
).
find
(
'
img
'
).
each
(
function
()
{
listOfImages
.
push
(
'
<figure><img src="
'
+
$
(
this
).
attr
(
'
src
'
)
+
'
" alt="
'
+
$
(
this
).
attr
(
'
alt
'
)
+
'
"><figcaption class="text-white">
'
+
$
(
this
).
attr
(
'
title
'
)
+
'
</figcaption></figure>
'
)
})
$
(
this
).
html
(
listOfImages
.
join
(
''
)).
removeClass
(
'
owl-carousel-need-replace hidden
'
);
})
})
\ No newline at end of file
common/modules/documentation/controllers/DocumentationAdminController.php
View file @
b735bb20
...
...
@@ -94,9 +94,6 @@ class DocumentationAdminController extends AdminController
];
if
(
Yii
::
$app
->
request
->
isPost
)
{
// echo '<pre>' . print_r(Yii::$app->request->post(), TRUE) . '</pre>';
// echo '<pre>' . print_r(Yii::$app->request->post('DocContent'), TRUE) . '</pre>';
// die();
$transaction
=
Yii
::
$app
->
db
->
beginTransaction
();
try
{
...
...
frontend/web/.htaccess
View file @
b735bb20
...
...
@@ -5,17 +5,17 @@ RewriteCond %{HTTP_HOST} ^www.task-on\.com$ [NC]
RewriteRule
^(.*)$ http://task-on.com/$1 [R=301,L]
RewriteCond
%{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule
^index\.php$ http://task-on.com/ [R=301,L]
RewriteRule
^index\.php$ http
s
://task-on.com/ [R=301,L]
RewriteCond
%{HTTP_HOST} ^www\.(.*) [NC]
RewriteRule
^(.*)$ http://%1/$1 [R=301,L]
RewriteCond
%{HTTP}
off
RewriteRule
(.*) http://%{HTTP_HOST}%{REQUEST_URI} [R,L]
RewriteCond
%{HTTP
S
}
off
RewriteRule
(.*) http
s
://%{HTTP_HOST}%{REQUEST_URI} [R,L]
RewriteCond
%{REQUEST_FILENAME} !-d
RewriteCond
%{REQUEST_URI} ^(.+)/$
RewriteRule
^(.+)/$ http://task-on.com/$1 [R=301,L]
RewriteRule
^(.+)/$ http
s
://task-on.com/$1 [R=301,L]
Redirect
301 /portfolio/appl /portfolio
...
...
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