diff --git a/docs/upgrades/upgrade_5.2.6-5.3.0.pl b/docs/upgrades/upgrade_5.2.6-5.3.0.pl index b02a97eec..548851566 100644 --- a/docs/upgrades/upgrade_5.2.6-5.3.0.pl +++ b/docs/upgrades/upgrade_5.2.6-5.3.0.pl @@ -6,6 +6,7 @@ use Parse::PlainConfig; use strict; use WebGUI::International; use WebGUI::SQL; +use WebGUI::URL; use WebGUI::Utility; @@ -147,6 +148,14 @@ $sth->finish; foreach my $query (@sql) { WebGUI::SQL->write($query); } +my $sth = WebGUI::SQL->read("select DataForm_fieldId,name,wobjectId from DataForm_fieldId"); +while (my @data = $sth->array) { + my $newname = WebGUI::URL::urlize($data[1]); + WebGUI::SQL->write("update DataForm_field set name=".quote($newname)." where DataForm_fieldId=".$data[0]); + WebGUI::SQL->write("update DataForm_entryData set name=".quote($newname)." where wobjectId=".$data[2]." and name=".quote($data[1])); +} +$sth->finish; + print "\tSetting up new global template structure.\n" unless ($quiet); diff --git a/docs/upgrades/upgrade_5.2.6-5.3.0.sql b/docs/upgrades/upgrade_5.2.6-5.3.0.sql index 80f2ef52c..ba4cc1347 100644 --- a/docs/upgrades/upgrade_5.2.6-5.3.0.sql +++ b/docs/upgrades/upgrade_5.2.6-5.3.0.sql @@ -204,14 +204,10 @@ delete from international where languageId=1 and namespace='WebGUI' and internat insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (832,1,'WebGUI','The collateral management system has several macros for its specific purpose.\r\n

\r\n\r\n^File();
\r\nThis macro builds a quick file link. It creates an icon for the file and outputs the files name. Then it links them both to the file for downloading.\r\n

\r\n\r\n^I();
\r\nThis macro retrieves an image from the collateral management system along with an HTML image tag so that you can quickly display an image from the repository in your content.\r\n

\r\nExample: ^I("logo");\r\n

\r\n\r\n^i();
\r\nThis macro retrieves the URL for any file in the collateral management system.\r\n

\r\nExample: ^i("status report");\r\n

\r\n\r\n\r\n^RandomImage();
\r\nThis macro takes a collateral folder as a parameter. If the folder name is omitted, then the root folder will be used. The macro then randomly chooses an image in the folder and returns it in much the same way the ^I(); macro works.\r\n

\r\nExample: ^RandomImage("site headers");\r\n

\r\n\r\n^RandomSnippet();
\r\nThis macro takes a collateral folder as a parameter. If the folder name is omitted, then the root folder will be used. The macro then randomly chooses a snippet from the folder and returns it in much the same way the ^Snippet(); macro works.\r\n

\r\nExample: ^RandomSnippet("quips");\r\n

\r\n\r\n\r\n^SI();
\r\nThe Scaled Image macro allows images to be found in the collateral and scaled (on the server-side), either maintaining the original aspect ratio or an entirely new ratio of your design. \r\n

\r\nIt takes four parameters. The first is the image name or optionally the collateral id. The second is the width. Set the width to "0" to maintain aspect ratio by height. The third is height. Set the height to "0" to maintain aspect ratio by width. The fourth parameter allows you to specify additional parameters to the image.\r\n

\r\nExamples:
\r\nRetrieving an image by name (no scaling)
\r\n^SI(myimage);\r\n

\r\nRetrieving an image by collateralId (no scaling)
\r\n^SI(66);\r\n

\r\nScaling by width, maintaining aspect ratio
\r\n^SI(66,25);\r\n

\r\nScaling by height, maintaining aspect ratio
\r\n^SI(66,0,25);\r\n

\r\nPlaying with the aspect ratio
\r\n^SI(66,148,25);\r\n

\r\nUsing parameters
\r\n^SI(66,0,0,\'border="0"\');\r\n

\r\n\r\n\r\n^Snippet();
\r\nThis macro retrieves the contents of a snippet in the collateral management system and inserts it into the page.\r\n

\r\nExample: ^Snippet("flash code");\r\n

\r\n\r\n^Thumbnail();
\r\nThis macro retrieves the URL for the thumbnail of any image in the collateral management system.\r\n

\r\nExample: ^Thumbnail("logo");\r\n

\r\n\r\n^ThumbnailLinker();
\r\nThis macro builds a quick image viewer using nothing more than the collateral management system. It creates a thumbnail image with the name of the image under it and then links them both to the full sized image. You can also specify a "1" as a second parameter to have the linker create a new window to display the linked image.\r\n

\r\nExample: ^ThumbnailLinker("logo");\r\n

\r\n\r\n', 1051221379,NULL); delete from help where namespace='MailForm'; update international set namespace='DataForm' where namespace='MailForm'; -delete from international where languageId=1 and namespace='DataForm' and internationalId=83; -insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (83,1,'DataForm','The following template variables are available for Data Form templates.\r\n

\r\n\r\nexport.tab.url
\r\nFollowing this URL will export the data stored to this data form as a tab delimited file.\r\n

\r\n\r\nexport.tab.label
\r\nThe default label for the export.tab.url variable.\r\n

\r\n\r\ncanEdit\r\nA conditional indicating whether the current user has the privileges to edit an existing entry or export the form\'s data.\r\n

\r\n\r\nback.url
\r\nA url that will take you back to the default page in the form.\r\n

\r\n\r\nback.label
\r\nThe default label for the back.url variable.\r\n

\r\n\r\nusername*
\r\nThe username of the user that submitted the data.\r\n

\r\n\r\nuserId*
\r\nThe user id of the user that submitted the data.\r\n

\r\n\r\ndate*
\r\nThe date that this data was submitted or last updated formatted as the user\'s preferred date/time format.\r\n

\r\n\r\n\r\nepoch*
\r\nThe date that this data was submitted or last updated formatted as an epoch date.\r\n

\r\n\r\nipAddress*
\r\nThe IP address of the user that submitted the data.\r\n

\r\n\r\nedit.url*
\r\nThe URL to the page to edit this entry.\r\n

\r\n\r\nerror_loop*
\r\nA loop containing error information, for instance if someone doesn\'t fill out a required field.\r\n

\r\n\r\n

\r\n\r\nerror.message*
\r\nAn error message indicating what the user might have done wrong.\r\n\r\n
\r\n\r\naddField.url
\r\nThe URL that content managers will visit to add a new field to the form.\r\n

\r\n\r\naddField.label
\r\nThe default label for the addField.url variable.\r\n

\r\n\r\nform.start
\r\nThe beginning of the form.\r\n

\r\n\r\nfield_loop
\r\nA loop containing all of the field information.\r\n

\r\n\r\n

\r\n\r\nfield.form
\r\nThe form element for this field.\r\n

\r\n\r\nfield.name
\r\nThe name of this field.\r\n

\r\n\r\nfield.value
\r\nThe value of this field. If this is new data, then the default value will be used.\r\n

\r\n\r\nfield.label
\r\nThe text label for this field.\r\n

\r\n\r\nfield.isHidden
\r\nA conditional indicating whether this field is supposed to be hidden. \r\n

\r\n\r\nfield.isDisplayed
\r\nA conditional indicating whether this field is supposed to be displayed. \r\n

\r\n\r\nfield.isEditable
\r\nA conditional indicating whether this field is editable. \r\n

\r\n\r\nfield.isRequired
\r\nA conditional indicating whether this field is required. \r\n

\r\n\r\nfield.isMailField
\r\nA conditional indicating whether this field is present only to facilitate sending an email. \r\n

\r\n\r\n\r\nfield.subtext
\r\nA description of the field so that users know what to put in the field.\r\n

\r\n\r\nfield.controls
\r\nWebGUI\'s administrative controls for this field.\r\n

\r\n\r\n

\r\n\r\nform.send
\r\nA form button with the word "send" printed on it.\r\n

\r\n\r\nform.save/b>
\r\nA form button with the word "save" printed on it.\r\n

\r\n\r\nform.end
\r\nThe end of the form.\r\n

\r\n\r\n*Only available if the user has already submitted the form.', 1052089810,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=84; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (84,1,'DataForm','Export tab delimited.', 1052088598,'Save the data with tabs as separaters.'); delete from international where languageId=1 and namespace='DataForm' and internationalId=61; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (61,1,'DataForm','Data Form, Add/Edit', 1052065048,NULL); -delete from international where languageId=1 and namespace='DataForm' and internationalId=71; -insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (71,1,'DataForm','This wobject creates a simple multipurpose data-entry form.\r\n

\r\n\r\nAcknowledgement
\r\nThis message will be displayed to the user after they submit their data..\r\n

\r\n\r\nMail entries?
\r\nIf set to yes, some additional fields will be added to your form for dealing with email. These fields will then be used to email any date entered into the form to a person of your choice.\r\n

\r\nNOTE: The "To" field that is added as a result of setting this to yes can accept a standard email address, or a WebGUI username or a WebGUI group name.\r\n

\r\n\r\nTemplate
\r\nChoose a template for your form.\r\n

\r\n\r\nEmail Template
\r\nChoose a template for the data that will be sent via email.\r\n

\r\n\r\nAcknowlegement Template
\r\nChoose a template that will be used to display the acknowlegement.\r\n', 1052065048,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=82; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (82,1,'DataForm','Data Form Template', 1052064770,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=81; @@ -219,7 +215,6 @@ insert into international (internationalId,languageId,namespace,message,lastUpda delete from international where languageId=1 and namespace='DataForm' and internationalId=28; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (28,1,'DataForm','Optional for text area and HTML area.', 1052048005,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=26; -insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (26,1,'DataForm','Store data?', 1052047897,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=11; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (11,1,'DataForm','To', 1052047848,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=62; @@ -266,195 +261,6 @@ delete from international where internationalId=31 and namespace='DataForm'; delete from international where internationalId=32 and namespace='DataForm'; delete from international where internationalId=9 and namespace='DataForm'; delete from international where internationalId=26 and namespace='DataForm'; -delete from help where helpId=20 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (20, 'WebGUI', 670, 625, '49,WebGUI;'); -delete from help where helpId=1 and namespace='FileManager'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'FileManager', 61, 71, '3,FileManager;2,FileManager;21,WebGUI;'); -delete from help where helpId=28 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (28, 'WebGUI', 678, 633, '1,WebGUI;3,WebGUI;'); -delete from help where helpId=31 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (31, 'WebGUI', 681, 636, '30,WebGUI;1,WebGUI;3,WebGUI;'); -delete from help where helpId=30 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (30, 'WebGUI', 680, 635, '31,WebGUI;'); -delete from help where helpId=25 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (25, 'WebGUI', 675, 630, '60,WebGUI;'); -delete from help where helpId=1 and namespace='Item'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Item', 61, 71, '2,Item;21,WebGUI;'); -delete from help where helpId=6 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (6, 'WebGUI', 656, 611, '12,WebGUI;'); -delete from help where helpId=46 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (46, 'WebGUI', 696, 651, '66,WebGUI;'); -delete from help where helpId=22 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (22, 'WebGUI', 672, 627, '12,WebGUI;'); -delete from help where helpId=1 and namespace='USS'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'USS', 61, 71, '3,USS;2,USS;21,WebGUI;'); -delete from help where helpId=24 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (24, 'WebGUI', 674, 629, '12,WebGUI;'); -delete from help where helpId=1 and namespace='FAQ'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'FAQ', 61, 71, '3,FAQ;2,FAQ;21,WebGUI;'); -delete from help where helpId=13 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (13, 'WebGUI', 663, 618, '12,WebGUI;'); -delete from help where helpId=1 and namespace='SyndicatedContent'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SyndicatedContent', 61, 71, '2,SyndicatedContent;21,WebGUI;'); -delete from help where helpId=1 and namespace='EventsCalendar'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'EventsCalendar', 61, 71, '2,EventsCalendar;3,EventsCalendar;21,WebGUI;'); -delete from help where helpId=1 and namespace='MessageBoard'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'MessageBoard', 61, 71, '2,MessageBoard;21,WebGUI;'); -delete from help where helpId=1 and namespace='LinkList'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'LinkList', 61, 71, '3,LinkList;2,LinkList;21,WebGUI;'); -delete from help where helpId=21 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (21, 'WebGUI', 671, 626, '19,WebGUI;18,WebGUI;27,WebGUI;14,WebGUI;'); -delete from help where helpId=1 and namespace='Article'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Article', 61, 71, '2,Article;21,WebGUI;'); -delete from help where helpId=1 and namespace='ExtraColumn'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'ExtraColumn', 61, 71, '21,WebGUI;'); -delete from help where helpId=27 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (27, 'WebGUI', 677, 632, '1,Article;1,EventsCalendar;1,ExtraColumn;1,FAQ;1,FileManager;1,HttpProxy;1,Item;1,LinkList;1,DataForm;1,MessageBoard;1,Poll;1,Product;1,SiteMap;1,SQLReport;1,Survey;1,SyndicatedContent;1,USS;1,WobjectProxy;21,WebGUI;'); -delete from help where helpId=1 and namespace='Poll'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Poll', 61, 71, '2,Poll;21,WebGUI;'); -delete from help where helpId=1 and namespace='SiteMap'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SiteMap', 61, 71, '2,SiteMap;21,WebGUI;'); -delete from help where helpId=1 and namespace='SQLReport'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SQLReport', 61, 71, '21,WebGUI;'); -delete from help where helpId=18 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (18, 'WebGUI', 668, 623, NULL); -delete from help where helpId=17 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (17, 'WebGUI', 667, 622, '10,WebGUI;'); -delete from help where helpId=2 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'WebGUI', 652, 607, '12,WebGUI;'); -delete from help where helpId=15 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (15, 'WebGUI', 665, 620, '10,WebGUI;'); -delete from help where helpId=16 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (16, 'WebGUI', 666, 621, '60,WebGUI;9,WebGUI;'); -delete from help where helpId=14 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (14, 'WebGUI', 664, 619, '21,WebGUI;'); -delete from help where helpId=12 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (12, 'WebGUI', 662, 617, '6,WebGUI;29,WebGUI;13,WebGUI;24,WebGUI;22,WebGUI;2,WebGUI;'); -delete from help where helpId=10 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (10, 'WebGUI', 660, 615, '17,WebGUI;15,WebGUI;8,WebGUI;'); -delete from help where helpId=8 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (8, 'WebGUI', 658, 613, '10,WebGUI;32,WebGUI;5,WebGUI;7,WebGUI;'); -delete from help where helpId=9 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (9, 'WebGUI', 659, 614, '19,WebGUI;61,WebGUI;18,WebGUI;16,WebGUI;4,WebGUI;'); -delete from help where helpId=7 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (7, 'WebGUI', 657, 612, '8,WebGUI;'); -delete from help where helpId=32 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (32, 'WebGUI', 682, 637, '8,WebGUI;'); -delete from help where helpId=5 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (5, 'WebGUI', 655, 610, '8,WebGUI;'); -delete from help where helpId=3 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'WebGUI', 653, 608, '1,WebGUI;'); -delete from help where helpId=4 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'WebGUI', 654, 609, '9,WebGUI;'); -delete from help where helpId=1 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'WebGUI', 642, 606, '52,WebGUI;3,WebGUI;'); -delete from help where helpId=29 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (29, 'WebGUI', 679, 634, '12,WebGUI;'); -delete from help where helpId=33 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (33, 'WebGUI', 683, 638, '61,WebGUI;34,WebGUI;35,WebGUI;50,WebGUI;'); -delete from help where helpId=34 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (34, 'WebGUI', 684, 639, '33,WebGUI;'); -delete from help where helpId=35 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (35, 'WebGUI', 685, 640, '33,WebGUI;'); -delete from help where helpId=19 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (19, 'WebGUI', 669, 624, '53,WebGUI;58,WebGUI;57,WebGUI;60,WebGUI;59,WebGUI;'); -delete from help where helpId=1 and namespace='DataForm'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'DataForm', 61, 71, '2,DataForm;3,DataForm;21,WebGUI;'); -delete from help where helpId=2 and namespace='DataForm'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'DataForm', 62, 72, '3,DataForm;1,DataForm;'); -delete from help where helpId=2 and namespace='FileManager'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'FileManager', 72, 73, '1,FileManager;'); -delete from help where helpId=2 and namespace='EventsCalendar'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'EventsCalendar', 72, 73, '4,EventsCalendar;1,EventsCalendar;'); -delete from help where helpId=2 and namespace='FAQ'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'FAQ', 72, 73, '1,FAQ;'); -delete from help where helpId=2 and namespace='LinkList'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'LinkList', 72, 73, '1,LinkList;'); -delete from help where helpId=47 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (47, 'WebGUI', 697, 698, '1,Article;17,WebGUI;1,MessageBoard;1,Poll;2,WebGUI;1,USS;'); -delete from help where helpId=1 and namespace='WobjectProxy'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'WobjectProxy', 5, 6, '21,WebGUI;'); -delete from help where helpId=1 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Product', 38, 39, '5,Product;4,Product;6,Product;2,Product;3,Product;7,Product;21,WebGUI;'); -delete from help where helpId=2 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Product', 40, 41, '6,Product;1,Product;'); -delete from help where helpId=3 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'Product', 42, 43, '1,Product;'); -delete from help where helpId=4 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'Product', 44, 45, '1,Product;'); -delete from help where helpId=5 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (5, 'Product', 46, 47, '1,Product;'); -delete from help where helpId=6 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (6, 'Product', 49, 50, '2,Product;1,Product;'); -delete from help where helpId=7 and namespace='Product'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (7, 'Product', 62, 63, '1,Product;51,WebGUI;'); -delete from help where helpId=1 and namespace='Survey'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Survey', 3, 4, '21,WebGUI;'); -delete from help where helpId=49 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (49, 'WebGUI', 785, 786, '53,WebGUI;54,WebGUI;56,WebGUI;20,WebGUI;61,WebGUI;55,WebGUI;'); -delete from help where helpId=50 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (50, 'WebGUI', 825, 826, '33,WebGUI;'); -delete from help where helpId=2 and namespace='Article'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Article', 72, 73, '1,Article;51,WebGUI;'); -delete from help where helpId=51 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (51, 'WebGUI', 827, 828, '2,Article;3,DataForm;3,EventsCalendar;3,FAQ;3,FileManager;2,Item;3,LinkList;2,MessageBoard;7,Product;2,SiteMap;2,SyndicatedContent;33,WebGUI;2,USS;'); -delete from help where helpId=3 and namespace='EventsCalendar'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'EventsCalendar', 94, 95, '1,EventsCalendar;51,WebGUI;'); -delete from help where helpId=3 and namespace='FAQ'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'FAQ', 76, 77, '1,FAQ;51,WebGUI;'); -delete from help where helpId=3 and namespace='FileManager'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'FileManager', 75, 76, '1,FileManager;51,WebGUI;'); -delete from help where helpId=4 and namespace='EventsCalendar'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'EventsCalendar', 96, 97, '2,EventsCalendar;51,WebGUI;'); -delete from help where helpId=2 and namespace='Item'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Item', 73, 74, '1,Item;51,WebGUI;'); -delete from help where helpId=3 and namespace='LinkList'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'LinkList', 75, 76, '1,LinkList;51,WebGUI;'); -delete from help where helpId=2 and namespace='MessageBoard'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'MessageBoard', 73, 74, '1,MessageBoard;51,WebGUI;'); -delete from help where helpId=2 and namespace='SiteMap'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'SiteMap', 72, 73, '1,SiteMap;51,WebGUI;'); -delete from help where helpId=2 and namespace='USS'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'USS', 74, 75, '1,USS;51,WebGUI;'); -delete from help where helpId=3 and namespace='USS'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'USS', 76, 77, '1,USS;51,WebGUI;'); -delete from help where helpId=52 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (52, 'WebGUI', 829, 830, '1,WebGUI;33,WebGUI;'); -delete from help where helpId=53 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (53, 'WebGUI', 831, 832, '49,WebGUI;19,WebGUI;'); -delete from help where helpId=54 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (54, 'WebGUI', 833, 834, '49,WebGUI;'); -delete from help where helpId=55 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (55, 'WebGUI', 835, 836, '49,WebGUI;'); -delete from help where helpId=56 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (56, 'WebGUI', 837, 838, '49,WebGUI;'); -delete from help where helpId=57 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (57, 'WebGUI', 839, 840, '19,WebGUI;'); -delete from help where helpId=58 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (58, 'WebGUI', 841, 842, '19,WebGUI;'); -delete from help where helpId=59 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (59, 'WebGUI', 843, 844, '19,WebGUI;'); -delete from help where helpId=60 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (60, 'WebGUI', 845, 846, '19,WebGUI;16,WebGUI;'); -delete from help where helpId=2 and namespace='SyndicatedContent'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'SyndicatedContent', 72, 73, '1,SyndicatedContent;'); -delete from help where helpId=1 and namespace='HttpProxy'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'HttpProxy', 10, 11, '21,WebGUI;'); -delete from help where helpId=2 and namespace='Poll'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Poll', 73, 74, '1,Poll;51,WebGUI;'); -delete from help where helpId=61 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (61, 'WebGUI', 931, 932, '49,WebGUI;9,WebGUI;33,WebGUI;64,WebGUI;62,WebGUI;63,WebGUI;'); -delete from help where helpId=62 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (62, 'WebGUI', 933, 934, '61,WebGUI;'); -delete from help where helpId=63 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (63, 'WebGUI', 936, 937, '61,WebGUI;'); -delete from help where helpId=64 and namespace='WebGUI'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (64, 'WebGUI', 938, 939, '61,WebGUI;'); -delete from help where helpId=3 and namespace='DataForm'; -insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'DataForm', 82, 83, '2,DataForm;1,DataForm;51,WebGUI;'); -INSERT INTO template VALUES (1,'Mail Form','\n

\n\n\n\n
  • \n\n\n\n\n

    \n\n\n\n \">\n · \">\n

    \n\n\n\n\n\n \n \n \n\n\n
    \n \n \n \n \n \n \n \n \n *\n
    \n
    \n\n\n','DataForm'); -INSERT INTO template VALUES (2,'Default Email','\n\n: \n','DataForm'); -INSERT INTO template VALUES (3,'Default Acknowlegement','\n

    \n\n\n\n \n \n\n\n
    \n

    \n\">','DataForm'); alter table groups add column scratchFilter text; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (945,1,'WebGUI','Scratch Filter', 1052560369,'There is a type of session variable called a "scratch" variable. So a scratch filter allows you to add someone to a group based upon a scratch variable.'); update userProfileField set dataType='selectList' where dataType='select'; @@ -588,6 +394,222 @@ delete from international where languageId=1 and namespace='DataForm' and intern insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (72,1,'DataForm','You may add as many additional fields to your Data Form as you like.\r\n

    \r\n\r\nLabel
    \r\nThis is an informative text label to let the user know what this field represents.\r\n

    \r\n\r\nField Name
    \r\nThe name of this field. It must be unique among all of the other fields on your form.\r\n

    \r\n\r\nSubtext
    \r\nAn extension of the label, this is a description of what should go in the field or optional instructions for the field.\r\n

    \r\n\r\nStatus
    \r\nHidden fields will not be visible to the user, but will be sent in the email.Displayed fields can be seen by the user but not modified. Modifiable fields can be filled in by the user. Required fields must be filled in by the user.\r\nIf you choose Hidden or Displayed, be sure to fill in a Default Value.\r\n

    \r\n\r\nType
    \r\nChoose the type of form element for this field. \r\n

    \r\n\r\nWidth
    \r\nSet the number of characters wide this field will be.\r\n

    \r\n\r\nHeight
    \r\nSet the number of characters tall this field will be. Only used on textarea and HTMLArea.\r\n

    \r\n\r\nPossible Values
    \r\nThis field is used for the list types (like Checkbox List and Select List). Enter the values you wish to appear, one per line.\r\n

    \r\n\r\nDefault Value (optional)
    \r\nEnter the default value (if any) for the field. For Yes/No fields, enter "yes" to select "Yes" and "no" to select "No".\r\n

    \r\n\r\n', 1053855075,NULL); delete from international where languageId=1 and namespace='DataForm' and internationalId=25; insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (25,1,'DataForm','Default Value(s)', 1053855043,NULL); +alter table DataForm add column listTemplateId int not null default 1; +delete from international where languageId=1 and namespace='DataForm' and internationalId=61; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (61,1,'DataForm','Data Form, Add/Edit', 1053885941,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=71; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (71,1,'DataForm','This wobject creates a simple multipurpose data-entry form.\r\n

    \r\n\r\nAcknowledgement
    \r\nThis message will be displayed to the user after they submit their data..\r\n

    \r\n\r\nMail entries?
    \r\nIf set to yes, some additional fields will be added to your form for dealing with email. These fields will then be used to email any date entered into the form to a person of your choice.\r\n

    \r\nNOTE: The "To" field that is added as a result of setting this to yes can accept a standard email address, or a WebGUI username or a WebGUI group name.\r\n

    \r\n\r\nTemplate
    \r\nChoose a template for your form.\r\n

    \r\n\r\nEmail Template
    \r\nChoose a template for the data that will be sent via email.\r\n

    \r\n\r\nAcknowlegement Template
    \r\nChoose a template that will be used to display the acknowlegement.\r\n

    \r\n\r\nList Template
    \r\nChoose a template that will be used to display the list of stored records in this Data Form.\r\n

    ', 1053885941,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=82; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (82,1,'DataForm','Data Form Template', 1053885798,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=83; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (83,1,'DataForm','The following template variables are available for Data Form templates.\r\n

    \r\n\r\nexport.tab.url
    \r\nFollowing this URL will export the data stored to this data form as a tab delimited file.\r\n

    \r\n\r\nexport.tab.label
    \r\nThe default label for the export.tab.url variable.\r\n

    \r\n\r\nentryList.url
    \r\nFollowing this URL will display a list of all the record entries in this data form.\r\n

    \r\n\r\nentryList.label
    \r\nThe default label for the entryList.url variable.\r\n

    \r\n\r\ncanEdit\r\nA conditional indicating whether the current user has the privileges to edit an existing entry or export the form\'s data.\r\n

    \r\n\r\nback.url
    \r\nA url that will take you back to the default page in the form.\r\n

    \r\n\r\nback.label
    \r\nThe default label for the back.url variable.\r\n

    \r\n\r\nusername*
    \r\nThe username of the user that submitted the data.\r\n

    \r\n\r\nuserId*
    \r\nThe user id of the user that submitted the data.\r\n

    \r\n\r\ndate*
    \r\nThe date that this data was submitted or last updated formatted as the user\'s preferred date/time format.\r\n

    \r\n\r\n\r\nepoch*
    \r\nThe date that this data was submitted or last updated formatted as an epoch date.\r\n

    \r\n\r\nipAddress*
    \r\nThe IP address of the user that submitted the data.\r\n

    \r\n\r\nedit.url*
    \r\nThe URL to the page to edit this entry.\r\n

    \r\n\r\nerror_loop*
    \r\nA loop containing error information, for instance if someone doesn\'t fill out a required field.\r\n

    \r\n\r\n

    \r\n\r\nerror.message*
    \r\nAn error message indicating what the user might have done wrong.\r\n\r\n
    \r\n\r\naddField.url
    \r\nThe URL that content managers will visit to add a new field to the form.\r\n

    \r\n\r\naddField.label
    \r\nThe default label for the addField.url variable.\r\n

    \r\n\r\nform.start
    \r\nThe beginning of the form.\r\n

    \r\n\r\nfield_loop
    \r\nA loop containing all of the field information.\r\n

    \r\n\r\n

    \r\n\r\nfield.form
    \r\nThe form element for this field.\r\n

    \r\n\r\nfield.name
    \r\nThe name of this field.\r\n

    \r\n\r\nfield.value
    \r\nThe value of this field. If this is new data, then the default value will be used.\r\n

    \r\n\r\nfield.label
    \r\nThe text label for this field.\r\n

    \r\n\r\nfield.isHidden
    \r\nA conditional indicating whether this field is supposed to be hidden. \r\n

    \r\n\r\nfield.isDisplayed
    \r\nA conditional indicating whether this field is supposed to be displayed. \r\n

    \r\n\r\nfield.isEditable
    \r\nA conditional indicating whether this field is editable. \r\n

    \r\n\r\nfield.isRequired
    \r\nA conditional indicating whether this field is required. \r\n

    \r\n\r\nfield.isMailField
    \r\nA conditional indicating whether this field is present only to facilitate sending an email. \r\n

    \r\n\r\n\r\nfield.subtext
    \r\nA description of the field so that users know what to put in the field.\r\n

    \r\n\r\nfield.controls
    \r\nWebGUI\'s administrative controls for this field.\r\n

    \r\n\r\n

    \r\n\r\nform.send
    \r\nA form button with the word "send" printed on it.\r\n

    \r\n\r\nform.save/b>
    \r\nA form button with the word "save" printed on it.\r\n

    \r\n\r\nform.end
    \r\nThe end of the form.\r\n

    \r\n\r\n*Only available if the user has already submitted the form.', 1053885798,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=88; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (88,1,'DataForm','Data Form List Template', 1053885702,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=89; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (89,1,'DataForm','The following variables are available to the Data Form List template:\r\n

    \r\n\r\nback.url
    \r\nThe URL to go back to the Data Form data entry page.\r\n

    \r\n\r\nback.label
    \r\nThe default label for the back.url.\r\n

    \r\n\r\nfield_loop
    \r\nA loop containing information about the fields in this Data Form.\r\n\r\n\r\nfield.name
    \r\nThe web safe name of this field.\r\n

    \r\n\r\nfield.label
    \r\nThe human readable label for this field.\r\n

    \r\n\r\nfield.id
    \r\nA unique identifier representing this field in the database.\r\n

    \r\n\r\nfield.isMailField
    \r\nA conditional indicating whether this field exists for the mail subsystem of the data form.\r\n

    \r\n\r\nfield.type
    \r\nThe data type associated with this field.\r\n

    \r\n\r\n\r\n\r\nrecord_loop
    \r\nA loop containing the record entries of this data form.\r\n

    \r\n\r\n

    \r\n\r\nrecord.entryId
    \r\nA unique identifier for this record entry.\r\n

    \r\n\r\nrecord.ipAddress
    \r\nThe IP Address of the user that submitted this record entry.\r\n

    \r\n\r\nrecord.edit.url
    \r\nThe URL to edit this record.\r\n

    \r\n\r\nrecord.username
    \r\nThe username of the person that submitted this record entry.\r\n

    \r\n\r\nrecord.userId
    \r\nThe user id of the person that submitted this record entry.\r\n

    \r\n\r\nrecord.submissionDate.epoch
    \r\nThe epoch datestamp for this record entry.\r\n

    \r\n\r\nrecord.submissionDate.human
    \r\nA human readable date stamp, based upon the user\'s preferences, for this record entry.\r\n

    \r\n\r\nrecord.data_loop
    \r\nA loop containing the data submitted by the user for each field in this data form.\r\n

    \r\n\r\n

    \r\n\r\nrecord.data.value
    \r\nThe value submitted by the user for this field in this record entry.\r\n

    \r\n\r\nrecord.data.name
    \r\nThe web safe name of this field.\r\n

    \r\n\r\nrecord.data.label
    \r\nThe human readable label for this field.\r\n

    \r\n\r\nrecord.data.isMailField
    \r\nA conditional indicating whether this field exists for the mail subsystem of the data form.\r\n

    \r\n\r\n

    \r\n\r\n
    ', 1053885702,NULL); +delete from international where languageId=1 and namespace='DataForm' and internationalId=87; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (87,1,'DataForm','List Template', 1053884753,'Prompt the user to select a template for the list view of the data form.'); +delete from international where languageId=1 and namespace='DataForm' and internationalId=86; +insert into international (internationalId,languageId,namespace,message,lastUpdated,context) values (86,1,'DataForm','List all entries.', 1053882548,'A label that links to all Data Form entries made to date.'); +INSERT INTO template VALUES (1,'Mail Form','\n

    \n
    \n\n\n
  • \n\n\n\n\n

    \n\n\n\n \">\n · \">\n \n · \">\n \n

    \n\n\n\n\n\n \n \n \n\n\n
    \n \n \n \n \n \n \n \n \n *\n
    \n
    \n\n\n','DataForm'); +INSERT INTO template VALUES (2,'Default Email','\n\n: \n','DataForm'); +INSERT INTO template VALUES (3,'Default Acknowlegement','\n

    \n\n\n\n \n \n\n\n
    \n

    \n\">','DataForm'); +INSERT INTO template VALUES (1,'Data List','\">\n

    \n\n\n\n\n \n \n \n\n\n\n\n\n \n \n \n \n \n \n \n\n\n
    Entry IDSubmission Date
    \">
    ','DataForm/List'); +delete from help where helpId=20 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (20, 'WebGUI', 670, 625, '49,WebGUI;'); +delete from help where helpId=1 and namespace='FileManager'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'FileManager', 61, 71, '3,FileManager;2,FileManager;21,WebGUI;'); +delete from help where helpId=28 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (28, 'WebGUI', 678, 633, '1,WebGUI;3,WebGUI;'); +delete from help where helpId=31 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (31, 'WebGUI', 681, 636, '30,WebGUI;1,WebGUI;3,WebGUI;'); +delete from help where helpId=30 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (30, 'WebGUI', 680, 635, '31,WebGUI;'); +delete from help where helpId=25 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (25, 'WebGUI', 675, 630, '60,WebGUI;'); +delete from help where helpId=1 and namespace='Item'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Item', 61, 71, '2,Item;21,WebGUI;'); +delete from help where helpId=6 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (6, 'WebGUI', 656, 611, '12,WebGUI;'); +delete from help where helpId=46 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (46, 'WebGUI', 696, 651, '66,WebGUI;'); +delete from help where helpId=22 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (22, 'WebGUI', 672, 627, '12,WebGUI;'); +delete from help where helpId=1 and namespace='USS'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'USS', 61, 71, '3,USS;2,USS;21,WebGUI;'); +delete from help where helpId=24 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (24, 'WebGUI', 674, 629, '12,WebGUI;'); +delete from help where helpId=1 and namespace='FAQ'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'FAQ', 61, 71, '3,FAQ;2,FAQ;21,WebGUI;'); +delete from help where helpId=13 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (13, 'WebGUI', 663, 618, '12,WebGUI;'); +delete from help where helpId=1 and namespace='SyndicatedContent'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SyndicatedContent', 61, 71, '2,SyndicatedContent;21,WebGUI;'); +delete from help where helpId=1 and namespace='EventsCalendar'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'EventsCalendar', 61, 71, '2,EventsCalendar;3,EventsCalendar;21,WebGUI;'); +delete from help where helpId=1 and namespace='MessageBoard'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'MessageBoard', 61, 71, '2,MessageBoard;21,WebGUI;'); +delete from help where helpId=1 and namespace='LinkList'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'LinkList', 61, 71, '3,LinkList;2,LinkList;21,WebGUI;'); +delete from help where helpId=21 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (21, 'WebGUI', 671, 626, '19,WebGUI;18,WebGUI;27,WebGUI;14,WebGUI;'); +delete from help where helpId=1 and namespace='Article'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Article', 61, 71, '2,Article;21,WebGUI;'); +delete from help where helpId=1 and namespace='ExtraColumn'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'ExtraColumn', 61, 71, '21,WebGUI;'); +delete from help where helpId=27 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (27, 'WebGUI', 677, 632, '1,Article;1,EventsCalendar;1,ExtraColumn;1,FAQ;1,FileManager;1,HttpProxy;1,Item;1,LinkList;1,DataForm;1,MessageBoard;1,Poll;1,Product;1,SiteMap;1,SQLReport;1,Survey;1,SyndicatedContent;1,USS;1,WobjectProxy;21,WebGUI;'); +delete from help where helpId=1 and namespace='Poll'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Poll', 61, 71, '2,Poll;21,WebGUI;'); +delete from help where helpId=1 and namespace='SiteMap'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SiteMap', 61, 71, '2,SiteMap;21,WebGUI;'); +delete from help where helpId=1 and namespace='SQLReport'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'SQLReport', 61, 71, '21,WebGUI;'); +delete from help where helpId=18 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (18, 'WebGUI', 668, 623, NULL); +delete from help where helpId=17 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (17, 'WebGUI', 667, 622, '10,WebGUI;'); +delete from help where helpId=2 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'WebGUI', 652, 607, '12,WebGUI;'); +delete from help where helpId=15 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (15, 'WebGUI', 665, 620, '10,WebGUI;'); +delete from help where helpId=16 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (16, 'WebGUI', 666, 621, '60,WebGUI;9,WebGUI;'); +delete from help where helpId=14 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (14, 'WebGUI', 664, 619, '21,WebGUI;'); +delete from help where helpId=12 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (12, 'WebGUI', 662, 617, '6,WebGUI;29,WebGUI;13,WebGUI;24,WebGUI;22,WebGUI;2,WebGUI;'); +delete from help where helpId=10 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (10, 'WebGUI', 660, 615, '17,WebGUI;15,WebGUI;8,WebGUI;'); +delete from help where helpId=8 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (8, 'WebGUI', 658, 613, '10,WebGUI;32,WebGUI;5,WebGUI;7,WebGUI;'); +delete from help where helpId=9 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (9, 'WebGUI', 659, 614, '19,WebGUI;61,WebGUI;18,WebGUI;16,WebGUI;4,WebGUI;'); +delete from help where helpId=7 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (7, 'WebGUI', 657, 612, '8,WebGUI;'); +delete from help where helpId=32 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (32, 'WebGUI', 682, 637, '8,WebGUI;'); +delete from help where helpId=5 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (5, 'WebGUI', 655, 610, '8,WebGUI;'); +delete from help where helpId=3 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'WebGUI', 653, 608, '1,WebGUI;'); +delete from help where helpId=4 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'WebGUI', 654, 609, '9,WebGUI;'); +delete from help where helpId=1 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'WebGUI', 642, 606, '52,WebGUI;3,WebGUI;'); +delete from help where helpId=29 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (29, 'WebGUI', 679, 634, '12,WebGUI;'); +delete from help where helpId=33 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (33, 'WebGUI', 683, 638, '61,WebGUI;34,WebGUI;35,WebGUI;50,WebGUI;'); +delete from help where helpId=34 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (34, 'WebGUI', 684, 639, '33,WebGUI;'); +delete from help where helpId=35 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (35, 'WebGUI', 685, 640, '33,WebGUI;'); +delete from help where helpId=19 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (19, 'WebGUI', 669, 624, '53,WebGUI;58,WebGUI;57,WebGUI;60,WebGUI;59,WebGUI;'); +delete from help where helpId=2 and namespace='FileManager'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'FileManager', 72, 73, '1,FileManager;'); +delete from help where helpId=2 and namespace='EventsCalendar'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'EventsCalendar', 72, 73, '4,EventsCalendar;1,EventsCalendar;'); +delete from help where helpId=2 and namespace='FAQ'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'FAQ', 72, 73, '1,FAQ;'); +delete from help where helpId=2 and namespace='LinkList'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'LinkList', 72, 73, '1,LinkList;'); +delete from help where helpId=47 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (47, 'WebGUI', 697, 698, '1,Article;17,WebGUI;1,MessageBoard;1,Poll;2,WebGUI;1,USS;'); +delete from help where helpId=1 and namespace='WobjectProxy'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'WobjectProxy', 5, 6, '21,WebGUI;'); +delete from help where helpId=1 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Product', 38, 39, '5,Product;4,Product;6,Product;2,Product;3,Product;7,Product;21,WebGUI;'); +delete from help where helpId=2 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Product', 40, 41, '6,Product;1,Product;'); +delete from help where helpId=3 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'Product', 42, 43, '1,Product;'); +delete from help where helpId=4 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'Product', 44, 45, '1,Product;'); +delete from help where helpId=5 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (5, 'Product', 46, 47, '1,Product;'); +delete from help where helpId=6 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (6, 'Product', 49, 50, '2,Product;1,Product;'); +delete from help where helpId=7 and namespace='Product'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (7, 'Product', 62, 63, '1,Product;51,WebGUI;'); +delete from help where helpId=1 and namespace='Survey'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'Survey', 3, 4, '21,WebGUI;'); +delete from help where helpId=49 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (49, 'WebGUI', 785, 786, '53,WebGUI;54,WebGUI;56,WebGUI;20,WebGUI;61,WebGUI;55,WebGUI;'); +delete from help where helpId=50 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (50, 'WebGUI', 825, 826, '33,WebGUI;'); +delete from help where helpId=2 and namespace='Article'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Article', 72, 73, '1,Article;51,WebGUI;'); +delete from help where helpId=51 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (51, 'WebGUI', 827, 828, '2,Article;3,DataForm;3,EventsCalendar;3,FAQ;3,FileManager;2,Item;3,LinkList;2,MessageBoard;7,Product;2,SiteMap;2,SyndicatedContent;33,WebGUI;2,USS;'); +delete from help where helpId=3 and namespace='EventsCalendar'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'EventsCalendar', 94, 95, '1,EventsCalendar;51,WebGUI;'); +delete from help where helpId=3 and namespace='FAQ'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'FAQ', 76, 77, '1,FAQ;51,WebGUI;'); +delete from help where helpId=3 and namespace='FileManager'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'FileManager', 75, 76, '1,FileManager;51,WebGUI;'); +delete from help where helpId=4 and namespace='EventsCalendar'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'EventsCalendar', 96, 97, '2,EventsCalendar;51,WebGUI;'); +delete from help where helpId=2 and namespace='Item'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Item', 73, 74, '1,Item;51,WebGUI;'); +delete from help where helpId=3 and namespace='LinkList'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'LinkList', 75, 76, '1,LinkList;51,WebGUI;'); +delete from help where helpId=2 and namespace='MessageBoard'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'MessageBoard', 73, 74, '1,MessageBoard;51,WebGUI;'); +delete from help where helpId=2 and namespace='SiteMap'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'SiteMap', 72, 73, '1,SiteMap;51,WebGUI;'); +delete from help where helpId=2 and namespace='USS'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'USS', 74, 75, '1,USS;51,WebGUI;'); +delete from help where helpId=3 and namespace='USS'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'USS', 76, 77, '1,USS;51,WebGUI;'); +delete from help where helpId=52 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (52, 'WebGUI', 829, 830, '1,WebGUI;33,WebGUI;'); +delete from help where helpId=53 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (53, 'WebGUI', 831, 832, '49,WebGUI;19,WebGUI;'); +delete from help where helpId=54 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (54, 'WebGUI', 833, 834, '49,WebGUI;'); +delete from help where helpId=55 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (55, 'WebGUI', 835, 836, '49,WebGUI;'); +delete from help where helpId=56 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (56, 'WebGUI', 837, 838, '49,WebGUI;'); +delete from help where helpId=57 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (57, 'WebGUI', 839, 840, '19,WebGUI;'); +delete from help where helpId=58 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (58, 'WebGUI', 841, 842, '19,WebGUI;'); +delete from help where helpId=59 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (59, 'WebGUI', 843, 844, '19,WebGUI;'); +delete from help where helpId=60 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (60, 'WebGUI', 845, 846, '19,WebGUI;16,WebGUI;'); +delete from help where helpId=2 and namespace='SyndicatedContent'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'SyndicatedContent', 72, 73, '1,SyndicatedContent;'); +delete from help where helpId=1 and namespace='HttpProxy'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'HttpProxy', 10, 11, '21,WebGUI;'); +delete from help where helpId=1 and namespace='DataForm'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (1, 'DataForm', 61, 71, '2,DataForm;4,DataForm;3,DataForm;21,WebGUI;'); +delete from help where helpId=2 and namespace='DataForm'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'DataForm', 62, 72, '3,DataForm;1,DataForm;'); +delete from help where helpId=2 and namespace='Poll'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (2, 'Poll', 73, 74, '1,Poll;51,WebGUI;'); +delete from help where helpId=61 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (61, 'WebGUI', 931, 932, '49,WebGUI;9,WebGUI;33,WebGUI;64,WebGUI;62,WebGUI;63,WebGUI;'); +delete from help where helpId=62 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (62, 'WebGUI', 933, 934, '61,WebGUI;'); +delete from help where helpId=63 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (63, 'WebGUI', 936, 937, '61,WebGUI;'); +delete from help where helpId=64 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (64, 'WebGUI', 938, 939, '61,WebGUI;'); +delete from help where helpId=3 and namespace='DataForm'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (3, 'DataForm', 82, 83, '2,DataForm;1,DataForm;51,WebGUI;'); +delete from help where helpId=65 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (65, 'WebGUI', 957, 958, '67,WebGUI;'); +delete from help where helpId=66 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (66, 'WebGUI', 960, 961, '46,WebGUI;'); +delete from help where helpId=67 and namespace='WebGUI'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (67, 'WebGUI', 968, 969, '65,WebGUI;'); +delete from help where helpId=4 and namespace='DataForm'; +insert into help (helpId,namespace,titleId,bodyId,seeAlso) values (4, 'DataForm', 88, 89, '1,DataForm;'); + diff --git a/lib/WebGUI/Form.pm b/lib/WebGUI/Form.pm index c15a44086..2f2a68752 100644 --- a/lib/WebGUI/Form.pm +++ b/lib/WebGUI/Form.pm @@ -471,7 +471,7 @@ sub fieldType { } elsif ($type eq "radioList") { $hash{radioList} = WebGUI::International::get(942); } elsif ($type eq "checkList") { - $hash{checkboxList} = WebGUI::International::get(941); + $hash{checkList} = WebGUI::International::get(941); } elsif ($type eq "zipcode") { $hash{zipcode} = WebGUI::International::get(944); } elsif ($type eq "checkbox") { diff --git a/lib/WebGUI/Wobject/DataForm.pm b/lib/WebGUI/Wobject/DataForm.pm index 1381d6fb0..fe001bec4 100644 --- a/lib/WebGUI/Wobject/DataForm.pm +++ b/lib/WebGUI/Wobject/DataForm.pm @@ -33,7 +33,7 @@ our @ISA = qw(WebGUI::Wobject); sub _createField { my $data = $_[0]; my %param; - $param{name} = WebGUI::URL::urlize($data->{name}); + $param{name} = $data->{name}; $param{name} = "field_".$data->{sequenceNumber} if ($param{name} eq ""); # Empty fieldname not allowed $session{form}{$param{name}} =~ s/\^.*?\;//gs ; # remove macro's from user input $param{value} = $data->{value}; @@ -103,11 +103,66 @@ sub duplicate { } #------------------------------------------------------------------- -sub getTemplateVars { +sub getListTemplateVars { + my $self = shift; + my $var = shift; + my @fieldLoop; + $var->{"back.url"} = WebGUI::URL::page(); + $var->{"back.label"} = WebGUI::International::get(18,$self->get("namespace")); + my $a = WebGUI::SQL->read("select DataForm_fieldId,name,label,isMailField,type from DataForm_field + where wobjectId=".$self->get("wobjectId")." order by sequenceNumber"); + while (my $field = $a->hashRef) { + push(@fieldLoop,{ + "field.name"=>$field->{name}, + "field.id"=>$field->{DataForm_fieldId}, + "field.label"=>$field->{label}, + "field.isMailField"=>$field->{isMailField}, + "field.type"=>$field->{type}, + }); + } + $a->finish; + $var->{field_loop} = \@fieldLoop; + my @recordLoop; + my $a = WebGUI::SQL->read("select ipAddress,username,userid,submissionDate,DataForm_entryId from DataForm_entry + where wobjectId=".$self->get("wobjectId")." order by submissionDate desc"); + while (my $record = $a->hashRef) { + my @dataLoop; + my $b = WebGUI::SQL->read("select b.name, b.label, b.isMailField, a.value from DataForm_entryData a left join DataForm_field b + on a.name=b.name where a.DataForm_entryId=".$record->{DataForm_entryId}." + order by b.sequenceNumber"); + while (my $data = $b->hashRef) { + push(@dataLoop,{ + "record.data.name"=>$data->{name}, + "record.data.label"=>$data->{label}, + "record.data.value"=>$data->{value}, + "record.data.isMailField"=>$data->{isMailField} + }); + } + $b->finish; + push(@recordLoop,{ + "record.ipAddress"=>$record->{ipAddress}, + "record.edit.url"=>WebGUI::URL::page("func=view&entryId=".$record->{DataForm_entryId}."&wid=".$self->get("wobjectId")), + "record.username"=>$record->{username}, + "record.userId"=>$record->{userId}, + "record.submissionDate.epoch"=>$record->{submissionDate}, + "record.submissionDate.human"=>WebGUI::DateTime::epochToHuman($record->{submissionDate}), + "record.entryId"=>$record->{DataForm_entryId}, + "record.data_loop"=>\@dataLoop + }); + } + $a->finish; + $var->{record_loop} = \@recordLoop; + return $var; +} + +#------------------------------------------------------------------- +sub getRecordTemplateVars { my $self = shift; my $var = shift; $var->{error_loop} = [] unless (exists $var->{error_loop}); $var->{canEdit} = (WebGUI::Privilege::canEditPage()); + $var->{"entryList.url"} = WebGUI::URL::page('func=view&entryId=list&wid='.$self->get("wobjectId")); + $var->{"entryList.label"} = WebGUI::International::get(86,$self->get("namespace")); $var->{"export.tab.url"} = WebGUI::URL::page('func=exportTab&wid='.$self->get("wobjectId")); $var->{"export.tab.label"} = WebGUI::International::get(84,$self->get("namespace")); $var->{"back.url"} = WebGUI::URL::page(); @@ -138,22 +193,23 @@ sub getTemplateVars { tie %data, 'Tie::CPHash'; my $sth = WebGUI::SQL->read("$select from DataForm_field as a $join $where order by a.sequenceNumber"); while (%data = $sth->hash) { - my $formValue = $session{form}{WebGUI::URL::urlize($data{name})}; + my $formValue = $session{form}{$data{name}}; if (defined $formValue) { $data{value} = $formValue; } elsif (not exists $data{value}) { $data{value} = $data{defaultValue}; } + my $hidden = (($data{status} eq "hidden" || ($data{isMailField} && !$self->get("mailData"))) && !$session{var}{adminOn}); push(@fields,{ "field.form" => _createField(\%data), "field.name" => $data{name}, "field.value" => $data{value}, "field.label" => $data{label}, "field.isMailField" => $data{isMailField}, - "field.isRequired" => ($data{status} eq "required"), - "field.isHidden" => ($data{status} eq "hidden" && !$session{var}{adminOn}), - "field.isDisplayed" => ($data{status} eq "displayed"), - "field.isEditable" => ($data{status} eq "editable"), + "field.isHidden" => $hidden, + "field.isDisplayed" => ($data{status} eq "displayed" && !$hidden), + "field.isEditable" => ($data{status} eq "editable" && !$hidden), + "field.isRequired" => ($data{status} eq "required" && !$hidden), "field.subtext" => $data{subtext}, "field.controls" => $self->_fieldAdminIcons($data{DataForm_fieldId},$data{isMailField}) }); @@ -185,6 +241,9 @@ sub new { acknowlegementTemplateId=>{ defaultValue=>3, }, + listTemplateId=>{ + defaultValue=>1, + }, mailData=>{ defaultValue=>0 } @@ -281,6 +340,13 @@ sub www_edit { -label=>WebGUI::International::get(81,$_[0]->get("namespace")), -afterEdit=>'func=edit&wid='.$_[0]->get("wobjectId") ); + $layout->template( + -name=>"listTemplateId", + -value=>$_[0]->getValue("listTemplateId"), + -namespace=>$_[0]->get("namespace")."/List", + -label=>WebGUI::International::get(87,$_[0]->get("namespace")), + -afterEdit=>'func=edit&wid='.$_[0]->get("wobjectId") + ); my $properties = WebGUI::HTMLForm->new; $properties->HTMLArea( -name=>"acknowledgement", @@ -461,7 +527,7 @@ sub www_editFieldSave { $_[0]->setCollateral("DataForm_field","DataForm_fieldId",{ DataForm_fieldId=>$session{form}{fid}, width=>$session{form}{width}, - name=>$session{form}{name}, + name=>WebGUI::URL::urlize($session{form}{name}), label=>$session{form}{label}, status=>$session{form}{status}, type=>$session{form}{type}, @@ -481,10 +547,23 @@ sub www_editFieldSave { sub www_exportTab { return WebGUI::Privilege::insufficient() unless (WebGUI::Privilege::canEditPage()); $session{header}{filename} = WebGUI::URL::urlize($_[0]->get("title")).".tab"; - $session{header}{mimetype} = "text/tab"; - return WebGUI::SQL->quickTab("select a.label, a.name, b.value, c.ipAddress, c.username, c.submissionDate, c.DataForm_entryId - from DataForm_field a left join DataForm_entryData b on a.name=b.name left join DataForm_entry c on - b.DataForm_entryId=c.DataForm_entryId where c.wobjectId=".$_[0]->get("wobjectId")." order by c.DataForm_entryId, a.sequenceNumber"); + $session{header}{mimetype} = "text/plain"; + my @fields = WebGUI::SQL->buildArray("select name from DataForm_field where wobjectId=".$_[0]->get("wobjectId")." order by sequenceNumber"); + my $select = "select a.DataForm_entryId as entryId, a.ipAddress, a.username, a.userId, a.submissionDate"; + my $from = " from DataForm_entry a"; + my $join; + my $where = " where a.wobjectId=".$_[0]->get("wobjectId"); + my $orderBy = " order by a.DataForm_entryId"; + my $columnCounter = "b"; + foreach my $field (@fields) { + my $extension = ""; + $extension = "mail_" if (isIn($field, qw(to from cc bcc subject))); + $select .= ", ".$columnCounter.".value as ".$extension.$field; + $join .= " left join DataForm_entryData ".$columnCounter." on a.DataForm_entryId=".$columnCounter.".DataForm_entryId and " + .$columnCounter.".name=".quote($field); + $columnCounter++; + } + return WebGUI::SQL->quickTab($select.$from.$join.$where.$orderBy); } #------------------------------------------------------------------- @@ -517,7 +596,7 @@ sub www_process { my $sth = WebGUI::SQL->read("select DataForm_fieldId,name,status,type,defaultValue,isMailField from DataForm_field where wobjectId=".$_[0]->get("wobjectId")." order by sequenceNumber"); while (%row = $sth->hash) { - my $value = WebGUI::FormProcessor::process(WebGUI::URL::urlize($row{name}),$row{type},$row{defaultValue}); + my $value = WebGUI::FormProcessor::process($row{name},$row{type},$row{defaultValue}); if ($row{status} eq "required" || $row{status} eq "editable") { $value = WebGUI::Macro::filter($value); } @@ -542,13 +621,13 @@ sub www_process { } $sth->finish; $var->{error_loop} = \@errors; - $var = $_[0]->getTemplateVars($var); + $var = $_[0]->getRecordTemplateVars($var); if ($hadErrors && !$updating) { WebGUI::SQL->write("delete from DataForm_entryData where DataForm_entryId=".$entryId); $_[0]->deleteCollateral("DataForm_entry","DataForm_entryId",$entryId); $_[0]->www_view($var); } else { - $_[0]->sendEmail($var) unless ($updating); + $_[0]->sendEmail($var) if ($_[0]->get("mailData") && !$updating); return $_[0]->processTemplate($_[0]->get("acknowlegementTemplateId"),$var); } } @@ -557,7 +636,10 @@ sub www_process { sub www_view { my $var; $var->{entryId} = $session{form}{entryId}; - $var = $_[1] || $_[0]->getTemplateVars($var); + if ($var->{entryId} eq "list" && WebGUI::Privilege::canEditPage()) { + return $_[0]->processTemplate($_[0]->get("listTemplateId"),$_[0]->getListTemplateVars,"DataForm/List"); + } + $var = $_[1] || $_[0]->getRecordTemplateVars($var); return $_[0]->processTemplate($_[0]->get("templateId"),$var); }