Commit 32a5fd6c authored by Alain Takoudjou's avatar Alain Takoudjou

erp5_web_mynij_search: Do not show view_actions menu in panel when not needed

Remove Views and Actions for other page when navigating to Search and Activities menu in left panel
parent b0fbc703
......@@ -11,6 +11,7 @@
.declareAcquiredMethod("getUrlParameter", "getUrlParameter")
.declareAcquiredMethod("getSetting", "getSetting")
.declareAcquiredMethod("getUrlFor", "getUrlFor")
.declareAcquiredMethod("updatePanel", "updatePanel")
/*.ready(function () {
var gadget = this;
......@@ -28,18 +29,12 @@
.declareMethod("render", function (options) {
var gadget = this;
return new RSVP.Queue()
.push(function (url_list) {
return gadget.updatePanel({view_action_dict: {}})
.push(function () {
return gadget.updateHeader({
page_title: "Mynij Activities"
//selection_url: url_list[0]
});
});
})
.declareMethod("render", function (options) {
var gadget = this;
return;
});
}(window, document, rJS, RSVP));
\ No newline at end of file
......@@ -242,7 +242,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>988.46752.35395.5563</string> </value>
<value> <string>994.60874.57737.41779</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -260,7 +260,7 @@
</tuple>
<state>
<tuple>
<float>1608224992.53</float>
<float>1632210066.65</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -13,6 +13,7 @@
.declareAcquiredMethod("getUrlFor", "getUrlFor")
.declareAcquiredMethod("redirect", "redirect")
.declareAcquiredMethod("getSetting", "getSetting")
.declareAcquiredMethod("updatePanel", "updatePanel")
.ready(function () {
var model_gadget,
......@@ -55,7 +56,8 @@
return new RSVP.Queue()
.push(function () {
return RSVP.all([
gadget.getUrlFor({command: 'history_previous'})
gadget.getUrlFor({command: 'history_previous'}),
gadget.updatePanel({view_action_dict: {}})
]);
})
.push(function (url_list) {
......@@ -242,9 +244,10 @@
select.onchange = function (e) {
e.preventDefault();
if (e.target.value === "ADD") {
return gadget.redirect({"command": "display", "options": {
page: "ojs_local_controller"
}});
//return gadget.redirect({"command": "display", "options": {
// page: "ojs_local_controller"
//}});
window.location.href = "https://store.mynij.com";
}
};
})
......
......@@ -242,7 +242,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>994.32554.11757.37154</string> </value>
<value> <string>994.60872.15715.26112</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -260,7 +260,7 @@
</tuple>
<state>
<tuple>
<float>1630510763.68</float>
<float>1632209810.69</float>
<string>UTC</string>
</tuple>
</state>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment