Commit 7df8d2b4 authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_jio: Add RSS into Invoice lists

    This allows user to get updated with the issued invoices.
parent 62ed5903
...@@ -181,7 +181,9 @@ ...@@ -181,7 +181,9 @@
}) })
.push(function (contract_relative_url) { .push(function (contract_relative_url) {
var promise_list = [ var promise_list = [
gadget.getUrlFor({command: "change", options: {"page": "slapos"}}) gadget.getUrlFor({command: "change", options: {"page": "slapos"}}),
gadget.getUrlFor({command: "change", options: {"page": "slap_rss_ticket",
"jio_key": "accounting_module"}})
]; ];
if (contract_relative_url) { if (contract_relative_url) {
promise_list.push( promise_list.push(
...@@ -195,10 +197,11 @@ ...@@ -195,10 +197,11 @@
var header_dict = { var header_dict = {
page_title: invoices_translation, page_title: invoices_translation,
selection_url: result[0], selection_url: result[0],
rss_url: result[1],
filter_action: true filter_action: true
}; };
if (result[1]) { if (result[2]) {
header_dict.contract_url = result[1]; header_dict.contract_url = result[2];
} }
return gadget.updateHeader(header_dict); return gadget.updateHeader(header_dict);
}); });
......
...@@ -236,7 +236,7 @@ ...@@ -236,7 +236,7 @@
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>986.54956.15848.43639</string> </value> <value> <string>991.36496.17865.938</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -254,7 +254,7 @@ ...@@ -254,7 +254,7 @@
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1602092381.9</float> <float>1619144094.17</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </state>
......
...@@ -11,6 +11,9 @@ document_path = "" ...@@ -11,6 +11,9 @@ document_path = ""
if context.getPortalType() in ["Hosting Subscription", "Computer"]: if context.getPortalType() in ["Hosting Subscription", "Computer"]:
document_path = "/%s" % context.getRelativeUrl() document_path = "/%s" % context.getRelativeUrl()
if context.getPortalType() in ["Accounting Transaction Module"]:
document_path = "/invoice"
web_site = context.getWebSiteValue() web_site = context.getWebSiteValue()
request_url = "%s/feed%s" % (web_site.absolute_url(), document_path) request_url = "%s/feed%s" % (web_site.absolute_url(), document_path)
......
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