SKJ_Meetmyteam - Version 0.1.1

Version Notes

First Release

Download this release

Release Info

Developer Sanjeev Jha
Extension SKJ_Meetmyteam
Version 0.1.1
Comparing to
See all releases


Version 0.1.1

Files changed (43) hide show
  1. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category.php +13 -0
  2. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit.php +45 -0
  3. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Form.php +19 -0
  4. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Tab/Form.php +55 -0
  5. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Tabs.php +24 -0
  6. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Grid.php +106 -0
  7. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam.php +12 -0
  8. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit.php +45 -0
  9. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Form.php +19 -0
  10. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Tab/Form.php +117 -0
  11. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Tabs.php +24 -0
  12. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Grid.php +142 -0
  13. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Renderer/Image.php +24 -0
  14. app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Renderer/Preview.php +21 -0
  15. app/code/local/SKJ/Meetmyteam/Block/Category.php +31 -0
  16. app/code/local/SKJ/Meetmyteam/Block/Meetmyteam.php +21 -0
  17. app/code/local/SKJ/Meetmyteam/Helper/Data.php +6 -0
  18. app/code/local/SKJ/Meetmyteam/Model/Category.php +16 -0
  19. app/code/local/SKJ/Meetmyteam/Model/Meetmyteam.php +16 -0
  20. app/code/local/SKJ/Meetmyteam/Model/Mysql4/Category.php +10 -0
  21. app/code/local/SKJ/Meetmyteam/Model/Mysql4/Category/Collection.php +10 -0
  22. app/code/local/SKJ/Meetmyteam/Model/Mysql4/Meetmyteam.php +10 -0
  23. app/code/local/SKJ/Meetmyteam/Model/Mysql4/Meetmyteam/Collection.php +10 -0
  24. app/code/local/SKJ/Meetmyteam/Model/Status.php +15 -0
  25. app/code/local/SKJ/Meetmyteam/Model/Wysiwyg/Config.php +18 -0
  26. app/code/local/SKJ/Meetmyteam/Model/Wysiwyg/Config.php~ +42 -0
  27. app/code/local/SKJ/Meetmyteam/controllers/Adminhtml/CategoryController.php +195 -0
  28. app/code/local/SKJ/Meetmyteam/controllers/Adminhtml/MeetmyteamController.php +227 -0
  29. app/code/local/SKJ/Meetmyteam/controllers/IndexController.php +30 -0
  30. app/code/local/SKJ/Meetmyteam/etc/config.xml +146 -0
  31. app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-install-0.1.0.php +25 -0
  32. app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-install-0.1.0.php~ +25 -0
  33. app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-upgrade-0.1.0-0.1.1.php +24 -0
  34. app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-upgrade-0.1.0-0.1.1.php~ +23 -0
  35. app/design/adminhtml/default/default/layout/meetmyteam.xml +13 -0
  36. app/design/frontend/base/default/layout/meetmyteam.xml +60 -0
  37. app/design/frontend/base/default/template/meetmyteam/category.phtml +77 -0
  38. app/design/frontend/base/default/template/meetmyteam/category_box.phtml +18 -0
  39. app/design/frontend/base/default/template/meetmyteam/detail.phtml +65 -0
  40. app/design/frontend/base/default/template/meetmyteam/meetmyteam.phtml +44 -0
  41. app/etc/modules/SKJ_Meetmyteam.xml +9 -0
  42. package.xml +24 -0
  43. skin/frontend/base/default/css/skj-myteam.css +120 -0
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category.php ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category extends Mage_Adminhtml_Block_Widget_Grid_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ $this->_controller = 'adminhtml_category';
8
+ $this->_blockGroup = 'meetmyteam';
9
+ $this->_headerText = Mage::helper('meetmyteam')->__('My team category Manager');
10
+ $this->_addButtonLabel = Mage::helper('meetmyteam')->__('Add Item');
11
+ parent::__construct();
12
+ }
13
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ parent::__construct();
8
+
9
+ $this->_objectId = 'id';
10
+ $this->_blockGroup = 'meetmyteam';
11
+ $this->_controller = 'adminhtml_category';
12
+
13
+ $this->_updateButton('save', 'label', Mage::helper('meetmyteam')->__('Save Item'));
14
+ $this->_updateButton('delete', 'label', Mage::helper('meetmyteam')->__('Delete Item'));
15
+
16
+ $this->_addButton('saveandcontinue', array(
17
+ 'label' => Mage::helper('adminhtml')->__('Save And Continue Edit'),
18
+ 'onclick' => 'saveAndContinueEdit()',
19
+ 'class' => 'save',
20
+ ), -100);
21
+
22
+ $this->_formScripts[] = "
23
+ function toggleEditor() {
24
+ if (tinyMCE.getInstanceById('meetmyteam_content') == null) {
25
+ tinyMCE.execCommand('mceAddControl', false, 'meetmyteam_content');
26
+ } else {
27
+ tinyMCE.execCommand('mceRemoveControl', false, 'meetmyteam_content');
28
+ }
29
+ }
30
+
31
+ function saveAndContinueEdit(){
32
+ editForm.submit($('edit_form').action+'back/edit/');
33
+ }
34
+ ";
35
+ }
36
+
37
+ public function getHeaderText()
38
+ {
39
+ if( Mage::registry('meetmyteam_data') && Mage::registry('meetmyteam_data')->getId() ) {
40
+ return Mage::helper('meetmyteam')->__("Edit Item '%s'", $this->htmlEscape(Mage::registry('meetmyteam_data')->getTitle()));
41
+ } else {
42
+ return Mage::helper('meetmyteam')->__('Add Item');
43
+ }
44
+ }
45
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Form.php ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
4
+ {
5
+ protected function _prepareForm()
6
+ {
7
+ $form = new Varien_Data_Form(array(
8
+ 'id' => 'edit_form',
9
+ 'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),
10
+ 'method' => 'post',
11
+ 'enctype' => 'multipart/form-data'
12
+ )
13
+ );
14
+
15
+ $form->setUseContainer(true);
16
+ $this->setForm($form);
17
+ return parent::_prepareForm();
18
+ }
19
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Tab/Form.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
4
+ {
5
+ protected function _prepareForm()
6
+ {
7
+ $form = new Varien_Data_Form();
8
+ $this->setForm($form);
9
+ $fieldset = $form->addFieldset('meetmyteam_form', array('legend'=>Mage::helper('meetmyteam')->__('Category information')));
10
+
11
+ $fieldset->addField('title', 'text', array(
12
+ 'label' => Mage::helper('meetmyteam')->__('Category'),
13
+ 'class' => 'required-entry',
14
+ 'required' => true,
15
+ 'name' => 'title',
16
+ ));
17
+
18
+
19
+ $fieldset->addField('description', 'editor', array(
20
+ 'name' => 'description',
21
+ 'label' => Mage::helper('meetmyteam')->__('Description'),
22
+ 'title' => Mage::helper('meetmyteam')->__('Description'),
23
+ 'style' => 'width:700px; height:200px;',
24
+ 'wysiwyg' => false,
25
+ 'required' => false,
26
+ ));
27
+
28
+ $fieldset->addField('status', 'select', array(
29
+ 'label' => Mage::helper('meetmyteam')->__('Status'),
30
+ 'name' => 'status',
31
+ 'required' => true,
32
+ 'values' => array(
33
+ array(
34
+ 'value' => 1,
35
+ 'label' => Mage::helper('meetmyteam')->__('Enabled'),
36
+ ),
37
+
38
+ array(
39
+ 'value' => 2,
40
+ 'label' => Mage::helper('meetmyteam')->__('Disabled'),
41
+ ),
42
+ ),
43
+ ));
44
+
45
+
46
+ if ( Mage::getSingleton('adminhtml/session')->getMeetmyteamData() )
47
+ {
48
+ $form->setValues(Mage::getSingleton('adminhtml/session')->getMeetmyteamData());
49
+ Mage::getSingleton('adminhtml/session')->setMeetmyteamData(null);
50
+ } elseif ( Mage::registry('meetmyteam_data') ) {
51
+ $form->setValues(Mage::registry('meetmyteam_data')->getData());
52
+ }
53
+ return parent::_prepareForm();
54
+ }
55
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Edit/Tabs.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
4
+ {
5
+
6
+ public function __construct()
7
+ {
8
+ parent::__construct();
9
+ $this->setId('meetmyteam_tabs');
10
+ $this->setDestElementId('edit_form');
11
+ $this->setTitle(Mage::helper('meetmyteam')->__('Category Information'));
12
+ }
13
+
14
+ protected function _beforeToHtml()
15
+ {
16
+ $this->addTab('form_section', array(
17
+ 'label' => Mage::helper('meetmyteam')->__('Category Information'),
18
+ 'title' => Mage::helper('meetmyteam')->__('Category Information'),
19
+ 'content' => $this->getLayout()->createBlock('meetmyteam/adminhtml_category_edit_tab_form')->toHtml(),
20
+ ));
21
+
22
+ return parent::_beforeToHtml();
23
+ }
24
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Category/Grid.php ADDED
@@ -0,0 +1,106 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Category_Grid extends Mage_Adminhtml_Block_Widget_Grid
4
+ {
5
+ public function __construct()
6
+ {
7
+
8
+
9
+ parent::__construct();
10
+ $this->setId('meetmyteamGrid');
11
+ $this->setDefaultSort('meetmyteam_cat_id');
12
+ $this->setDefaultDir('ASC');
13
+ $this->setSaveParametersInSession(true);
14
+ }
15
+
16
+ protected function _prepareCollection()
17
+ {
18
+ $collection = Mage::getModel('meetmyteam/category')->getCollection();
19
+ $this->setCollection($collection);
20
+ return parent::_prepareCollection();
21
+ }
22
+
23
+ protected function _prepareColumns()
24
+ {
25
+ $this->addColumn('meetmyteam_cat_id', array(
26
+ 'header' => Mage::helper('meetmyteam')->__('ID'),
27
+ 'align' =>'right',
28
+ 'width' => '50px',
29
+ 'index' => 'meetmyteam_cat_id',
30
+ ));
31
+
32
+ $this->addColumn('title', array(
33
+ 'header' => Mage::helper('meetmyteam')->__('Category'),
34
+ 'align' =>'left',
35
+ 'index' => 'title',
36
+ ));
37
+
38
+
39
+ $this->addColumn('status', array(
40
+ 'header' => Mage::helper('meetmyteam')->__('Status'),
41
+ 'align' => 'left',
42
+ 'width' => '80px',
43
+ 'index' => 'status',
44
+ 'type' => 'options',
45
+ 'options' => array(
46
+ 1 => 'Enabled',
47
+ 2 => 'Disabled',
48
+ ),
49
+ ));
50
+
51
+ $this->addColumn('action',
52
+ array(
53
+ 'header' => Mage::helper('newsletter')->__('Action'),
54
+ 'index' =>'meetmyteam_cat_id',
55
+ 'sortable' =>false,
56
+ 'filter' => false,
57
+ 'no_link' => false,
58
+ 'width' => '170px',
59
+ 'renderer'=> new SKJ_Meetmyteam_Block_Adminhtml_Renderer_Preview(),
60
+ ));
61
+
62
+
63
+
64
+
65
+ $this->addExportType('*/*/exportCsv', Mage::helper('meetmyteam')->__('CSV'));
66
+ $this->addExportType('*/*/exportXml', Mage::helper('meetmyteam')->__('XML'));
67
+
68
+ return parent::_prepareColumns();
69
+ }
70
+
71
+ protected function _prepareMassaction()
72
+ {
73
+ $this->setMassactionIdField('meetmyteam_cat_id');
74
+ $this->getMassactionBlock()->setFormFieldName('meetmyteam');
75
+
76
+ $this->getMassactionBlock()->addItem('delete', array(
77
+ 'label' => Mage::helper('meetmyteam')->__('Delete'),
78
+ 'url' => $this->getUrl('*/*/massDelete'),
79
+ 'confirm' => Mage::helper('meetmyteam')->__('Are you sure?')
80
+ ));
81
+
82
+ $statuses = Mage::getSingleton('meetmyteam/status')->getOptionArray();
83
+
84
+ array_unshift($statuses, array('label'=>'', 'value'=>''));
85
+ $this->getMassactionBlock()->addItem('status', array(
86
+ 'label'=> Mage::helper('meetmyteam')->__('Change status'),
87
+ 'url' => $this->getUrl('*/*/massStatus', array('_current'=>true)),
88
+ 'additional' => array(
89
+ 'visibility' => array(
90
+ 'name' => 'status',
91
+ 'type' => 'select',
92
+ 'class' => 'required-entry',
93
+ 'label' => Mage::helper('meetmyteam')->__('Status'),
94
+ 'values' => $statuses
95
+ )
96
+ )
97
+ ));
98
+ return $this;
99
+ }
100
+
101
+ public function getRowUrl($row)
102
+ {
103
+ return $this->getUrl('*/*/edit', array('id' => $row->getId()));
104
+ }
105
+
106
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam extends Mage_Adminhtml_Block_Widget_Grid_Container
3
+ {
4
+ public function __construct()
5
+ {
6
+ $this->_controller = 'adminhtml_meetmyteam';
7
+ $this->_blockGroup = 'meetmyteam';
8
+ $this->_headerText = Mage::helper('meetmyteam')->__('Item Manager');
9
+ $this->_addButtonLabel = Mage::helper('meetmyteam')->__('Add Item');
10
+ parent::__construct();
11
+ }
12
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ parent::__construct();
8
+
9
+ $this->_objectId = 'id';
10
+ $this->_blockGroup = 'meetmyteam';
11
+ $this->_controller = 'adminhtml_meetmyteam';
12
+
13
+ $this->_updateButton('save', 'label', Mage::helper('meetmyteam')->__('Save Item'));
14
+ $this->_updateButton('delete', 'label', Mage::helper('meetmyteam')->__('Delete Item'));
15
+
16
+ $this->_addButton('saveandcontinue', array(
17
+ 'label' => Mage::helper('adminhtml')->__('Save And Continue Edit'),
18
+ 'onclick' => 'saveAndContinueEdit()',
19
+ 'class' => 'save',
20
+ ), -100);
21
+
22
+ $this->_formScripts[] = "
23
+ function toggleEditor() {
24
+ if (tinyMCE.getInstanceById('meetmyteam_content') == null) {
25
+ tinyMCE.execCommand('mceAddControl', false, 'meetmyteam_content');
26
+ } else {
27
+ tinyMCE.execCommand('mceRemoveControl', false, 'meetmyteam_content');
28
+ }
29
+ }
30
+
31
+ function saveAndContinueEdit(){
32
+ editForm.submit($('edit_form').action+'back/edit/');
33
+ }
34
+ ";
35
+ }
36
+
37
+ public function getHeaderText()
38
+ {
39
+ if( Mage::registry('meetmyteam_data') && Mage::registry('meetmyteam_data')->getId() ) {
40
+ return Mage::helper('meetmyteam')->__("Edit Item '%s'", $this->htmlEscape(Mage::registry('meetmyteam_data')->getTitle()));
41
+ } else {
42
+ return Mage::helper('meetmyteam')->__('Add Item');
43
+ }
44
+ }
45
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Form.php ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
4
+ {
5
+ protected function _prepareForm()
6
+ {
7
+ $form = new Varien_Data_Form(array(
8
+ 'id' => 'edit_form',
9
+ 'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),
10
+ 'method' => 'post',
11
+ 'enctype' => 'multipart/form-data'
12
+ )
13
+ );
14
+
15
+ $form->setUseContainer(true);
16
+ $this->setForm($form);
17
+ return parent::_prepareForm();
18
+ }
19
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Tab/Form.php ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
4
+ {
5
+
6
+
7
+ /**
8
+ * Preparing global layout
9
+ *
10
+ * You can redefine this method in child classes for changin layout
11
+ *
12
+ * @return Mage_Core_Block_Abstract
13
+ */
14
+
15
+ /*
16
+ protected function _prepareLayout()
17
+ {
18
+ parent::_prepareLayout();
19
+ if (Mage::getSingleton('cms/wysiwyg_config')->isEnabled()) {
20
+ $this->getLayout()->getBlock('head')->setCanLoadTinyMce(true);
21
+ }
22
+ }
23
+ */
24
+
25
+ protected function _prepareForm()
26
+ {
27
+ $form = new Varien_Data_Form();
28
+ $this->setForm($form);
29
+ $fieldset = $form->addFieldset('meetmyteam_form', array('legend'=>Mage::helper('meetmyteam')->__('Item information')));
30
+
31
+ // Get category collection
32
+ $optioncat[''] = 'Select category';
33
+
34
+ $categoryCollection = Mage::getModel('meetmyteam/category')->getCollection()
35
+ ->addFieldToFilter('status' , '1');
36
+ ;
37
+
38
+ foreach($categoryCollection as $category){
39
+ $optioncat[$category->getID()] = $category->getTitle();
40
+ }
41
+
42
+ $fieldset->addField('category', 'select', array(
43
+ 'label' => Mage::helper('meetmyteam')->__('category'),
44
+ 'name' => 'category',
45
+ 'values' => $optioncat,
46
+ 'required' => true,
47
+ ));
48
+
49
+ $fieldset->addField('title', 'text', array(
50
+ 'label' => Mage::helper('meetmyteam')->__('Name'),
51
+ 'class' => 'required-entry',
52
+ 'required' => true,
53
+ 'name' => 'title',
54
+ ));
55
+
56
+ $fieldset->addField('description', 'text', array(
57
+ 'label' => Mage::helper('meetmyteam')->__('Designation'),
58
+ 'class' => 'required-entry',
59
+ 'required' => true,
60
+ 'name' => 'description',
61
+ ));
62
+
63
+
64
+ $fieldset->addField('filename', 'image', array(
65
+ 'label' => Mage::helper('meetmyteam')->__('Image'),
66
+ 'required' => false,
67
+ 'name' => 'filename',
68
+ ));
69
+
70
+ $fieldset->addField('status', 'select', array(
71
+ 'label' => Mage::helper('meetmyteam')->__('Status'),
72
+ 'name' => 'status',
73
+ 'required' => true,
74
+ 'values' => array(
75
+ array(
76
+ 'value' => 1,
77
+ 'label' => Mage::helper('meetmyteam')->__('Enabled'),
78
+ ),
79
+
80
+ array(
81
+ 'value' => 2,
82
+ 'label' => Mage::helper('meetmyteam')->__('Disabled'),
83
+ ),
84
+ ),
85
+ ));
86
+
87
+
88
+ $fieldset->addField('content', 'editor', array(
89
+ 'name' => 'content',
90
+ 'label' => Mage::helper('meetmyteam')->__('Content'),
91
+ 'title' => Mage::helper('meetmyteam')->__('Content'),
92
+ 'style' => 'width:700px; height:300px;',
93
+ 'wysiwyg' => false,
94
+ 'required' => true,
95
+ ));
96
+
97
+ /*
98
+ $fieldset->addField('content', 'editor', array(
99
+ 'name' => 'content',
100
+ 'label' => Mage::helper('meetmyteam')->__('content'),
101
+ 'title' => Mage::helper('meetmyteam')->__('content'),
102
+ 'style' => 'width:100%;height:300px;',
103
+ 'required' => true,
104
+ 'config' => Mage::getSingleton('meetmyteam/wysiwyg_config')->getConfig()
105
+ ));
106
+ */
107
+
108
+ if ( Mage::getSingleton('adminhtml/session')->getMeetmyteamData() )
109
+ {
110
+ $form->setValues(Mage::getSingleton('adminhtml/session')->getMeetmyteamData());
111
+ Mage::getSingleton('adminhtml/session')->setMeetmyteamData(null);
112
+ } elseif ( Mage::registry('meetmyteam_data') ) {
113
+ $form->setValues(Mage::registry('meetmyteam_data')->getData());
114
+ }
115
+ return parent::_prepareForm();
116
+ }
117
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Edit/Tabs.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
4
+ {
5
+
6
+ public function __construct()
7
+ {
8
+ parent::__construct();
9
+ $this->setId('meetmyteam_tabs');
10
+ $this->setDestElementId('edit_form');
11
+ $this->setTitle(Mage::helper('meetmyteam')->__('Item Information'));
12
+ }
13
+
14
+ protected function _beforeToHtml()
15
+ {
16
+ $this->addTab('form_section', array(
17
+ 'label' => Mage::helper('meetmyteam')->__('Item Information'),
18
+ 'title' => Mage::helper('meetmyteam')->__('Item Information'),
19
+ 'content' => $this->getLayout()->createBlock('meetmyteam/adminhtml_meetmyteam_edit_tab_form')->toHtml(),
20
+ ));
21
+
22
+ return parent::_beforeToHtml();
23
+ }
24
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Meetmyteam/Grid.php ADDED
@@ -0,0 +1,142 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Block_Adminhtml_Meetmyteam_Grid extends Mage_Adminhtml_Block_Widget_Grid
4
+ {
5
+ public function __construct()
6
+ {
7
+ parent::__construct();
8
+ $this->setId('meetmyteamGrid');
9
+ $this->setDefaultSort('meetmyteam_id');
10
+ $this->setDefaultDir('ASC');
11
+ $this->setSaveParametersInSession(true);
12
+ }
13
+
14
+ protected function _prepareCollection()
15
+ {
16
+ $collection = Mage::getModel('meetmyteam/meetmyteam')->getCollection();
17
+ $this->setCollection($collection);
18
+ return parent::_prepareCollection();
19
+ }
20
+
21
+ protected function _prepareColumns()
22
+ {
23
+
24
+ $catCollection = Mage::getModel('meetmyteam/category')->getCollection();
25
+ $catCollection->addFieldToFilter('status',Array('eq'=>1));
26
+
27
+ foreach($catCollection as $cat)
28
+ {
29
+ $key = $cat['meetmyteam_cat_id'];
30
+ $categoryOption[$key] = $cat->getTitle();
31
+ }
32
+
33
+ $this->addColumn('meetmyteam_id', array(
34
+ 'header' => Mage::helper('meetmyteam')->__('ID'),
35
+ 'align' =>'right',
36
+ 'width' => '50px',
37
+ 'index' => 'meetmyteam_id',
38
+ ));
39
+
40
+ $this->addColumn('title', array(
41
+ 'header' => Mage::helper('meetmyteam')->__('Name'),
42
+ 'align' =>'left',
43
+ 'index' => 'title',
44
+ ));
45
+
46
+
47
+ $this->addColumn('description', array(
48
+ 'header' => Mage::helper('meetmyteam')->__('Designation'),
49
+ 'width' => '250px',
50
+ 'index' => 'description',
51
+ ));
52
+
53
+ $this->addColumn('filename', array(
54
+ 'header' => Mage::helper('meetmyteam')->__('Image'),
55
+ 'width' => '200px',
56
+ 'index' => 'meetmyteam_id',
57
+ 'renderer'=> new SKJ_Meetmyteam_Block_Adminhtml_Renderer_Image(),
58
+ ));
59
+
60
+
61
+ $this->addColumn('status', array(
62
+ 'header' => Mage::helper('meetmyteam')->__('Status'),
63
+ 'align' => 'left',
64
+ 'width' => '80px',
65
+ 'index' => 'status',
66
+ 'type' => 'options',
67
+ 'options' => array(
68
+ 1 => 'Enabled',
69
+ 2 => 'Disabled',
70
+ ),
71
+ ));
72
+
73
+ $this->addColumn('category', array(
74
+ 'header' => Mage::helper('customer')->__('Category'),
75
+ 'width' => '200px',
76
+ 'index' => 'category',
77
+ 'type' => 'options',
78
+ 'options' => $categoryOption,
79
+ ));
80
+
81
+
82
+ $this->addColumn('action',
83
+ array(
84
+ 'header' => Mage::helper('meetmyteam')->__('Action'),
85
+ 'width' => '100',
86
+ 'type' => 'action',
87
+ 'getter' => 'getId',
88
+ 'actions' => array(
89
+ array(
90
+ 'caption' => Mage::helper('meetmyteam')->__('Edit'),
91
+ 'url' => array('base'=> '*/*/edit'),
92
+ 'field' => 'id'
93
+ )
94
+ ),
95
+ 'filter' => false,
96
+ 'sortable' => false,
97
+ 'index' => 'stores',
98
+ 'is_system' => true,
99
+ ));
100
+
101
+ $this->addExportType('*/*/exportCsv', Mage::helper('meetmyteam')->__('CSV'));
102
+ $this->addExportType('*/*/exportXml', Mage::helper('meetmyteam')->__('XML'));
103
+
104
+ return parent::_prepareColumns();
105
+ }
106
+
107
+ protected function _prepareMassaction()
108
+ {
109
+ $this->setMassactionIdField('meetmyteam_id');
110
+ $this->getMassactionBlock()->setFormFieldName('meetmyteam');
111
+
112
+ $this->getMassactionBlock()->addItem('delete', array(
113
+ 'label' => Mage::helper('meetmyteam')->__('Delete'),
114
+ 'url' => $this->getUrl('*/*/massDelete'),
115
+ 'confirm' => Mage::helper('meetmyteam')->__('Are you sure?')
116
+ ));
117
+
118
+ $statuses = Mage::getSingleton('meetmyteam/status')->getOptionArray();
119
+
120
+ array_unshift($statuses, array('label'=>'', 'value'=>''));
121
+ $this->getMassactionBlock()->addItem('status', array(
122
+ 'label'=> Mage::helper('meetmyteam')->__('Change status'),
123
+ 'url' => $this->getUrl('*/*/massStatus', array('_current'=>true)),
124
+ 'additional' => array(
125
+ 'visibility' => array(
126
+ 'name' => 'status',
127
+ 'type' => 'select',
128
+ 'class' => 'required-entry',
129
+ 'label' => Mage::helper('meetmyteam')->__('Status'),
130
+ 'values' => $statuses
131
+ )
132
+ )
133
+ ));
134
+ return $this;
135
+ }
136
+
137
+ public function getRowUrl($row)
138
+ {
139
+ return $this->getUrl('*/*/edit', array('id' => $row->getId()));
140
+ }
141
+
142
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Renderer/Image.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Render block for my team
4
+ *
5
+ *
6
+ * @category SKJ
7
+ * @package SKJ_Meetmyteam
8
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
9
+ */
10
+ class SKJ_Meetmyteam_Block_Adminhtml_Renderer_Image extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract{
11
+
12
+ public function render(Varien_Object $row)
13
+ {
14
+
15
+ $html = '<img ';
16
+ $html .= 'id="' . $row->getId() . '" ';
17
+ $html .= 'src="'. Mage::getBaseUrl('media') . $row->getFilename() . '"';
18
+ $html .= 'class="grid-image ' . $this->getColumn()->getInlineCss().'"';
19
+ $html .= 'style="weight:30px;height:30px"' . '"/>';
20
+ return $html;
21
+ }
22
+
23
+
24
+ }
app/code/local/SKJ/Meetmyteam/Block/Adminhtml/Renderer/Preview.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Render for my team
4
+ *
5
+ *
6
+ * @category SKJ
7
+ * @package SKJ_Meetmyteam
8
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
9
+ */
10
+ class SKJ_Meetmyteam_Block_Adminhtml_Renderer_Preview extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract
11
+ {
12
+
13
+ public function render(Varien_Object $row)
14
+ {
15
+ $categoryId = $row->getMeetmyteamCatId();
16
+ $href = Mage::getUrl('meetmyteam/index/category',array('id'=>$categoryId));
17
+
18
+ return '<a href="'.$href.'" target="_blank">'.$this->__('Preview').'</a>';
19
+ }
20
+
21
+ }
app/code/local/SKJ/Meetmyteam/Block/Category.php ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Block_Category extends Mage_Core_Block_Template
10
+ {
11
+
12
+ public function getCategoryList()
13
+ {
14
+ $collection = Mage::getModel('meetmyteam/category')->getCollection()
15
+ ->addFieldToFilter('status' , '1');
16
+
17
+ return $collection;
18
+ }
19
+
20
+ public function getCategory()
21
+ {
22
+ $id = Mage::app()->getRequest()->getParam('id');
23
+ $catCollection = Mage::getModel('meetmyteam/category')->getCollection();
24
+ $catCollection->addFieldToFilter('status',Array('eq'=>1));
25
+ $catCollection->addFieldToFilter('meetmyteam_cat_id',Array('eq'=>$id));
26
+
27
+ return $catCollection->getFirstItem();
28
+ }
29
+
30
+
31
+ }
app/code/local/SKJ/Meetmyteam/Block/Meetmyteam.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Block_Meetmyteam extends Mage_Core_Block_Template
10
+ {
11
+
12
+ public function getAllMembers()
13
+ {
14
+ $collection = Mage::getModel('meetmyteam/meetmyteam')->getCollection();
15
+ $collection->addFieldToFilter('status',Array('eq'=>1));
16
+
17
+ return $collection;
18
+ }
19
+
20
+
21
+ }
app/code/local/SKJ/Meetmyteam/Helper/Data.php ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Helper_Data extends Mage_Core_Helper_Abstract
4
+ {
5
+
6
+ }
app/code/local/SKJ/Meetmyteam/Model/Category.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Model_Category extends Mage_Core_Model_Abstract
10
+ {
11
+ public function _construct()
12
+ {
13
+ parent::_construct();
14
+ $this->_init('meetmyteam/category');
15
+ }
16
+ }
app/code/local/SKJ/Meetmyteam/Model/Meetmyteam.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Model_Meetmyteam extends Mage_Core_Model_Abstract
10
+ {
11
+ public function _construct()
12
+ {
13
+ parent::_construct();
14
+ $this->_init('meetmyteam/meetmyteam');
15
+ }
16
+ }
app/code/local/SKJ/Meetmyteam/Model/Mysql4/Category.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Mysql4_Category extends Mage_Core_Model_Mysql4_Abstract
4
+ {
5
+ public function _construct()
6
+ {
7
+ // Note that the meetmyteam_cat_id refers to the key field in your database table.
8
+ $this->_init('meetmyteam/category', 'meetmyteam_cat_id');
9
+ }
10
+ }
app/code/local/SKJ/Meetmyteam/Model/Mysql4/Category/Collection.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Mysql4_Category_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
4
+ {
5
+ public function _construct()
6
+ {
7
+ parent::_construct();
8
+ $this->_init('meetmyteam/category');
9
+ }
10
+ }
app/code/local/SKJ/Meetmyteam/Model/Mysql4/Meetmyteam.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Mysql4_Meetmyteam extends Mage_Core_Model_Mysql4_Abstract
4
+ {
5
+ public function _construct()
6
+ {
7
+ // Note that the meetmyteam_id refers to the key field in your database table.
8
+ $this->_init('meetmyteam/meetmyteam', 'meetmyteam_id');
9
+ }
10
+ }
app/code/local/SKJ/Meetmyteam/Model/Mysql4/Meetmyteam/Collection.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Mysql4_Meetmyteam_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
4
+ {
5
+ public function _construct()
6
+ {
7
+ parent::_construct();
8
+ $this->_init('meetmyteam/meetmyteam');
9
+ }
10
+ }
app/code/local/SKJ/Meetmyteam/Model/Status.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Status extends Varien_Object
4
+ {
5
+ const STATUS_ENABLED = 1;
6
+ const STATUS_DISABLED = 2;
7
+
8
+ static public function getOptionArray()
9
+ {
10
+ return array(
11
+ self::STATUS_ENABLED => Mage::helper('meetmyteam')->__('Enabled'),
12
+ self::STATUS_DISABLED => Mage::helper('meetmyteam')->__('Disabled')
13
+ );
14
+ }
15
+ }
app/code/local/SKJ/Meetmyteam/Model/Wysiwyg/Config.php ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class SKJ_Meetmyteam_Model_Wysiwyg_Config extends Mage_Cms_Model_Wysiwyg_Config
4
+ {
5
+
6
+ public function getConfig($data = array())
7
+ {
8
+
9
+ $config = parent::getConfig($data);
10
+ $config->setData('files_browser_window_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/cms_wysiwyg_images/index/'));
11
+ $config->setData('directives_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/cms_wysiwyg/directive'));
12
+ $config->setData('directives_url_quoted', preg_quote($config->getData('directives_url')));
13
+ $config->setData('widget_window_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/widget/index'));
14
+ return $config;
15
+ }
16
+
17
+
18
+ }
app/code/local/SKJ/Meetmyteam/Model/Wysiwyg/Config.php~ ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Config for Wysiwyg redactor which we use on testimonial form page
5
+ *
6
+ * @category Turnkeye
7
+ * @package Turnkeye_Testimonial
8
+ * @author Viacheslav Fedorenko <v.fedorenko@turnkeye.com>
9
+ */
10
+ class SKJ_Meetmyteam_Model_Wysiwyg_Config extends Mage_Cms_Model_Wysiwyg_Config
11
+ {
12
+
13
+ /**
14
+ * Return Wysiwyg config as Varien_Object
15
+ *
16
+ * Config options description:
17
+ *
18
+ * enabled: Enabled Visual Editor or not
19
+ * hidden: Show Visual Editor on page load or not
20
+ * use_container: Wrap Editor contents into div or not
21
+ * no_display: Hide Editor container or not (related to use_container)
22
+ * translator: Helper to translate phrases in lib
23
+ * files_browser_*: Files Browser (media, images) settings
24
+ * encode_directives: Encode template directives with JS or not
25
+ *
26
+ * @param $data Varien_Object constructor params to override default config values
27
+ *
28
+ * @return Varien_Object
29
+ */
30
+ public function getConfig($data = array())
31
+ {
32
+ echo "e";exit;
33
+ $config = parent::getConfig($data);
34
+ $config->setData('files_browser_window_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/cms_wysiwyg_images/index/'));
35
+ $config->setData('directives_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/cms_wysiwyg/directive'));
36
+ $config->setData('directives_url_quoted', preg_quote($config->getData('directives_url')));
37
+ $config->setData('widget_window_url',Mage::getSingleton('adminhtml/url')->getUrl('adminhtml/widget/index'));
38
+ return $config;
39
+ }
40
+
41
+
42
+ }
app/code/local/SKJ/Meetmyteam/controllers/Adminhtml/CategoryController.php ADDED
@@ -0,0 +1,195 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Adminhtml_CategoryController extends Mage_Adminhtml_Controller_action
10
+ {
11
+
12
+ protected function _initAction() {
13
+ $this->loadLayout()
14
+ ->_setActiveMenu('meetmyteam/category')
15
+ ->_addBreadcrumb(Mage::helper('adminhtml')->__('Items Manager'), Mage::helper('adminhtml')->__('Category Manager'));
16
+
17
+ return $this;
18
+ }
19
+
20
+ public function indexAction() {
21
+ $this->_initAction()
22
+ ->renderLayout();
23
+ }
24
+
25
+ public function editAction() {
26
+ $id = $this->getRequest()->getParam('id');
27
+ $model = Mage::getModel('meetmyteam/category')->load($id);
28
+
29
+ if ($model->getId() || $id == 0) {
30
+ $data = Mage::getSingleton('adminhtml/session')->getFormData(true);
31
+ if (!empty($data)) {
32
+ $model->setData($data);
33
+ }
34
+
35
+ Mage::register('meetmyteam_data', $model);
36
+
37
+ $this->loadLayout();
38
+ $this->_setActiveMenu('meetmyteam/items');
39
+
40
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'), Mage::helper('adminhtml')->__('Category Manager'));
41
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));
42
+
43
+ $this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
44
+
45
+ $this->_addContent($this->getLayout()->createBlock('meetmyteam/adminhtml_category_edit'))
46
+ ->_addLeft($this->getLayout()->createBlock('meetmyteam/adminhtml_category_edit_tabs'));
47
+
48
+ $this->renderLayout();
49
+ } else {
50
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('meetmyteam')->__('Item does not exist'));
51
+ $this->_redirect('*/*/');
52
+ }
53
+ }
54
+
55
+ public function newAction() {
56
+ $this->_forward('edit');
57
+ }
58
+
59
+ public function saveAction() {
60
+ if ($data = $this->getRequest()->getPost()) {
61
+
62
+
63
+
64
+ $model = Mage::getModel('meetmyteam/category');
65
+ $model->setData($data)
66
+ ->setId($this->getRequest()->getParam('id'));
67
+
68
+ try {
69
+ if ($model->getCreatedTime == NULL || $model->getUpdateTime() == NULL) {
70
+ $model->setCreatedTime(now())
71
+ ->setUpdateTime(now());
72
+ } else {
73
+ $model->setUpdateTime(now());
74
+ }
75
+
76
+ $model->save();
77
+
78
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('meetmyteam')->__('Item was successfully saved'));
79
+ Mage::getSingleton('adminhtml/session')->setFormData(false);
80
+
81
+ if ($this->getRequest()->getParam('back')) {
82
+ $this->_redirect('*/*/edit', array('id' => $model->getId()));
83
+ return;
84
+ }
85
+ $this->_redirect('*/*/');
86
+ return;
87
+ } catch (Exception $e) {
88
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
89
+ Mage::getSingleton('adminhtml/session')->setFormData($data);
90
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
91
+ return;
92
+ }
93
+ }
94
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('meetmyteam')->__('Unable to find item to save'));
95
+ $this->_redirect('*/*/');
96
+ }
97
+
98
+ public function deleteAction() {
99
+ if( $this->getRequest()->getParam('id') > 0 ) {
100
+ try {
101
+ $model = Mage::getModel('meetmyteam/category');
102
+
103
+ $model->setId($this->getRequest()->getParam('id'))
104
+ ->delete();
105
+
106
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully deleted'));
107
+ $this->_redirect('*/*/');
108
+ } catch (Exception $e) {
109
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
110
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
111
+ }
112
+ }
113
+ $this->_redirect('*/*/');
114
+ }
115
+
116
+ public function massDeleteAction() {
117
+ $meetmyteamIds = $this->getRequest()->getParam('meetmyteam');
118
+ if(!is_array($meetmyteamIds)) {
119
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('adminhtml')->__('Please select item(s)'));
120
+ } else {
121
+ try {
122
+ foreach ($meetmyteamIds as $meetmyteamId) {
123
+ $meetmyteam = Mage::getModel('meetmyteam/category')->load($meetmyteamId);
124
+ $meetmyteam->delete();
125
+ }
126
+ Mage::getSingleton('adminhtml/session')->addSuccess(
127
+ Mage::helper('adminhtml')->__(
128
+ 'Total of %d record(s) were successfully deleted', count($meetmyteamIds)
129
+ )
130
+ );
131
+ } catch (Exception $e) {
132
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
133
+ }
134
+ }
135
+ $this->_redirect('*/*/index');
136
+ }
137
+
138
+ public function massStatusAction()
139
+ {
140
+ $meetmyteamIds = $this->getRequest()->getParam('meetmyteam');
141
+ if(!is_array($meetmyteamIds)) {
142
+ Mage::getSingleton('adminhtml/session')->addError($this->__('Please select item(s)'));
143
+ } else {
144
+ try {
145
+ foreach ($meetmyteamIds as $meetmyteamId) {
146
+ $meetmyteam = Mage::getSingleton('meetmyteam/category')
147
+ ->load($meetmyteamId)
148
+ ->setStatus($this->getRequest()->getParam('status'))
149
+ ->setIsMassupdate(true)
150
+ ->save();
151
+ }
152
+ $this->_getSession()->addSuccess(
153
+ $this->__('Total of %d record(s) were successfully updated', count($meetmyteamIds))
154
+ );
155
+ } catch (Exception $e) {
156
+ $this->_getSession()->addError($e->getMessage());
157
+ }
158
+ }
159
+ $this->_redirect('*/*/index');
160
+ }
161
+
162
+ public function exportCsvAction()
163
+ {
164
+ $fileName = 'meetmyteamcategory.csv';
165
+ $content = $this->getLayout()->createBlock('meetmyteam/adminhtml_category_grid')
166
+ ->getCsv();
167
+
168
+ $this->_sendUploadResponse($fileName, $content);
169
+ }
170
+
171
+ public function exportXmlAction()
172
+ {
173
+ $fileName = 'meetmyteamcategory.xml';
174
+ $content = $this->getLayout()->createBlock('meetmyteam/adminhtml_category_grid')
175
+ ->getXml();
176
+
177
+ $this->_sendUploadResponse($fileName, $content);
178
+ }
179
+
180
+ protected function _sendUploadResponse($fileName, $content, $contentType='application/octet-stream')
181
+ {
182
+ $response = $this->getResponse();
183
+ $response->setHeader('HTTP/1.1 200 OK','');
184
+ $response->setHeader('Pragma', 'public', true);
185
+ $response->setHeader('Cache-Control', 'must-revalidate, post-check=0, pre-check=0', true);
186
+ $response->setHeader('Content-Disposition', 'attachment; filename='.$fileName);
187
+ $response->setHeader('Last-Modified', date('r'));
188
+ $response->setHeader('Accept-Ranges', 'bytes');
189
+ $response->setHeader('Content-Length', strlen($content));
190
+ $response->setHeader('Content-type', $contentType);
191
+ $response->setBody($content);
192
+ $response->sendResponse();
193
+ die;
194
+ }
195
+ }
app/code/local/SKJ/Meetmyteam/controllers/Adminhtml/MeetmyteamController.php ADDED
@@ -0,0 +1,227 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_Adminhtml_MeetmyteamController extends Mage_Adminhtml_Controller_action
10
+ {
11
+
12
+ protected function _initAction() {
13
+ $this->loadLayout()
14
+ ->_setActiveMenu('meetmyteam/items')
15
+ ->_addBreadcrumb(Mage::helper('adminhtml')->__('Items Manager'), Mage::helper('adminhtml')->__('Item Manager'));
16
+
17
+ return $this;
18
+ }
19
+
20
+ public function indexAction() {
21
+ $this->_initAction()
22
+ ->renderLayout();
23
+ }
24
+
25
+ public function editAction() {
26
+ $id = $this->getRequest()->getParam('id');
27
+ $model = Mage::getModel('meetmyteam/meetmyteam')->load($id);
28
+
29
+ if ($model->getId() || $id == 0) {
30
+ $data = Mage::getSingleton('adminhtml/session')->getFormData(true);
31
+ if (!empty($data)) {
32
+ $model->setData($data);
33
+ }
34
+
35
+ Mage::register('meetmyteam_data', $model);
36
+
37
+ $this->loadLayout();
38
+ $this->_setActiveMenu('meetmyteam/items');
39
+
40
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'), Mage::helper('adminhtml')->__('Item Manager'));
41
+ $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));
42
+
43
+ $this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
44
+
45
+ $this->_addContent($this->getLayout()->createBlock('meetmyteam/adminhtml_meetmyteam_edit'))
46
+ ->_addLeft($this->getLayout()->createBlock('meetmyteam/adminhtml_meetmyteam_edit_tabs'));
47
+
48
+ $this->renderLayout();
49
+ } else {
50
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('meetmyteam')->__('Item does not exist'));
51
+ $this->_redirect('*/*/');
52
+ }
53
+ }
54
+
55
+ public function newAction() {
56
+ $this->_forward('edit');
57
+ }
58
+
59
+ public function saveAction() {
60
+ if ($data = $this->getRequest()->getPost()) {
61
+
62
+ if(isset($_FILES['filename']['name']) && $_FILES['filename']['name'] != '') {
63
+ try {
64
+ /* Starting upload */
65
+ $uploader = new Varien_File_Uploader('filename');
66
+
67
+ // Any extention would work
68
+ $uploader->setAllowedExtensions(array('jpg','jpeg','gif','png'));
69
+ $uploader->setAllowRenameFiles(false);
70
+
71
+ // Set the file upload mode
72
+ // false -> get the file directly in the specified folder
73
+ // true -> get the file in the product like folders
74
+ // (file.jpg will go in something like /media/f/i/file.jpg)
75
+ $uploader->setFilesDispersion(false);
76
+
77
+ // We set media as the upload dir
78
+ $path = Mage::getBaseDir('media') . DS ;
79
+ $uploader->save($path, $_FILES['filename']['name'] );
80
+
81
+ } catch (Exception $e) {
82
+
83
+ }
84
+
85
+ //this way the name is saved in DB
86
+
87
+ $data['filename'] = str_replace(" ","_",$_FILES['filename']['name']);
88
+ }
89
+
90
+
91
+ if(is_array($data['filename'])){
92
+ unset($data['filename']);
93
+ }
94
+
95
+ $model = Mage::getModel('meetmyteam/meetmyteam');
96
+ $model->setData($data)
97
+ ->setId($this->getRequest()->getParam('id'));
98
+
99
+
100
+ try {
101
+ if ($model->getCreatedTime == NULL || $model->getUpdateTime() == NULL) {
102
+ $model->setCreatedTime(now())
103
+ ->setUpdateTime(now());
104
+ } else {
105
+ $model->setUpdateTime(now());
106
+ }
107
+
108
+ $model->save();
109
+
110
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('meetmyteam')->__('Item was successfully saved'));
111
+ Mage::getSingleton('adminhtml/session')->setFormData(false);
112
+
113
+ if ($this->getRequest()->getParam('back')) {
114
+ $this->_redirect('*/*/edit', array('id' => $model->getId()));
115
+ return;
116
+ }
117
+ $this->_redirect('*/*/');
118
+ return;
119
+ } catch (Exception $e) {
120
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
121
+ Mage::getSingleton('adminhtml/session')->setFormData($data);
122
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
123
+ return;
124
+ }
125
+ }
126
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('meetmyteam')->__('Unable to find item to save'));
127
+ $this->_redirect('*/*/');
128
+ }
129
+
130
+ public function deleteAction() {
131
+ if( $this->getRequest()->getParam('id') > 0 ) {
132
+ try {
133
+ $model = Mage::getModel('meetmyteam/meetmyteam');
134
+
135
+ $model->setId($this->getRequest()->getParam('id'))
136
+ ->delete();
137
+
138
+ Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully deleted'));
139
+ $this->_redirect('*/*/');
140
+ } catch (Exception $e) {
141
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
142
+ $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
143
+ }
144
+ }
145
+ $this->_redirect('*/*/');
146
+ }
147
+
148
+ public function massDeleteAction() {
149
+ $meetmyteamIds = $this->getRequest()->getParam('meetmyteam');
150
+ if(!is_array($meetmyteamIds)) {
151
+ Mage::getSingleton('adminhtml/session')->addError(Mage::helper('adminhtml')->__('Please select item(s)'));
152
+ } else {
153
+ try {
154
+ foreach ($meetmyteamIds as $meetmyteamId) {
155
+ $meetmyteam = Mage::getModel('meetmyteam/meetmyteam')->load($meetmyteamId);
156
+ $meetmyteam->delete();
157
+ }
158
+ Mage::getSingleton('adminhtml/session')->addSuccess(
159
+ Mage::helper('adminhtml')->__(
160
+ 'Total of %d record(s) were successfully deleted', count($meetmyteamIds)
161
+ )
162
+ );
163
+ } catch (Exception $e) {
164
+ Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
165
+ }
166
+ }
167
+ $this->_redirect('*/*/index');
168
+ }
169
+
170
+ public function massStatusAction()
171
+ {
172
+ $meetmyteamIds = $this->getRequest()->getParam('meetmyteam');
173
+ if(!is_array($meetmyteamIds)) {
174
+ Mage::getSingleton('adminhtml/session')->addError($this->__('Please select item(s)'));
175
+ } else {
176
+ try {
177
+ foreach ($meetmyteamIds as $meetmyteamId) {
178
+ $meetmyteam = Mage::getSingleton('meetmyteam/meetmyteam')
179
+ ->load($meetmyteamId)
180
+ ->setStatus($this->getRequest()->getParam('status'))
181
+ ->setIsMassupdate(true)
182
+ ->save();
183
+ }
184
+ $this->_getSession()->addSuccess(
185
+ $this->__('Total of %d record(s) were successfully updated', count($meetmyteamIds))
186
+ );
187
+ } catch (Exception $e) {
188
+ $this->_getSession()->addError($e->getMessage());
189
+ }
190
+ }
191
+ $this->_redirect('*/*/index');
192
+ }
193
+
194
+ public function exportCsvAction()
195
+ {
196
+ $fileName = 'meetmyteam.csv';
197
+ $content = $this->getLayout()->createBlock('meetmyteam/adminhtml_meetmyteam_grid')
198
+ ->getCsv();
199
+
200
+ $this->_sendUploadResponse($fileName, $content);
201
+ }
202
+
203
+ public function exportXmlAction()
204
+ {
205
+ $fileName = 'meetmyteam.xml';
206
+ $content = $this->getLayout()->createBlock('meetmyteam/adminhtml_meetmyteam_grid')
207
+ ->getXml();
208
+
209
+ $this->_sendUploadResponse($fileName, $content);
210
+ }
211
+
212
+ protected function _sendUploadResponse($fileName, $content, $contentType='application/octet-stream')
213
+ {
214
+ $response = $this->getResponse();
215
+ $response->setHeader('HTTP/1.1 200 OK','');
216
+ $response->setHeader('Pragma', 'public', true);
217
+ $response->setHeader('Cache-Control', 'must-revalidate, post-check=0, pre-check=0', true);
218
+ $response->setHeader('Content-Disposition', 'attachment; filename='.$fileName);
219
+ $response->setHeader('Last-Modified', date('r'));
220
+ $response->setHeader('Accept-Ranges', 'bytes');
221
+ $response->setHeader('Content-Length', strlen($content));
222
+ $response->setHeader('Content-type', $contentType);
223
+ $response->setBody($content);
224
+ $response->sendResponse();
225
+ die;
226
+ }
227
+ }
app/code/local/SKJ/Meetmyteam/controllers/IndexController.php ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * @category SKJ
4
+ * @package SKJ_Meetmyteam
5
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
6
+ * @website http://www.sanjeevkumarjha.com.np
7
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
8
+ */
9
+ class SKJ_Meetmyteam_IndexController extends Mage_Core_Controller_Front_Action
10
+ {
11
+ public function indexAction()
12
+ {
13
+ $this->loadLayout();
14
+ $this->renderLayout();
15
+ }
16
+
17
+ public function detailAction()
18
+ {
19
+ $this->loadLayout();
20
+ $this->renderLayout();
21
+ }
22
+
23
+ public function categoryAction()
24
+ {
25
+ $this->loadLayout();
26
+ $this->renderLayout();
27
+ }
28
+
29
+
30
+ }
app/code/local/SKJ/Meetmyteam/etc/config.xml ADDED
@@ -0,0 +1,146 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * @category SKJ
5
+ * @package SKJ_Meetmyteam
6
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
7
+ * @website http://www.sanjeevkumarjha.com.np
8
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
9
+ */
10
+ -->
11
+ <config>
12
+ <modules>
13
+ <SKJ_Meetmyteam>
14
+ <version>0.1.1</version>
15
+ </SKJ_Meetmyteam>
16
+ </modules>
17
+ <frontend>
18
+ <routers>
19
+ <meetmyteam>
20
+ <use>standard</use>
21
+ <args>
22
+ <module>SKJ_Meetmyteam</module>
23
+ <frontName>meetmyteam</frontName>
24
+ </args>
25
+ </meetmyteam>
26
+ </routers>
27
+ <layout>
28
+ <updates>
29
+ <meetmyteam>
30
+ <file>meetmyteam.xml</file>
31
+ </meetmyteam>
32
+ </updates>
33
+ </layout>
34
+ </frontend>
35
+ <admin>
36
+ <routers>
37
+ <meetmyteam>
38
+ <use>admin</use>
39
+ <args>
40
+ <module>SKJ_Meetmyteam</module>
41
+ <frontName>meetmyteam</frontName>
42
+ </args>
43
+ </meetmyteam>
44
+ </routers>
45
+ </admin>
46
+ <adminhtml>
47
+ <menu>
48
+ <meetmyteam module="meetmyteam">
49
+ <title>My Team</title>
50
+ <sort_order>71</sort_order>
51
+ <children>
52
+ <items module="meetmyteam">
53
+ <title>Manage Member</title>
54
+ <sort_order>0</sort_order>
55
+ <action>meetmyteam/adminhtml_meetmyteam</action>
56
+ </items>
57
+ <cat module="meetmyteam">
58
+ <title>Manage category</title>
59
+ <sort_order>0</sort_order>
60
+ <action>meetmyteam/adminhtml_category</action>
61
+ </cat>
62
+ </children>
63
+ </meetmyteam>
64
+ </menu>
65
+ <acl>
66
+ <resources>
67
+ <admin>
68
+ <children>
69
+ <meetmyteam module="meetmyteam">
70
+ <title>Meetmyteam</title>
71
+ <sort_order>71</sort_order>
72
+ <children>
73
+ <items module="meetmyteam">
74
+ <title>Manage Member</title>
75
+ <sort_order>0</sort_order>
76
+ <action>meetmyteam/adminhtml_meetmyteam</action>
77
+ </items>
78
+ <cat module="meetmyteam">
79
+ <title>Manage category</title>
80
+ <sort_order>0</sort_order>
81
+ <action>meetmyteam/adminhtml_category</action>
82
+ </cat>
83
+ </children>
84
+ </meetmyteam>
85
+ </children>
86
+ </admin>
87
+ </resources>
88
+ </acl>
89
+ <layout>
90
+ <updates>
91
+ <meetmyteam>
92
+ <file>meetmyteam.xml</file>
93
+ </meetmyteam>
94
+ </updates>
95
+ </layout>
96
+ </adminhtml>
97
+ <global>
98
+ <models>
99
+ <meetmyteam>
100
+ <class>SKJ_Meetmyteam_Model</class>
101
+ <resourceModel>meetmyteam_mysql4</resourceModel>
102
+ </meetmyteam>
103
+ <meetmyteam_mysql4>
104
+ <class>SKJ_Meetmyteam_Model_Mysql4</class>
105
+ <entities>
106
+ <meetmyteam>
107
+ <table>meetmyteam</table>
108
+ </meetmyteam>
109
+ <category>
110
+ <table>meetmyteam_cat</table>
111
+ </category>
112
+ </entities>
113
+ </meetmyteam_mysql4>
114
+ </models>
115
+ <resources>
116
+ <meetmyteam_setup>
117
+ <setup>
118
+ <module>SKJ_Meetmyteam</module>
119
+ </setup>
120
+ <connection>
121
+ <use>core_setup</use>
122
+ </connection>
123
+ </meetmyteam_setup>
124
+ <meetmyteam_write>
125
+ <connection>
126
+ <use>core_write</use>
127
+ </connection>
128
+ </meetmyteam_write>
129
+ <meetmyteam_read>
130
+ <connection>
131
+ <use>core_read</use>
132
+ </connection>
133
+ </meetmyteam_read>
134
+ </resources>
135
+ <blocks>
136
+ <meetmyteam>
137
+ <class>SKJ_Meetmyteam_Block</class>
138
+ </meetmyteam>
139
+ </blocks>
140
+ <helpers>
141
+ <meetmyteam>
142
+ <class>SKJ_Meetmyteam_Helper</class>
143
+ </meetmyteam>
144
+ </helpers>
145
+ </global>
146
+ </config>
app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-install-0.1.0.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ $installer = $this;
4
+
5
+ $installer->startSetup();
6
+
7
+ $installer->run("
8
+
9
+ -- DROP TABLE IF EXISTS {$this->getTable('meetmyteam')};
10
+ CREATE TABLE {$this->getTable('meetmyteam')} (
11
+ `meetmyteam_id` int(11) unsigned NOT NULL auto_increment,
12
+ `title` varchar(255) NOT NULL default '',
13
+ `filename` varchar(255) NOT NULL default '',
14
+ `category` int(11) NOT NULL default '0',
15
+ `content` text NOT NULL default '',
16
+ `description` text NOT NULL default '',
17
+ `status` smallint(6) NOT NULL default '0',
18
+ `created_time` datetime NULL,
19
+ `update_time` datetime NULL,
20
+ PRIMARY KEY (`meetmyteam_id`)
21
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
22
+
23
+ ");
24
+
25
+ $installer->endSetup();
app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-install-0.1.0.php~ ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ $installer = $this;
4
+
5
+ $installer->startSetup();
6
+
7
+ $installer->run("
8
+
9
+ -- DROP TABLE IF EXISTS {$this->getTable('meetmyteam')};
10
+ CREATE TABLE {$this->getTable('meetmyteam')} (
11
+ `meetmyteam_id` int(11) unsigned NOT NULL auto_increment,
12
+ `title` varchar(255) NOT NULL default '',
13
+ `filename` varchar(255) NOT NULL default '',
14
+ `category` int(11) NOT NULL default '',
15
+ `content` text NOT NULL default '',
16
+ `description` text NOT NULL default '',
17
+ `status` smallint(6) NOT NULL default '0',
18
+ `created_time` datetime NULL,
19
+ `update_time` datetime NULL,
20
+ PRIMARY KEY (`meetmyteam_id`)
21
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
22
+
23
+ ");
24
+
25
+ $installer->endSetup();
app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-upgrade-0.1.0-0.1.1.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /* @var $installer Mage_Core_Model_Resource_Setup */
4
+ $installer = $this;
5
+
6
+ $installer->startSetup();
7
+
8
+ $installer->run("
9
+
10
+ -- DROP TABLE IF EXISTS meetmyteam_cat;
11
+ CREATE TABLE meetmyteam_cat (
12
+ `meetmyteam_cat_id` int(11) unsigned NOT NULL auto_increment,
13
+ `title` varchar(255) NOT NULL default '',
14
+ `description` text NOT NULL default '',
15
+ `status` smallint(6) NOT NULL default '0',
16
+ `created_time` datetime NULL,
17
+ `update_time` datetime NULL,
18
+ PRIMARY KEY (`meetmyteam_cat_id`)
19
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
20
+
21
+ ");
22
+
23
+
24
+ $installer->endSetup();
app/code/local/SKJ/Meetmyteam/sql/meetmyteam_setup/mysql4-upgrade-0.1.0-0.1.1.php~ ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /* @var $installer Mage_Core_Model_Resource_Setup */
4
+ $installer = $this;
5
+
6
+ $installer->startSetup();
7
+
8
+ $installer->run("
9
+
10
+ -- DROP TABLE IF EXISTS meetmyteam_cat;
11
+ CREATE TABLE meetmyteam_cat (
12
+ `meetmyteam_cat_id` int(11) unsigned NOT NULL auto_increment,
13
+ `title` varchar(255) NOT NULL default '',
14
+ `status` smallint(6) NOT NULL default '0',
15
+ `created_time` datetime NULL,
16
+ `update_time` datetime NULL,
17
+ PRIMARY KEY (`meetmyteam_cat_id`)
18
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
19
+
20
+ ");
21
+
22
+
23
+ $installer->endSetup();
app/design/adminhtml/default/default/layout/meetmyteam.xml ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <layout version="0.1.0">
3
+ <meetmyteam_adminhtml_meetmyteam_index>
4
+ <reference name="content">
5
+ <block type="meetmyteam/adminhtml_meetmyteam" name="meetmyteam" />
6
+ </reference>
7
+ </meetmyteam_adminhtml_meetmyteam_index>
8
+ <meetmyteam_adminhtml_category_index>
9
+ <reference name="content">
10
+ <block type="meetmyteam/adminhtml_category" name="meetmyteam" />
11
+ </reference>
12
+ </meetmyteam_adminhtml_category_index>
13
+ </layout>
app/design/frontend/base/default/layout/meetmyteam.xml ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * @category SKJ
5
+ * @package SKJ_Meetmyteam
6
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
7
+ * @website http://www.sanjeevkumarjha.com.np
8
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
9
+ */
10
+ -->
11
+ <layout version="0.1.0">
12
+
13
+ <!-- Display list of category in left sidebar -->
14
+ <default>
15
+ <reference name="head">
16
+ <action method="addCss"><stylesheet>css/skj-myteam.css</stylesheet></action>
17
+ </reference>
18
+ <reference name="left">
19
+ <block type="meetmyteam/category" name="left.myteam" before="-" template="meetmyteam/category_box.phtml">
20
+ </block>
21
+ </reference>
22
+ </default>
23
+
24
+ <!-- Display member by category -->
25
+ <meetmyteam_index_category>
26
+ <reference name="root">
27
+ <action method="setTemplate"><template>page/2columns-left.phtml</template></action>
28
+ <!-- Mark root page block that template is applied -->
29
+ <action method="setIsHandle"><applied>1</applied></action>
30
+ </reference>
31
+ <reference name="content">
32
+ <block type="meetmyteam/category" name="meetmyteam" template="meetmyteam/category.phtml" />
33
+ </reference>
34
+ </meetmyteam_index_category>
35
+
36
+ <!-- Display all member -->
37
+ <meetmyteam_index_index>
38
+ <reference name="root">
39
+ <action method="setTemplate"><template>page/2columns-left.phtml</template></action>
40
+ <!-- Mark root page block that template is applied -->
41
+ <action method="setIsHandle"><applied>1</applied></action>
42
+ </reference>
43
+ <reference name="content">
44
+ <block type="meetmyteam/meetmyteam" name="meetmyteam" template="meetmyteam/meetmyteam.phtml" />
45
+ </reference>
46
+ </meetmyteam_index_index>
47
+
48
+ <!-- Display detail of member -->
49
+ <meetmyteam_index_detail>
50
+ <reference name="root">
51
+ <action method="setTemplate"><template>page/2columns-left.phtml</template></action>
52
+ <!-- Mark root page block that template is applied -->
53
+ <action method="setIsHandle"><applied>1</applied></action>
54
+ </reference>
55
+ <reference name="content">
56
+ <block type="meetmyteam/meetmyteam" name="meetmyteam" template="meetmyteam/detail.phtml" />
57
+ </reference>
58
+ </meetmyteam_index_detail>
59
+
60
+ </layout>
app/design/frontend/base/default/template/meetmyteam/category.phtml ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php $category = $this->getCategory(); ?>
2
+ <?php
3
+ // get breadcrumbs block
4
+ $breadcrumbs = $this->getLayout()->getBlock('breadcrumbs');
5
+ // add first item with link
6
+ $breadcrumbs->addCrumb(
7
+ 'home',
8
+ array(
9
+ 'label'=>$this->__('Home'),
10
+ 'title'=>$this->__('Home'),
11
+ 'link'=>Mage::getBaseUrl()
12
+ )
13
+ );
14
+
15
+ // add third item without link
16
+ $breadcrumbs->addCrumb(
17
+ 'unlink',
18
+ array(
19
+ 'label'=>$this->__($category->getTitle()),
20
+ 'title'=>$this->__($category->getTitle()),
21
+ )
22
+ );
23
+ echo $breadcrumbs->toHtml();
24
+ ?>
25
+
26
+ <div class="page-title">
27
+ <h1>
28
+ <?php echo $this->__($category->getTitle());
29
+ ?>
30
+ </h1>
31
+ </div>
32
+ <?php echo $this->__($category->getDescription()) ?>
33
+
34
+ <br/>
35
+
36
+ <?php
37
+ $collection = Mage::getModel('meetmyteam/meetmyteam')->getCollection();
38
+ $collection->addFieldToFilter('status',Array('eq'=>1));
39
+ $collection->addFieldToFilter('category',Array('eq'=>$category->getId()));
40
+
41
+ $size = $collection->getSize();
42
+
43
+ if($size>0){
44
+ ?>
45
+ <div>
46
+ <ul class="leader_not">
47
+ <?php
48
+ $url = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB);
49
+ $i = 0;
50
+ foreach ($collection as $item) {
51
+ $i = $i+1;
52
+ //$detailUrl = Mage::getUrl('meetmyteam/index/detail',array('id'=>$item->getId(),'cat_id'=>$item->getCategory()));
53
+ $detailUrl = Mage::getUrl('meetmyteam/index/detail',array('id'=>$item->getId()));
54
+ ?>
55
+
56
+ <li><span class="photo_section">
57
+ <a href="<?php echo $detailUrl; ?>"> <img height="170" width="150" border="0" title="<?php echo $item->getTitle(); ?>" alt="<?php echo $item->getTitle(); ?>" src="<?php echo $url.'media'.DS.$item->getFilename(); ?>"> </a>
58
+ </span>
59
+
60
+ <div class="title">
61
+ <?php echo $item->getTitle(); ?>
62
+ </div>
63
+
64
+ <div class="sub-heading"><?php echo $item->getDescription(); ?></div>
65
+
66
+ <div class="full-bio"><a href="<?php echo $detailUrl; ?>" class="links">View bio</a></div>
67
+ </li>
68
+
69
+
70
+ <?php
71
+ }
72
+ echo "</ul></div>";
73
+ }else{
74
+ echo "No any member in this group.";
75
+ }
76
+
77
+
app/design/frontend/base/default/template/meetmyteam/category_box.phtml ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php $categories = $this->getCategoryList();
2
+ $size = $categories->getSize();
3
+ if($size > 0):
4
+ ?>
5
+ <h4>
6
+ <?php echo $this->__('Team Member') ?>
7
+ </h4>
8
+ <ul>
9
+ <?php
10
+ foreach ($categories as $category) {
11
+ echo "<li>";
12
+ $detailUrl = Mage::getUrl('meetmyteam/index/category',array('id'=>$category->getMeetmyteamCatId()));
13
+ echo "<a href='".$detailUrl."'>".$category->getTitle()." </a>";
14
+ echo "</li>";
15
+ }
16
+ ?>
17
+ </ul>
18
+ <?php endif; ?>
app/design/frontend/base/default/template/meetmyteam/detail.phtml ADDED
@@ -0,0 +1,65 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ $id = Mage::app()->getRequest()->getParam('id');
3
+
4
+ $item = Mage::getModel('meetmyteam/meetmyteam')->load($id);
5
+ ?>
6
+ <?php
7
+ $category = Mage::getModel('meetmyteam/category')->load($item->getCategory());
8
+ ?>
9
+ <?php
10
+ $detailUrl = Mage::getUrl('meetmyteam/index/category',array('id'=>$item->getCategory()));
11
+ ?>
12
+ <?php
13
+ // get breadcrumbs block
14
+ $breadcrumbs = $this->getLayout()->getBlock('breadcrumbs');
15
+ // add first item with link
16
+ $breadcrumbs->addCrumb(
17
+ 'home',
18
+ array(
19
+ 'label'=>$this->__('Home'),
20
+ 'title'=>$this->__('Home'),
21
+ 'link'=>Mage::getBaseUrl()
22
+ )
23
+ );
24
+
25
+
26
+ $breadcrumbs->addCrumb(
27
+ 'category',
28
+ array(
29
+ 'label'=> $this->__($category->getTitle()),
30
+ 'title'=> $this->__($category->getTitle()),
31
+ 'link'=> $detailUrl
32
+ )
33
+ );
34
+
35
+ // add third item without link
36
+ $breadcrumbs->addCrumb(
37
+ 'unlink',
38
+ array(
39
+ 'label'=>$this->__($item->getTitle()),
40
+ 'title'=>$this->__($item->getTitle()),
41
+ )
42
+ );
43
+ echo $breadcrumbs->toHtml();
44
+ ?>
45
+ <div class="meetmyteam-detail">
46
+ <?php
47
+ $url = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB);
48
+ echo "<img width='250px' height='250px' title='". $item->getTitle() ."' alt='". $item->getTitle() ."' src='".$url."media".DS.$item->getFilename()."'/>";
49
+ echo "<h4> ".$item->getTitle()."</h4>";
50
+
51
+ echo "<h6>";
52
+ echo $item->getDescription();
53
+ echo "</h6>";
54
+ echo "<p>";
55
+ echo $item->getContent();
56
+ echo "</p>";
57
+
58
+ ?>
59
+
60
+ </div>
61
+
62
+ <a class="detail-back" href="<?php echo $detailUrl; ?>">&lt; Back </a><br/>
63
+
64
+
65
+
app/design/frontend/base/default/template/meetmyteam/meetmyteam.phtml ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <span class="myteam-head">
2
+ <h4>
3
+ <?php echo $this->__('My Team') ?>
4
+ </h4>
5
+ </span>
6
+ <?php
7
+ $collection = $this->getAllMembers();
8
+
9
+ $size = $collection->getSize();
10
+
11
+ if($size>0){
12
+ ?>
13
+ <div>
14
+ <ul class="leader_not">
15
+ <?php
16
+ $url = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB);
17
+ foreach ($collection as $item) {
18
+ $i = $i+1;
19
+ //$detailUrl = Mage::getUrl('meetmyteam/index/detail',array('id'=>$item->getId(),'cat_id'=>$item->getCategory()));
20
+ $detailUrl = Mage::getUrl('meetmyteam/index/detail',array('id'=>$item->getId()));
21
+ ?>
22
+
23
+ <li><span class="photo_section">
24
+ <a href="<?php echo $detailUrl; ?>"> <img height="170" width="150" border="0" title="<?php echo $item->getTitle(); ?>" alt="<?php echo $item->getTitle(); ?>" src="<?php echo $url.'media'.DS.$item->getFilename(); ?>"> </a>
25
+ </span>
26
+
27
+ <div class="title">
28
+ <?php echo $item->getTitle(); ?>
29
+ </div>
30
+
31
+ <div class="sub-heading"><?php echo $item->getDescription(); ?></div>
32
+
33
+ <div class="full-bio"><a href="<?php echo $detailUrl; ?>" class="links">View bio</a></div>
34
+ </li>
35
+
36
+
37
+ <?php
38
+ }
39
+ echo "</ul></div>";
40
+ }else{
41
+ echo "No any member in this group.";
42
+ }
43
+
44
+
app/etc/modules/SKJ_Meetmyteam.xml ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <config>
3
+ <modules>
4
+ <SKJ_Meetmyteam>
5
+ <active>true</active>
6
+ <codePool>local</codePool>
7
+ </SKJ_Meetmyteam>
8
+ </modules>
9
+ </config>
package.xml ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>SKJ_Meetmyteam</name>
4
+ <version>0.1.1</version>
5
+ <stability>stable</stability>
6
+ <license uri="http://opensource.org/licenses/osl-3.0.php">version OSL v3.0</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>Team Management is easy to display your team members for each team member group.</summary>
10
+ <description>Team Management is easy to display your team members for each team member group.&#xD;
11
+ &#xD;
12
+ Features include:&#xD;
13
+ &#xD;
14
+ Easily see team member information - You can easily see a list of everyone on the team including their name, designation, biography and profile picture of each member.&#xD;
15
+ &#xD;
16
+ Find Who&#x2019;s On Each member group - You can see a complete list of every member on the team.</description>
17
+ <notes>First Release</notes>
18
+ <authors><author><name>Sanjeev Kumar Jha</name><user>sakjha10</user><email>jha.sanjeev.in@gmail.com</email></author></authors>
19
+ <date>2015-06-25</date>
20
+ <time>18:18:00</time>
21
+ <contents><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="skj-myteam.css" hash="8800d4c322e00307bacd514e94b49e70"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="SKJ_Meetmyteam.xml" hash="ff5636717a2f26da2e81845e51e9ab27"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="meetmyteam"><file name="category.phtml" hash="086d5c633bf786cbf7b56c0fdc140488"/><file name="category_box.phtml" hash="1e91b374b5143206929923020912c50b"/><file name="detail.phtml" hash="f76eb81b2ed255acdaeb66bbb306354c"/><file name="meetmyteam.phtml" hash="2ce1ef278c791d1c8e1a775d6b895403"/></dir></dir><dir name="layout"><file name="meetmyteam.xml" hash="ad62f3d727a7e9e4e91e018dde0fc7d3"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="meetmyteam.xml" hash="43133958343482f9e62c66ba03d59726"/></dir></dir></dir></dir></target><target name="magelocal"><dir name="SKJ"><dir name="Meetmyteam"><dir name="Block"><dir name="Adminhtml"><dir name="Category"><dir name="Edit"><file name="Form.php" hash="a0e4afc0acb0349e52b0a2e1100d2314"/><dir name="Tab"><file name="Form.php" hash="57c7b71cf4342b947bbde551406686ed"/></dir><file name="Tabs.php" hash="7bbbdeca0cf30b377dc10eea06eced06"/></dir><file name="Edit.php" hash="469c1fc9633341aa5a2fd11a82758bf5"/><file name="Grid.php" hash="f3a133ad26dbdd77780144128aec6c2f"/></dir><file name="Category.php" hash="24b703d87e3970378611845596917d5b"/><dir name="Meetmyteam"><dir name="Edit"><file name="Form.php" hash="f35c94d92186fcd95d035cd208e7bc0b"/><dir name="Tab"><file name="Form.php" hash="f90e91e958caa5695f5bb2bb14ffe267"/></dir><file name="Tabs.php" hash="8999f697d85b668a66aa1c903b449c83"/></dir><file name="Edit.php" hash="4618091f20e4870e7f2d004ac68694d4"/><file name="Grid.php" hash="4e773a5229723c568d3b3eae12b2b329"/></dir><file name="Meetmyteam.php" hash="eda38dc3b3f8541fce6e57c9054cb6ce"/><dir name="Renderer"><file name="Image.php" hash="2a05f442d666879dcc123448f54d921e"/><file name="Preview.php" hash="8171809bd2a1a87b9fd3f52759448ed2"/></dir></dir><file name="Category.php" hash="60862ed334ffe34e236ae108f5c3b044"/><file name="Meetmyteam.php" hash="bcbcd05a310377706642ec02bf1e441a"/></dir><dir name="Helper"><file name="Data.php" hash="c243bcb9a48f889fc56497417da21bec"/></dir><dir name="Model"><file name="Category.php" hash="4cd23ce3b0b8204e7cb8e0b8a4ce26be"/><file name="Meetmyteam.php" hash="2bdb9919636eae66a2e97e7a106ebb52"/><dir name="Mysql4"><dir name="Category"><file name="Collection.php" hash="f2626f19f54975660aec9b1fc85f0dd0"/></dir><file name="Category.php" hash="b2378c476d8170df691745374068c914"/><dir name="Meetmyteam"><file name="Collection.php" hash="a6d4943bb60fa57d97dcbb58ce4629f2"/></dir><file name="Meetmyteam.php" hash="cf3d49b3e8861d40fbad764ba61f2707"/></dir><file name="Status.php" hash="bd8e2ed3300c4b8e940b6a529d5832e8"/><dir name="Wysiwyg"><file name="Config.php" hash="6e8364d8f1df6b715e9eb88ca42c1859"/><file name="Config.php~" hash="c086f047a6e8a05b7693e262594dfa21"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="CategoryController.php" hash="822e9120b3ce65897d970e879a78d859"/><file name="MeetmyteamController.php" hash="0edd1d3aff489df94c2fc28eb96099c6"/></dir><file name="IndexController.php" hash="93838a98b19a1246f631a3c6664216ae"/></dir><dir name="etc"><file name="config.xml" hash="c2d12310e9b16b73870174d05af63ea7"/></dir><dir name="sql"><dir name="meetmyteam_setup"><file name="mysql4-install-0.1.0.php" hash="4cb218488da3fa7e18b78190da3f384c"/><file name="mysql4-install-0.1.0.php~" hash="d33cd35f49046d260ad5cca71caa7761"/><file name="mysql4-upgrade-0.1.0-0.1.1.php" hash="d4b68bd4ecbb6b0877111a9291530d89"/><file name="mysql4-upgrade-0.1.0-0.1.1.php~" hash="d9755bb560aedd0899f3699df562dfd3"/></dir></dir></dir></dir></target></contents>
22
+ <compatible/>
23
+ <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
24
+ </package>
skin/frontend/base/default/css/skj-myteam.css ADDED
@@ -0,0 +1,120 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * css for my team
3
+ *
4
+ *
5
+ * @category SKJ
6
+ * @package SKJ_Meetmyteam
7
+ * @author Sanjeev Kumar Jha <jha.sanjeev.in@gmail.com>
8
+ */
9
+
10
+ /*======================Meet my team========================*/
11
+ .leader_not {
12
+ float: left;
13
+ width: 100%;
14
+ margin-top: 20px;
15
+ text-align: center;
16
+ margin-left: -20px;
17
+ }
18
+ .leader_not li {
19
+ float:left;
20
+ margin-left: 20px;
21
+ margin-bottom: 20px;
22
+ padding: 4px;
23
+ background-color: #fff;
24
+ border: 1px solid #ccc;
25
+ border: 1px solid rgba(0, 0, 0, 0.2);
26
+ -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
27
+ -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
28
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
29
+ }
30
+ .photo_section {
31
+
32
+ width: 100%;
33
+ margin-bottom: 10px;
34
+ display:block;
35
+ }
36
+ .photo_section img {
37
+ max-height: 170px;
38
+ max-width:150px;
39
+ }
40
+ .full-bio .links {
41
+ float:none;
42
+ }
43
+ .meetmyteam-detail {
44
+ float: left;
45
+ width: 100%;
46
+ margin-top: 30px;
47
+ }
48
+
49
+
50
+
51
+ .meetmyteam-detail img {
52
+ float: left;
53
+ margin: 0 20px 0 0;
54
+ padding: 4px;
55
+ background-color: #fff;
56
+ border: 1px solid #ccc;
57
+ border: 1px solid rgba(0, 0, 0, 0.2);
58
+ -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
59
+ -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
60
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
61
+ }
62
+ .meetmyteam-detail p {
63
+ font-size: 14px;
64
+ line-height: 24px;
65
+ }
66
+ .detail-back {
67
+ color: #fff !important;
68
+ text-transform: uppercase;
69
+ display: block;
70
+ background: #10578d;
71
+ text-decoration:none;
72
+ font-family: 'open_sanssemibold';
73
+ font-size: 16px;
74
+ padding: 8px 9px;
75
+ font-style: normal;
76
+ float:right;
77
+ }
78
+ .detail-back:hover {
79
+ background: #36987c;
80
+ color: #fff !important;
81
+ }
82
+ .detail-back-rb {
83
+ color: #fff !important;
84
+ text-transform: uppercase;
85
+ display: block;
86
+ background: #36987c;
87
+
88
+ font-family: 'open_sanssemibold';
89
+ font-size: 16px;
90
+ padding: 8px 9px;
91
+ font-style: normal;
92
+ float:right;
93
+ position:relative;
94
+ top:-50px;
95
+ }
96
+ .detail-back-rb:hover {
97
+ background: #10578d;
98
+ color: #fff !important;
99
+ }
100
+
101
+
102
+
103
+ .myteam-head {
104
+ padding-top: 30px;
105
+ }
106
+
107
+ .full-bio{padding: 7px 0px;}
108
+
109
+ .full-bio a{ color:#36987c;}
110
+ .full-bio a:hover{ color:#3d6277;}
111
+
112
+
113
+
114
+ .leader_not .title{ font-family:Georgia, "Times New Roman", Times, serif; font-style:italic; color:#3d6277;}
115
+
116
+ .leader_not .sub-heading{ font-size:13px;}
117
+
118
+ .meetmyteam-detail img{ width:250px; height:283px;}
119
+
120
+