Commit c8f3e826 authored by Romain Courteaud's avatar Romain Courteaud

[erp5_web_jabber_client] Use erp5_launcher as top gadget

Split each page into a separate gadget.
Stop using patched renderjs.
parent 4c986964
......@@ -99,14 +99,27 @@
</item>
<item>
<key> <string>text_content</string> </key>
<value> <string>CACHE MANIFEST\n
<value> <string encoding="cdata"><![CDATA[
CACHE MANIFEST\n
# generated on Mon, 2 Mar 2016 09:00:00 +0000\n
\n
CACHE:\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/fonts/fontawesome-webfont.eot?v=4.2.0\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/fonts/fontawesome-webfont.eot?#iefix&v=4.2.0\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/fonts/fontawesome-webfont.woff?v=4.2.0\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/fonts/fontawesome-webfont.ttf?v=4.2.0\n
https://netdna.bootstrapcdn.com/font-awesome/4.2.0/fonts/fontawesome-webfont.svg?v=4.2.0#fontawesomeregular\n
URI.js\n
i18next.js\n
gadget_translation.html\n
gadget_translation.js\n
gadget_translation_data.js\n
erp5_launcher.html\n
erp5_launcher.js\n
gadget_erp5.css\n
gadget_global.js\n
gadget_jabberclient.js\n
gadget_jabberclient.html\n
gadget_jabberconnection.html\n
gadget_jabberconnection.js\n
gadget_jio.js\n
gadget_jio.html\n
handlebars.js\n
......@@ -116,9 +129,38 @@ jquerymobile.css\n
jquerymobile.js\n
renderjs.js\n
rsvp.js\n
\n
gadget_erp5_editor_panel.html\n
gadget_erp5_editor_panel.js\n
gadget_erp5_form.html\n
gadget_erp5_form.js\n
gadget_erp5_header.html\n
gadget_erp5_header.js\n
gadget_erp5_field_string.html\n
gadget_erp5_field_string.js\n
gadget_erp5_field_password.html\n
gadget_erp5_field_password.js\n
gadget_jabberclient_page_dialog.html\n
gadget_jabberclient_page_dialog.js\n
gadget_jabberclient_router.html\n
gadget_jabberclient_router.js\n
gadget_jabberclient_page_password.html\n
gadget_jabberclient_page_password.js\n
gadget_jabberclient_page_connect.html\n
gadget_jabberclient_page_connect.js\n
gadget_jabberclient_page_subscribe.js\n
gadget_jabberclient_page_subscribe.html\n
gadget_jabberclient_panel.html\n
gadget_jabberclient_panel.js\n
gadget_jabberclient_page_contact.js\n
gadget_jabberclient_page_contact.html\n
gadget_jabberclient_jio.html\n
gadget_jabberclient_jio.js\n
favicon.ico\n
connection/\n
NETWORK:\n
*</string> </value>
*
]]></string> </value>
</item>
<item>
<key> <string>title</string> </key>
......@@ -239,7 +281,7 @@ NETWORK:\n
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>normie</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -253,7 +295,7 @@ NETWORK:\n
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>945.44005.30137.52718</string> </value>
<value> <string>949.35452.57030.13636</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -271,7 +313,7 @@ NETWORK:\n
</tuple>
<state>
<tuple>
<float>1442825498.81</float>
<float>1456907697.62</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -104,7 +104,7 @@
<value> <string encoding="cdata"><![CDATA[
<!doctype html>\n
<html>\n
<html manifest="gadget_jabberconnection.appcache">\n
<head>\n
<meta charset="utf-8">\n
<title>Connection</title>\n
......@@ -242,7 +242,7 @@
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>romain</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -256,7 +256,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>939.33860.38910.29713</string> </value>
<value> <string>949.35389.52548.34798</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -274,8 +274,8 @@
</tuple>
<state>
<tuple>
<float>1418214410.97</float>
<string>GMT</string>
<float>1456847737.11</float>
<string>UTC</string>
</tuple>
</state>
</object>
......
......@@ -101,8 +101,8 @@
<key> <string>text_content</string> </key>
<value> <string encoding="cdata"><![CDATA[
/*jslint nomen: true*/\n
/*global window, rJS, Strophe, $iq, $pres, $msg, RSVP*/\n
/*jslint indent: 2, maxerr: 3, nomen: true */\n
\n
(function (window, rJS, Strophe, $iq, $pres, $msg, RSVP) {\n
"use strict";\n
......@@ -117,7 +117,7 @@
this.errors += 1;\n
Strophe.warn("request errored, status: " + reqStatus +\n
", number of errors: " + this.errors);\n
if (this.errors > 4) {\n
if (this.errors > 2) {\n
this._onDisconnectTimeout();\n
this._conn._changeConnectStatus(\n
Strophe.Status.ERROR,\n
......@@ -222,9 +222,9 @@
result = gadget.notifyXMPPAttached();\n
} else {\n
if (status === Strophe.Status.ERROR) {\n
throw new Error("XMPP Connection Error");\n
result = gadget.notifyXMPPConnectionError();\n
}\n
throw new Error("Unknown connection status: " + status);\n
result = gadget.notifyXMPPError(status);\n
}\n
return result;\n
});\n
......@@ -302,6 +302,10 @@
\'notifyXMPPDisconnected\')\n
.declareAcquiredMethod(\'notifyXMPPDisconnecting\',\n
\'notifyXMPPDisconnecting\')\n
.declareAcquiredMethod(\'notifyXMPPConnectionError\',\n
\'notifyXMPPConnectionError\')\n
.declareAcquiredMethod(\'notifyXMPPError\',\n
\'notifyXMPPError\')\n
.declareAcquiredMethod(\'notifyXMPPAttached\',\n
\'notifyXMPPAttached\')\n
.declareAcquiredMethod(\'notifyXMPPMessageTextReceived\',\n
......@@ -383,15 +387,15 @@
})\n
\n
.declareMethod(\'resetPassword\', function (server, new_passwd) {\n
var defer = RSVP.defer();\n
var defer = RSVP.defer(),\n
uid;\n
function jsonifyResponse(domElt) {\n
try {\n
var result = [],\n
type = domElt.getAttribute(\'type\');\n
if(type === "result") {\n
if (type === "result") {\n
result.push("Password Reset Success.");\n
}\n
else {\n
} else {\n
throw new Error("Password Reset Failure.");\n
}\n
defer.resolve(result);\n
......@@ -399,7 +403,7 @@
defer.reject(error);\n
}\n
}\n
var uid = this.props.jid.split(\'@\')[0];\n
uid = this.props.jid.split(\'@\')[0];\n
this.props.connection.sendIQ(\n
$iq({to: server, type: "set"})\n
.c("query", {xmlns: "jabber:iq:register"})\n
......@@ -583,7 +587,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>944.7242.54723.60006</string> </value>
<value> <string>949.35404.19073.41659</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -601,8 +605,8 @@
</tuple>
<state>
<tuple>
<float>1436191748.38</float>
<string>GMT</string>
<float>1456844917.63</float>
<string>UTC</string>
</tuple>
</state>
</object>
......
......@@ -167,6 +167,83 @@
<persistent> <string encoding="base64">AAAAAAAAAAU=</string> </persistent>
</value>
</item>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_content_security_policy</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_translation_gadget_url</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_application_title</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_router_gadget_url</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_manifest_url</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_jio_gadget_url</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>configuration_panel_gadget_url</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>string</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>_mt_index</string> </key>
<value>
......@@ -197,10 +274,39 @@
<key> <string>categories</string> </key>
<value>
<tuple>
<string>aggregate/web_page_module/jabber_gadget_jabberclient_html</string>
<string>caching_policy/must-revalidate</string>
<string>aggregate/web_page_module/rjs_gadget_erp5_html</string>
</tuple>
</value>
</item>
<item>
<key> <string>configuration_application_title</string> </key>
<value> <string>Jabber Client</string> </value>
</item>
<item>
<key> <string>configuration_content_security_policy</string> </key>
<value> <string>default-src \'none\'; img-src \'self\' data:; media-src \'self\' blob:; connect-src \'self\' data:; script-src \'self\' \'unsafe-eval\'; font-src netdna.bootstrapcdn.com; style-src \'self\' netdna.bootstrapcdn.com \'unsafe-inline\' data:; frame-src \'self\' data:</string> </value>
</item>
<item>
<key> <string>configuration_jio_gadget_url</string> </key>
<value> <string>gadget_jabberclient_jio.html</string> </value>
</item>
<item>
<key> <string>configuration_manifest_url</string> </key>
<value> <string>gadget_jabberclient.appcache</string> </value>
</item>
<item>
<key> <string>configuration_panel_gadget_url</string> </key>
<value> <string>gadget_jabberclient_panel.html</string> </value>
</item>
<item>
<key> <string>configuration_router_gadget_url</string> </key>
<value> <string>gadget_jabberclient_router.html</string> </value>
</item>
<item>
<key> <string>configuration_translation_gadget_url</string> </key>
<value> <string>gadget_translation.html</string> </value>
</item>
<item>
<key> <string>container_layout</string> </key>
<value> <string>WebSection_renderDefaultPageAsGadget</string> </value>
......@@ -225,9 +331,7 @@
</item>
<item>
<key> <string>layout_configuration_form_id</string> </key>
<value>
<none/>
</value>
<value> <string>WebSection_viewRenderJSPreference</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
......@@ -428,7 +532,7 @@
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>romain</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -442,7 +546,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>939.33823.21257.56849</string> </value>
<value> <string>949.24016.56134.48605</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -460,8 +564,8 @@
</tuple>
<state>
<tuple>
<float>1418206071.42</float>
<string>GMT</string>
<float>1456492716.38</float>
<string>UTC</string>
</tuple>
</state>
</object>
......
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