Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Lu Xu
erp5
Commits
5080aca4
Commit
5080aca4
authored
May 17, 2012
by
Ivan Tyagov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Split generic Tabbular gadget from ERP5 form rendering using gadgets.
parent
31666ee6
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
13 deletions
+14
-13
bt5/erp5_jquery_plugin_renderjs/PathTemplateItem/portal_skins/erp5_jquery/jquery/plugin/renderjs/renderjs.js.xml
..._skins/erp5_jquery/jquery/plugin/renderjs/renderjs.js.xml
+10
-9
bt5/erp5_jquery_plugin_renderjs/PathTemplateItem/portal_skins/erp5_jquery/jquery/plugin/renderjs/renderjs_test.js.xml
...s/erp5_jquery/jquery/plugin/renderjs/renderjs_test.js.xml
+3
-3
bt5/erp5_jquery_plugin_renderjs/bt/revision
bt5/erp5_jquery_plugin_renderjs/bt/revision
+1
-1
No files found.
bt5/erp5_jquery_plugin_renderjs/PathTemplateItem/portal_skins/erp5_jquery/jquery/plugin/renderjs/renderjs.js.xml
View file @
5080aca4
...
...
@@ -12,7 +12,7 @@
</item>
<item>
<key>
<string>
_EtagSupport__etag
</string>
</key>
<value>
<string>
ts37
002880.65
</string>
</value>
<value>
<string>
ts37
244071.21
</string>
</value>
</item>
<item>
<key>
<string>
__name__
</string>
</key>
...
...
@@ -138,20 +138,20 @@ var TabbularGadget = {\n
visible_dom.removeClass("not_selected");\n
},\n
\n
addNewTabGadget: function(form_id, dom_id, gadget_data_handler) {\n
// add new gadget and render it\n
addNewTabGadget: function(dom_id, gadget, gadget_data_handler, gadget_data_source) {\n
/*\n
* add new gadget and render it\n
*/\n
var html_string;\n
tab_container=$(\'#\'+dom_id);\n
tab_container.empty();\n
// XXX: allow add any gadget,gadget:source items within API\n
html_string =[\'<div class="gadget" \',\n
\'gadget="\' +
form_id + \'/Form_asRenderJSGadget"
\',\n
\'gadget="\' +
gadget + \'"
\',\n
\'gadget:data-handler="\' + gadget_data_handler + \'" \',\n
\'gadget:data-source="
Form_asJSON?form_id=\' + form_id +
\'">
</div>
\'].join(\'\\n\');\n
\'gadget:data-source="
\' + gadget_data_source +
\'">
</div>
\'].join(\'\\n\');\n
\n
tab_container.append(html_string);\n
tab_gadget = tab_container.find(".gadget");\n
Form.setCurrentFormId(form_id);\n
\n
// render new gadget\n
is_ready = false;\n
...
...
@@ -168,7 +168,8 @@ var TabbularGadget = {\n
};\n
\n
/*\n
Form field renderer\n
Form field renderer.\n
Note: This is an ERP5 form implementation for the moment.\n
*/\n
var Form = {\n
\n
...
...
@@ -769,7 +770,7 @@ var RenderJs = {\n
</item>
<item>
<key>
<string>
size
</string>
</key>
<value>
<int>
253
73
</int>
</value>
<value>
<int>
253
34
</int>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
...
...
bt5/erp5_jquery_plugin_renderjs/PathTemplateItem/portal_skins/erp5_jquery/jquery/plugin/renderjs/renderjs_test.js.xml
View file @
5080aca4
...
...
@@ -8,7 +8,7 @@
<dictionary>
<item>
<key>
<string>
_EtagSupport__etag
</string>
</key>
<value>
<string>
ts37
003035.66
</string>
</value>
<value>
<string>
ts37
244023.74
</string>
</value>
</item>
<item>
<key>
<string>
__name__
</string>
</key>
...
...
@@ -37,7 +37,7 @@ function setupRenderJSTest(){\n
\n
module("TabularGadget");\n
test(\'addNewTabGadget\', function(){\n
TabbularGadget.addNewTabGadget("
Person_view", "qunit-fixture", "FormUpdater.update
");\n
TabbularGadget.addNewTabGadget("
qunit-fixture", "Person_view/Form_asRenderJSGadget", "FormUpdater.update", "Form_asJSON?form_id=Person_view
");\n
equal($("#qunit-fixture").children(".gadget").length, 1);\n
equal(GadgetIndex.getGadgetList().length, 1);\n
\n
...
...
@@ -80,7 +80,7 @@ function setupRenderJSTest(){\n
</item>
<item>
<key>
<string>
size
</string>
</key>
<value>
<int>
1
755
</int>
</value>
<value>
<int>
1
812
</int>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
...
...
bt5/erp5_jquery_plugin_renderjs/bt/revision
View file @
5080aca4
13
\ No newline at end of file
14
\ No newline at end of file
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