Browse Source

Jan 8 [ADD] : Initial Commit 'odoo_database_restore_manager'

pull/195/merge
AjmalCybro 2 years ago
parent
commit
9e40561f52
  1. 52
      odoo_database_restore_manager/README.rst
  2. 23
      odoo_database_restore_manager/__init__.py
  3. 56
      odoo_database_restore_manager/__manifest__.py
  4. 6
      odoo_database_restore_manager/doc/RELEASE_NOTES.md
  5. 23
      odoo_database_restore_manager/models/__init__.py
  6. 235
      odoo_database_restore_manager/models/database_manager.py
  7. 34
      odoo_database_restore_manager/models/res_config_settings.py
  8. 3
      odoo_database_restore_manager/security/ir.model.access.csv
  9. BIN
      odoo_database_restore_manager/static/description/assets/icons/check.png
  10. BIN
      odoo_database_restore_manager/static/description/assets/icons/chevron.png
  11. BIN
      odoo_database_restore_manager/static/description/assets/icons/cogs.png
  12. BIN
      odoo_database_restore_manager/static/description/assets/icons/consultation.png
  13. BIN
      odoo_database_restore_manager/static/description/assets/icons/ecom-black.png
  14. BIN
      odoo_database_restore_manager/static/description/assets/icons/education-black.png
  15. BIN
      odoo_database_restore_manager/static/description/assets/icons/hotel-black.png
  16. BIN
      odoo_database_restore_manager/static/description/assets/icons/license.png
  17. BIN
      odoo_database_restore_manager/static/description/assets/icons/lifebuoy.png
  18. BIN
      odoo_database_restore_manager/static/description/assets/icons/manufacturing-black.png
  19. BIN
      odoo_database_restore_manager/static/description/assets/icons/pos-black.png
  20. BIN
      odoo_database_restore_manager/static/description/assets/icons/puzzle.png
  21. BIN
      odoo_database_restore_manager/static/description/assets/icons/restaurant-black.png
  22. BIN
      odoo_database_restore_manager/static/description/assets/icons/service-black.png
  23. BIN
      odoo_database_restore_manager/static/description/assets/icons/trading-black.png
  24. BIN
      odoo_database_restore_manager/static/description/assets/icons/training.png
  25. BIN
      odoo_database_restore_manager/static/description/assets/icons/update.png
  26. BIN
      odoo_database_restore_manager/static/description/assets/icons/user.png
  27. BIN
      odoo_database_restore_manager/static/description/assets/icons/wrench.png
  28. BIN
      odoo_database_restore_manager/static/description/assets/misc/categories.png
  29. BIN
      odoo_database_restore_manager/static/description/assets/misc/check-box.png
  30. BIN
      odoo_database_restore_manager/static/description/assets/misc/compass.png
  31. BIN
      odoo_database_restore_manager/static/description/assets/misc/corporate.png
  32. BIN
      odoo_database_restore_manager/static/description/assets/misc/customer-support.png
  33. BIN
      odoo_database_restore_manager/static/description/assets/misc/cybrosys-logo.png
  34. BIN
      odoo_database_restore_manager/static/description/assets/misc/features.png
  35. BIN
      odoo_database_restore_manager/static/description/assets/misc/logo.png
  36. BIN
      odoo_database_restore_manager/static/description/assets/misc/pictures.png
  37. BIN
      odoo_database_restore_manager/static/description/assets/misc/pie-chart.png
  38. BIN
      odoo_database_restore_manager/static/description/assets/misc/right-arrow.png
  39. BIN
      odoo_database_restore_manager/static/description/assets/misc/star.png
  40. BIN
      odoo_database_restore_manager/static/description/assets/misc/support.png
  41. BIN
      odoo_database_restore_manager/static/description/assets/misc/whatsapp.png
  42. BIN
      odoo_database_restore_manager/static/description/assets/modules/1.gif
  43. BIN
      odoo_database_restore_manager/static/description/assets/modules/2.png
  44. BIN
      odoo_database_restore_manager/static/description/assets/modules/3.png
  45. BIN
      odoo_database_restore_manager/static/description/assets/modules/4.png
  46. BIN
      odoo_database_restore_manager/static/description/assets/modules/5.png
  47. BIN
      odoo_database_restore_manager/static/description/assets/modules/6.png
  48. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/1.png
  49. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/2.png
  50. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/3.png
  51. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/4.png
  52. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/5.png
  53. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/6.png
  54. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/7.png
  55. BIN
      odoo_database_restore_manager/static/description/assets/screenshots/hero.gif
  56. BIN
      odoo_database_restore_manager/static/description/banner.jpg
  57. BIN
      odoo_database_restore_manager/static/description/icon.png
  58. 714
      odoo_database_restore_manager/static/description/index.html
  59. BIN
      odoo_database_restore_manager/static/src/img/odoo_logo.png
  60. BIN
      odoo_database_restore_manager/static/src/img/restore.png
  61. 77
      odoo_database_restore_manager/static/src/js/db_restore.js
  62. 60
      odoo_database_restore_manager/static/src/scss/db_restore.scss
  63. 53
      odoo_database_restore_manager/static/src/xml/db_restore_dashboard.xml
  64. 13
      odoo_database_restore_manager/views/database_manager_views.xml
  65. 25
      odoo_database_restore_manager/views/res_config_settings_views.xml
  66. 22
      odoo_database_restore_manager/wizard/__init__.py
  67. 106
      odoo_database_restore_manager/wizard/database_restore.py
  68. 24
      odoo_database_restore_manager/wizard/database_restore_views.xml

52
odoo_database_restore_manager/README.rst

@ -0,0 +1,52 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:target: https://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
Odoo Database Restore Manager
=============================
All the database backups that are stored by module auto_database_backup can be
restored and downloaded using this module.
Configuration
=============
The auto_database_backup module should be installed ( Here is the link: https://apps.odoo.com/apps/modules/15.0/auto_database_backup/ )
All the requirements for auto_database_backup module should be installed.
Installation
============
- www.odoo.com/documentation/15.0/setup/install.html
- Install our custom addon
License
-------
General Public License, Version 3 (AGPL v3).
(https://www.gnu.org/licenses/agpl-3.0-standalone.html)
Company
-------
* `Cybrosys Techno Solutions <https://cybrosys.com/>`__
Credits
-------
* Developer: (V15) Aslam A K, Contact: odoo@cybrosys.com
Contacts
--------
* Mail Contact : odoo@cybrosys.com
* Website : https://cybrosys.com
Bug Tracker
-----------
Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported.
Maintainer
==========
.. image:: https://cybrosys.com/images/logo.png
:target: https://cybrosys.com
This module is maintained by Cybrosys Technologies.
For support and more information, please visit https://www.cybrosys.com
Further information
===================
HTML Description: `<static/description/index.html>`__

23
odoo_database_restore_manager/__init__.py

@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
from . import models
from . import wizard

56
odoo_database_restore_manager/__manifest__.py

@ -0,0 +1,56 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
{
'name': "Odoo Database Restore Manager Odoo15",
'version': "15.0.1.0.0'",
'category': "Extra Tools",
'summary': """Easily Restore The Previous Database Backups Stored in Different Locations like Google Drive,
Dropbox, Onedrive, Nextcloud and Amazon S3""",
'description': """Easily Restore The Previous Database Backups Stored in Different Locations like Google Drive,
Dropbox, Onedrive, Nextcloud and Amazon S3, Odoo15, backup, restore""",
'author': 'Cybrosys Techno Solutions',
'company': 'Cybrosys Techno Solutions',
'maintainer': 'Cybrosys Techno Solutions',
'website': "https://www.cybrosys.com",
'depends': ['base_setup', 'auto_database_backup'],
'data': [
'security/ir.model.access.csv',
'views/database_manager_views.xml',
'views/res_config_settings_views.xml',
'wizard/database_restore_views.xml'
],
'assets': {
'web.assets_backend': [
'/odoo_database_restore_manager/static/src/js/db_restore.js',
'/odoo_database_restore_manager/static/src/scss/db_restore.scss'
],
'web.assets_qweb': [
'/odoo_database_restore_manager/static/src/xml/db_restore_dashboard.xml',
],
},
'external_dependencies': {'python': ['dropbox']},
'images': ['static/description/banner.jpg'],
'license': 'LGPL-3',
'installable': True,
'auto_install': False,
'application': True,
}

6
odoo_database_restore_manager/doc/RELEASE_NOTES.md

@ -0,0 +1,6 @@
## Module <odoo_database_restore_manager>
#### 05.01.2023
#### Version 15.0.1.0.0
#### ADD
- Initial commit for Odoo Database Restore Manager

23
odoo_database_restore_manager/models/__init__.py

@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
from . import database_manager
from . import res_config_settings

235
odoo_database_restore_manager/models/database_manager.py

@ -0,0 +1,235 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
import boto3
import dropbox
import ftplib
import nextcloud_client
import os
import paramiko
import requests
from datetime import datetime
from odoo import fields, models
class DatabaseRestoreManager(models.Model):
"""
Dashboard model to view all database backups
"""
_name = 'database.manager'
_description = 'Dashboard Model to View All Database Backups'
def action_import_files(self):
"""
Import latest backups from the storages configured
"""
return_data = {}
backup_count = int(self.env['ir.config_parameter'].get_param(
'odoo_database_restore_manager.backup_count'))
if backup_count <= 0:
return ['error', 'Please set a backup count', 'Storages']
if not self.env['db.backup.configure'].search([]):
return ['error', 'No Backups Found', 'auto_database_backup']
for rec in self.env['db.backup.configure'].search([]):
if rec.backup_destination == 'dropbox':
try:
dbx_dict = {}
dbx = dropbox.Dropbox(app_key=rec.dropbox_client_key,
app_secret=rec.dropbox_client_secret,
oauth2_refresh_token=
rec.dropbox_refresh_token)
response = dbx.files_list_folder(path=rec.dropbox_folder)
for files in response.entries:
file = dbx.files_get_temporary_link(
path=files.path_lower)
dbx_dict[file.metadata.name] = \
file.link, 'Dropbox', files.client_modified
return_data.update(dict(list(
sorted(dbx_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'Dropbox']
if rec.backup_destination == 'onedrive':
try:
onedrive_dict = {}
if rec.onedrive_token_validity <= fields.Datetime.now():
rec.generate_onedrive_refresh_token()
url = "https://graph.microsoft.com/v1.0/me/drive/items" \
"/%s/children?Content-Type=application/json" \
% rec.onedrive_folder_key
response = requests.request("GET", url, headers={
'Authorization': 'Bearer "' +
rec.onedrive_access_token + '"'},
data={})
for file in response.json().get('value'):
if list(file.keys())[0] == '@microsoft.graph.downloadUrl':
onedrive_dict[file['name']] = file[
'@microsoft.graph.downloadUrl'], 'OneDrive', \
datetime.strptime(
file['createdDateTime'],
"%Y-%m-%dT%H:%M:%S.%fZ").strftime(
"%Y-%m-%d %H:%M:%S")
return_data.update(dict(list(
sorted(onedrive_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'OneDrive']
if rec.backup_destination == 'google_drive':
try:
gdrive_dict = {}
if rec.gdrive_token_validity <= fields.Datetime.now():
rec.generate_gdrive_refresh_token()
response = requests.get(
f"https://www.googleapis.com/drive/v3/files",
headers={
"Authorization": "Bearer %s"
% rec.gdrive_access_token},
params={
"q": f"'{rec.google_drive_folder_key}' in parents",
"fields":
"files(name, webContentLink, createdTime)", })
for file_data in response.json().get("files", []):
gdrive_dict[file_data.get("name")] = file_data.get(
"webContentLink"), 'Google Drive', \
datetime.strptime(file_data.get("createdTime"),
"%Y-%m-%dT%H:%M:%S.%fZ").strftime(
"%Y-%m-%d %H:%M:%S")
return_data.update(dict(list(
sorted(gdrive_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'Google Drive']
if rec.backup_destination == 'local':
try:
local_dict = {}
for root, dirs, files in os.walk(rec.backup_path):
for file in files:
file_path = os.path.join(root, file)
create_date = datetime.fromtimestamp(
os.path.getctime(file_path)).strftime(
"%Y-%m-%d %H:%M:%S")
local_dict[
file] = file_path, 'Local Storage', create_date
return_data.update(dict(list(
sorted(local_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'Local']
if rec.backup_destination == 'ftp':
try:
ftp_dict = {}
ftp_server = ftplib.FTP()
ftp_server.connect(rec.ftp_host, int(rec.ftp_port))
ftp_server.login(rec.ftp_user, rec.ftp_password)
for file in ftp_server.nlst(rec.ftp_path):
file_details = ftp_server.voidcmd("MDTM " + file)
ftp_dict[os.path.basename(
file)] = file, 'FTP Storage', datetime.strptime(
file_details[4:].strip(), "%Y%m%d%H%M%S")
ftp_server.quit()
return_data.update(dict(list(
sorted(ftp_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'FTP server']
if rec.backup_destination == 'sftp':
sftp_client = paramiko.SSHClient()
sftp_client.set_missing_host_key_policy(
paramiko.AutoAddPolicy())
try:
sftp_dict = {}
sftp_client.connect(hostname=rec.sftp_host,
username=rec.sftp_user,
password=rec.sftp_password,
port=rec.sftp_port)
sftp_server = sftp_client.open_sftp()
sftp_server.chdir(rec.sftp_path)
file_list = sftp_server.listdir()
for file_name in file_list:
sftp_dict[file_name] = os.path.join(rec.sftp_path,
file_name),\
'SFTP Storage', datetime.fromtimestamp(
sftp_server.stat(file_name).st_mtime)
sftp_server.close()
return_data.update(dict(list(
sorted(sftp_dict.items(), key=lambda x: x[1][2],
reverse=True))[:backup_count]))
except Exception as error:
return ['error', error, 'SFTP server']
finally:
sftp_client.close()
if rec.backup_destination == 'next_cloud':
try:
nxt_dixt = {}
nc_access = nextcloud_client.Client(rec.domain)
nc_access.login(rec.next_cloud_user_name,
rec.next_cloud_password)
for file_name in [file.name for file in
nc_access.list(
'/' + rec.nextcloud_folder_key)]:
link_info = nc_access.share_file_with_link(
'/' + rec.nextcloud_folder_key + '/' + file_name,
publicUpload=False)
file_info = nc_access.file_info(
'/' + rec.nextcloud_folder_key + '/' + file_name)
input_datetime = datetime.strptime(
file_info.attributes['{DAV:}getlastmodified'],
"%a, %d %b %Y %H:%M:%S %Z")
output_date_str = input_datetime.strftime(
"%Y-%m-%d %H:%M:%S")
nxt_dixt[
file_name] = link_info.get_link() + '/download', 'Nextcloud', output_date_str
return_data.update(dict(list(sorted(nxt_dixt.items(),
key=lambda x: x[1][2],
reverse=True))[
:backup_count]))
except Exception as e:
# Handle any exceptions that occur during SFTP Storage
# backup retrieval
return ['error', e, 'Nextcloud']
if rec.backup_destination == 'amazon_s3':
try:
s3_dixt = {}
client = boto3.client('s3', aws_access_key_id=rec.aws_access_key,
aws_secret_access_key=rec.aws_secret_access_key)
region = client.get_bucket_location(Bucket=rec.bucket_file_name)
client = boto3.client(
's3', region_name=region['LocationConstraint'],
aws_access_key_id=rec.aws_access_key,
aws_secret_access_key=rec.aws_secret_access_key
)
response = client.list_objects(Bucket=rec.bucket_file_name, Prefix=rec.aws_folder_name)
for data in response['Contents']:
if data['Size'] != 0:
url = client.generate_presigned_url(
ClientMethod='get_object',
Params={'Bucket': rec.bucket_file_name,
'Key': data['Key']}, ExpiresIn=3600)
s3_dixt[data['Key']] = url, 'AmazonS3', data['LastModified']
return_data.update(dict(list(sorted(s3_dixt.items(),
key=lambda x: x[1][2],
reverse=True))[
:backup_count]))
except Exception as e:
# Handle any exceptions that occur during amazon_s3 Storage
# backup retrieval
return ['error', e, 'Amazon S3']
return return_data

34
odoo_database_restore_manager/models/res_config_settings.py

@ -0,0 +1,34 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
from odoo import fields, models
class ResConfigSettings(models.TransientModel):
"""
Configure the number of backups for restore
"""
_inherit = 'res.config.settings'
backup_count = fields.Integer(string='Backup Count',
help='Number of backups to list for restore',
config_parameter=
'odoo_database_restore_manager.backup_count')

3
odoo_database_restore_manager/security/ir.model.access.csv

@ -0,0 +1,3 @@
id,name,model_id/id,group_id/id,perm_read,perm_write,perm_create,perm_unlink
access_database_manager,access.database.manager,model_database_manager,base.group_user,1,1,1,1
access_database_restore,access.database.restore,model_database_restore,base.group_user,1,1,1,1
1 id name model_id/id group_id/id perm_read perm_write perm_create perm_unlink
2 access_database_manager access.database.manager model_database_manager base.group_user 1 1 1 1
3 access_database_restore access.database.restore model_database_restore base.group_user 1 1 1 1

BIN
odoo_database_restore_manager/static/description/assets/icons/check.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/chevron.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

BIN
odoo_database_restore_manager/static/description/assets/icons/cogs.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/consultation.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/ecom-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 576 B

BIN
odoo_database_restore_manager/static/description/assets/icons/education-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 733 B

BIN
odoo_database_restore_manager/static/description/assets/icons/hotel-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 911 B

BIN
odoo_database_restore_manager/static/description/assets/icons/license.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/lifebuoy.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/manufacturing-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 673 B

BIN
odoo_database_restore_manager/static/description/assets/icons/pos-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 878 B

BIN
odoo_database_restore_manager/static/description/assets/icons/puzzle.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 B

BIN
odoo_database_restore_manager/static/description/assets/icons/restaurant-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 905 B

BIN
odoo_database_restore_manager/static/description/assets/icons/service-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 839 B

BIN
odoo_database_restore_manager/static/description/assets/icons/trading-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 427 B

BIN
odoo_database_restore_manager/static/description/assets/icons/training.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 627 B

BIN
odoo_database_restore_manager/static/description/assets/icons/update.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
odoo_database_restore_manager/static/description/assets/icons/user.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 988 B

BIN
odoo_database_restore_manager/static/description/assets/icons/wrench.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/categories.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/check-box.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/compass.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/corporate.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/customer-support.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/cybrosys-logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/features.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 B

BIN
odoo_database_restore_manager/static/description/assets/misc/logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/pictures.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/pie-chart.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/right-arrow.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 967 B

BIN
odoo_database_restore_manager/static/description/assets/misc/star.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/support.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

BIN
odoo_database_restore_manager/static/description/assets/misc/whatsapp.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.0 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/1.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 538 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/2.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/3.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/4.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/5.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

BIN
odoo_database_restore_manager/static/description/assets/modules/6.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

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

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

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

Binary file not shown.

After

Width:  |  Height:  |  Size: 121 KiB

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

Binary file not shown.

After

Width:  |  Height:  |  Size: 122 KiB

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

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

BIN
odoo_database_restore_manager/static/description/assets/screenshots/5.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

BIN
odoo_database_restore_manager/static/description/assets/screenshots/6.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

BIN
odoo_database_restore_manager/static/description/assets/screenshots/7.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 121 KiB

BIN
odoo_database_restore_manager/static/description/assets/screenshots/hero.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 200 KiB

BIN
odoo_database_restore_manager/static/description/banner.jpg

Binary file not shown.

After

Width:  |  Height:  |  Size: 90 KiB

BIN
odoo_database_restore_manager/static/description/icon.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

714
odoo_database_restore_manager/static/description/index.html

@ -0,0 +1,714 @@
<div style="background-color: #714B67; min-height: 600px; width: 100%; padding: 15px; position: relative;">
<!-- TITLE BAR -->
<div class="d-flex align-items-center justify-content-between"
style="border-bottom: 1px solid #875A7B; padding: 15px; display: flex; justify-content: space-between; align-items: center;">
<img src="assets/misc/cybrosys-logo.png" width="42" height="42"
style="width: 42px; height: 42px;"/>
<div>
<div style="color: #7C7BAD; font-size: 14px; font-family: 'Montserrat', sans-serif; font-weight: bold; background-color: white; display: inline-block; padding: 3px 10px; border-radius: 50px;"
class="mr-2">
<i class="fa fa-check mr-1"></i>Community
</div>
<div style="color: #875A7B; font-size: 14px; font-family: 'Montserrat', sans-serif; font-weight: bold; background-color: white; display: inline-block; padding: 3px 10px; border-radius: 50px;"
class="mr-2">
<i class="fa fa-check mr-1"></i>Enterprise
</div>
</div>
</div>
<!-- END OF TITLE BAR -->
<div class="container">
<div class="row">
<div class="col-sm-12 col-md-12 col-lg-12">
<!-- APP HERO -->
<h1 style="color: #FFFFFF; font-weight: bolder; font-size: 50px; text-align: center; margin-top: 50px;">
Odoo Database Restore Manager</h1>
<p style="color:#FFFFFF; padding: 8px 15px; text-align: center; font-size: 24px;">
Easily Restore The Previous Database Backups Stored in Different Locations like Google Drive,
Dropbox, Onedrive, Nextcloud and Amazon S3
</p>
<!-- END OF APP HERO -->
<img src="assets/screenshots/hero.gif"
style="width: 75%; height: auto; position: absolute; margin-left: auto; margin-right: auto; top: 45%; left: 12%; right: auto;"/>
</div>
</div>
</div>
</div>
<!-- NAVIGATION SECTION -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px; margin-top: 300px;">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/compass.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Explore This
Module</h2>
</div>
<div class="row my-4" style="font-family: 'Montserrat', sans-serif;">
<div class="col-sm-12 col-md-6 my-3">
<a href="#overview">
<div class="d-flex justify-content-between align-items-center"
style="background-color: #f5f5f5; padding: 30px; width: 100%;">
<div>
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Overview</span>
<span
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">Learn
more about this
module</span>
</div>
<img src="assets/misc/right-arrow.png" width="36"
height="36"/>
</div>
</a>
</div>
<div class="col-sm-12 col-md-6 my-3">
<a href="#features">
<div class="d-flex justify-content-between align-items-center"
style="background-color: #f5f5f5; padding: 30px; width: 100%;">
<div>
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Features</span>
<span
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">View
features of this
module</span>
</div>
<img src="assets/misc/right-arrow.png" width="36"
height="36"/>
</div>
</a>
</div>
<div class="col-sm-12 col-md-6 my-3">
<a href="#screenshots">
<div class="d-flex justify-content-between align-items-center"
style="background-color: #f5f5f5; padding: 30px; width: 100%;">
<div>
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Screenshots</span>
<span
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">View
screenshots for this
module</span>
</div>
<img src="assets/misc/right-arrow.png" width="36"
height="36"/>
</div>
</a>
</div>
</div>
<!-- END OF NAVIGATION SECTION -->
<!-- OVERVIEW SECTION -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;"
id="overview">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/pie-chart.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Overview
</h2>
</div>
<div class="row"
style="font-family: 'Montserrat', sans-serif; font-weight: 400; font-size: 14px; line-height: 200%;">
<div class="col-sm-12 py-4">
Odoo Database Restore Manager enhances the database restoration process
by seamlessly restoring database backups that were previously uploaded
to different storage locations using the "<a
href="https://apps.odoo.com/apps/modules/15.0/auto_database_backup/">
auto_database_backup </a>" module.
With the Odoo Database Restore Manager, users can effortlessly restore
their Odoo databases from previously created backups. It simplifies the
restoration process and provides a centralized interface to manage and
restore backups stored in various locations.
The app integrates seamlessly with the "auto_database_backup" module,
which automatically creates backups of Odoo databases and uploads them
to different storage options such as local directories, FTP servers,
SFTP servers, Google Drive, Dropbox, and OneDrive. By utilizing
the auto_database_backup module, users can schedule regular backups and
store them in diverse storage locations for enhanced data protection.
</div>
</div>
<!-- END OF OVERVIEW SECTION -->
<!-- FEATURES SECTION -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;"
id="features">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/features.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Features
</h2>
</div>
<div class="row"
style="font-family: 'Montserrat', sans-serif; font-weight: 400; font-size: 14px; line-height: 200%;">
<div class="col-sm-12 col-md-6">
<div class="d-flex align-items-center"
style="margin-top: 40px; margin-bottom: 40px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Easy and Flexible Restoration</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Google Drive</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Dropbox</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Onedrive</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Google Drive</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Nextcloud</span>
</div>
<div class="d-flex align-items-center"
style="margin-top: 30px; margin-bottom: 30px">
<img src="assets/misc/check-box.png" class="mr-2"/>
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Restore Previous Database from Amazon S3</span>
</div>
</div>
</div>
<!-- END OF FEATURES SECTION -->
<!-- SCREENSHOTS SECTION -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;"
id="screenshots">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/pictures.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Screenshots
</h2>
</div>
<div class="row">
<div class="col-sm-12">
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Configure Backups by <a
href="https://apps.odoo.com/apps/modules/15.0/auto_database_backup/">
Automatic Database Backup </a> Module
</h3>
<p
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
</p>
<img src="assets/screenshots/1.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Configure the Number of Latest Backups to be Shown
</h3>
<p
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
</p>
<img src="assets/screenshots/2.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Database Restore Manager View
</h3>
<p
style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
</p>
<img src="assets/screenshots/3.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Filter on Storage Location and Restore Button
</h3>
<p style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
<img src="assets/screenshots/4.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Restoring Database Backup
</h3>
<p style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
New Database Name and Master Password
</p>
<img src="assets/screenshots/5.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Restore Complete
</h3>
<p style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
</p>
<img src="assets/screenshots/6.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">
Download Backups
</h3>
<p style="font-family: 'Roboto', sans-serif !important; font-weight: 400 !important; color: #282F33 !important; font-size: 1rem !important;">
</p>
<img src="assets/screenshots/7.png" class="img-thumbnail">
</div>
</div>
</div>
<!-- END OF SCREENSHOTS SECTION -->
<!-- RELATED PRODUCTS -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/categories.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Related
Products
</h2>
</div>
<div class="row">
<div class="col-sm-12">
<div id="demo1" class="row carousel slide" data-ride="carousel">
<!-- The slideshow -->
<div class="carousel-inner" style="padding: 30px;">
<div class="carousel-item" style="min-height: 198.656px;">
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/auto_database_backup/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/1.gif">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/odoo_dynamic_dashboard/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/2.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/all_in_one_dynamic_custom_fields/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/3.png">
</div>
</a>
</div>
</div>
<div class="carousel-item active"
style="min-height: 198.656px;">
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/export_stockinfo_xls/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/4.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/auto_database_backup/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/5.png">
</div>
</a>
</div>
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16"
style="float:left">
<a href="https://apps.odoo.com/apps/modules/15.0/hide_menu_user/"
target="_blank">
<div style="border-radius:10px">
<img class="img img-responsive center-block"
style="border-radius: 0px;"
src="assets/modules/6.png">
</div>
</a>
</div>
</div>
</div>
<!-- Left and right controls -->
<a class="carousel-control-prev" href="#demo1" data-slide="prev"
style="width:35px; color:#000"> <span
class="carousel-control-prev-icon"><i
class="fa fa-chevron-left"
style="font-size:24px"></i></span>
</a> <a class="carousel-control-next" href="#demo1"
data-slide="next" style="width:35px; color:#000">
<span class="carousel-control-next-icon"><i
class="fa fa-chevron-right"
style="font-size:24px"></i></span>
</a>
</div>
</div>
</div>
<!-- END OF RELATED PRODUCTS -->
<!-- OUR SERVICES -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/star.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Our Services
</h2>
</div>
<div class="container my-5">
<div class="row">
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #1dd1a1 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/cogs.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Customization</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #ff6b6b !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/wrench.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Implementation</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #6462CD !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/lifebuoy.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Support</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #ffa801 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/user.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Hire
Odoo
Developer</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #54a0ff !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/puzzle.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Integration</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #6d7680 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/update.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Migration</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #786fa6 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/consultation.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Consultancy</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #f8a5c2 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/training.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Implementation</h6>
</div>
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4">
<div class="d-flex justify-content-center align-items-center mx-3 my-3"
style="background-color: #e6be26 !important; border-radius: 15px !important; height: 80px; width: 80px;">
<img src="assets/icons/license.png" class="img-responsive"
height="48px" width="48px">
</div>
<h6 class="text-center"
style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;">
Odoo
Licensing Consultancy</h6>
</div>
</div>
</div>
<!-- END OF OUR SERVICES -->
<!-- OUR INDUSTRIES -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/corporate.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Our
Industries
</h2>
</div>
<div class="container my-5">
<div class="row">
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/trading-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Trading
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Easily procure
and
sell your products</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/pos-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
POS
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Easy
configuration
and convivial experience</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/education-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Education
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
A platform for
educational management</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/manufacturing-black.png"
class="img-responsive mb-3" height="48px"
width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Manufacturing
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Plan, track and
schedule your operations</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/ecom-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
E-commerce &amp; Website
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Mobile
friendly,
awe-inspiring product pages</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/service-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Service Management
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Keep track of
services and invoice</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/restaurant-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Restaurant
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
Run your bar or
restaurant methodically</p>
</div>
</div>
<div class="col-lg-3">
<div class="my-4 d-flex flex-column justify-content-center"
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;">
<img src="assets/icons/hotel-black.png"
class="img-responsive mb-3" height="48px" width="48px">
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;">
Hotel Management
</h5>
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;">
An
all-inclusive
hotel management application</p>
</div>
</div>
</div>
</div>
<!-- END OF OUR INDUSTRIES -->
<!-- SUPPORT -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;">
<div class="d-flex justify-content-center align-items-center mr-2"
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;">
<img src="assets/misc/customer-support.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Support
</h2>
</div>
<div class="container mt-5">
<div class="row">
<div class="col-sm-12 col-md-6">
<div style="background-color: #F6F8F9; padding: 30px; display: flex; align-items: center;">
<div class="mr-4"
style="background-color: #714B67; display: inline-block; height: 70px; width: 70px; display: flex; align-items: center; justify-content: center;">
<img src="assets/misc/support.png" height="48" width="48"
style="width: 42px; height: 42px;"/>
</div>
<div>
<h4>Need Help?</h4>
<p style="line-height: 100%;">Got questions or need help?
Get in touch.</p>
<a href="mailto:odoo@cybrosys.com">
<p style="font-weight: 400; font-size: 28px; line-height: 80%; color: #714B67;">
odoo@cybrosys.com</p>
</a>
</div>
</div>
</div>
<div class="col-sm-12 col-md-6">
<div style="background-color: #F6F8F9; padding: 30px; display: flex; align-items: center;">
<div class="mr-4"
style="background-color: #2AC44D; display: inline-block; height: 70px; width: 70px; display: flex; align-items: center; justify-content: center;">
<img src="assets/misc/whatsapp.png" height="52" width="52"
style="width: 52px; height: 52px;"/>
</div>
<div>
<h4>WhatsApp</h4>
<p style="line-height: 100%;">Say hi to us on WhatsApp!</p>
<a href="https://api.whatsapp.com/send?phone=918606827707">
<p style="font-weight: 400; font-size: 28px; line-height: 80%; color: #714B67;">
+91 86068
27707</p>
</a>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-12 my-5 d-flex justify-content-center align-items-center">
<img src="assets/misc/logo.png" width="144" height="31"
style="width:144px; height: 31px; margin-top: 40px;"/>
</div>
</div>
</div>
<!-- END OF SUPPORT -->

BIN
odoo_database_restore_manager/static/src/img/odoo_logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

BIN
odoo_database_restore_manager/static/src/img/restore.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

77
odoo_database_restore_manager/static/src/js/db_restore.js

@ -0,0 +1,77 @@
odoo.define('odoo_database_restore_manager.dashboard', function (require) {
'use strict';
var AbstractAction = require('web.AbstractAction');
var core = require('web.core');
var rpc = require('web.rpc');
var DbRestoreDashboard = AbstractAction.extend({
template: 'DbRestoreDashboard',
events: {
'click #db_restore': 'restore',
'change #db_location': 'filter_location',
},
// Appends backups retrieved by function(action_import_files) to div db_restore_files.
init: function () {
this._super.apply(this, arguments);
var self = this;
rpc.query({
model: 'database.manager',
method: 'action_import_files',
args: ['']
}).then(function (result) {
if (result[0] == 'error') {
self.do_action({
'type': 'ir.actions.client',
'tag': 'display_notification',
'params': {
'message': 'Failed to Load Files from ' + result[2] + ' [ ' + result[1] + ' ]',
'type': 'warning',
'sticky': false,
}
});
} else {
var count = 1;
_.each(result, function (name, index) {
var downloadBackup = '';
if (['Dropbox', 'OneDrive', 'Google Drive', 'Nextcloud', 'AmazonS3'].includes(name[1])) {
downloadBackup = '<a href="' + name[0] + '"> <button type="button" class="backup_download btn btn-primary"> <i class="fa fa-download o_pivot_download"></i></button></a>';
}
self.$el.find('.db_restore_files').append('<tr class="file_row table-secondary"><td scope="row" style="text-align:center;">' + count + '</td><td>' + index + '</td><td>' + name[1] + '</td><td>' + name[2] + '</td><td><button type="button" id="db_restore" value=' + name[0] + ' class="btn btn-primary"><i class="fa fa-floppy-o fa-fw"></i> Restore </button>' + downloadBackup + '</td></tr>');
count++;
});
}
});
},
// Open up the wizard to restore the selected backup file.
restore: function (ev) {
this.do_action({
name: "Restore Database",
type: 'ir.actions.act_window',
res_model: 'database.restore',
view_mode: 'form',
view_type: 'form',
views: [[false, 'form']],
context: {
default_db_file: ev.target.getAttribute('value'),
default_backup_location: this.$(ev.target).closest('tr').find('td').eq(2).text()
},
target: 'new',
});
},
// Filter backups based on storage types.
filter_location: function (ev) {
var e = this.$("#db_location").get(0);
var self = this;
this.$('.file_row').each(function (index, name) {
self.$(this).hide();
var location = self.$(name).find('td').eq(2).text();
if (e.value === 'all_backups') {
self.$(this).show();
} else if (e.value === location) {
self.$(this).show();
}
});
},
});
core.action_registry.add("database_manager_dashboard", DbRestoreDashboard);
return DbRestoreDashboard;
});

60
odoo_database_restore_manager/static/src/scss/db_restore.scss

@ -0,0 +1,60 @@
#db_location {
outline: none;
border: none;
font-size: 15px;
box-shadow: none;
background-color: #fff;
padding: 4px 24px;
height: 40px;
}
.db_restore_content {
height: 100%;
width: 100%;
}
#db_restore {
color: #ffffff;
width: 90px;
background-color: #b1b1b1;
height: 30px;
border: none;
text-transform: capitalize;
}
#db_restore:hover {
background-color: #000;
color: #fff;
}
.backup_download {
color: #ffffff;
width: 30px;
background-color: #b1b1b1;
height: 30px;
border: none;
text-transform: capitalize;
}
.backup_download:hover {
background-color: #000;
color: #fff;
}
.table-head {
background-color: #2e2e2e;
color: #fff;
border: 1px solid #eaeaea;
}
.file_row {
--table-bg: #ffffff;
color: #000;
border: 1px solid #eaeaea;
}
.scrollable-table {
height: 75vh;
overflow-y: auto;
}
.company_image {
max-width: 200px;
max-height: 100px;
margin: 20px;
}
.option {
background-color: black;
color: white;
}

53
odoo_database_restore_manager/static/src/xml/db_restore_dashboard.xml

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!-- Dashboard template -->
<template id="db_restore">
<t t-name="DbRestoreDashboard">
<section class="dashboard_main_section db_restore_section"
id="main_section_manager">
<center>
<img src="/odoo_database_restore_manager/static/src/img/odoo_logo.png"
style="width:300px; margin: 20px;"/>
</center>
<!-- Selection for filtering on basis of storage types -->
<div class="filter_location"
style="float:right;margin-right: 15px; margin-bottom: 10px;">
<label for="db_location">
<select id="db_location" class="form-select">
<option value="all_backups">All Backups</option>
<option value="OneDrive">OneDrive</option>
<option value="Dropbox">Dropbox</option>
<option value="AmazonS3">Amazon</option>
<option value="Google Drive">Google Drive</option>
<option value="Local Storage">Local Storage</option>
<option value="FTP Storage">FTP Storage</option>
<option value="SFTP Storage">SFTP Storage</option>
<option value="Nextcloud">Nextcloud</option>
</select>
</label>
</div>
<br/>
<!-- Table to show all Backup Files -->
<div class="db_restore_content">
<table class="table table-light table-hover"
id="db_restore_table">
<thead class="table-dark" style="--table-bg: #8e8f8f;">
<tr style="test-align:center;">
<th class="sort-number" style="text-align:center;"
scope="col">SL NO:
</th>
<th class="sort-time" scope="col">Backup Files</th>
<th class="sort-time" scope="col">Backup Location
</th>
<th class="sort-time" scope="col">Time (UTC)</th>
<th scope="col"/>
<th scope="col"/>
</tr>
</thead>
<tbody class="db_restore_files" style="test-align:center;">
<!-- Appends files here -->
</tbody>
</table>
</div>
</section>
</t>
</template>

13
odoo_database_restore_manager/views/database_manager_views.xml

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<!-- Database manager views -->
<record id="database_manager_action" model="ir.actions.client">
<field name="name">Database Restore</field>
<field name="tag">database_manager_dashboard</field>
<field name="target">current</field>
</record>
<menuitem id="odoo_database_restore_manager_menu_root"
parent="auto_database_backup.db_backup_menu_root"
name="Database Restore Manager"
action="database_manager_action"/>
</odoo>

25
odoo_database_restore_manager/views/res_config_settings_views.xml

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<!-- Set backup count view on settings -->
<record id="res_config_settings_view_form" model="ir.ui.view">
<field name="name">
res.config.settings.view.form.inherit.odoo_database_restore_manager
</field>
<field name="model">res.config.settings</field>
<field name="inherit_id" ref="base.res_config_settings_view_form"/>
<field name="arch" type="xml">
<xpath expr="//div[@id='user_default_rights']" position="inside">
<div class="col-12 col-lg-6 o_setting_box">
<div class="o_setting_left_pane"/>
<div class="o_setting_right_pane">
<label string="Backup Count" for="backup_count"/>
<div class="text-muted">
Configure the number of backups to restore
</div>
<field name="backup_count"/>
</div>
</div>
</xpath>
</field>
</record>
</odoo>

22
odoo_database_restore_manager/wizard/__init__.py

@ -0,0 +1,22 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
from . import database_restore

106
odoo_database_restore_manager/wizard/database_restore.py

@ -0,0 +1,106 @@
# -*- coding: utf-8 -*-
###############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Aslam AK (odoo@cybrosys.com)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL v3), Version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
###############################################################################
import ftplib
import gdown
import odoo
import odoo.modules.registry
import os
import paramiko
import requests
import tempfile
from odoo import fields, models, _
from odoo.exceptions import UserError
from odoo.http import dispatch_rpc
from odoo.service import db
from odoo.tools.misc import str2bool
class DataBaseRestore(models.TransientModel):
"""
Database Restore Model
"""
_name = "database.restore"
_description = "Restore Backups"
db_file = fields.Char(string="File",
help="Path or URL to the database backup file")
db_name = fields.Char(string="Database Name",
help="Name of the database to restore")
db_master_pwd = fields.Char(string="Database Master Password",
help="Master password for the database")
backup_location = fields.Char(string="Backup Location",
help="Location where the database backup is "
"stored")
def action_restore_database(self, copy=False):
"""
Function to restore the database Backups
"""
insecure = odoo.tools.config.verify_admin_password('admin')
if insecure and self.db_master_pwd:
dispatch_rpc('db', 'change_admin_password',
["admin", self.db_master_pwd])
try:
db.check_super(self.db_master_pwd)
temp_file = tempfile.NamedTemporaryFile(delete=False)
if self.backup_location == 'Google Drive':
gdown.download(self.db_file, temp_file.name, quiet=False)
elif self.backup_location in ['Dropbox', 'OneDrive']:
response = requests.get(self.db_file, stream=True)
temp_file.write(response.content)
elif self.backup_location == 'FTP Storage':
for rec in self.env['db.backup.configure'].search([]):
if rec.backup_destination == 'ftp' and \
rec.ftp_path == os.path.dirname(self.db_file):
ftp_server = ftplib.FTP()
ftp_server.connect(rec.ftp_host, int(rec.ftp_port))
ftp_server.login(rec.ftp_user, rec.ftp_password)
ftp_server.retrbinary("RETR " + self.db_file,
temp_file.write)
temp_file.seek(0)
ftp_server.quit()
elif self.backup_location == 'SFTP Storage':
for rec in self.env['db.backup.configure'].search([]):
if rec.backup_destination == 'sftp' and \
rec.sftp_path == os.path.dirname(self.db_file):
sftp_client = paramiko.SSHClient()
sftp_client.set_missing_host_key_policy(
paramiko.AutoAddPolicy())
sftp_client.connect(hostname=rec.sftp_host,
username=rec.sftp_user,
password=rec.sftp_password,
port=rec.sftp_port)
sftp_server = sftp_client.open_sftp()
sftp_server.getfo(self.db_file, temp_file)
sftp_server.close()
sftp_client.close()
elif self.backup_location == 'Local Storage':
temp_file.name = self.db_file
db.restore_db(self.db_name, temp_file.name, str2bool(copy))
temp_file.close()
return {
'type': 'ir.actions.act_url',
'url': '/web/database/manager'
}
except Exception as error:
raise UserError(
_("Database restore error: %s" % (str(error) or repr(error))))

24
odoo_database_restore_manager/wizard/database_restore_views.xml

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- Restore database wizard view -->
<record id="database_restore_view_form" model="ir.ui.view">
<field name="name">database.restore.view.form</field>
<field name="model">database.restore</field>
<field name="arch" type="xml">
<form string="database restore wizard">
<group class="oe_title">
<field name="db_name"/>
<field name="db_master_pwd" password="True"/>
</group>
<footer>
<button string="Restore" name="action_restore_database"
type="object"
class="oe_highlight" data-hotkey="q"
help="Confirm Upload"/>
<button string="Cancel" class="btn btn-secondary"
special="cancel" help="Cancel Upload"/>
</footer>
</form>
</field>
</record>
</odoo>
Loading…
Cancel
Save