List Info

Thread: Renewed cry for help with datatable and 2.5.1




Renewed cry for help with datatable and 2.5.1
country flaguser name
United States
2008-03-29 21:14:53


All:

It is wonderful all the help, comments, and quick responses I see to
my (and others) posts from the community. What a joy it is to work
with the FOSS community -- I can't believe I ever worked in the PUSS
(Proprietary Unopen Source Software) world!

Anyway, I continue to suffer from some incompatibility (or bug)
between 2.4.1 and 2.5.1. I do custom client-side pagination, and
it "breaks" in 2.5.1. I have a large JSON object that I extract
a "page" from as one navigates the dataset, and I use
widget.DataTable.initializeTable() to "refresh" the new page. All
worked up until 2.5.1. I notice that the docs say to call render()
separately after the initializeTable() and I do that (which seems to
be backwards compatible with 2.4.1). However, that table just
says "no records" once I call render(). I have verified that my
array (DS is type JS_ARRAY) has the right data in it.

Here is the link to the "broken" 2.5.1 example:

http://sandbox.bluelinkdirect.com/sandbox/client_page_table_1.html

Here is the link to the working 2.4.1 example:

http://sandbox.bluelinkdirect.com/sandbox/client_page_table_2.html

Please note, I moved my testing to a different server, so note the
new links if any of you have been following this saga. I just added
the domain to the host, so it may not be resolved for a few hours
(entered at 10:00 PM EDT (USA) on 29 March 2008).

I have given up for the moment on scrolling tables, due to several
issues (my tables may be very large), and server-side pagination is
also undesirable for various reasons, so I really, really want my
current structure to continue to work under 2.5.1.

Also note that I see worthy UI speed enhancements under 2.5.1 for
everything else, so I am eager to upgrade my live servers as soon as
possible!!!!

Thanks again for your continued work and help community!

~~bret

__._,_.___
.

__,_._,___
Re: Renewed cry for help with datatable and 2.5.1
country flaguser name
United States
2008-03-30 12:01:48


Update:

I started digging into the YUI scripts assuming this must be an error
(or change) in YUI (see original notes below). I find this code in
2.4.1:

YAHOO.widget.DataTable.prototype.initializeTable = function(oData) {
// Clear the RecordSet
this._oRecordSet.reset();

// Add data to RecordSet
var records = this._oRecordSet.addRecords(oData);

// Clear selections
this._unselectAllTrEls();
this._unselectAllTdEls();
this._aSelections = null;
this._oAnchorRecord = null;
this._oAnchorCell = null;

// Refresh the view
this.refreshView();
this.fireEvent(";initEvent");
};

And this code in 2.5.1:

initializeTable : function() {
// Reset init flag
this._bInit = true;

// Clear the RecordSet
this._oRecordSet.reset();

// Clear selections
this._unselectAllTrEls();
this._unselectAllTdEls();
this._aSelections = null;
this._oAnchorRecord = null;
this._oAnchorCell = null;

// Clear sort
this.set("sortedBy", null);
},

So it appears that initializeTable in 2.5.1 really DOES NOT do what
it used to do. Before, I sent in my (new) data and after it
cleared/rest everything, it updated the table (recordset) with my
(new) data.

Appearently that is no longer the case?

How do I achieve the same functionality as before? I'm missing it
somehow...

Thanks,
~~bret

--- In ydn-javascript%40yahoogroups.com">ydn-javascriptyahoogroups.com, "bretlevy" <bret...> wrote:
&gt;
>
> All:
>;
> It is wonderful all the help, comments, and quick responses I see
to
> my (and others) posts from the community. What a joy it is to work
> with the FOSS community -- I can't believe I ever worked in the
PUSS
> (Proprietary Unopen Source Software) world!
&gt;
> Anyway, I continue to suffer from some incompatibility (or bug)
> between 2.4.1 and 2.5.1. I do custom client-side pagination, and
> it "breaks" in 2.5.1. I have a large JSON object that I extract
> a "page" from as one navigates the dataset, and I use
> widget.DataTable.initializeTable() to "refresh" the new page. All
> worked up until 2.5.1. I notice that the docs say to call render()
> separately after the initializeTable() and I do that (which seems
to
> be backwards compatible with 2.4.1). However, that table just
> says "no records&quot; once I call render(). I have verified that my
> array (DS is type JS_ARRAY) has the right data in it.
>
> Here is the link to the "broken" 2.5.1 example:
>
> http://sandbox.bluelinkdirect.com/sandbox/client_page_table_1.html
&gt;
> Here is the link to the working 2.4.1 example:
>
> http://sandbox.bluelinkdirect.com/sandbox/client_page_table_2.html
&gt;
> Please note, I moved my testing to a different server, so note the
> new links if any of you have been following this saga. I just
added
> the domain to the host, so it may not be resolved for a few hours
> (entered at 10:00 PM EDT (USA) on 29 March 2008).
&gt;
> I have given up for the moment on scrolling tables, due to several
> issues (my tables may be very large), and server-side pagination is
> also undesirable for various reasons, so I really, really want my
> current structure to continue to work under 2.5.1.
&gt;
> Also note that I see worthy UI speed enhancements under 2.5.1 for
> everything else, so I am eager to upgrade my live servers as soon
as
> possible!!!!
>
> Thanks again for your continued work and help community!
>
> ~~bret
&gt;

__._,_.___
.

__,_._,___
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )