Commit graph

7286 commits

Author SHA1 Message Date
Patrick Donelan
fa6976fb40 More ResponseJSON refactoring.
Finished refactoring nextQuestions()
Added recordedResponses sub
Added getTemplatedText sub
Added sectionId, questionId, answerId, sIndex, qIndex, aIndexes
abstraction subs
2009-02-06 05:15:26 +00:00
Patrick Donelan
306502465c Started refactoring nextQuestions in ResponseJSON
Made perlcritic happier
Extracted getQuestionResponses from processGotoExpression
Eliminated getPreviousAnswer
2009-02-06 01:56:54 +00:00
Patrick Donelan
3340a675b7 Updated Survey.pm to use new ResponseJSON.pm methods 2009-02-06 01:56:35 +00:00
Patrick Donelan
345989370f Renamed ResponseJSON branching methods 2009-02-06 01:56:18 +00:00
Patrick Donelan
932a033b58 More ResponseJSON refactoring
Removed unnecessary $session argument from recordResponses
Refactored nextQuestions to return a list rather than an arrayref
Lots more documentation for ResponseJSON
More param validation for ResponseJSON
Refactored recordResponses
Updated tests
2009-02-06 01:55:56 +00:00
Patrick Donelan
90d314d2f1 Refactored next/last response/section related accessors and mutators
(and tests).

Added more documentation.
2009-02-06 01:55:33 +00:00
Patrick Donelan
669e986189 Replaced ResponseJSON's implementation of shuffle with List::Util's
shuffle and updated Colin's ninja shuffle tests
2009-02-04 02:05:44 +00:00
Patrick Donelan
477f014177 Improved createSurveyOrder documentation, and made perlcritic happy 2009-02-04 00:16:44 +00:00
Patrick Donelan
6fb325699f Refactored createSurveyOrder in ResponseJSON
Added lastSectionIndex, lastQuestionIndex, lastAswerIndex convenience
methods to SurveyJSON to simplify iterations over Sections, Questions
and Answers
2009-02-04 00:16:26 +00:00
Patrick Donelan
66a2adcbe5 Moved ResponseJSON data hash to private variable, for security and
consistency with SurveyJSON

Added some more accessors/mutators, and param validation
2009-02-03 08:32:40 +00:00
Patrick Donelan
17dbf7fa66 Updated Survey.pm to use the new SurveyJSON contructor params 2009-02-03 08:32:22 +00:00
Patrick Donelan
57fb3cb238 Refactored SurveyJSON for perlcritic compliance.
Simplified some code, refactored out some C-isms.
2009-02-03 08:32:06 +00:00
Patrick Donelan
821635eb71 Refactored ResponseJSON and SurveyJSON
Added Params::Validate to ResponseJSON.pm
Refactored ResponseJSON constructor and re-ordered params for
consistency
Added new ->session accessor
Updates tests
Removed unnecessary logging methods
Further refactored SurveyJSON, gave private variables underscores,
replaced direct hash access with accessors
2009-02-03 08:31:43 +00:00
Patrick Donelan
8833459c74 Added param validation to all SurveyJSON.pm methods. 2009-02-03 08:31:24 +00:00
Patrick Donelan
d00c8661f3 Made first argument to SurveyJSON contructor $session for consistency
with rest of wg.

Also added Params::Validate validation.
2009-02-03 08:31:07 +00:00
Patrick Donelan
a1033aeaa2 Replaced all decode/encode_json method calls with to/from_json method
calls now that we've licked the Survey encoding bug (wrong mysql db
field type)
2009-01-27 05:47:36 +00:00
Patrick Donelan
c4eb4e3b57 Refactored updateQuestionAnswers and addAnswersToQuestion in SurveyJSON 2009-01-26 02:20:28 +00:00
Patrick Donelan
a2d01c34da Fixed a bug where newly created questions would not pre-populate answers
(caused by my refactoring)
2009-01-26 02:20:11 +00:00
Patrick Donelan
1376c8ae92 Merge commit WebGUI_7.6.9-beta into survey-rfe
* commit 'tags/WebGUI_7.6.9-beta': (31 commits)
  Release 7.6.9-beta
  preparing for 7.6.9 release
  fixed: Exporting to static files can leak large amounts of memory
  fixed: HTTP Proxy doesn't serve new content to visitors
  use to_json and from_json in more places instead of encode_json and decode_json
  Document the heretofore missing date template variable in
  Qualify a chained method call when getting Workflow instances.  If the
  Attempt to fix IE6 bug
  fixed: ukplayer example is now loaded with swfobject.js released under the MIT licence, see gotcha's and /extras/ukplayer
  Added a style for printing Alumni pages
  Emails sent about low stock should have status unread, not completed.
  Moved draggable.js to extras/yui-webgui/build/layout since it is now a wrapper around YUI dragdrob
  Attributions in the changelog for a patch provided to fix a bug.
  whups, left in console.logs
  Updated draggable.js to wrap the YUI
  fixed #4137: Calendar Search page has extra head tags in body
  Fix a typo typo in the Operation/Workflow POD.
  Forward port Shelf view fix.  Was not displaying child shelves, only self.
  Forward port the PayDriver bug fixes from 7.5 branch.  Labels are always
  fixed #9264: new slideShow.swf uploaded in extras/ukplayer (United Knowledge/Arjan Widlak)
  ...

Conflicts:
	lib/WebGUI/Asset/Wobject/Survey.pm
2009-01-22 04:39:43 +00:00
Graham Knop
b255495c02 fixed: Exporting to static files can leak large amounts of memory 2009-01-22 01:14:33 +00:00
Graham Knop
5fe7ffa55c fixed: HTTP Proxy doesn't serve new content to visitors 2009-01-22 01:14:26 +00:00
Graham Knop
315ce0941f use to_json and from_json in more places instead of encode_json and decode_json 2009-01-22 01:14:14 +00:00
Colin Kuskie
b249b98a86 Document the heretofore missing date template variable in
the Syndicated Content item loop.
2009-01-21 23:30:21 +00:00
Colin Kuskie
88973add2f Qualify a chained method call when getting Workflow instances. If the
workflow for an instance is ever deleted, then no existing instances after that
instance will ever be sent to Spectre.
2009-01-21 21:12:26 +00:00
Patrick Donelan
8d5e6880c0 More SurveyJSON refactoring (mostly documentation) 2009-01-21 05:34:58 +00:00
Patrick Donelan
102ec0dd25 More SurveyJSON refactoring.. 2009-01-21 05:34:41 +00:00
Patrick Donelan
ef7c0cfaa1 More SurveJSON refactoring (mostly documentation and simple code
changes)
2009-01-21 05:34:23 +00:00
Patrick Donelan
fe32551bca Added totalSections/Questions/Answers helper subs, refactored
getDragDropList to use helper subs, and added extra $address param
documentation.
2009-01-21 03:34:22 +00:00
Patrick Donelan
6d10570fdb Refactored SurveyJSON's new, freeze and addObject for readability 2009-01-20 07:34:55 +00:00
Colin Kuskie
08db6b5036 Emails sent about low stock should have status unread, not completed. 2009-01-19 18:45:05 +00:00
Yung Han Khoe
6598ca8854 rfe 9197: Survey timeout handling 2009-01-19 12:49:20 +00:00
Patrick Donelan
c4540a96ee Replaces to_json and from_json with encode_json/decode_json to properly
handle non-ascii user input (e.g. MS Word apostrophe)
2009-01-19 03:33:07 +00:00
Kaleb Murphy
1dc5387e1f Moved draggable.js to extras/yui-webgui/build/layout since it is now a wrapper around YUI dragdrob 2009-01-16 16:20:30 +00:00
Kaleb Murphy
2e47d3b2a1 Updated draggable.js to wrap the YUI 2009-01-16 00:34:50 +00:00
Doug Bell
96662a5f59 fixed #4137: Calendar Search page has extra head tags in body 2009-01-15 20:12:36 +00:00
Colin Kuskie
8cee4f745a Fix a typo typo in the Operation/Workflow POD. 2009-01-15 17:46:39 +00:00
Colin Kuskie
1460618ad4 Forward port Shelf view fix. Was not displaying child shelves, only self. 2009-01-15 16:35:01 +00:00
Yung Han Khoe
46cca4fae1 rfe 9200: Survey Text/TextArea handling 2009-01-15 14:17:40 +00:00
Colin Kuskie
1b6dd7be63 Forward port the PayDriver bug fixes from 7.5 branch. Labels are always
taken consistently from the JSON blob, and not a mixture of the two.
2009-01-15 00:34:34 +00:00
Colin Kuskie
7081202353 Mirror the indent loop calculation to the rel_depth in the Navigation. 2009-01-14 17:44:17 +00:00
Colin Kuskie
55d4c12ce1 Update POD about getKeywordsForAsset. 2009-01-14 17:43:42 +00:00
Patrick Donelan
a02cbf95a7 More minor edits from flux branch 2009-01-14 06:15:10 +00:00
Patrick Donelan
b7520da07d Merge commit 'tags/WebGUI_7.6.8-beta' into survey-rfe
* commit 'tags/WebGUI_7.6.8-beta': (96 commits)
  Release 7.6.8-beta
  preparing for 7.6.8 release
  convert to new storage format
  fixing photo comment test
  fixed: Syndicated Content corrupts wide characters
  Add the WikiPage to the list of contributions shown in the Account Contributions tab.
  added #!/usr/bin/env perl to all utility scripts
  Forward port i18n fix for Gallery Album RSS list.
  Fix some Survey i18n typos in the time limit hoverhelp.
  Large batch of Help and i18n.  Also, make sure that the
  Fix a typo in the i18n help for the ITransact Pay Driver.
  Correct dataform captcha variable name in the help.
  Forward porting expanded patch for handling deleted things.
  Have Thingy check for existance of table and column to prevent
  Fix linking to other things and autocreating the form field for it.
  Update test to match fixed code.
  Remove the warnings pragma
  Only resize photos if they are larger than the Gallery resolutions.
  Fix a syntax error made in the i18n of the search button.
  I18n'ed a submit button in the manage transactions screen.
  ...

Conflicts:

	lib/WebGUI/Asset/Wobject/Survey.pm
	lib/WebGUI/Asset/Wobject/Survey/SurveyJSON.pm
	www/extras/wobject/Survey/editsurvey.js
	www/extras/wobject/Survey/editsurvey/object.js
2009-01-14 06:00:06 +00:00
Colin Kuskie
3804ad7ddd Moving toolbar cache into the getToolbar sub. This was to be the forward port
of the getToolbar adminOn fix, but 7.6 already does uses adminOn to prevent
extra output from being generated.
2009-01-14 04:22:27 +00:00
David Delikat
d27b5b0066 fixed bug 9428: ASSET::get now includes keywords when
called without a property name.
2009-01-12 22:28:46 +00:00
Colin Kuskie
e3c77d4e80 Add a test for evaluating templates and macros in the right order
in the Snippet.  Fix a bug with that.
2009-01-12 22:23:41 +00:00
Frank Dillon
dde2b149b5 Fixed a bug where posts would error because they didn't point to the thread 2009-01-12 04:46:25 +00:00
Colin Kuskie
501c686872 Clarify size vs density in the ImageGallery i18n. 2009-01-12 00:47:03 +00:00
Colin Kuskie
f90f2f3a57 fix i18n typo in MatrixListing. 2009-01-12 00:44:58 +00:00
Graham Knop
33a3f2b439 fixed: Syndicated Content corrupts wide characters 2009-01-09 10:33:12 +00:00