Commit 594758df authored by Vincent Bechu's avatar Vincent Bechu

[erp5_officejs] WIP add upload link in header, be carefull this commit erase some previous change

parent 858a363b
......@@ -26,22 +26,20 @@
if (result.data.rows[i].value.hasOwnProperty("modification_date")) {
date = new Date(result.data.rows[i].value.modification_date);
result.data.rows[i].value.modification_date = {
field_gadget_param: {
allow_empty_time: 0,
ampm_time_style: 0,
css_class: "date_field",
date_only: 0,
description: "The Date",
editable: 0,
hidden: 0,
hidden_day_is_last_day: 0,
"default": date.toUTCString(),
key: "modification_date",
required: 0,
timezone_style: 0,
title: "Modification Date",
type: "DateTimeField"
}
allow_empty_time: 0,
ampm_time_style: 0,
css_class: "date_field",
date_only: 0,
description: "The Date",
editable: 0,
hidden: 0,
hidden_day_is_last_day: 0,
"default": date.toUTCString(),
key: "modification_date",
required: 0,
timezone_style: 0,
title: "Modification Date",
type: "DateTimeField"
};
result.data.rows[i].value["listbox_uid:list"] = {
key: "listbox_uid:list",
......@@ -124,15 +122,21 @@
.push(function () {
return RSVP.all([
gadget.getUrlFor({command: "change", options: {"page": "ojs_add_document"}}),
gadget.getSetting('document_title_plural')
gadget.getSetting('document_title_plural'),
gadget.getUrlFor({command: "change", options: {"page": "ojs_upload_convert"}}),
gadget.getSetting('upload_extension', false)
]);
})
.push(function (result) {
return gadget.updateHeader({
var header = {
page_title: result[1],
filter_action: true,
add_url: result[0]
});
};
if (result[3]) {
header.upload_url = result[2];
}
return gadget.updateHeader(header);
});
});
}(window, rJS, RSVP));
\ No newline at end of file
......@@ -16,7 +16,6 @@
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
......@@ -24,6 +23,7 @@
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
</tuple>
......@@ -42,6 +42,8 @@
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
......@@ -56,7 +58,6 @@
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
......@@ -199,7 +200,7 @@
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>publish</string> </value>
<value> <string>publish_alive</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
......@@ -225,7 +226,7 @@
</tuple>
<state>
<tuple>
<float>1495446491.04</float>
<float>1523365973.43</float>
<string>UTC</string>
</tuple>
</state>
......@@ -234,7 +235,7 @@
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>published</string> </value>
<value> <string>published_alive</string> </value>
</item>
</dictionary>
</list>
......@@ -256,7 +257,7 @@
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>vincent</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -270,7 +271,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>966.41210.1237.18158</string> </value>
<value> <string>966.50136.58427.36864</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -288,7 +289,7 @@
</tuple>
<state>
<tuple>
<float>1523022228.16</float>
<float>1523366737.77</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