Changeset 490 for Dev/trunk/src/client/qed-client/pages
- Timestamp:
- 03/08/14 22:51:23 (11 years ago)
- Location:
- Dev/trunk/src/client/qed-client/pages
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
Dev/trunk/src/client/qed-client/pages/index.js
r443 r490 1 1 define([ 2 'dojo/_base/declare', 3 '../app/Router', 4 '../app/Page', 5 'dojo/text!./templates/index.html' 6 ],function(declare,Router,Page,template){ 2 "../app/Page", 3 "../app/Router", 4 "../model/classes/questions", 5 "../model/classes/surveys", 6 "dojo/_base/declare", 7 "dojo/text!./templates/index.html" 8 ], function(Page, Router, questions, surveys, declare, template) { 7 9 return declare([Page],{ 8 10 templateString: template, … … 11 13 if ( this._started ) { return; } 12 14 this.inherited(arguments); 13 this.btnContentCreate.on("click",function(){ Router.go("/sessions"); }); 14 this.btnContentFacilitate.on("click",function(){ Router.go("/run"); }); 15 this.btnSurveys.on("click",function(){ Router.go("/surveys"); }); 16 this.btnQuestions.on("click",function(){ Router.go("/questions"); }); 17 this.btnApplications.on("click",function(){ Router.go("/applications"); }); 18 this.btnDashboards.on("click",function(){ Router.go("/dashboards"); }); 19 this.btnResults.on("click",function(){ Router.go("/results"); }); 15 //this.btnContentCreate.on("click",function(){ Router.go("/sessions"); }); 16 //this.btnContentFacilitate.on("click",function(){ Router.go("/run"); }); 17 this.btnSurveys.on("click",function(){ 18 Router.go(surveys.getCollectionPath()); 19 }); 20 this.btnQuestions.on("click",function(){ 21 Router.go(questions.getCollectionPath()); 22 }); 23 //this.btnApplications.on("click",function(){Router.go("/applications");}); 24 //this.btnDashboards.on("click",function(){ Router.go("/dashboards"); }); 25 //this.btnResults.on("click",function(){ Router.go("/results"); }); 20 26 } 21 27 }); -
Dev/trunk/src/client/qed-client/pages/question.js
r487 r490 1 1 define([ 2 "../app/Content",3 "../app/Page",4 2 "../app/Router", 5 3 "../model/classes/questions", 6 "../model/widgets/QuestionEditorPreview", 7 "../model/widgets/QuestionEditorToolkit", 8 "../widgets/_ComplexValueMixin", 4 "./_ObjectPage", 5 "dojo/Deferred", 9 6 "dojo/_base/declare", 10 7 "dojo/_base/event", 11 8 "dojo/_base/lang", 12 " dojo/when",9 "require", 13 10 "dojo/text!./templates/question.html" 14 ], function(Content, Page, Router, questions, QuestionEditorPreview, QuestionEditorToolkit, _ComplexValueMixin, declare, event, lang, when, template) { 15 return declare([Page,_ComplexValueMixin], { 11 ], function(Router, questions, _ObjectPage, Deferred, declare, event, lang, require, template) { 12 return declare([_ObjectPage], { 13 contextRequire: require, 16 14 templateString: template, 17 15 _toolkit: null, 18 16 _preview: null, 19 value: null, 20 21 buildRendering: function() { 22 this.inherited(arguments); 23 24 this._toolkit = new QuestionEditorToolkit({ 25 },this.QuestionEditorToolkitNode); 26 this._toolkit.on('submit',lang.hitch(this,"_onSave")); 27 this._toolkit.startup(); 28 29 this._preview = new QuestionEditorPreview({ 30 name: 'content', 31 delay: 5, 32 region: 'center' 33 }); 34 this._preview.startup(); 35 this.addChild(this._preview); 36 }, 17 classStore: questions, 37 18 startup: function() { 38 19 if ( this._started ) { return; } 39 20 this.inherited(arguments); 40 if ( !this.questionId ) { 41 throw new Error("Error: no reference to object set!"); 21 this.propertiesForm.on('change',lang.hitch(this,'_handlePropertiesChange')); 22 this.contentList.on('change',lang.hitch(this,'_handleContentChange')); 23 this._load(); 24 }, 25 _refresh: function() { 26 this.titleNode.innerHTML = this.object.title || ""; 27 this.propertiesForm.set('value',this.object); 28 this.contentList.set('value',this.object.content); 29 }, 30 _handlePropertiesChange: function() { 31 if ( this.propertiesForm.validate() ) { 32 lang.mixin(this.object,this.propertiesForm.get('value')); 42 33 } 43 if (this.questionId === "new") { 44 this.set('value', questions.create()); 34 this.markDirty(); 35 }, 36 _handleContentChange: function() { 37 if ( this.contentList.validate() ) { 38 this.object.content = this.contentList.get('value'); 39 } 40 this.markDirty(); 41 }, 42 _save: function() { 43 if ( this.propertiesForm.validate() && this.contentList.validate() ) { 44 lang.mixin(this.object,this.propertiesForm.get('value')); 45 this.object.content = this.contentList.get('value'); 46 return this.inherited(arguments); 45 47 } else { 46 when(questions.load(this.questionId)) 47 .then(lang.hitch(this, function(value) { 48 this.set('value', value); 49 })); 48 return new Deferred().reject(); 50 49 } 51 50 }, 52 _setValueAttr: function(value) {53 this.value = value;54 this.inherited(arguments);55 this.titleNode.innerHTML = value.title || "";56 },57 _getValueAttr: function() {58 var value = this.inherited(arguments);59 lang.mixin(this.value, value);60 return this.value;61 },62 51 _onSave: function(evt) { 63 if ( this.validate() ) { 64 questions.save(this.get('value')) 65 .then(function() { 66 Router.go('/questions'); 67 },function(err){ 68 Content.notify(err,'error'); 69 }); 70 } 52 this._save(); 71 53 if ( evt ) { event.stop( evt ); } 72 54 return false; 73 55 }, 74 _onDiscard: function() { 75 Router.go('/questions'); 76 return true; 56 _onSaveAndClose: function(evt) { 57 this._save() 58 .then(function(){ 59 Router.go(questions.getCollectionPath()); 60 }); 61 if ( evt ) { event.stop( evt ); } 62 return false; 63 }, 64 _onDiscard: function(evt) { 65 this.markClean(); 66 Router.go(questions.getCollectionPath()); 67 if ( evt ) { event.stop( evt ); } 68 return false; 69 }, 70 _ignore: function(evt) { 71 if ( evt ) { event.stop( evt ); } 72 return false; 77 73 } 78 74 }); -
Dev/trunk/src/client/qed-client/pages/questions.js
r487 r490 1 1 define([ 2 "../app/Content",3 2 "../app/Page", 4 3 "../app/Router", … … 10 9 "dojo/_base/lang", 11 10 "dojo/text!./templates/questions.html" 12 ], function( Content,Page, Router, questions, TabbedQuestionBrowser, Deferred, declare, event, lang, template) {11 ], function(Page, Router, questions, TabbedQuestionBrowser, Deferred, declare, event, lang, template) { 13 12 return declare([Page],{ 14 13 templateString: template, … … 41 40 }, 42 41 onNewQuestion: function() { 43 Router.go( "/question/new");42 Router.go(questions.getObjectPath('new')); 44 43 }, 45 44 onDeleteQuestion: function(question) { 46 45 questions.remove(question) 47 .then( function(){48 Content.notify("Question deleted.");49 } ,function(err){50 Content.notify(err,'error');51 }) ;46 .then(lang.hitch(this,function(){ 47 this.notify("Question deleted."); 48 }),lang.hitch(this,function(err){ 49 this.notify(err.error,'error'); 50 })); 52 51 }, 53 52 onEditQuestion: function(question) { 54 Router.go( "/question/"+question._id);53 Router.go(questions.getObjectPath(question)); 55 54 }, 56 55 onPublishQuestion: function(question) { 57 56 question.publicationDate = new Date(); 58 57 questions.save(question) 59 .then( function(){60 Content.notify("Question published.");61 } ,function(err){62 Content.notify(err,'error');63 }) ;58 .then(lang.hitch(this,function(){ 59 this.notify("Question published."); 60 }),lang.hitch(this,function(err){ 61 this.notify(err.error,'error'); 62 })); 64 63 } 65 64 }); -
Dev/trunk/src/client/qed-client/pages/response.js
r487 r490 1 1 define([ 2 "../app/Content",3 2 "../app/Page", 4 "../lib/async",5 3 "../model/classes/responses", 6 4 "dojo/_base/declare", … … 13 11 "require", 14 12 "dojo/text!./templates/response.html" 15 ], function( Content, Page, async, responses, declare, event, json, lang, all, request, when, require, template) {13 ], function(Page, responses, declare, event, json, lang, all, request, when, require, template) { 16 14 return declare([Page],{ 17 15 contextRequire: require, … … 60 58 .then(lang.hitch(this,function(response){ 61 59 this.response = response; 62 Content.notify("Your response is saved.");63 }), function(err){64 Content.notify(err,'error');65 }) ;60 this.notify("Your response is saved."); 61 }), lang.hitch(this,function(err){ 62 this.notify(err.error,'error'); 63 })); 66 64 }, 67 65 _onSubmit: function(e) { … … 89 87 .then(lang.hitch(this,function(res){ 90 88 this._showInfo("<div>Your response has been deleted, no answers have been saved.</div>"); 91 Content.notify("Your response is deleted.");92 }), function(err){93 Content.notify(err,'error');94 }) ;89 this.notify("Your response is deleted."); 90 }), lang.hitch(this,function(err){ 91 this.notify(err.error,'error'); 92 })); 95 93 if ( e ) { event.stop(e); } 96 94 return false; -
Dev/trunk/src/client/qed-client/pages/survey.js
r487 r490 1 1 define([ 2 "../app/Page",3 2 "../app/Router", 4 3 "../model/classes/surveys", 5 4 "../model/widgets/QuestionListView", 6 5 "../model/widgets/TabbedQuestionBrowser", 6 "./_ObjectPage", 7 7 "dojo/_base/array", 8 8 "dojo/_base/declare", … … 12 12 "require", 13 13 "dojo/text!./templates/survey.html" 14 ], function( Page, Router, surveys, QuestionListView, TabbedQuestionBrowser, array, declare, event, lang, when, require, template) {15 return declare([ Page],{14 ], function(Router, surveys, QuestionListView, TabbedQuestionBrowser, _ObjectPage, array, declare, event, lang, when, require, template) { 15 return declare([_ObjectPage],{ 16 16 contextRequire: require, 17 17 templateString: template, 18 survey: null,18 classStore: surveys, 19 19 questionList: null, 20 20 startup: function() { 21 21 if ( this._started ) { return; } 22 22 this.inherited(arguments); 23 if ( this.surveyId ) { 24 this._setupQuestionBrowser(); 25 this._setupListView(); 26 this._loadSurvey(); 27 } else { 28 throw "No valid uid or survey passed!"; 29 } 23 this._setupQuestionBrowser(); 24 this._setupListView(); 25 this._load(); 30 26 }, 31 27 _setupQuestionBrowser: function() { … … 60 56 this.questionList.startup(); 61 57 }, 62 _loadSurvey: function() { 63 if ( this.surveyId === "new" ) { 64 this.survey = surveys.create(); 65 this.refresh(); 66 } else { 67 when(surveys.load(this.surveyId)) 68 .then(lang.hitch(this,function(survey){ 69 this.survey = survey; 70 this.questionList.set('value', 71 this.survey.questions); 72 this.refresh(); 73 })); 74 } 58 _refresh: function() { 59 this.titleNode.innerHTML = this.object.title || "(set title in properties)"; 60 this.propertiesDialog.set('value',this.object); 61 this.questionList.set('value', 62 this.object.questions); 63 }, 64 _save: function() { 65 this.object.questions = this.questionList.get('value'); 66 return this.inherited(arguments); 75 67 }, 76 68 _includeQuestion: function(question) { 77 69 this.questionList.appendItem(question); 78 70 }, 79 refresh: function() {80 this.titleNode.innerHTML = this.survey.title || "(set title in properties)";81 this.propertiesDialog.set('value',this.survey);82 },83 71 _onShowProperties: function(evt) { 84 72 this.propertiesDialog.show(); 73 if ( evt ) { event.stop(evt); } 74 return false; 85 75 }, 86 76 _onPropertiesOk: function(evt) { 87 77 this.propertiesDialog.hide(); 88 lang.mixin(this.survey, this.propertiesDialog.get('value')); 89 this.refresh(); 90 event.stop(evt); 78 lang.mixin(this.object, this.propertiesDialog.get('value')); 79 this.markDirty(); 80 this._refresh(); 81 if ( evt ) { event.stop(evt); } 91 82 return false; 92 83 }, 93 84 _onPropertiesCancel: function(evt) { 94 85 this.propertiesDialog.hide(); 95 this.propertiesDialog. reset('value',this.survey);96 event.stop(evt);86 this.propertiesDialog.set('value',this.object); 87 if ( evt ) { event.stop(evt); } 97 88 return false; 98 89 }, 99 90 _onSave: function(evt) { 100 this.survey.questions = this.questionList.get('value'); 101 surveys.save(this.survey) 91 this._save(); 92 if ( evt ) { event.stop(evt); } 93 return false; 94 }, 95 _onSaveAndClose: function(evt) { 96 this._save() 102 97 .then(function() { 103 Router.go( '/surveys');98 Router.go(surveys.getCollectionPath()); 104 99 }); 105 100 event.stop(evt); 106 101 return false; 107 102 }, 108 _onDiscard: function(evt) { 109 Router.go('/surveys'); 103 _onDiscardAndClose: function(evt) { 104 this.markClean(); 105 Router.go(surveys.getCollectionPath()); 110 106 }, 111 107 _onShowPreview: function() { 112 Router.go( '/previewSurvey/'+this.survey._id,{108 Router.go(surveys.getPreviewPath(this.object),{ 113 109 preview: true 114 110 }); -
Dev/trunk/src/client/qed-client/pages/surveyRun.js
r487 r490 1 1 define([ 2 2 "../app/Content", 3 "../app/Pa ge",3 "../app/Path", 4 4 "../app/Router", 5 5 "../lib/func", 6 6 "../model/classes/responses", 7 7 "../model/classes/surveyRuns", 8 "../model/classes/surveys", 8 9 "../widgets/LineWithActionsWidget", 10 "./_ObjectPage", 11 "dojo/Deferred", 9 12 "dojo/_base/array", 10 13 "dojo/_base/declare", … … 14 17 "require", 15 18 "dojo/text!./templates/surveyRun.html" 16 ], function(Content, Pa ge, Router, func, responses, surveyRuns, LineWithActionsWidget, array, declare, event, lang, when, require, template) {17 return declare([ Page],{19 ], function(Content, Path, Router, func, responses, surveyRuns, surveys, LineWithActionsWidget, _ObjectPage, Deferred, array, declare, event, lang, when, require, template) { 20 return declare([_ObjectPage],{ 18 21 contextRequire: require, 19 22 templateString: template, 20 surveyRun: null,23 classStore: surveyRuns, 21 24 startup: function() { 22 25 if ( this._started ) { return; } 23 26 this.inherited(arguments); 24 this.surveyRunWidget.on("blur",lang.hitch(this,'_onPropChange')); 25 if ( this.surveyRunId ) { 26 this._loadSurveyRun(); 27 this.surveyRunWidget.on("change",lang.hitch(this,'_onPropChange')); 28 this._load(); 29 }, 30 _refresh: function() { 31 this.titleNode.innerHTML = this.object.title || ""; 32 this.surveySummaryWidget.set('value',this.object.survey); 33 this.surveyRunWidget.set('value',this.object); 34 this._refreshURL(); 35 this._loadResponses(); 36 }, 37 _refreshURL: function() { 38 if ( this.object.mode === "open" ) { 39 this.runURLNode.innerHTML = 40 this._link(this._buildGeneralURL(this.object)); 27 41 } else { 28 throw "No valid uid or survey passed!"; 42 this.runURLNode.innerHTML = 43 "No general URL. Add individual respondents below."; 29 44 } 30 45 }, 31 _loadSurveyRun: function() {32 when(surveyRuns.load(this.surveyRunId))33 .then(lang.hitch(this,function(surveyRun){34 this.surveyRun = surveyRun;35 this.refreshSurveyRun();36 this._loadResponses();37 }));38 },39 refreshSurveyRun: function() {40 this.titleNode.innerHTML = this.surveyRun.title || "";41 this.surveySummaryWidget.set('value',this.surveyRun.survey);42 this.surveyRunWidget.set('value',this.surveyRun);43 this._onPropChange();44 },45 46 _loadResponses: function() { 46 responses.query({surveyRunId:surveyRuns.getId(this. surveyRun)})47 responses.query({surveyRunId:surveyRuns.getId(this.object)}) 47 48 .then(lang.hitch(this,function(allResponses){ 48 49 array.forEach(allResponses, function(response){ … … 73 74 }, 74 75 _onPropChange: function(e) { 75 var surveyRun = this.surveyRunWidget.get('value'); 76 if ( surveyRun.mode === "open" ) { 77 this.runURLNode.innerHTML = 78 this._link(this._buildGeneralURL(this.surveyRun)); 79 } else { 80 this.runURLNode.innerHTML = 81 "No general URL. Add individual respondents below."; 76 if ( this.surveyRunWidget.validate() ) { 77 lang.mixin(this.object,this.surveyRunWidget.get('value')); 78 this._refreshURL(); 82 79 } 80 this.markDirty(); 83 81 }, 84 82 _buildGeneralURL: function(surveyRun) { 85 return 'response.html# !/surveyRuns/'+surveyRuns.getId(surveyRun)+'!secret='+surveyRun.secret;83 return 'response.html#'+Path.format(surveyRuns.getObjectPath(surveyRun),{secret:surveyRun.secret}); 86 84 }, 87 85 _buildResponseURL: function(response) { 88 return 'response.html# !/responses/'+responses.getId(response)+'!secret='+response.secret;86 return 'response.html#'+Path.format(responses.getObjectPath(response),{secret:response.secret}); 89 87 }, 90 88 _link: function(url,label) { 91 89 return '<a target="_blank" href="'+url+'">'+(label || url)+'</a>'; 92 90 }, 91 _save: function() { 92 if ( this.surveyRunWidget.validate() ) { 93 lang.mixin(this.object,this.surveyRunWidget.get('value')); 94 return this.inherited(arguments); 95 } else { 96 return new Deferred.reject(); 97 } 98 }, 93 99 _onSave: function(evt) { 94 if ( this.surveyRunWidget.validate() ) { 95 lang.mixin(this.surveyRun,this.surveyRunWidget.get('value')); 96 97 surveyRuns.save(this.surveyRun) 98 .then(function() { 99 Router.go('/surveys'); 100 },function(err){ 101 Content.notify(err); 102 }); 103 } 100 this._save(); 101 if ( evt ) { event.stop(evt); } 102 return false; 103 }, 104 _onSaveAndClose: function(evt) { 105 this._save() 106 .then(function() { 107 Router.go(surveys.getCollectionPath()); 108 }); 104 109 if ( evt ) { event.stop(evt); } 105 110 return false; 106 111 }, 107 112 _onDiscard: function(evt) { 108 Router.go('/surveys'); 113 this.markClean(); 114 Router.go(surveys.getCollectionPath()); 109 115 if ( evt ) { event.stop(evt); } 110 116 return false; -
Dev/trunk/src/client/qed-client/pages/surveys.js
r487 r490 1 1 define([ 2 "../app/Content",3 2 "../app/Page", 4 3 "../app/Router", 4 "../model/classes/surveyRuns", 5 5 "../model/classes/surveys", 6 "../model/classes/surveyRuns",7 6 "../widgets/LineWithActionsWidget", 8 7 "dojo/_base/array", … … 11 10 "dojo/when", 12 11 "dojo/text!./templates/surveys.html" 13 ], function( Content, Page, Router, surveys, surveyRuns, LineWithActionsWidget, array, declare, lang, when, template) {12 ], function(Page, Router, surveyRuns, surveys, LineWithActionsWidget, array, declare, lang, when, template) { 14 13 return declare([Page],{ 15 14 templateString: template, … … 20 19 }, 21 20 _onNewSurvey: function(){ 22 Router.go( '/survey/new');21 Router.go(surveys.getObjectPath('new')); 23 22 }, 24 23 _onPublishSurvey:function(survey){ … … 29 28 self.refreshDrafts(); 30 29 self.refreshPublished(); 31 }, function(err){32 Content.notify(err,'error');33 }) ;30 },lang.hitch(this,function(err){ 31 this.notify(err.error,'error'); 32 })); 34 33 }, 35 34 _onDeleteSurvey:function(survey){ … … 38 37 .then(function(){ 39 38 self.refreshDrafts(); 40 }, function(err){41 Content.notify(err,'error');42 }) ;39 },lang.hitch(this,function(err){ 40 this.notify(err.error,'error'); 41 })); 43 42 }, 44 43 _onEditSurvey:function(survey){ 45 Router.go( '/survey/'+survey._id);44 Router.go(surveys.getObjectPath(survey)); 46 45 }, 47 46 _onPreviewSurvey:function(survey){ 48 Router.go( '/previewSurvey/'+survey._id);47 Router.go(surveys.getPreviewPath(survey)); 49 48 }, 50 49 _onRunSurvey:function(survey){ … … 54 53 .then(lang.hitch(this,function(surveyRun){ 55 54 this._onRunDetails(surveyRun); 56 }), function(err){57 Content.notify(err);58 }) ;55 }),lang.hitch(this,function(err){ 56 this.notify(err.error,'error'); 57 })); 59 58 }, 60 59 _onRunDetails: function(surveyRun) { 61 Router.go( '/surveyRun/'+surveyRun._id);60 Router.go(surveyRuns.getObjectPath(surveyRun)); 62 61 }, 63 62 refresh: function() { -
Dev/trunk/src/client/qed-client/pages/templates/question.html
r466 r490 1 < formclass="orange">1 <div class="orange"> 2 2 <div data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'top'"> 3 3 <h2> … … 6 6 </h2> 7 7 </div> 8 <div data-dojo-type="dijit/layout/BorderContainer" data-dojo-props="region:'left', design:'headline'" style="width: 300px;"> 9 <div data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'center'"> 10 <div data-dojo-attach-point="QuestionEditorToolkitNode"></div> 8 <form data-dojo-type="dijit/form/Form" 9 data-dojo-props="region:'left'" 10 data-dojo-attach-point="propertiesForm" 11 data-dojo-attach-event="onSubmit:_ignore"> 12 <div data-dojo-type="dijit/layout/BorderContainer" data-dojo-props="design:'headline'" style="width: 300px;"> 13 <div data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'center'"> 14 <div data-dojo-type="../model/widgets/QuestionEditorToolkit" 15 data-dojo-attach-point="QuestionEditorToolkitNode"></div> 16 </div> 17 <div data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'top'"> 18 <button data-dojo-type="dijit/form/Button" 19 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'" 20 data-dojo-attach-event="onClick:_onSave"> 21 Save</button> 22 <button data-dojo-type="dijit/form/Button" 23 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'" 24 data-dojo-attach-event="onClick:_onSaveAndClose"> 25 Save & Close</button> 26 <button data-dojo-type="dijit/form/Button" 27 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconCancel'" 28 data-dojo-attach-event="onClick:_onDiscard"> 29 Discard & Close</button> 30 </div> 11 31 </div> 12 <div data-dojo-type="dijit/layout/ContentPane" data-dojo-props="region:'top'"> 13 <button data-dojo-type="dijit/form/Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconCancel'" data-dojo-attach-event="onClick:_onDiscard">Discard</button> 14 <button data-dojo-type="dijit/form/Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'" data-dojo-attach-event="onClick:_onSave">Save and exit</button> 15 </div> 16 </div> 17 </form> 32 </form> 33 <div data-dojo-type="../model/widgets/QuestionEditorPreview" 34 data-dojo-attach-point="contentList" 35 data-dojo-props="name:'content',delay:5,region:'center'"></div> 36 </div> -
Dev/trunk/src/client/qed-client/pages/templates/survey.html
r457 r490 24 24 data-dojo-attach-event="onClick:_onSave" 25 25 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'"> 26 Save Changes</button>26 Save</button> 27 27 <button data-dojo-type="dijit/form/Button" 28 data-dojo-attach-event="onClick:_onDiscard" 28 data-dojo-attach-event="onClick:_onSaveAndClose" 29 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'"> 30 Save & Close</button> 31 <button data-dojo-type="dijit/form/Button" 32 data-dojo-attach-event="onClick:_onDiscardAndClose" 29 33 data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconCancel'"> 30 Discard changes</button>34 Discard & Close</button> 31 35 <button data-dojo-type="dijit/form/Button" 32 36 data-dojo-attach-event="onClick:_onShowPreview" -
Dev/trunk/src/client/qed-client/pages/templates/surveyRun.html
r467 r490 45 45 <div> 46 46 <div class="qedLabel">Export results</div> 47 <a target="_blank" href="/api/surveyRuns/${ surveyRunId}/responses.csv" class="qedField">To CSV</a>47 <a target="_blank" href="/api/surveyRuns/${objectId}/responses.csv" class="qedField">To CSV</a> 48 48 </div> 49 49 </fieldset> … … 55 55 class="blue" 56 56 data-dojo-props="baseClass: 'rftBlockButton', iconClass: 'rftIcon rftIconSave'" 57 data-dojo-attach-event="onClick:_onSave">Save & Close</button> 57 data-dojo-attach-event="onClick:_onSave">Save</button> 58 <button data-dojo-type="dijit/form/Button" 59 class="blue" 60 data-dojo-props="baseClass: 'rftBlockButton', iconClass: 'rftIcon rftIconSave'" 61 data-dojo-attach-event="onClick:_onSaveAndClose">Save & Close</button> 58 62 <button data-dojo-type="dijit/form/Button" 59 63 class="blue"
Note: See TracChangeset
for help on using the changeset viewer.