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
Labels
Merge Requests
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Jérome Perrin
erp5
Commits
ad8ab2f0
Commit
ad8ab2f0
authored
Apr 16, 2018
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Translate panel contextual menu
parent
eaf307c5
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
64 additions
and
22 deletions
+64
-22
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_html.html
...plateItem/web_page_module/rjs_gadget_erp5_panel_html.html
+3
-3
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_html.xml
...mplateItem/web_page_module/rjs_gadget_erp5_panel_html.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
...hTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
+5
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
...TemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
+2
-2
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_translate_zuite/testPanel.zpt
...em/portal_tests/renderjs_ui_translate_zuite/testPanel.zpt
+47
-8
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_zuite/testPanelHighlightCurrentView.zpt
...tests/renderjs_ui_zuite/testPanelHighlightCurrentView.zpt
+5
-5
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_html.html
View file @
ad8ab2f0
...
...
@@ -60,19 +60,19 @@
<
dt
class
=
"
ui-content-title ui-body-c ui-btn ui-btn-icon-left ui-icon-eye
"
data
-
i18n
=
"
Views
"
>
Views
<
/dt
>
{{
#
each
view_list
}}
<
dd
data
-
role
=
"
listview
"
data
-
theme
=
"
c
"
data
-
inset
=
"
true
"
class
=
"
document-listview
"
>
<
a
data
-
i18n
=
"
{{title}}
"
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
a
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
/dd
>
{{
/
each
}}
<
dt
class
=
"
ui-content-title ui-body-c ui-btn ui-btn-icon-left ui-icon-random
"
data
-
i18n
=
"
Workflows
"
>
Workflows
<
/dt
>
{{
#
each
workflow_list
}}
<
dd
data
-
role
=
"
listview
"
data
-
theme
=
"
c
"
data
-
inset
=
"
true
"
class
=
"
document-listview
"
>
<
a
data
-
i18n
=
"
{{title}}
"
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
a
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
/dd
>
{{
/
each
}}
<
dt
class
=
"
ui-content-title ui-body-c ui-btn ui-btn-icon-left ui-icon-cogs
"
data
-
i18n
=
"
Actions
"
>
Actions
<
/dt
>
{{
#
each
action_list
}}
<
dd
data
-
role
=
"
listview
"
data
-
theme
=
"
c
"
data
-
inset
=
"
true
"
class
=
"
document-listview
"
>
<
a
data
-
i18n
=
"
{{title}}
"
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
a
class
=
"
ui-body-inherit {{class_name}}
"
href
=
"
{{href}}
"
>
{{
title
}}
<
/a
>
<
/dd
>
{{
/
each
}}
</script>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_html.xml
View file @
ad8ab2f0
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
965.
39086.65235.37700
</string>
</value>
<value>
<string>
965.
45005.21388.22067
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
15
19039107
.29
</float>
<float>
15
23892174
.29
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
View file @
ad8ab2f0
...
...
@@ -292,11 +292,14 @@
href
:
result_list
[
i
+
workflow_list
.
length
+
view_list
.
length
]
});
}
gadget
.
element
.
querySelector
(
"
dl
"
).
innerHTML
=
panel_template_body_desktop
({
return
gadget
.
translateHtml
(
panel_template_body_desktop
({
workflow_list
:
result_workflow_list
,
view_list
:
result_view_list
,
action_list
:
result_action_list
});
}));
})
.
push
(
function
(
translated_html
)
{
gadget
.
element
.
querySelector
(
"
dl
"
).
innerHTML
=
translated_html
;
});
}
}
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
View file @
ad8ab2f0
...
...
@@ -230,7 +230,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
96
5.59353.60904.62617
</string>
</value>
<value>
<string>
96
6.58910.9997.17254
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>
152
0010851.84
</float>
<float>
152
3892386.86
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_translate_zuite/testPanel.zpt
View file @
ad8ab2f0
...
...
@@ -28,58 +28,97 @@
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Home"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Home"]
</td>
<td>
zhuye
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Modules"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Modules"]
</td>
<td>
mokuai
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Worklists"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Worklists"]
</td>
<td>
gongzhuoliebiao
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="History"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="History"]
</td>
<td>
lishi
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Search"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Search"]
</td>
<td>
soushuo
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Preferences"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Preferences"]
</td>
<td>
pianai
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//a[@data-i18n="Logout"]
</td>
<td>
//
div[@data-gadget-scope='panel']//
a[@data-i18n="Logout"]
</td>
<td>
tuichu
</td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//div[@data-gadget-scope="erp5_checkbox"]//label
</td>
<td>
//div[@data-gadget-scope=
'panel']//div[@data-gadget-scope=
"erp5_checkbox"]//label
</td>
<td>
bianxue
</td>
</tr>
<tal:block
metal:use-macro=
"here/PTZuite_CommonTemplate/macros/init"
/>
<tr>
<td>
open
</td>
<td>
${base_url}/web_site_module/renderjs_runner/wo/#/foo_module
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
link=Title 1
</td>
<td></td>
</tr>
<tr>
<td>
verifyElementPresent
</td>
<td>
link=Title 1
</td>
<td></td>
</tr>
<tr>
<td>
click
</td>
<td>
link=Title 1
</td>
<td></td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//div[@data-gadget-scope='panel']//dt[@data-i18n="Views"]
</td>
<td></td>
</tr>
<tr>
<td>
verifyText
</td>
<td>
//div[@data-gadget-scope='panel']//dt[@data-i18n="Views"]
</td>
<td>
shitu
</td>
</tr>
<tr>
<td>
assertElementPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[text()="yanzhen"]
</td>
<td></td>
</tr>
</tbody></table>
</body>
</html>
\ No newline at end of file
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_zuite/testPanelHighlightCurrentView.zpt
View file @
ad8ab2f0
...
...
@@ -53,7 +53,7 @@
<tr>
<td>
verifyElementPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[
@data-i18n='View'][
contains(@class, 'active')]
</td>
<td>
//div[@data-gadget-scope='panel']//a[
text()='View' and
contains(@class, 'active')]
</td>
<td></td>
</tr>
...
...
@@ -61,13 +61,13 @@
<tr>
<td>
verifyElementNotPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[
@data-i18n='View'][
contains(@class, 'active')]
</td>
<td>
//div[@data-gadget-scope='panel']//a[
text()='View' and
contains(@class, 'active')]
</td>
<td></td>
</tr>
<tr>
<td>
verifyElementPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[
@data-i18n='Relation Fields'][
contains(@class, 'active')]
</td>
<td>
//div[@data-gadget-scope='panel']//a[
text()='Relation Fields' and
contains(@class, 'active')]
</td>
<td></td>
</tr>
...
...
@@ -103,13 +103,13 @@
<tr>
<td>
waitForElementPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[
@data-i18n='Custom Dialog Action'][
contains(@class, 'active')]
</td>
<td>
//div[@data-gadget-scope='panel']//a[
text()='Custom Dialog Action' and
contains(@class, 'active')]
</td>
<td></td>
</tr>
<tr>
<td>
verifyElementNotPresent
</td>
<td>
//div[@data-gadget-scope='panel']//a[
@data-i18n='Relation Fields'][
contains(@class, 'active')]
</td>
<td>
//div[@data-gadget-scope='panel']//a[
text()='Relation Fields' and
contains(@class, 'active')]
</td>
<td></td>
</tr>
...
...
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