Re: Query Tool JS Minimal Refactoring

From: Yosry Muhammad <yosrym93(at)gmail(dot)com>
To: Aditya Toshniwal <aditya(dot)toshniwal(at)enterprisedb(dot)com>
Cc: Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com>, pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: Re: Query Tool JS Minimal Refactoring
Date: 2019-08-23 09:02:46
Message-ID: CAFSMqn894khK+emax+99r7SMtokF3N=4_xDgWzGeZoXmN=6jzA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Please find an updated patch attached.

On Fri, Aug 23, 2019 at 7:57 AM Aditya Toshniwal <
aditya(dot)toshniwal(at)enterprisedb(dot)com> wrote:

> Hi Yosry,
>
> This breaks the reconnect for query tool. Open a query tool, execute some
> query and then restart the python server. Go to the query tool and click
> execute. It will show a warning, on continuing it should connect again. It
> throws exception in browser console:
> Uncaught TypeError: Cannot read property 'apply' of undefined
> at Object.eval (VM69935 sqleditor.js:1769)
> at Object.callback (alertify.js:3347)
> at triggerCallback (alertify.js:1220)
> at Object.buttonsClickHandler (alertify.js:1241)
> at HTMLDivElement.eval (alertify.js:299)
>
> On Thu, Aug 22, 2019 at 11:44 PM Yosry Muhammad <yosrym93(at)gmail(dot)com>
> wrote:
>
>> Please find an updated patch attached.
>>
>> On Mon, Aug 19, 2019 at 9:54 AM Yosry Muhammad <yosrym93(at)gmail(dot)com>
>> wrote:
>>
>>> Jasmine tests passed on my machine, I will take another look once I have
>>> access to my machine.
>>>
>>> On Mon, Aug 19, 2019, 7:57 AM Akshay Joshi <
>>> akshay(dot)joshi(at)enterprisedb(dot)com> wrote:
>>>
>>>> Hi Yosry
>>>>
>>>> Jasmine tests are failing, can you please fix those and resend the
>>>> patch.
>>>>
>>>> On Fri, Aug 16, 2019 at 11:23 PM Yosry Muhammad <yosrym93(at)gmail(dot)com>
>>>> wrote:
>>>>
>>>>> Hi hackers,
>>>>>
>>>>> Please find attached a patch with minimal refactoring of:
>>>>> web/pgadmin/tools/sqleditor/static/js/sqleditor.js
>>>>>
>>>>> This includes merging 2 redundant functions into one and renaming some
>>>>> functions to have more expressive and consistent names.
>>>>>
>>>>> Please review !
>>>>> Thanks.
>>>>> --
>>>>> *Yosry Muhammad Yosry*
>>>>>
>>>>> Computer Engineering student,
>>>>> The Faculty of Engineering,
>>>>> Cairo University (2021).
>>>>> Class representative of CMP 2021.
>>>>> https://www.linkedin.com/in/yosrym93/
>>>>>
>>>>
>>>>
>>>> --
>>>> *Thanks & Regards*
>>>> *Akshay Joshi*
>>>>
>>>> *Sr. Software Architect*
>>>> *EnterpriseDB Software India Private Limited*
>>>> *Mobile: +91 976-788-8246*
>>>>
>>>
>>
>> --
>> *Yosry Muhammad Yosry*
>>
>> Computer Engineering student,
>> The Faculty of Engineering,
>> Cairo University (2021).
>> Class representative of CMP 2021.
>> https://www.linkedin.com/in/yosrym93/
>>
>
>
> --
> Thanks and Regards,
> Aditya Toshniwal
> Software Engineer | EnterpriseDB India | Pune
> "Don't Complain about Heat, Plant a TREE"
>

--
*Yosry Muhammad Yosry*

Computer Engineering student,
The Faculty of Engineering,
Cairo University (2021).
Class representative of CMP 2021.
https://www.linkedin.com/in/yosrym93/

Attachment Content-Type Size
sqleditorjs_refactor_v3.patch text/x-patch 15.7 KB

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Aditya Toshniwal 2019-08-23 10:21:25 Re: Query Tool JS Minimal Refactoring
Previous Message Dave Page 2019-08-23 08:53:28 pgAdmin 4 commit: Fix PGADMIN_SERVER_JSON_FILE environment variable sup