Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
loadComplete function
27/10/2008
17:16
Avatar
pat
Member
Members
Forum Posts: 9
Member Since:
14/10/2008
sp_UserOfflineSmall Offline

This works ...
loadComplete: function() {
    $.each(colNames2, function(i,k) { $("#"+ctab).setCell("0", k, "", {'font-weight':'bold'}); });
}

But this …
loadComplete: setBold(ctab, colNames1)

function setBold(grd, nameArr) {
    $.each(nameArr, function(i,k) { $("#"+grd).setCell("0", k, "", {'font-weight':'bold'}); });
};

fails because the $t.grid object doesn't exist in the setCell function. Is there a way to get this setBold function to work?

27/10/2008
17:27
Avatar
digitalspaghetti
Member
Members
Forum Posts: 7
Member Since:
25/10/2008
sp_UserOfflineSmall Offline

In your case, you need to do an anonymous function, like this:

loadComplete: function() {
    setBold(ctab, colNames1);
}

That should for you, however on the same function - my function is failing, and I don't know why:

'loadComplete': function() {
            var row_ids = jQuery("#campaigns-list").getDataIDs();
            jQuery.each(row_ids, function(i, row_id){
                var output = [];
                output.push('<a href="#" rel="'+row_id+'" class="campaign-button-edit">edit</a>');
                output.push('<a href="#" rel="'+row_id+'" class="campaign-button-delete">delete</a>');
                jQuery("#campaigns-list").setRowData(row_id, {
                    'actions':output.join('')
                    }
                );
            });

}

In my function I can see the row_id when i output it to firebug, however nothing appears in the column, except the column header - and I only get 5 columns back, when I should be getting 6 (the actions being missing).

Any ideas folks?

27/10/2008
18:29
Avatar
digitalspaghetti
Member
Members
Forum Posts: 7
Member Since:
25/10/2008
sp_UserOfflineSmall Offline

NM, I managed to fix it by passing a null value in the returned array of row values from PHP

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
58 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information