VS_Viewproduct - Version 1.0.0

Version Notes

When you are editing some product in Magento admin and want to check it out in frontend of your Magento project. The easiest way to get to your desired product in the frontend – view product link.

Download this release

Release Info

Developer Magento Core Team
Extension VS_Viewproduct
Version 1.0.0
Comparing to
See all releases


Version 1.0.0

app/code/community/VS/Viewproduct/Block/Adminhtml/Catalog/Product/Edit.php ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ class VS_Viewproduct_Block_Adminhtml_Catalog_Product_Edit extends Mage_Adminhtml_Block_Catalog_Product_Edit
3
+ {
4
+
5
+ public function getHeader()
6
+ {
7
+ $header = parent::getHeader();
8
+
9
+ if(Mage::getStoreConfig('viewproduct/general/enabled')){
10
+ if ($this->getProduct()->getId()) {
11
+ $url = $this->getProduct()->getUrlInStore();
12
+ $header .= "&nbsp&nbsp<a href='$url' target='_blank'>view product</a>";
13
+ }
14
+ }
15
+ return $header;
16
+ }
17
+
18
+ }
app/code/community/VS/Viewproduct/etc/config.xml ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <config>
3
+ <modules>
4
+ <VS_Viewproduct>
5
+ <version>1.6.0.0</version>
6
+ </VS_Viewproduct>
7
+ </modules>
8
+
9
+ <global>
10
+ <blocks>
11
+ <adminhtml>
12
+ <rewrite>
13
+ <catalog_product_edit>VS_Viewproduct_Block_Adminhtml_Catalog_Product_Edit</catalog_product_edit>
14
+ </rewrite>
15
+ </adminhtml>
16
+ </blocks>
17
+ </global>
18
+ <adminhtml>
19
+ <acl>
20
+ <resources>
21
+ <admin>
22
+ <children>
23
+ <system>
24
+ <children>
25
+ <config>
26
+ <children>
27
+ <viewproduct translate="title" module="viewproduct">
28
+ <title>View Product</title>
29
+ </viewproduct>
30
+ </children>
31
+ </config>
32
+ </children>
33
+ </system>
34
+ </children>
35
+ </admin>
36
+ </resources>
37
+ </acl>
38
+ </adminhtml>
39
+ </config>
app/code/community/VS/Viewproduct/etc/system.xml ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+
3
+ <config>
4
+ <tabs>
5
+ <vs_extensions>
6
+ <label>VS Extensions</label>
7
+ <sort_order>195</sort_order>
8
+ </vs_extensions>
9
+ </tabs>
10
+ <sections>
11
+ <viewproduct translate="label" >
12
+ <label>View Product From Backend</label>
13
+ <tab>vs_extensions</tab>
14
+ <frontend_type>text</frontend_type>
15
+ <sort_order>90</sort_order>
16
+ <show_in_default>1</show_in_default>
17
+ <show_in_website>1</show_in_website>
18
+ <show_in_store>1</show_in_store>
19
+ <groups>
20
+ <general translate="label">
21
+ <label>Settings</label>
22
+ <frontend_type>text</frontend_type>
23
+ <sort_order>1</sort_order>
24
+ <show_in_default>1</show_in_default>
25
+ <show_in_website>1</show_in_website>
26
+ <show_in_store>1</show_in_store>
27
+ <fields>
28
+ <enabled translate="label">
29
+ <label>Enabled</label>
30
+ <frontend_type>select</frontend_type>
31
+ <source_model>adminhtml/system_config_source_yesno</source_model>
32
+ <sort_order>1</sort_order>
33
+ <show_in_default>1</show_in_default>
34
+ <show_in_website>1</show_in_website>
35
+ <show_in_store>1</show_in_store>
36
+ </enabled>
37
+ </fields>
38
+ </general>
39
+
40
+ </groups>
41
+
42
+ </viewproduct>
43
+ </sections>
44
+ </config>
app/etc/modules/VS_Viewproduct.xml ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <config>
3
+ <modules>
4
+ <VS_Viewproduct>
5
+ <active>true</active>
6
+ <codePool>community</codePool>
7
+ <depends>
8
+ <Mage_Adminhtml/>
9
+ </depends>
10
+ </VS_Viewproduct>
11
+ </modules>
12
+ </config>
package.xml ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>VS_Viewproduct</name>
4
+ <version>1.0.0</version>
5
+ <stability>stable</stability>
6
+ <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>When you are editing some product in Magento admin and want to check it out in frontend of your Magento project. The easiest way to get to your desired product in the frontend &#x2013; view product link.</summary>
10
+ <description>When you are editing some product in Magento admin and want to check it out in frontend of your Magento project. The easiest way to get to your desired product in the frontend &#x2013; view product link.</description>
11
+ <notes>When you are editing some product in Magento admin and want to check it out in frontend of your Magento project. The easiest way to get to your desired product in the frontend &#x2013; view product link.</notes>
12
+ <authors><author><name>virendra kumar sharma</name><user>auto-converted</user><email>bhardwajveerendra@gmail.com</email></author></authors>
13
+ <date>2012-05-08</date>
14
+ <time>12:35:55</time>
15
+ <contents><target name="magecommunity"><dir name="VS"><dir name="Viewproduct"><dir name="Block"><dir name="Adminhtml"><dir name="Catalog"><dir name="Product"><file name="Edit.php" hash="960b6cc7553ea8d8a22b4bd3ca8614d7"/></dir></dir></dir></dir><dir name="etc"><file name="config.xml" hash="326f0aa80bc13acf55544b2293729b85"/><file name="system.xml" hash="31e89d5dbb0b1c2f10e35d21dbb1a253"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="VS_Viewproduct.xml" hash="8f0725a2d6f96c1c56bdad77b0128712"/></dir></target></contents>
16
+ <compatible/>
17
+ <dependencies/>
18
+ </package>