Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
web-apps
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
web-apps
Commits
7a650ebd
Commit
7a650ebd
authored
May 24, 2016
by
Oleg Korshul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add baseUrl param to plugin
parent
2d7812fe
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
2 deletions
+6
-2
apps/common/main/lib/controller/Plugins.js
apps/common/main/lib/controller/Plugins.js
+3
-1
apps/common/main/lib/model/Plugin.js
apps/common/main/lib/model/Plugin.js
+1
-0
apps/common/main/lib/view/Plugins.js
apps/common/main/lib/view/Plugins.js
+1
-1
apps/documenteditor/main/app/controller/Main.js
apps/documenteditor/main/app/controller/Main.js
+1
-0
No files found.
apps/common/main/lib/controller/Plugins.js
View file @
7a650ebd
...
...
@@ -93,6 +93,7 @@ define([
var
plugin
=
new
Asc
.
CPlugin
();
plugin
.
set_Name
(
item
.
get
(
'
name
'
));
plugin
.
set_Guid
(
item
.
get
(
'
guid
'
));
plugin
.
set_BaseUrl
(
item
.
get
(
'
baseUrl
'
));
var
variations
=
item
.
get
(
'
variations
'
),
variationsArr
=
[];
variations
.
forEach
(
function
(
itemVar
){
...
...
@@ -136,9 +137,10 @@ define([
});
}
var
_baseUrl
=
(
plugin
.
get_BaseUrl
().
length
==
0
)
?
me
.
panelPlugins
.
pluginsPath
:
plugin
.
get_BaseUrl
();
me
.
pluginDlg
=
new
Common
.
Views
.
PluginDlg
({
title
:
plugin
.
get_Name
(),
url
:
me
.
panelPlugins
.
pluginsPath
+
variation
.
get_Url
(),
url
:
_baseUrl
+
variation
.
get_Url
(),
buttons
:
newBtns
,
toolcallback
:
_
.
bind
(
this
.
onToolClose
,
this
)
});
...
...
apps/common/main/lib/model/Plugin.js
View file @
7a650ebd
...
...
@@ -73,6 +73,7 @@ define([
return
{
id
:
Common
.
UI
.
getId
(),
name
:
''
,
baseUrl
:
''
,
guid
:
Common
.
UI
.
getId
(),
variations
:
[],
currentVariation
:
0
,
...
...
apps/common/main/lib/view/Plugins.js
View file @
7a650ebd
...
...
@@ -75,7 +75,7 @@ define([
el
:
$
(
'
#plugins-list
'
),
store
:
this
.
storePlugins
,
enableKeyEvents
:
false
,
itemTemplate
:
_
.
template
(
'
<div id="<%= id %>" class="item-plugins" style="background-image: url(
'
+
this
.
pluginsPath
+
'
<%= variations[currentVariation].get("icons")[(window.devicePixelRatio > 1) ? 1 : 0] %>); background-position: 0 0;"></div>
'
)
itemTemplate
:
_
.
template
(
'
<div id="<%= id %>" class="item-plugins" style="background-image: url(
'
+
'
<% if (baseUrl !=="") { %>
'
+
'
<%= baseUrl %>
'
+
'
<% } else { %>
'
+
this
.
pluginsPath
+
'
<% } %>
'
+
'
<%= variations[currentVariation].get("icons")[(window.devicePixelRatio > 1) ? 1 : 0] %>); background-position: 0 0;"></div>
'
)
});
this
.
trigger
(
'
render:after
'
,
this
);
...
...
apps/documenteditor/main/app/controller/Main.js
View file @
7a650ebd
...
...
@@ -1730,6 +1730,7 @@ define([
arr
.
push
(
new
Common
.
Models
.
Plugin
({
name
:
item
.
name
,
guid
:
item
.
guid
,
baseUrl
:
item
.
baseUrl
,
variations
:
variationsArr
,
currentVariation
:
0
}));
...
...
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