[pgAdmin4][Patch]: RM #3029 Cannot sort columns when importing data

From: Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com>
To: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: [pgAdmin4][Patch]: RM #3029 Cannot sort columns when importing data
Date: 2018-10-25 10:57:54
Message-ID: CANxoLDcZ5dZW2HtsbWh8=bcCzsBz6wBEARPbp2uf9Lf4vzMDuQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi Hackers,

Attached is the patch to fix the RM #3029 Cannot sort columns when
importing data.
Select2 orders the selections based on the order of the `<options>` behind
the scenes. This means that the order will typically match the order of the
options as they appear in the dropdown. For *import/export* it shows in the
order of columns define in the table.

Solution: I have just reorders the options inside the select2 every time,
an item is selected. I have made this change into the select2 control with
new option "*preserveSelectionOrder*" by default it is false, so won't
impact any other module.

--
*Akshay Joshi*

*Sr. Software Architect *

*Phone: +91 20-3058-9517Mobile: +91 976-788-8246*

Attachment Content-Type Size
RM_3209.patch application/octet-stream 2.3 KB

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Aditya Toshniwal 2018-10-25 11:16:48 Re: [pgAdmin4][Patch]: Fixed process watcher status message.
Previous Message Dave Page 2018-10-25 09:40:29 Re: [pgAdmin4][Patch]: RM #1513 - Unable to do max selection to drop tables/sequences/functions