Re: New mechanism in backgrid to render different types of cells in same column [pgAdmin4]

From: Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>
To: Harshal Dhumal <harshal(dot)dhumal(at)enterprisedb(dot)com>
Cc: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: Re: New mechanism in backgrid to render different types of cells in same column [pgAdmin4]
Date: 2016-02-05 09:09:58
Message-ID: CAG7mmoykzTC5yFnAOUkwx7RJA+iwiNwMy+h06z+sfQrsV93G9Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

On Fri, Feb 5, 2016 at 2:16 PM, Harshal Dhumal <
harshal(dot)dhumal(at)enterprisedb(dot)com> wrote:

> Hi, Ashesh,
>
Hi Harshal,

[ Please do not forget to reply to All next time.. :-) ]

>
> Same patch which I send on 19 Jan with very minor change. i.e. properly
> initialize bool cell for dynamic variable cell.
>
Thanks - I've committed the patch.

--

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>

>
>
>
> --
> *Harshal Dhumal*
> *Software Engineer *
>
>
>
> EenterpriseDB <http://www.enterprisedb.com>
>
> On Tue, Jan 19, 2016 at 12:42 AM, Harshal Dhumal <
> harshal(dot)dhumal(at)enterprisedb(dot)com> wrote:
>
>> +
>> Also fixed some minor issues related to Unique column functionality in
>> Variable control in same patch.
>>
>> --
>> *Harshal Dhumal*
>> *Software Engineer *
>>
>>
>>
>> EenterpriseDB <http://www.enterprisedb.com>
>>
>> On Tue, Jan 19, 2016 at 12:37 AM, Harshal Dhumal <
>> harshal(dot)dhumal(at)enterprisedb(dot)com> wrote:
>>
>>> Hi,
>>>
>>> This patch is replacement for our developed DynamicVariablecell.
>>>
>>> Now we can pass cellFunction in column schema to get appropriate cell
>>> class.
>>> User provided cellFunction must return valid cell class.
>>> cellFunction will be called with context (this) as column and model as
>>> argument.
>>>
>>> eg.:
>>>
>>> schema: [
>>> {id: 'name', label:'Name', type:'text', editable: false, cell: 'string'},
>>> {
>>> id: 'value', label:'Value', type: 'text', editable: true,
>>> cellFunction: function(model){
>>>
>>> if (isNaN(model.get(this.get('name')))) {
>>> return "string";
>>> } else {
>>> return Backgrid.NumberCell;
>>> }
>>> }
>>> },
>>> {id: 'database', label:'Database', type: 'text', editable: false},
>>> .
>>> .
>>> .
>>>
>>>
>>>
>>>
>>> --
>>> *Harshal Dhumal*
>>> *Software Engineer *
>>>
>>>
>>>
>>> EenterpriseDB <http://www.enterprisedb.com>
>>>
>>
>>
>

In response to

Browse pgadmin-hackers by date

  From Date Subject
Next Message Harshal Dhumal 2016-02-05 09:29:54 Re: Minor issue in variable js [pgadmin4]
Previous Message Ashesh Vashi 2016-02-05 09:06:12 pgAdmin 4 commit: Using different strategy to render different type of