public inbox for [email protected]
help / color / mirror / Atom feedFrom: Murtuza Zabuawala <[email protected]>
To: Ashesh Vashi <[email protected]>
Cc: pgadmin-hackers <[email protected]>
Subject: Re: PATCH: Initiale backup utility [pgAdmin4]
Date: Sat, 14 May 2016 22:35:20 +0530
Message-ID: <CAKKotZSBvbYvMRszGnizxnsSoZEgJnoN7J5zuqQZJJcEuP6OKA@mail.gmail.com> (raw)
In-Reply-To: <CAG7mmow9+8-E=-uMiqJ+_nBkVHVbQsVqx4qgPcvmWO-L7R=VZw@mail.gmail.com>
References: <CAKKotZT0Uz66ZSVmzXBRPbyVL1Zz3dJBvfWChOGYPvuw-6ioBw@mail.gmail.com>
<CAG7mmow9+8-E=-uMiqJ+_nBkVHVbQsVqx4qgPcvmWO-L7R=VZw@mail.gmail.com>
List-Unsubscribe: <mailto:[email protected]?body=unsub%20pgadmin-hackers>
Hi,
PFA patch for backup which is add-on to last patch which includes TODO list
& node selection validation
Regards,
Murtuza
--
Regards,
Murtuza Zabuawala
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
On Fri, May 13, 2016 at 5:39 PM, Ashesh Vashi <[email protected]
> wrote:
> On Tue, May 3, 2016 at 5:41 PM, Murtuza Zabuawala <
> [email protected]> wrote:
>
>> Hi,
>>
>> PFA patch to add backup server/global/database object functionality.
>>
>> This patch depends on,
>> - File manager control patch & job executer.
>>
>>
>> *TODO:*
>> - Integrate browser tree control
>>
> Put that in the TODO list.
>
> We will select the current object at the moment for backup at the moment.
>
> We will add object selection in later phase.
>
> Please take look at the patch.
> It needs to define the message class properly for better message.
>
> --
>
> Thanks & Regards,
>
> Ashesh Vashi
> EnterpriseDB INDIA: Enterprise PostgreSQL Company
> <http://www.enterprisedb.com/;
>
>
> *http://www.linkedin.com/in/asheshvashi*
> <http://www.linkedin.com/in/asheshvashi;
>
>>
>>
>> --
>> Regards,
>> Murtuza Zabuawala
>> EnterpriseDB: http://www.enterprisedb.com
>> The Enterprise PostgreSQL Company
>>
>>
>> --
>> Sent via pgadmin-hackers mailing list ([email protected])
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgadmin-hackers
>>
>>
>
--
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
Attachments:
[application/octet-stream] Added_selected_object.patch (2.3K, 3-Added_selected_object.patch)
download | inline diff:
diff --git a/web/pgadmin/tools/backup/templates/backup/js/backup.js b/web/pgadmin/tools/backup/templates/backup/js/backup.js
index 36956fe..d8de0d7 100644
--- a/web/pgadmin/tools/backup/templates/backup/js/backup.js
+++ b/web/pgadmin/tools/backup/templates/backup/js/backup.js
@@ -11,6 +11,24 @@ define([
return pgBrowser.Backup;
}
+/*
+=====================
+TODO LIST FOR BACKUP:
+=====================
+1) Add Object tree on object tab which allows user to select
+ objects which can be backed up
+2) Allow user to select/deselect objects
+3) If database is selected in browser
+ show all database children objects selected in Object tree
+4) If schema is selected in browser
+ show all schema children objects selected in Object tree
+5) If table is selected then show table/schema/database selected
+ in Object tree
+6) if root objects like database/schema is not selected and their
+ children are selected then add them separately with in tables attribute
+ with schema.
+*/
+
var CustomSwitchControl = Backform.CustomSwitchControl = Backform.SwitchControl.extend({
template: _.template([
'<label class="<%=Backform.controlLabelClassName%> custom_switch_label_class"><%=label%></label>',
@@ -599,6 +617,23 @@ define([
// Set current database into model
this.view.model.set('database', treeInfo.database.label);
+ // We will remove once object tree is implemented
+ // If selected node is Schema then add it in model
+ if(d._type == 'schema') {
+ var schemas = [];
+ schemas.push(d.label);
+ this.view.model.set('schemas', schemas);
+ }
+ // If selected node is Table then add it in model along with
+ // its schema
+ if(d._type == 'table') {
+ var tables = [],
+ selected_table = [];
+ selected_table.push(treeInfo.schema.label)
+ selected_table.push(d.label);
+ this.view.model.set('tables', selected_table);
+ }
+
var self = this,
baseUrl = "{{ url_for('backup.index') }}" +
"create_job/backup_object/" + treeInfo.server._id,
view thread (3+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: PATCH: Initiale backup utility [pgAdmin4]
In-Reply-To: <CAKKotZSBvbYvMRszGnizxnsSoZEgJnoN7J5zuqQZJJcEuP6OKA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox