View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
08784Bug reportsRemoteControlpublic2014-04-04 10:26
Reportermasciugo Assigned Toc_schmitz  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version2.05+ 
Fixed in Version2.05+ 
Summary08784: align get_summary RPC Routine to other ones
Description

I'm writing a ruby gem library to integrate limesurvey into a Ruby on Rails web application.

To do that I wrote a no-persistance Rails model (a ruby class) for the survey entity. This model should acts like an ORM which instead of interacting with an underlying database it interacts with the Limesurvey remote control system. Hence, to build a survey ruby object on the fly with all possible attributes I use 3 RPC routines sequentially:

  • get_survey_properties
  • get_language_properties
  • get_summary

While the first two accept an array of properties (my attributes) as argument, the last one needs to provide desired available statistics (still attributes for me) one by one. So to retrieve all of them I need to run the routine multiple times affecting performances.

I understand that this is a personal need but I think that, in general, it should be easier to map Limesurvey entities in other language entities through the API. Also I wonder why that syntax difference among those three routines about the properties argument?

thanks a lot

TagsNo tags attached.
Bug heat4
Complete LimeSurvey version number (& build)140131
I will donate to the project if issue is resolvedNo
Browser
Database type & versionmysql 5.1.71
Server OS (if known)Linux 2.6.32-431.el6.x86_64
Webserver software & version (if known)httpd-2.2.15-29.el6.centos.x86_64
PHP Version5.3.3

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2014-03-02 11:04

administrator   ~29036

Add new option 'all' to retrieve an array of all values

c_schmitz

c_schmitz

2014-03-02 11:05

administrator   ~29037

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

c_schmitz

c_schmitz

2014-03-02 12:29

administrator   ~29043

2.0+ Build 140302 released.

masciugo

masciugo

2014-03-05 11:10

reporter   ~29100

before all thanks for your job.
But maybe something is missing.. It seems that the property 'all' is not among the permitted ones ($aPermittedStats). In fact I got {"status"=>"No such property"}

c_schmitz

c_schmitz

2014-03-17 12:56

administrator   ~29266

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

c_schmitz

c_schmitz

2014-03-17 13:14

administrator   ~29268

2.05+ Build 140317 released

masciugo

masciugo

2014-03-24 17:56

reporter   ~29525

Last edited: 2014-03-24 18:04

it seems that option 'all' returns a result like the following:

{"completed_responses"=>"4", "incomplete_responses"=>"4", "full_responses"=>"5", "count"=>"5", "invalid"=>"0", "sent"=>"3", "optout"=>"0", "completed"=>"1"}

but if you run getsummary for property, for example, 'count' you got an error (unknown property). In few words, when using the 'all' feature, it returns Token stats names without their 'token' prefix.

Another strange behavior is that asking for all properties raises a "no available data" when the survey is not active. I would instead expect blank values for Survey stats (because of no responses at all) along with valid Token stats

c_schmitz

c_schmitz

2014-03-27 11:41

administrator   ~29571

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

c_schmitz

c_schmitz

2014-03-27 11:42

administrator   ~29572

Please check out the latest patch below and let me know if it looks alright.

masciugo

masciugo

2014-03-27 13:13

reporter   ~29575

Last edited: 2014-03-27 13:13

with option 'all' now returns the expected result:

{"token_count"=>"5", "token_invalid"=>"0", "token_sent"=>"3", "token_opted_out"=>"0", "token_completed"=>"1", "completed_responses"=>"4", "incomplete_responses"=>"4", "full_responses"=>"5"}

Instead, asking for ONE token stat returns ALL token stats:

{"token_count"=>"5", "token_invalid"=>"0", "token_sent"=>"3", "token_opted_out"=>"0", "token_completed"=>"1"}

and also, asking for ONE Survey stat returns ALL Survey stats:

{"completed_responses"=>"4", "incomplete_responses"=>"4", "full_responses"=>"5"}

c_schmitz

c_schmitz

2014-03-28 15:57

administrator   ~29583

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

c_schmitz

c_schmitz

2014-03-28 16:00

administrator   ~29584

Darn typo - please try again and let me know.

masciugo

masciugo

2014-03-28 18:35

reporter   ~29591

it seems ok to me. thank you

c_schmitz

c_schmitz

2014-04-04 10:26

administrator   ~29660

2.05+ Build 140404 released.

Related Changesets

LimeSurvey: master 102b8099

2014-03-02 10:03:44

c_schmitz

Details Diff
Fixed issue 08784: get_summary RPC routine only delivering one value at a time Affected Issues
08784
mod - application/helpers/remotecontrol/remotecontrol_handle.php Diff File

LimeSurvey: master 0f032d58

2014-03-13 09:44:50

c_schmitz

Details Diff
Fixed issue 08784: align get_summary RPC Routine to other ones Affected Issues
08784
mod - application/helpers/remotecontrol/remotecontrol_handle.php Diff File

LimeSurvey: 2.06 b949d4d6

2014-03-27 10:24:51

c_schmitz

Details Diff
Fixed issue 08784: get_summary RPC routine only delivering one value at a time Affected Issues
08784
mod - application/helpers/remotecontrol/remotecontrol_handle.php Diff File

LimeSurvey: 2.06 dac732f9

2014-03-28 14:57:34

c_schmitz

Details Diff
Fixed issue 08784: get_summary RPC routine only delivering one value at a time Affected Issues
08784
mod - application/helpers/remotecontrol/remotecontrol_handle.php Diff File

Issue History

Date Modified Username Field Change
2014-02-27 15:34 masciugo New Issue
2014-02-28 14:43 c_schmitz Assigned To => c_schmitz
2014-02-28 14:43 c_schmitz Status new => assigned
2014-03-02 11:04 c_schmitz Note Added: 29036
2014-03-02 11:04 c_schmitz Status assigned => resolved
2014-03-02 11:04 c_schmitz Fixed in Version => 2.05+
2014-03-02 11:04 c_schmitz Resolution open => fixed
2014-03-02 11:05 c_schmitz Changeset attached => LimeSurvey master 102b8099
2014-03-02 11:05 c_schmitz Note Added: 29037
2014-03-02 12:29 c_schmitz Note Added: 29043
2014-03-02 12:29 c_schmitz Status resolved => closed
2014-03-05 11:10 masciugo Note Added: 29100
2014-03-05 11:10 masciugo Status closed => feedback
2014-03-05 11:10 masciugo Resolution fixed => reopened
2014-03-17 12:56 c_schmitz Status feedback => resolved
2014-03-17 12:56 c_schmitz Resolution reopened => fixed
2014-03-17 12:56 c_schmitz Changeset attached => LimeSurvey master 0f032d58
2014-03-17 12:56 c_schmitz Note Added: 29266
2014-03-17 13:14 c_schmitz Note Added: 29268
2014-03-17 13:14 c_schmitz Status resolved => closed
2014-03-24 17:56 masciugo Note Added: 29525
2014-03-24 17:56 masciugo Status closed => feedback
2014-03-24 17:56 masciugo Resolution fixed => reopened
2014-03-24 18:04 masciugo Note Edited: 29525
2014-03-27 11:41 c_schmitz Changeset attached => LimeSurvey 2.06 b949d4d6
2014-03-27 11:41 c_schmitz Note Added: 29571
2014-03-27 11:42 c_schmitz Note Added: 29572
2014-03-27 13:13 masciugo Note Added: 29575
2014-03-27 13:13 masciugo Status feedback => assigned
2014-03-27 13:13 masciugo Note Edited: 29575
2014-03-28 15:57 c_schmitz Changeset attached => LimeSurvey 2.06 dac732f9
2014-03-28 15:57 c_schmitz Note Added: 29583
2014-03-28 16:00 c_schmitz Note Added: 29584
2014-03-28 16:00 c_schmitz Status assigned => feedback
2014-03-28 18:35 masciugo Note Added: 29591
2014-03-28 18:35 masciugo Status feedback => assigned
2014-03-28 18:59 c_schmitz Status assigned => resolved
2014-03-28 18:59 c_schmitz Resolution reopened => fixed
2014-04-04 10:26 c_schmitz Note Added: 29660
2014-04-04 10:26 c_schmitz Status resolved => closed