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
Paul Graydon
erp5
Commits
ba45e294
Commit
ba45e294
authored
Jan 09, 2023
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_web_renderjs_ui: disable acquisition in case of dropped sub gadget
parent
5890e325
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
55 additions
and
12 deletions
+55
-12
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
...mplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
+53
-10
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
...plateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
+2
-2
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
View file @
ba45e294
/*globals window, document, RSVP, rJS,
URI, location, XMLHttpRequest, console, navigator, Event,
URL, domsugar*/
/*jslint indent: 2, maxlen: 80*/
/*jslint indent: 2, maxlen: 80
, unparam: true
*/
(
function
(
window
,
document
,
RSVP
,
rJS
,
XMLHttpRequest
,
location
,
console
,
navigator
,
Event
,
URL
,
domsugar
)
{
...
...
@@ -506,8 +506,13 @@
// XXX Those methods may be directly integrated into the header,
// as it handles the submit triggering
.
allowPublicAcquisition
(
'
notifySubmitting
'
,
function
notifySubmitting
(
argument_list
argument_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
return
RSVP
.
all
([
route
(
this
,
"
header
"
,
'
notifySubmitting
'
),
this
.
deferChangeState
({
...
...
@@ -518,8 +523,13 @@
]);
})
.
allowPublicAcquisition
(
'
notifySubmitted
'
,
function
notifySubmitted
(
argument_list
argument_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
return
RSVP
.
all
([
route
(
this
,
"
header
"
,
'
notifySubmitted
'
),
this
.
deferChangeState
({
...
...
@@ -531,8 +541,13 @@
]);
})
.
allowPublicAcquisition
(
'
notifyChange
'
,
function
notifyChange
(
argument_list
argument_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
return
RSVP
.
all
([
route
(
this
,
"
header
"
,
'
notifyChange
'
),
this
.
deferChangeState
({
...
...
@@ -606,7 +621,12 @@
return
route
(
this
,
'
router
'
,
'
getCommandUrlForDict
'
,
param_list
);
})
.
allowPublicAcquisition
(
"
updateHeader
"
,
function
updateHeader
(
param_list
)
{
.
allowPublicAcquisition
(
"
updateHeader
"
,
function
updateHeader
(
param_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
initHeaderOptions
(
this
);
var
text_list
=
[],
key
,
...
...
@@ -631,28 +651,46 @@
});
})
.
allowPublicAcquisition
(
"
updatePanel
"
,
function
updatePanel
(
param_list
)
{
.
allowPublicAcquisition
(
"
updatePanel
"
,
function
updatePanel
(
param_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
var
gadget
=
this
;
initPanelOptions
(
gadget
);
gadget
.
props
.
panel_argument_list
=
param_list
[
0
];
})
.
allowPublicAcquisition
(
'
refreshHeaderAndPanel
'
,
function
acquireRefreshHeaderAndPanel
()
{
function
acquireRefreshHeaderAndPanel
(
ignore
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
return
refreshHeaderAndPanel
(
this
,
true
);
})
.
allowPublicAcquisition
(
'
hidePanel
'
,
function
hidePanel
(
param_list
)
{
return
hideDesktopPanel
(
this
,
param_list
[
0
]);
})
.
allowPublicAcquisition
(
'
triggerPanel
'
,
function
triggerPanel
()
{
.
allowPublicAcquisition
(
'
triggerPanel
'
,
function
triggerPanel
(
ignore
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
// Force calling panel toggle
return
this
.
deferChangeState
({
panel_visible
:
new
Date
().
getTime
()
});
})
.
allowPublicAcquisition
(
'
renderEditorPanel
'
,
function
renderEditorPanel
(
param_list
)
{
function
renderEditorPanel
(
param_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, no need to keep notification
return
;
}
return
this
.
deferChangeState
({
// Force calling editor panel render
editor_panel_render_timestamp
:
new
Date
().
getTime
(),
...
...
@@ -703,8 +741,13 @@
});
})
.
allowPublicAcquisition
(
"
triggerMaximize
"
,
function
maximize
(
param_list
param_list
,
scope
)
{
if
(
scope
===
undefined
)
{
// If sub gadget has been dropped, nothing to maximize
return
;
}
return
triggerMaximize
(
this
,
param_list
[
0
]);
})
/////////////////////////////////////////////////////////////////
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.xml
View file @
ba45e294
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
995.60357.5039.47650
</string>
</value>
<value>
<string>
1005.39881.44610.14899
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
16
39487214.66
</float>
<float>
16
73426576.41
</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