View Issue Details

This bug affects 1 person(s).
 8
IDProjectCategoryView StatusLast Update
06067Bug reportsOtherpublic2012-08-03 13:48
ReporterFred Assigned Tojcleeland  
PrioritynormalSeverityblock 
Status closedResolutionfixed 
Product Version2.00b1 
Fixed in Version2.00RC7 
Summary06067: Can't edit participant attribute value
Description

If you try to update exitsting attributes on Participant Panel, it either doesn't save or generates a blank error dialog,

PHP Fatal error: Call to a member function bindParam() on a non-object in /htdocs/limesurvey/application/models/ParticipantAttributeNames.php on line 201

Steps To Reproduce

Assumes you have some participant attributes defined and set on a partcipant
Main Menu
Participants Panel
Display Participant
Click on + to open attributes
Double click on the row you want to edit
Change the attribute
Click the submit icon at left of row

Additional Information

This grid control in the CPD is pretty flaky in general. Sometimes you have to click over and over to activate something. Sometimes attributes display right away and other times you have to click the column heading to get them to display.

Also, when you add or edit things, you have to scroll down to a tiny "reload" button at the bottom to get things to show up (more of a usability problem).

TagsNo tags attached.
Bug heat8
Complete LimeSurvey version number (& build)120406
I will donate to the project if issue is resolvedNo
BrowserChrome, Safari
Database type & versionMySQL 5.5.9
Server OS (if known)OSX
Webserver software & version (if known)2.2.17
PHP Version5.3.6

Users monitoring this issue

There are no users monitoring this issue.

Activities

jcleeland

jcleeland

2012-05-08 08:23

reporter   ~18618

I've made a bunch of updates and fixes to the participants panel over the last few weeks which I think will have fixed this issue. I can't replicate the bug in the current development build.

Could you test this against an updated version and let me know.

Fred

Fred

2012-05-08 17:29

reporter   ~18628

I pulled the current Yii branch from github. It says Version 2.0b2. Still getting the same error.

If I try to edit the participant email (as opposed to attributes) it generates this message too.
[08-May-2012 11:27:55] PHP Fatal error: Call to a member function bindParam() on a non-object in /Users/fred/Dropbox/MAMP/htdocs/limesurvey/application/models/Participants.php on line 153

Fred

Fred

2012-05-08 22:49

reporter   ~18637

Update: The Attribute problem only happens when:

1) You are changing an existing value in an attribute. For example if there is an attribute called "Customer" and you try to change it from "Yes" to "No"
2) The attribute is a drop-down list attribute. The error doesn't happen on a text box attribute.

Maybe this will help reproduce it.

xavierdepotter

xavierdepotter

2012-05-25 11:33

reporter   ~18896

Hello,
When I update Lime surveys From the version 1.90 to 2.0b1, I have the same problem :
The LimeSurvey database is being upgraded (2012-05-25 11:15:47) .
Please be patient...
. . . . . . . . . . . . . . . . . . .
Fatal error: Call to a member function getText() on a non-object in C:\Program Files\EasyPHP-5.3.9\www\limesurvey\application\helpers\update\upgrade-all_helper.php on line 201

Regards
Xavier

jcleeland

jcleeland

2012-05-29 08:26

reporter   ~18984

@Xavier: I think you may have put this comment in the wrong place - your issue is not related to the attribute values.

@Fred - it's killing me, I just can't replicate. I've created an attribute called 'Customer', added the values "Yes" and "No" to it. Then I've edited a participants attributes, set the "Customer" attribute to "Yes". Saved it. Reloaded the grid, edited it and changed it to "No". Reloaded the grid. All saved, all worked, no errors!

Maybe you could post a screenshot of the error message?

Fred

Fred

2012-05-29 16:19

reporter   ~18992

Hi Jason, I just tried again and still getting the same error. Maybe it's just me.

By the way, one other oddity I notice with editing drop down participant attributes: If you edit the row by clicking on the pencil icon at the left, then the attribute value field opens in a text-box control, but if you edit it by double-clicking on the attribute value field, it is a drop down control.

Mazi

Mazi

2012-05-30 16:51

updater   ~19004

Fred, did you try to reproduce this at a fresh database that was not generated by LS1.92 but by a fresh LS2 install?

Fred

Fred

2012-05-30 17:50

reporter   ~19010

Marcel, yes this is on my LS2 test system. Just to be sure I just wiped everything out, downloaded the Version 2.0RC2 Build 120528 from the Limesurvey site, let it install and create a new database, and cleared my browser cache. Still getting the same error PHP Fatal error: Call to a member function bindParam() on a non-object in /MAMP/htdocs/limesurvey/application/models/ParticipantAttributeNames.php on line 201.

If you can't reproduce it then maybe it is something to do with my dev setup (MAMP).

jcleeland

jcleeland

2012-07-27 08:08

reporter   ~20007

Closing because of inactivity. I'm going to assume the problem is resolved in the current release. If it isn't please reopen.

Fred

Fred

2012-07-28 17:16

reporter   ~20047

Sorry to re-open this but still having the same problem with RC7. The same error also appears when you edit a participant name or email address. In that case it is : PHP Fatal error: Call to a member function bindParam() on a non-object in /MAMP/htdocs/ls2/application/models/Participants.php on line 153

Another related item: Drop down attributes aren't behaving correctly (or at least, as I would expect them to). If you add a participant, then expose their attributes, then click on the "pencil" icon to edit a dropdown attribute, it opens a text box rather than a drop-down list. You can enter any value you like in the text box and save it, so there is no validation.

The only way to show the drop-down control is to not use the edit icon, but rather double-click on the blank space where the value would be (or to double-click on the value if it is already entered and you are trying to edit it).

jcleeland

jcleeland

2012-07-29 03:24

reporter   ~20054

Fix committed to Yii branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=9173

jcleeland

jcleeland

2012-07-29 04:03

reporter   ~20055

Fix committed to Yii branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=9174

jcleeland

jcleeland

2012-07-29 04:06

reporter   ~20056

@fred, although I was still unable to replicate the problem both of the functions where you are getting errors use a Yii method called ->addParams which I've found problematic in other instances. So I've removed that and used a different method. Could you see if it makes a difference for you?

Fred

Fred

2012-07-30 19:55

reporter   ~20082

Hi Jason, I put your four file changes in and everything is working now! Tested the dropdown functionality, editing attributes, and editing participants. No more error. Great job. I was kind of blaming the jqgrid control for this, but sounds like it was the Yii->jqgrid connection.

Related Changesets

LimeSurvey: Yii 27ebd205

2012-07-28 18:23:53

jcleeland

Details Diff
Fixed issue 06067 (partial fix) - jqGrid behaviours for editing attributes fixed - dropdown appears when dropdown should, dropdown doesn't appear when it shouldn't! Affected Issues
06067
mod - scripts/admin/displayParticipant.js Diff File

LimeSurvey: Yii 710709cc

2012-07-28 19:03:20

jcleeland

Details Diff
Fixed issue 06067 - changed save methodology to see if it resolves @fred's issues (params entered via different method) Affected Issues
06067
mod - application/controllers/admin/participantsaction.php Diff File
mod - application/models/ParticipantAttributeNames.php Diff File
mod - application/models/Participants.php Diff File

Issue History

Date Modified Username Field Change
2012-05-04 17:37 Fred New Issue
2012-05-05 23:18 c_schmitz Assigned To => jcleeland
2012-05-05 23:18 c_schmitz Status new => assigned
2012-05-08 08:23 jcleeland Note Added: 18618
2012-05-08 17:29 Fred Note Added: 18628
2012-05-08 22:49 Fred Note Added: 18637
2012-05-25 11:33 xavierdepotter Note Added: 18896
2012-05-29 08:26 jcleeland Note Added: 18984
2012-05-29 16:19 Fred Note Added: 18992
2012-05-30 16:51 Mazi Note Added: 19004
2012-05-30 17:50 Fred Note Added: 19010
2012-07-27 08:08 jcleeland Note Added: 20007
2012-07-27 08:08 jcleeland Status assigned => closed
2012-07-27 08:08 jcleeland Resolution open => fixed
2012-07-27 08:08 jcleeland Fixed in Version => 2.00RC7
2012-07-28 17:16 Fred Note Added: 20047
2012-07-28 17:16 Fred Status closed => feedback
2012-07-28 17:16 Fred Resolution fixed => reopened
2012-07-29 03:24 jcleeland Changeset attached => LimeSurvey Yii 27ebd205
2012-07-29 03:24 jcleeland Note Added: 20054
2012-07-29 04:03 jcleeland Changeset attached => LimeSurvey Yii 710709cc
2012-07-29 04:03 jcleeland Note Added: 20055
2012-07-29 04:06 jcleeland Note Added: 20056
2012-07-30 19:55 Fred Note Added: 20082
2012-07-30 19:55 Fred Status feedback => assigned
2012-07-31 06:28 jcleeland Status assigned => resolved
2012-07-31 06:28 jcleeland Resolution reopened => fixed
2012-08-03 13:48 c_schmitz Status resolved => closed