diff --git a/muk_web_share/README.md b/muk_web_share/README.md deleted file mode 100644 index c636b2c..0000000 --- a/muk_web_share/README.md +++ /dev/null @@ -1,5 +0,0 @@ -# MuK Web Share - -Adds a button to every form view. By clicking this button a dialog - opens and the current form can be shared with another user. On mobile -devices, the link of the form can be posted to Whatsapp. \ No newline at end of file diff --git a/muk_web_share/__init__.py b/muk_web_share/__init__.py index 48ccf85..21f21ae 100644 --- a/muk_web_share/__init__.py +++ b/muk_web_share/__init__.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - ################################################################################### # # Copyright (C) 2017 MuK IT GmbH diff --git a/muk_web_share/__manifest__.py b/muk_web_share/__manifest__.py index b2313f4..bc1d463 100644 --- a/muk_web_share/__manifest__.py +++ b/muk_web_share/__manifest__.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - ################################################################################### # # Copyright (C) 2017 MuK IT GmbH @@ -22,16 +20,11 @@ { "name": "MuK Web Share", "summary": """Share Button""", - "description": """ - Adds a button to every form view. By clicking - this button a dialog opens and the current form - can be shared with another user. On mobile devices, - the link of the form can be posted to Whatsapp. - """, - "version": "11.0.1.0.4", + "version": "11.0.2.0.0", "category": "Extra Tools", "license": "AGPL-3", "website": "http://www.mukit.at", + "live_test_url": "https://demo.mukit.at/web/login", "author": "MuK IT", "contributors": [ "Mathias Markl ", @@ -43,8 +36,6 @@ "data": [ "template/assets.xml", ], - "demo": [ - ], "qweb": [ "static/src/xml/*.xml", ], diff --git a/muk_web_share/doc/changelog.rst b/muk_web_share/doc/changelog.rst index 9ee2b48..f2ae21c 100644 --- a/muk_web_share/doc/changelog.rst +++ b/muk_web_share/doc/changelog.rst @@ -1,3 +1,8 @@ +`2.0.0` +------- + +- Migrated to Python 3 + `1.0.0` ------- diff --git a/muk_web_share/doc/index.rst b/muk_web_share/doc/index.rst new file mode 100644 index 0000000..0e909dc --- /dev/null +++ b/muk_web_share/doc/index.rst @@ -0,0 +1,49 @@ +============= +MuK Web Share +============= + +Adds a button to every form view. By clicking this button a dialog opens and the +current form can be shared with another user. On mobile devices, the link of the +form can be posted to Whatsapp. + +Installation +============ + +To install this module, you need to: + +Download the module and add it to your Odoo addons folder. Afterward, log on to +your Odoo server and go to the Apps menu. Trigger the debug modus and update the +list by clicking on the "Update Apps List" link. Now install the module by +clicking on the install button. + +Configuration +============= + +No additional configuration is needed to use this module. + +Usage +============= + +Go to any form view and in readonly mode there is a share button on the right +side of the form sheet. By clicking on this button the share dialog opens and +the currently active form can be shared with another user or into a channel. + +Credits +======= + +Contributors +------------ + +* Mathias Markl + +Author & Maintainer +------------------- + +This module is maintained by the `MuK IT GmbH `_. + +MuK IT is an Austrian company specialized in customizing and extending Odoo. +We develop custom solutions for your individual needs to help you focus on +your strength and expertise to grow your business. + +If you want to get in touch please contact us via mail +(sale@mukit.at) or visit our website (https://mukit.at). diff --git a/muk_web_share/static/description/demo.gif b/muk_web_share/static/description/demo.gif new file mode 100644 index 0000000..044ae41 Binary files /dev/null and b/muk_web_share/static/description/demo.gif differ diff --git a/muk_web_share/static/description/index.html b/muk_web_share/static/description/index.html index 8fe3b53..3d567d6 100644 --- a/muk_web_share/static/description/index.html +++ b/muk_web_share/static/description/index.html @@ -4,20 +4,23 @@

Share Odoo Forms to your colleagues.

MuK IT GmbH - www.mukit.at

-
- +
+
-
+

Overview

-

Adds a button to every form view. By clicking - this button a dialog opens and the current form can be shared with - another user. On mobile devices, the link of the form can be posted - to Whatsapp.

+

Adds a button to every form view. Go to any + form view and in readonly mode there is a share button on the right + side of the form sheet. By clicking on this button the share dialog + opens and the currently active form can be shared with another user + or into a channel.On mobile devices, the link of the form can be + posted to Whatsapp.

@@ -28,6 +31,7 @@

The button is added to every Odoo FormView and can be further customized using css or less.

+
@@ -42,20 +46,54 @@
-

After sending the url of the - form, the chat automatically opens.

+

If the form is sent in a channel + or directly to a user, the chat opens automatically. When sending it + to a new message, the dialog is closed and the URL is saved to the + clipboard.

+
+ + + +
+

Demo

+
+
+
User:
+
+
apps
+
+
+
Password:
+
+
+
demo
+
+
+

Help and Support

+
Feel free to + contact us, if you need any help with your Odoo integration or + addiontal features.
')); self.$content.find('.muk_share_buttons_whatsapp').attr("href", - 'whatsapp://send?text=' + self.url); + 'whatsapp://send?text=' + encodeURIComponent(self.url)); self.$content.find('.muk_share_buttons_email').attr("href", - 'mailto:?subject=&body=' + self.url); + 'mailto:?subject=' + _t("Share") + '&body=' + encodeURIComponent(self.url)); self.$content.find('.muk_share_buttons_chat').click(function(e) { e.preventDefault(); e.stopPropagation(); @@ -94,8 +94,8 @@ var ShareDialog = Dialog.extend({ model: 'res.users', method: 'search_read', context: session.user_context, - }).then(function(users) { - var users = _.filter(users, function (user) { + }).then(function(result) { + var users = _.filter(result, function (user) { return !user.share && user.id !== session.uid; }); self.$content.find('#user').append($(QWeb.render('muk_web_share.ShareUsers', { @@ -163,6 +163,7 @@ var ShareDialog = Dialog.extend({ newMessage: function(message) { this.copyClipboard(message); this.openChat(); + this.close(); }, openChat: function() { chat_manager.bus.trigger('open_chat');