47 return parent::getTitle() .
' - ' . Zurmo::t(
'ReportsModule',
'Summation');
66 $gridView->setView($moduleForReportWizardView, 0, 0);
67 $gridView->setView($filtersForReportWizardView, 1, 0);
68 $gridView->setView($groupBysForReportWizardView, 2, 0);
69 $gridView->setView($displayAttributesForReportWizardView, 3, 0);
70 $gridView->setView($drillDownDisplayAttributesForReportWizardView, 4, 0);
71 $gridView->setView($orderBysForReportWizardView, 5, 0);
72 $gridView->setView($chartForReportWizardView, 6, 0);
73 $gridView->setView($generalDataForReportWizardView, 7, 0);
74 return $gridView->render();
83 assert(
'is_string($formName)');
84 return "linkId = $('#" . $formName .
"').find('.attachLoadingTarget').attr('id');
87 $('#" . static::getValidationScenarioInputId() .
"').val('" .
88 ReportWizardForm::FILTERS_VALIDATION_SCENARIO .
"');
89 $('#ModuleForReportWizardView').hide();
90 " . static::renderTreeViewAjaxScriptContent($formName,
'FiltersForReportWizardView', $this->model->type) .
"
91 $('#FiltersForReportWizardView').show();
92 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('25%');
93 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
97 $('#" . static::getValidationScenarioInputId() .
"').val('" .
98 ReportWizardForm::GROUP_BYS_VALIDATION_SCENARIO .
"');
99 $('#FiltersForReportWizardView').hide();
100 " . static::renderTreeViewAjaxScriptContent($formName,
'GroupBysForReportWizardView', $this->model->type) .
"
101 $('#GroupBysForReportWizardView').show();
102 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('37.5%');
103 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
107 $('#" . static::getValidationScenarioInputId() .
"').val('" .
108 ReportWizardForm::DISPLAY_ATTRIBUTES_VALIDATION_SCENARIO .
"');
109 $('#GroupBysForReportWizardView').hide();
110 " . static::renderTreeViewAjaxScriptContent($formName,
'DisplayAttributesForReportWizardView', $this->model->type) .
"
111 $('#DisplayAttributesForReportWizardView').show();
112 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('50%');
113 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
117 $('#" . static::getValidationScenarioInputId() .
"').val('" .
118 ReportWizardForm::DRILL_DOWN_DISPLAY_ATTRIBUTES_VALIDATION_SCENARIO .
"');
119 $('#DisplayAttributesForReportWizardView').hide();
120 " . static::renderTreeViewAjaxScriptContent($formName,
'DrillDownDisplayAttributesForReportWizardView', $this->model->type) .
"
121 $('#DrillDownDisplayAttributesForReportWizardView').show();
122 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('62.5%');
123 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
127 $('#" . static::getValidationScenarioInputId() .
"').val('" .
128 ReportWizardForm::ORDER_BYS_VALIDATION_SCENARIO .
"');
129 $('#DrillDownDisplayAttributesForReportWizardView').hide();
130 " . static::renderTreeViewAjaxScriptContent($formName,
'OrderBysForReportWizardView', $this->model->type) .
"
131 $('#OrderBysForReportWizardView').show();
132 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('75%');
133 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
135 if (linkId == '" . OrderBysForReportWizardView::getNextPageLinkId() .
"')
137 $('#" . static::getValidationScenarioInputId() .
"').val('" .
138 ReportWizardForm::CHART_VALIDATION_SCENARIO .
"');
139 $('#OrderBysForReportWizardView').hide();
140 " . static::renderLoadChartSeriesAndRangesScriptContent($formName) .
"
141 $('#ChartForReportWizardView').show();
142 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('87.5%');
143 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
147 $('#" . static::getValidationScenarioInputId() .
"').val('" .
148 ReportWizardForm::GENERAL_DATA_VALIDATION_SCENARIO .
"');
149 $('#ChartForReportWizardView').hide();
150 $('#GeneralDataForReportWizardView').show();
151 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('100%');
152 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').next().addClass('current-step');
160 $('#" . $formName .
"').find('.attachLoadingTarget').removeClass('loading');
161 $('#" . $formName .
"').find('.attachLoadingTarget').removeClass('loading-ajax-submit');
162 $('#" . $formName .
"').find('.attachLoadingTarget').removeClass('attachLoadingTarget');
167 protected function registerClickFlowScript()
169 Yii::app()->clientScript->registerScript(
'clickflow',
"
173 url = document.referrer;
174 window.location.href = url;
181 $('#" . static::getValidationScenarioInputId() .
"').val('" .
182 ReportWizardForm::MODULE_VALIDATION_SCENARIO .
"');
183 $('#" . WizardActiveForm::makeErrorsSummaryId(static::getFormId()) .
"').hide();
184 $('#ModuleForReportWizardView').show();
185 $('#FiltersForReportWizardView').hide();
186 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('12.5%');
187 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
194 $('#" . static::getValidationScenarioInputId() .
"').val('" .
195 ReportWizardForm::FILTERS_VALIDATION_SCENARIO .
"');
196 $('#FiltersForReportWizardView').show();
197 $('#GroupBysForReportWizardView').hide();
198 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('25%');
199 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
206 $('#" . static::getValidationScenarioInputId() .
"').val('" .
207 ReportWizardForm::GROUP_BYS_VALIDATION_SCENARIO .
"');
208 $('#GroupBysForReportWizardView').show();
209 $('#DisplayAttributesForReportWizardView').hide();
210 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('37.5%');
211 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
218 $('#" . static::getValidationScenarioInputId() .
"').val('" .
219 ReportWizardForm::DISPLAY_ATTRIBUTES_VALIDATION_SCENARIO .
"');
220 $('#DisplayAttributesForReportWizardView').show();
221 $('#DrillDownDisplayAttributesForReportWizardView').hide();
222 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('50%');
223 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
230 $('#" . static::getValidationScenarioInputId() .
"').val('" .
231 ReportWizardForm::DRILL_DOWN_DISPLAY_ATTRIBUTES_VALIDATION_SCENARIO .
"');
232 $('#DrillDownDisplayAttributesForReportWizardView').show();
233 $('#OrderBysForReportWizardView').hide();
234 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('62.5%');
235 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
242 $('#" . static::getValidationScenarioInputId() .
"').val('" .
243 ReportWizardForm::ORDER_BYS_VALIDATION_SCENARIO .
"');
244 $('#OrderBysForReportWizardView').show();
245 $('#ChartForReportWizardView').hide();
246 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('75%');
247 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
254 $('#" . static::getValidationScenarioInputId() .
"').val('" .
255 ReportWizardForm::CHART_VALIDATION_SCENARIO .
"');
256 $('#ChartForReportWizardView').show();
257 $('#GeneralDataForReportWizardView').hide();
258 $('.StepsAndProgressBarForWizardView').find('.progress-bar').width('87.5%');
259 $('.StepsAndProgressBarForWizardView').find('.current-step').removeClass('current-step').prev().addClass('current-step');
272 assert(
'is_string($formName)');
273 $url = Yii::app()->createUrl(static::getModuleId() .
'/' . static::getControllerId() .
'/getAvailableSeriesAndRangesForChart',
274 array_merge($_GET, array(
'type' => $this->model->type)));
278 url : '" . $url .
"',
280 data : $('#" . $formName .
"').serialize(),
282 success : function(data)
284 rebuildSelectInputFromDataAndLabels
285 ('SummationReportWizardForm_ChartForReportForm_firstSeries', data.firstSeriesDataAndLabels);
286 rebuildSelectInputFromDataAndLabels
287 ('SummationReportWizardForm_ChartForReportForm_firstRange', data.firstRangeDataAndLabels);
288 rebuildSelectInputFromDataAndLabels
289 ('SummationReportWizardForm_ChartForReportForm_secondSeries', data.secondSeriesDataAndLabels);
290 rebuildSelectInputFromDataAndLabels
291 ('SummationReportWizardForm_ChartForReportForm_secondRange', data.secondRangeDataAndLabels);
303 protected function registerScripts()
305 parent::registerScripts();
306 Yii::app()->clientScript->registerScriptFile(
307 Yii::app()->getAssetManager()->publish(
308 Yii::getPathOfAlias(
'application.core.elements.assets')) .
'/SelectInputUtils.js', CClientScript::POS_END);
309 $this->registerLinkedRemovalScript();
312 protected function registerLinkedRemovalScript()
314 Yii::app()->clientScript->registerScript(
'linkedRemovalScript',
"
315 //When a group by is removed, remove the corresponding display column and/or order by column if
317 $('#GroupBysForReportWizardView').find('.remove-dynamic-row-link').live('click', function()
319 var inputIdBeingRemoved = $(this).prev().find('input').first().val();
320 $('#DisplayAttributesForReportWizardView').find('.dynamic-row').each(function()
322 if (inputIdBeingRemoved == $(this).find('input').first().val())
324 $(this).parent().remove();
328 $('#OrderBysForReportWizardView').find('.dynamic-row').each(function()
330 if (inputIdBeingRemoved == $(this).find('input').first().val())
332 $(this).parent().remove();
341 protected function registerModuleClassNameChangeScriptExtraPart()
343 return " $('#OrderBysForReportWizardView').find('.dynamic-rows').find('ul:first').find('li').remove();
344 $('#OrderBysTreeArea').html('');
346 $('#GroupBysForReportWizardView').find('.dynamic-rows').find('ul:first').find('li').remove();
347 $('#GroupBysTreeArea').html('');
349 $('#DrillDownDisplayAttributesForReportWizardView').find('.dynamic-rows').find('ul:first').find('li').remove();
350 $('#DrillDownDisplayAttributesTreeArea').html('');
352 $('input:radio[name=\"SummationReportWizardForm[ChartForReportForm][type]\"]').filter('[value=\"\"]').attr('checked', true)
353 onChangeChartType($('.chart-selector:checked'));
static getNextPageLinkId()
static getPreviousPageLinkId()
static getNextPageLinkId()
static getZeroComponentsClassName()
renderConfigSaveAjax($formName)
renderContainingViews(WizardActiveForm $form)
static getNextPageLinkId()
static getZeroComponentsClassName()
static getPreviousPageLinkId()
renderLoadChartSeriesAndRangesScriptContent($formName)
static getPreviousPageLinkId()
static getPreviousPageLinkId()
static getNextPageLinkId()
static getNextPageLinkId()
static getPreviousPageLinkId()
static getNextPageLinkId()
static getPreviousPageLinkId()
static getPreviousPageLinkId()
static getPreviousPageLinkId()
static getNextPageLinkId()
static getZeroComponentsClassName()
getSaveAjaxString($formName, $redirectAfterSave=true, array $additionalAjaxOptions=array())