Browse Source

Sep 18: [FIX] Bug Fixed 'easy_chatgpt_access'

pull/332/head
Cybrosys Technologies 7 months ago
parent
commit
a810000a9d
  1. 2
      easy_chatgpt_access/__manifest__.py
  2. BIN
      easy_chatgpt_access/static/description/assets/screenshots/1.png
  3. BIN
      easy_chatgpt_access/static/description/assets/screenshots/2.png
  4. BIN
      easy_chatgpt_access/static/description/assets/screenshots/3.png
  5. BIN
      easy_chatgpt_access/static/description/assets/screenshots/4.png
  6. 4
      easy_chatgpt_access/static/description/index.html
  7. 2
      easy_chatgpt_access/static/src/js/chatgpt_button.js
  8. 19
      easy_chatgpt_access/static/src/js/chatgpt_dialog.js

2
easy_chatgpt_access/__manifest__.py

@ -43,7 +43,7 @@
'easy_chatgpt_access/static/src/js/chatgpt_dialog.js',
],
},
'images': ['static/description/banner.jpg'],
'images': ['static/description/banner.png'],
'license': 'AGPL-3',
'installable': True,
'auto_install': False,

BIN
easy_chatgpt_access/static/description/assets/screenshots/1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 400 KiB

After

Width:  |  Height:  |  Size: 40 KiB

BIN
easy_chatgpt_access/static/description/assets/screenshots/2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 261 KiB

After

Width:  |  Height:  |  Size: 35 KiB

BIN
easy_chatgpt_access/static/description/assets/screenshots/3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 298 KiB

After

Width:  |  Height:  |  Size: 132 KiB

BIN
easy_chatgpt_access/static/description/assets/screenshots/4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 134 KiB

4
easy_chatgpt_access/static/description/index.html

@ -27,10 +27,6 @@
style="background-color:#017E84 !important;font-size: 0.8rem !important; color:#fff !important; font-weight:500 !important; padding:4px !important; margin:0 3px !important; border-radius:50px !important; min-width: 120px !important;">
Community
</div>
<div class="text-center"
style="background-color:#875A7B !important; color:#fff !important;font-size: 0.8rem !important; font-weight:500 !important; padding:4px !important; margin:0 3px !important; border-radius:50px !important;min-width: 120px !important;">
Enterprise
</div>
</div>
</div>
</div>

2
easy_chatgpt_access/static/src/js/chatgpt_button.js

@ -125,7 +125,7 @@ export class SystrayIcon extends Component {
};
session.isEnterprise = function () {
return !!session.server_version_info[5];
};
};
SystrayIcon.template = "systray_icon";
export const systrayItem = {
Component: SystrayIcon,

19
easy_chatgpt_access/static/src/js/chatgpt_dialog.js

@ -11,6 +11,7 @@ patch(ChatGPTDialog.prototype, {
setup() {
super.setup(...arguments);
this.action = useService('action');
this.notification = useService("notification");
},
// Copy the generated AI text into clipboard when hitting the Copy button
copyMessage(ev) {
@ -22,16 +23,16 @@ patch(ChatGPTDialog.prototype, {
textArea.select();
var successful = document.execCommand('copy');
document.body.removeChild(textArea)
// Display notification after copying the text
this.action.doAction({
type: "ir.actions.client",
tag: "display_notification",
params: {
title: "Text copied",
message: "Text copied to Clipboard!",
sticky: false,
this.displayNotification(
("Text copied to Clipboard")
);
return successful;
},
displayNotification(text) {
this.notification.add(text, {
type: 'success',
title: 'Text copied',
sticky: false,
});
return successful;
}
})

Loading…
Cancel
Save