Website1service_RemoveNews - Version 1.0.0

Version Notes

This version is properly tested on the following Magento CE versions: 1.8, 1.8.1.0, 1.9

Download this release

Release Info

Developer SpaceLight
Extension Website1service_RemoveNews
Version 1.0.0
Comparing to
See all releases


Version 1.0.0

app/code/community/Website1service/RemoveNews/Block/Adminhtml/Newsletter/Deletenews.php ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Adminhtml newsletter templates grid block action item renderer
4
+ *
5
+ * @Info Free Extension
6
+ * @Feature Add Delete action to the drop down list
7
+ * @author Website1service.com
8
+ */
9
+
10
+ class Website1service_RemoveNews_Block_Adminhtml_Newsletter_Deletenews extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Action
11
+ {
12
+
13
+
14
+ public function render(Varien_Object $row)
15
+ {
16
+ if($row->isValidForSend()) {
17
+ $actions[] = array(
18
+ 'url' => $this->getUrl('*/newsletter_queue/edit', array('template_id' => $row->getId())),
19
+ 'caption' => Mage::helper('newsletter')->__('Queue Newsletter...')
20
+ );
21
+ }
22
+
23
+ $actions[] = array(
24
+ 'url' => $this->getUrl('*/*/preview', array('id'=>$row->getId())),
25
+ 'popup' => true,
26
+ 'caption' => Mage::helper('newsletter')->__('Preview')
27
+ );
28
+ //MP add the delete action
29
+ $actions[] = array(
30
+ 'url' => $this->getUrl('*/newsletter_template/delete', array('id'=>$row->getId())),
31
+ 'caption' => Mage::helper('newsletter')->__('Delete')
32
+ );
33
+
34
+ $this->getColumn()->setActions($actions);
35
+
36
+ return parent::render($row);
37
+ }
38
+
39
+ }
app/code/community/Website1service/RemoveNews/etc/config.xml ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <config>
3
+ <modules>
4
+ <Website1service_RemoveNews>
5
+ <version>1.0.0</version>
6
+ </Website1service_RemoveNews>
7
+ </modules>
8
+ <global>
9
+ <blocks>
10
+ <adminhtml>
11
+ <rewrite>
12
+ <newsletter_template_grid_renderer_action>Website1service_RemoveNews_Block_Adminhtml_Newsletter_Deletenews</newsletter_template_grid_renderer_action>
13
+ </rewrite>
14
+ </adminhtml>
15
+ </blocks>
16
+ </global>
17
+ <stores>
18
+ <admin>
19
+ <!-- default admin design package and theme -->
20
+ <design>
21
+ <package>
22
+ <name>default</name>
23
+ </package>
24
+ <theme>
25
+ <!-- possible change for your own theme-->
26
+ <default>default</default>
27
+ </theme>
28
+ </design>
29
+ </admin>
30
+ </stores>
31
+ </config>
app/etc/modules/Website1service_RemoveNews.xml ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <config>
3
+ <modules>
4
+ <Website1service_RemoveNews>
5
+ <active>true</active>
6
+ <codePool>community</codePool>
7
+ </Website1service_RemoveNews>
8
+ </modules>
9
+ </config>
package.xml ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>Website1service_RemoveNews</name>
4
+ <version>1.0.0</version>
5
+ <stability>stable</stability>
6
+ <license>OSL v3.0</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>This extension allows you to delete the newsletter templates in your admin panel.</summary>
10
+ <description>Magento doesn't allow you to delete newsletter template. You can only mark it to queue or preview but you can't delete it. This extension allows you to seamlessly delete any newsletter template and the newsletter queue in the same time. You will just have to select the drop down action "Delete" to remove completely from the database your newsletter&#xD;
11
+ </description>
12
+ <notes>This version is properly tested on the following Magento CE versions: 1.8, 1.8.1.0, 1.9&#xD;
13
+ </notes>
14
+ <authors><author><name>SpaceLight</name><user>Website1service</user><email>magento-dev@website1service.com</email></author></authors>
15
+ <date>2014-09-26</date>
16
+ <time>08:51:46</time>
17
+ <contents><target name="mageetc"><dir name="modules"><file name="Website1service_RemoveNews.xml" hash="c464c9125a9e4d5a5c2e5eed093d870b"/></dir></target><target name="magecommunity"><dir name="Website1service"><dir name="RemoveNews"><dir name="Block"><dir name="Adminhtml"><dir name="Newsletter"><file name="Deletenews.php" hash="78a085a94d37748755577c443d9e2bcd"/></dir></dir></dir><dir name="etc"><file name="config.xml" hash="a8e2497b834411cc134d1e69da2740ba"/></dir></dir></dir></target></contents>
18
+ <compatible/>
19
+ <dependencies><required><php><min>5.2.0</min><max>5.5.12</max></php></required></dependencies>
20
+ </package>