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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
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
Léo-Paul Géneau
erp5
Commits
729cb937
Commit
729cb937
authored
Jan 09, 2015
by
Xiaowu Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add title translation in listbox gadget
parent
2b842d3a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
21 deletions
+25
-21
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_listbox_js.xml
...mplateItem/web_page_module/rjs_gadget_erp5_listbox_js.xml
+25
-21
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_listbox_js.xml
View file @
729cb937
...
...
@@ -119,7 +119,6 @@
// Init local properties\n
.ready(function (g) {\n
g.props = {};\n
\n
})\n
\n
// Assign the element to a variable\n
...
...
@@ -145,6 +144,7 @@
thead = gadget.props.element.querySelector(\'thead\'),\n
field_json = options.field_json,\n
tr = document.createElement("tr"),\n
document_table = gadget.props.element.querySelector(\'.document_table\'),\n
th,\n
i;\n
\n
...
...
@@ -159,6 +159,13 @@
tr.appendChild(th);\n
}\n
thead.appendChild(tr);\n
return new RSVP.Queue()\n
.push(function () {\n
return gadget.translateHtml(document_table.innerHTML);\n
})\n
.push(function (my_translate_html) {\n
document_table.innerHTML = my_translate_html;\n
});\n
})\n
\n
//////////////////////////////////////////////\n
...
...
@@ -282,7 +289,7 @@
\n
paging_prev.className = "ui-btn ui-icon-carat-l ui-btn-icon-left responsive ui-first-child";\n
paging_prev.textContent = "Previous";\n
paging_prev.setAttribute("data-i18n", "
p
revious");\n
paging_prev.setAttribute("data-i18n", "
P
revious");\n
paging_prev.href = url_list[0];\n
paging_info.className = "ui-btn ui-disabled";\n
if ((begin_from === 0)
&&
(counter === 0)) {\n
...
...
@@ -300,7 +307,7 @@
// paging_info.textContent = "Page " + ((begin_from + lines) / lines);\n
paging_next.className = "ui-btn ui-icon-carat-r ui-btn-icon-right responsive ui-last-child";\n
paging_next.textContent = "Next";\n
paging_next.setAttribute("data-i18n", "
n
ext");\n
paging_next.setAttribute("data-i18n", "
N
ext");\n
paging_next.href = url_list[1];\n
\n
if (begin_from === 0) {\n
...
...
@@ -323,25 +330,22 @@
for (len = table.children.length; len > 0; len -= 1) {\n
table.removeChild(table.lastChild);\n
}\n
\n
// NOTE: for passing translations, temp must contain a table\n
temp_table.appendChild(fragment);\n
temp.appendChild(temp_table);\n
\n
return gadget.translateHtml(temp.innerHTML);\n
})\n
.push(function (my_translated_html) {\n
var new_body,\n
new_foot,\n
temp = document.createElement("div");\n
\n
temp.innerHTML = my_translated_html;\n
new_body = temp.querySelector("tbody");\n
new_foot = temp.querySelector("tfoot");\n
table.appendChild(new_body);\n
table.appendChild(new_foot);\n
return gadget;\n
});\n
.push(function (my_translated_html) {\n
var new_body,\n
new_foot,\n
temp = document.createElement("div");\n
temp.innerHTML = my_translated_html;\n
new_body = temp.querySelector("tbody");\n
new_foot = temp.querySelector("tfoot");\n
table.appendChild(new_body);\n
table.appendChild(new_foot);\n
return gadget;\n
});\n
});\n
\n
}(window, document, rJS, URI, RSVP));
...
...
@@ -467,7 +471,7 @@
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
super_sven
</string>
</value>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
...
...
@@ -481,7 +485,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
940.
2151.12481.15257
</string>
</value>
<value>
<string>
940.
11535.19754.41932
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -499,8 +503,8 @@
</tuple>
<state>
<tuple>
<float>
1420
243220.12
</float>
<string>
GMT
</string>
<float>
1420
800963.59
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
...
...
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