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
138
Merge Requests
138
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
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
fd299b3d
Commit
fd299b3d
authored
Feb 19, 2018
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Display more links in desktop mode
parent
7d59d147
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
39 additions
and
20 deletions
+39
-20
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
...b_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
+17
-11
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
..._page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.js
...teItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.js
+18
-5
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.xml
...eItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.xml
+2
-2
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
View file @
fd299b3d
...
...
@@ -15,6 +15,7 @@
.
declareAcquiredMethod
(
"
notifyChange
"
,
"
notifyChange
"
)
.
declareAcquiredMethod
(
"
displayFormulatorValidationError
"
,
"
displayFormulatorValidationError
"
)
.
declareAcquiredMethod
(
'
isDesktopMedia
'
,
'
isDesktopMedia
'
)
.
allowPublicAcquisition
(
"
notifyChange
"
,
function
()
{
return
this
.
notifyChange
({
modified
:
true
});
})
...
...
@@ -80,22 +81,23 @@
// render the header
.
push
(
function
()
{
var
new_content_action
=
form_gadget
.
state
.
erp5_document
.
_links
.
action_object_new_content_action
;
if
(
new_content_action
!==
undefined
)
{
new_content_action
=
form_gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
view
:
new_content_action
.
href
,
editable
:
true
}});
}
else
{
new_content_action
=
""
;
}
return
RSVP
.
all
([
form_gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
tab
"
}}),
form_gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
action
"
}}),
new_content_action
,
form_gadget
.
state
.
erp5_document
.
_links
.
action_object_new_content_action
?
form_gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
view
:
form_gadget
.
state
.
erp5_document
.
_links
.
action_object_new_content_action
.
href
,
editable
:
true
}})
:
""
,
form_gadget
.
getUrlFor
({
command
:
'
history_previous
'
}),
form_gadget
.
getUrlFor
({
command
:
'
selection_previous
'
}),
form_gadget
.
getUrlFor
({
command
:
'
selection_next
'
}),
calculatePageTitle
(
form_gadget
,
form_gadget
.
state
.
erp5_document
)
calculatePageTitle
(
form_gadget
,
form_gadget
.
state
.
erp5_document
),
form_gadget
.
isDesktopMedia
(),
form_gadget
.
state
.
erp5_document
.
_links
.
action_object_jio_report
?
form_gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
export
"
}})
:
""
]);
})
.
push
(
function
(
all_result
)
{
...
...
@@ -107,10 +109,14 @@
previous_url
:
all_result
[
4
],
next_url
:
all_result
[
5
],
page_title
:
all_result
[
6
]
};
},
is_desktop
=
all_result
[
7
];
if
(
form_gadget
.
state
.
save_action
===
true
)
{
header_dict
.
save_action
=
true
;
}
if
(
is_desktop
)
{
header_dict
.
export_url
=
all_result
[
8
];
}
return
form_gadget
.
updateHeader
(
header_dict
);
});
})
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
View file @
fd299b3d
...
...
@@ -230,7 +230,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
965.
14609.38920.44509
</string>
</value>
<value>
<string>
965.
39385.16585.60774
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>
151
7561386.33
</float>
<float>
151
9047926.74
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.js
View file @
fd299b3d
...
...
@@ -26,6 +26,7 @@
/////////////////////////////////////////////////////////////////
.
declareAcquiredMethod
(
"
updateHeader
"
,
"
updateHeader
"
)
.
declareAcquiredMethod
(
"
getUrlFor
"
,
"
getUrlFor
"
)
.
declareAcquiredMethod
(
'
isDesktopMedia
'
,
'
isDesktopMedia
'
)
/////////////////////////////////////////////////////////////////
// Proxy methods to the child gadget
...
...
@@ -100,13 +101,20 @@
gadget
.
getUrlFor
({
command
:
'
selection_next
'
}),
gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
tab
"
}}),
gadget
.
state
.
erp5_document
.
_links
.
action_object_jio_report
?
gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
export
"
}})
:
""
,
calculatePageTitle
(
gadget
,
gadget
.
state
.
erp5_document
)
gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
page
:
"
export
"
}})
:
""
,
calculatePageTitle
(
gadget
,
gadget
.
state
.
erp5_document
),
gadget
.
isDesktopMedia
(),
gadget
.
state
.
erp5_document
.
_links
.
action_object_new_content_action
?
gadget
.
getUrlFor
({
command
:
'
change
'
,
options
:
{
view
:
gadget
.
state
.
erp5_document
.
_links
.
action_object_new_content_action
.
href
,
editable
:
true
}})
:
""
]);
})
.
push
(
function
(
all_result
)
{
return
gadget
.
updateHeader
(
{
var
options
=
{
edit_url
:
all_result
[
0
],
actions_url
:
all_result
[
1
],
selection_url
:
all_result
[
2
],
...
...
@@ -115,7 +123,12 @@
tab_url
:
all_result
[
5
],
export_url
:
all_result
[
6
],
page_title
:
all_result
[
7
]
});
},
is_desktop
=
all_result
[
8
];
if
(
is_desktop
)
{
options
.
add_url
=
all_result
[
9
];
}
return
gadget
.
updateHeader
(
options
);
});
});
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_js.xml
View file @
fd299b3d
...
...
@@ -230,7 +230,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
965.
14600.20468.49988
</string>
</value>
<value>
<string>
965.
39384.38396.19200
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>
151
7561447.52
</float>
<float>
151
9047884.69
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
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