HCE Project DC service web UI  0.2
Hierarchical Cluster Engine DC service web UI
 All Classes Namespaces Files Functions Variables Pages
interface.php
Go to the documentation of this file.
1 <?php
2 /* @var $this SiteController */
3 
4 $this->pageTitle=Yii::app()->name . ' - Interface Elements';
5 $this->breadcrumbs=array(
6  'Interface Elements',
7 );
8 ?>
9 <?php
10 
11 $sample_text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.';
12 ?>
13 <div class="page-header">
14  <h1>Interface elements</h1>
15 </div>
16 
17 <div class="row-fluid">
18  <div class="span6">
19  <?php
20  $this->beginWidget('zii.widgets.CPortlet', array(
21  'title'=>"CJuiAccordion",
22  ));
23 
24  ?>
25  <?php
26  $this->widget('zii.widgets.jui.CJuiAccordion', array(
27  'panels'=>array(
28  'panel 1'=>$sample_text,
29  'panel 2'=>$sample_text,
30  'panel 3'=>$sample_text,
31  'panel 4'=>$sample_text,
32  // panel 5 contains the content rendered by a partial view
33  //'panel 5'=>$this->renderPartial('_partial',null,true),
34  ),
35  // additional javascript options for the accordion plugin
36  'options'=>array(
37  'animated'=>'bounceslide',
38  ),
39  ));
40  ?>
41  <?php $this->endWidget();?>
42  </div>
43  <div class="span6">
44 
45  <?php
46  $this->beginWidget('zii.widgets.CPortlet', array(
47  'title'=>"HTML accordion",
48  ));
49 
50  ?>
51  <div class="accordion" id="accordion2">
52  <div class="accordion-group">
53  <div class="accordion-heading">
54  <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseOne">
55  Collapsible Group Item #1
56  </a>
57  </div>
58  <div id="collapseOne" class="accordion-body collapse in">
59  <div class="accordion-inner">
60  <?php echo $sample_text;?>
61  </div>
62  </div>
63  </div>
64  <div class="accordion-group">
65  <div class="accordion-heading">
66  <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseTwo">
67  Collapsible Group Item #2
68  </a>
69  </div>
70  <div id="collapseTwo" class="accordion-body collapse">
71  <div class="accordion-inner">
72  <?php echo $sample_text;?>
73  </div>
74  </div>
75  </div>
76  <div class="accordion-group">
77  <div class="accordion-heading">
78  <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseThree">
79  Collapsible Group Item #3
80  </a>
81  </div>
82  <div id="collapseThree" class="accordion-body collapse">
83  <div class="accordion-inner">
84  <?php echo $sample_text;?>
85  </div>
86  </div>
87  </div>
88  <div class="accordion-group">
89  <div class="accordion-heading">
90  <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseFour">
91  Collapsible Group Item #4
92  </a>
93  </div>
94  <div id="collapseFour" class="accordion-body collapse">
95  <div class="accordion-inner">
96  <?php echo $sample_text;?>
97  </div>
98  </div>
99  </div>
100  </div>
101 
102 
103  <?php $this->endWidget();?>
104  </div>
105 </div>
106 
107 <div class="row-fluid">
108  <div class="span6">
109  <?php
110  $this->beginWidget('zii.widgets.CPortlet', array(
111  'title'=>"CJuiTabs",
112  ));
113 
114  ?>
115  <?php
116  $this->widget('zii.widgets.jui.CJuiTabs', array(
117  'tabs'=>array(
118  'StaticTab 1'=>$sample_text,
119  'StaticTab 2'=>$sample_text,
120  'StaticTab 3'=>array('content'=>$sample_text, 'id'=>'tab3'),
121  ),
122  // additional javascript options for the tabs plugin
123  'options'=>array(
124  'collapsible'=>true,
125  ),
126  ));
127  ?>
128  <?php $this->endWidget();?>
129  </div>
130  <div class="span6">
131 
132  <?php
133  $this->beginWidget('zii.widgets.CPortlet', array(
134  'title'=>"CPortlet",
135  ));
136 
137  ?>
138 <p>This content is in a portlet</p>
139 <pre>&lt;?php $this-&gt;beginWidget('zii.widgets.CPortlet'); ?&gt; <br />...insert content here... <br />&lt;?php $this-&gt;endWidget(); ?&gt;</pre>
140 
141  <?php $this->endWidget();?>
142  </div>
143 </div>
144 
145 <div class="row-fluid">
146  <div class="span6">
147  <?php
148  $this->beginWidget('zii.widgets.CPortlet', array(
149  'title'=>"CJuiAutoComplete",
150  ));
151 
152  ?>
153  <p>Type <code>john</code> in the fild to see it at work</p>
154  <?php
155  $this->widget('zii.widgets.jui.CJuiAutoComplete', array(
156  'name'=>'city',
157  'source'=>array('John Doe', 'John Murry', 'Ben John', 'Johnny Walker'),
158  // additional javascript options for the autocomplete plugin
159  'options'=>array(
160  'minLength'=>'2',
161  ),
162  'htmlOptions'=>array(
163  'style'=>'height:20px;'
164  ),
165  ));
166  ?>
167 
168  <?php $this->endWidget();?>
169  </div>
170  <div class="span6">
171 
172  <?php
173  $this->beginWidget('zii.widgets.CPortlet', array(
174  'title'=>"CJuiDatePicker",
175  ));
176 
177  ?>
178  <p>Click on the element below to see date picker</p>
179  <?php
180  $this->widget('zii.widgets.jui.CJuiDatePicker', array(
181  'name'=>'publishDate',
182  // additional javascript options for the date picker plugin
183  'options'=>array(
184  'showAnim'=>'fold',
185  ),
186  'htmlOptions'=>array(
187  'style'=>'height:20px;'
188  ),
189  ));
190  ?>
191 
192  <?php $this->endWidget();?>
193  </div>
194 </div>
195 
196 <div class="row-fluid">
197  <div class="span6">
198  <?php
199  $this->beginWidget('zii.widgets.CPortlet', array(
200  'title'=>"CJuiButton",
201  ));
202 
203  ?>
204 
205  <?php
206  $this->widget('zii.widgets.jui.CJuiButton', array(
207  'name'=>'button',
208  'caption'=>'Save',
209  'value'=>'asd',
210  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
211  ));
212 
213  $this->widget('zii.widgets.jui.CJuiButton', array(
214  'name'=>'button1',
215  'caption'=>'Save',
216  'value'=>'asd1',
217  'htmlOptions'=>array('class'=>'btn btn-primary'),
218  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
219  ));
220 
221  $this->widget('zii.widgets.jui.CJuiButton', array(
222  'name'=>'button2',
223  'caption'=>'Save',
224  'value'=>'asd2',
225  'htmlOptions'=>array('class'=>'btn btn-info'),
226  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
227  ));
228 
229  $this->widget('zii.widgets.jui.CJuiButton', array(
230  'name'=>'button3',
231  'caption'=>'Save',
232  'value'=>'asd3',
233  'htmlOptions'=>array('class'=>'btn btn-success'),
234  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
235  ));
236 
237  $this->widget('zii.widgets.jui.CJuiButton', array(
238  'name'=>'button4',
239  'caption'=>'Save',
240  'value'=>'asd4',
241  'htmlOptions'=>array('class'=>'btn btn-warning'),
242  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
243  ));
244 
245  $this->widget('zii.widgets.jui.CJuiButton', array(
246  'name'=>'button5',
247  'caption'=>'Save',
248  'value'=>'asd5',
249  'htmlOptions'=>array('class'=>'btn btn-danger'),
250  'onclick'=>new CJavaScriptExpression('function(){alert("Save button has been clicked"); this.blur(); return false;}'),
251  ));
252  ?>
253  <?php $this->endWidget();?>
254  </div>
255  <div class="span6">
256 
257  <?php
258  $this->beginWidget('zii.widgets.CPortlet', array(
259  'title'=>"CJuiDialog",
260  ));
261 
262  ?>
263 
264  <?php
265  $this->beginWidget('zii.widgets.jui.CJuiDialog', array(
266  'id'=>'mydialog',
267  // additional javascript options for the dialog plugin
268  'options'=>array(
269  'title'=>'Dialog box 1',
270  'autoOpen'=>false,
271  ),
272  ));
273 
274  echo $sample_text;
275 
276 $this->endWidget('zii.widgets.jui.CJuiDialog');
277 
278 // the link that may open the dialog
279 $dialog_button = '<button type="button" class="btn btn-primary" data-loading-text="Loading...">Open dialog</button>';
280 echo CHtml::link($dialog_button, '#', array(
281  'onclick'=>'$("#mydialog").dialog("open"); return false;',
282 ));
283  ?>
284 
285  <?php $this->endWidget();?>
286  </div>
287 </div>
288 
289 <div class="row-fluid">
290  <div class="span6">
291  <?php
292  $this->beginWidget('zii.widgets.CPortlet', array(
293  'title'=>"CJuiProgressBar",
294  ));
295  ?>
296  <p>Standard progress bar</p>
297  <p><code> with no styles defined</code></p>
298  <?php
299  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
300  'value'=>30,
301  ));
302  ?>
303  <p>Striped progress bar</p>
304  <p><code>'htmlOptions'=>array('class'=>'progress-striped'),</code></p>
305 
306  <?php
307  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
308  'value'=>40,
309  'htmlOptions'=>array('class'=>'progress progress-striped'),
310  ));
311  ?>
312  <p>Striped scrolling progress bar</p>
313  <p><code>'htmlOptions'=>array('class'=>'progress-striped active'),</code></p>
314  <?php
315  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
316  'value'=>50,
317  'htmlOptions'=>array('class'=>'progress-striped active'),
318  ));
319  ?>
320  <p>Different colors to chose from</p>
321  <p><code>'htmlOptions'=>array('class'=>'progress-info'),</code></p>
322  <?php
323  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
324  'value'=>60,
325  'htmlOptions'=>array('class'=>'progress-info'),
326  ));
327  ?>
328  <p><code>'htmlOptions'=>array('class'=>'progress-success')</code></p>
329  <?php
330  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
331  'value'=>70,
332  'htmlOptions'=>array('class'=>'progress-success'),
333  ));
334  ?>
335  <p><code>'htmlOptions'=>array('class'=>'progress-warning'),</code></p>
336  <?php
337  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
338  'value'=>80,
339  'htmlOptions'=>array('class'=>'progress-warning'),
340  ));
341  ?>
342  <p><code>'htmlOptions'=>array('class'=>'progress-danger'),</code></p>
343  <?php
344  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
345  'value'=>90,
346  'htmlOptions'=>array('class'=>'progress-danger'),
347  ));
348  ?>
349  <p><code>'htmlOptions'=>array('class'=>'progress-info progress-striped'),</code></p>
350  <?php
351  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
352  'value'=>90,
353  'htmlOptions'=>array('class'=>'progress-info progress-striped'),
354  ));
355  ?>
356  <p><code>'htmlOptions'=>array('class'=>'progress-success progress-striped'),</code></p>
357  <?php
358  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
359  'value'=>80,
360  'htmlOptions'=>array('class'=>'progress-success progress-striped'),
361  ));
362  ?>
363  <p><code>'htmlOptions'=>array('class'=>'progress-warning progress-striped'),</code></p>
364  <?php
365  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
366  'value'=>70,
367  'htmlOptions'=>array('class'=>'progress-warning progress-striped'),
368  ));
369  ?>
370  <p><code>'htmlOptions'=>array('class'=>'progress-danger progress-striped'),</code></p>
371  <?php
372  $this->widget('zii.widgets.jui.CJuiProgressBar', array(
373  'value'=>60,
374  'htmlOptions'=>array('class'=>'progress-danger progress-striped'),
375  ));
376  ?>
377  <?php $this->endWidget();?>
378  </div>
379  <div class="span6">
380 
381  <?php
382  $this->beginWidget('zii.widgets.CPortlet', array(
383  'title'=>"HTML - Progress bar",
384  ));
385 
386  ?>
387  <p>Standard progress bar</p>
388  <p><code>.progress</code></p>
389  <div class="progress">
390  <div class="bar" style="width: 30%;"></div>
391  </div>
392  <p>Striped progress bar</p>
393  <p><code>.progress-striped</code></p>
394  <div class="progress progress-striped">
395  <div class="bar" style="width: 40%;"></div>
396  </div>
397  <p>Striped active progress bar</p>
398  <p><code>.progress-striped .active</code></p>
399  <div class="progress progress-striped active">
400  <div class="bar" style="width: 50%;"></div>
401  </div>
402  <p>Different colors to chose from</p>
403  <p><code>.progress-info</code></p>
404  <div class="progress progress-info">
405  <div class="bar" style="width: 60%;"></div>
406  </div>
407  <p><code>.progress-success</code></p>
408  <div class="progress progress-success">
409  <div class="bar" style="width: 70%;"></div>
410  </div>
411  <p><code>.progress-warning</code></p>
412  <div class="progress progress-warning">
413  <div class="bar" style="width: 80%;"></div>
414  </div>
415  <p><code>.progress-danger</code></p>
416  <div class="progress progress-danger">
417  <div class="bar" style="width: 90%;"></div>
418  </div>
419  <p><code>.progress-info .progress-striped</code></p>
420  <div class="progress progress-info progress-striped">
421  <div class="bar" style="width: 90%;"></div>
422  </div>
423  <p><code>.progress-success .progress-striped</code></p>
424  <div class="progress progress-success progress-striped">
425  <div class="bar" style="width: 80%;"></div>
426  </div>
427  <p><code>.progress-warning .progress-striped</code></p>
428  <div class="progress progress-warning progress-striped">
429  <div class="bar" style="width: 70%;"></div>
430  </div>
431  <p><code>.progress-danger .progress-striped</code></p>
432  <div class="progress progress-danger progress-striped">
433  <div class="bar" style="width: 60%;"></div>
434  </div>
435 
436  <?php $this->endWidget();?>
437  </div>
438 </div>
439 
440 <div class="row-fluid">
441  <div class="span6">
442  <?php
443  $this->beginWidget('zii.widgets.CPortlet', array(
444  'title'=>"CJuiSlider",
445  ));
446 
447  ?>
448  <p><code> with no style defined</code></p>
449  <?php
450  $this->widget('zii.widgets.jui.CJuiSlider', array(
451  'value'=>30,
452  ));
453  ?>
454 
455  <p><code>.progress-info</code></p>
456  <?php
457  $this->widget('zii.widgets.jui.CJuiSlider', array(
458  'value'=>40,
459  'htmlOptions'=>array('class'=>'progress-info'),
460  ));
461  ?>
462  <p><code>.progress-success</code></p>
463  <?php
464  $this->widget('zii.widgets.jui.CJuiSlider', array(
465  'value'=>30,
466  'htmlOptions'=>array('class'=>'progress-success'),
467  ));
468  ?>
469  <p><code>.progress-warning</code></p>
470  <?php
471  $this->widget('zii.widgets.jui.CJuiSlider', array(
472  'value'=>20,
473  'htmlOptions'=>array('class'=>'progress-warning'),
474  ));
475  ?>
476  <p><code>.progress-danger</code></p>
477  <?php
478  $this->widget('zii.widgets.jui.CJuiSlider', array(
479  'value'=>30,
480  'htmlOptions'=>array('class'=>'progress-danger'),
481  ));
482  ?>
483 
484  <p><code>.progress-striped</code></p>
485  <?php
486  $this->widget('zii.widgets.jui.CJuiSlider', array(
487  'value'=>30,
488  'htmlOptions'=>array('class'=>'progress-striped'),
489  ));
490  ?>
491  <?php $this->endWidget();?>
492  </div>
493  <div class="span6">
494 
495  <?php
496  $this->beginWidget('zii.widgets.CPortlet', array(
497  'title'=>"CJuiSlider - vertical",
498  ));
499  ?>
500 
501  <?php $this->endWidget();?>
502  </div>
503 </div>