Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hg5zr-0006O4-8q for pgadmin-hackers@arkaria.postgresql.org; Wed, 26 Jun 2019 11:21:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hg5zp-0004AB-G0 for pgadmin-hackers@arkaria.postgresql.org; Wed, 26 Jun 2019 11:21:49 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hg5zo-0004A4-Vk for pgadmin-hackers@lists.postgresql.org; Wed, 26 Jun 2019 11:21:49 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hg5zi-0000X7-Ei for pgadmin-hackers@postgresql.org; Wed, 26 Jun 2019 11:21:47 +0000 Received: by mail-wr1-x442.google.com with SMTP id p13so2262672wru.10 for ; Wed, 26 Jun 2019 04:21:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pgadmin.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=B7pu4CgzYzf8KKsAPoWbRHoDRyq5qmW5Rph89UhCyac=; b=bheSmeEfVmYUnSIXcslS55llaHzI86cDxTgDbRGEkLhyQpCWaZc+zh5X+l8vvj2/sJ Fj/gZC8WE+o5KrooRRWIJ6pF/i+/QHBqUNBSVxwn0KGzxVSJEZlaS8a86g2TeMKft7Bj zA7KdWWStlbX8I7yGDYqPLdv7GJSP9IPYZYHh75/GrUyUHELY9HfKNFu+EwEr+ho1C5U E3nJnzwbJH2b6Z9WYrTuWTdIfeT7j1tvRYJD9vPBei4Q9xrX++QmV8lyr5Ph00qc2Po1 VGMimO/4ae8Y6v2knhFVeKPOtD7cpfnQCrC0UsCnxx1ZZytYa6AxBVqNdKd9n1CBYjh1 zRmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=B7pu4CgzYzf8KKsAPoWbRHoDRyq5qmW5Rph89UhCyac=; b=a6ZLOXbaItSBy682dUmTIG73y2SBlTDkGHFScgKsrcJJSxn+jcILXlqQMVKI4g/Mr5 amOGStUP4e7cuhHnZgT64VgGeNCqhvB6T2LBaC4GfuYXYTWt1sUBP8bJ+d8vhOtutLw7 bb5gZL3eQN5Lcl8Oh2ufbOHNy8HhAMa22RNdnLFjmWsN2aqfnqYHxmKaK04P8PXAaf8r TYN8wPHbMNOSgPCi15UQRS4dwJj76lGo1uoO9K/bpihacRaJ52QNsIG6EII0YLW8eNr7 6zummo2dLDXVR8d6Lz5sm1Z5f7ZaBCQV08vtt5+HO7957IcxhtjJu+jX6XfEI+SZdcC5 paQQ== X-Gm-Message-State: APjAAAUsZzOZiynFly5+6BobxJXX1Mp6zLQij4owXhJY5ze4Bl3cuDhp ynoB0BrwxGbbbdeGP0swRLv1xoehx+HU7SZK87JHvg== X-Google-Smtp-Source: APXvYqyYnPQEH2jW7+lVlJZuWjm4EPquJGsV+cLN3ipERJ5LQrL+zmP3CQXIz0KqqYivu9LzT/FyOh3oRjk0huu2RtA= X-Received: by 2002:a5d:4086:: with SMTP id o6mr3367239wrp.185.1561548100797; Wed, 26 Jun 2019 04:21:40 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Dave Page Date: Wed, 26 Jun 2019 07:21:29 -0400 Message-ID: Subject: Re: [pgAdmin][RM4139] Drag and drop object names in Query Editor from Browser Tree To: Aditya Toshniwal Cc: pgadmin-hackers Content-Type: multipart/alternative; boundary="000000000000d92670058c383f0c" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --000000000000d92670058c383f0c Content-Type: text/plain; charset="UTF-8" Hi On Wed, Jun 26, 2019 at 2:24 AM Aditya Toshniwal < aditya.toshniwal@enterprisedb.com> wrote: > Hi Hackers, > > Attached is the patch to allow tree nodes to be dragged and dropped in > query editor wherever you take the drop cursor. The drop text will be fully > qualified and double quoted if required. > For functions/procedures it will drop the the label stripping away the > parameter names, with empty pair of round brackets. It will also set the > focus cursor inside the brackets if there were params otherwiser to the end > of text. > For adding a node type, you need to register it in browser.js along with a > callback function which will return drop text along with cursor positioning > and selection. Currently, I have registered for "table partition type > sequence package view mview foreign_table edbvar schema column edbfunc > function edbproc procedure". > > Please note, the drag design customisation is not supported in IE. > I think for functions/procedures, we should include placeholders for the parameters, so the user has a hint about what they need to fill in to complete the call. Also; shouldn't there be a doc update? Thanks. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company --000000000000d92670058c383f0c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi

On Wed, Jun 26, 2019 at 2:24 AM Aditya Toshniwal &l= t;aditya.toshniwal@ent= erprisedb.com> wrote:
Hi Hackers,

<= div style=3D"font-family:verdana,sans-serif">Attached is the patch to allow= tree nodes to be dragged and dropped in query editor wherever you take the= drop cursor. The drop text will be fully qualified and double quoted if re= quired.
For functions/pr= ocedures it will drop the the label stripping away the parameter names, wit= h empty pair of round brackets. It will also set the focus cursor inside th= e brackets if there were params otherwiser to the end of text.
For adding a node type, you ne= ed to register it in browser.js along with a callback function which will r= eturn drop text along with cursor positioning and selection. Currently, I h= ave=C2=A0registered for "tab= le partition type sequence package view mview foreign_table edbvar schema c= olumn edbfunc function edbproc procedure".

Please note, the drag design customisation is not supported in IE.

I think for functions/pro= cedures, we should include placeholders for the parameters, so the user has= a hint about what they need to fill in to complete the call.
Also; shouldn't there be a doc update?

=
Thanks.
=C2=A0
--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
<= br>EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
=
--000000000000d92670058c383f0c--