Version Notes
Installation steps
Download this release
Release Info
| Developer | Niveus Solutions |
| Extension | Niveus_ProductVideo |
| Version | 1.5.0 |
| Comparing to | |
| See all releases | |
Code changes from version 1.4.0 to 1.5.0
app/code/community/Niveus/ProductVideo/Model/Observer.php
CHANGED
|
@@ -20,22 +20,29 @@ class Niveus_ProductVideo_Model_Observer
|
|
| 20 |
{
|
| 21 |
$product = $observer->getProduct();
|
| 22 |
|
| 23 |
-
$
|
| 24 |
-
->
|
| 25 |
-
|
| 26 |
-
->addFieldToFilter('store_id', $product->getStoreId());
|
| 27 |
|
| 28 |
-
|
| 29 |
{
|
| 30 |
-
|
| 31 |
-
|
|
|
|
|
|
|
| 32 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
|
| 34 |
// Video 1
|
| 35 |
|
| 36 |
-
|
| 37 |
$model = Mage::getModel('productvideo/videos');
|
| 38 |
|
|
|
|
| 39 |
try
|
| 40 |
{
|
| 41 |
|
|
@@ -56,7 +63,7 @@ class Niveus_ProductVideo_Model_Observer
|
|
| 56 |
|
| 57 |
// Video 2
|
| 58 |
|
| 59 |
-
|
| 60 |
$model = Mage::getModel('productvideo/videos');
|
| 61 |
try
|
| 62 |
{
|
|
@@ -76,7 +83,7 @@ class Niveus_ProductVideo_Model_Observer
|
|
| 76 |
|
| 77 |
// Video 3
|
| 78 |
|
| 79 |
-
|
| 80 |
$model = Mage::getModel('productvideo/videos');
|
| 81 |
try
|
| 82 |
{
|
| 20 |
{
|
| 21 |
$product = $observer->getProduct();
|
| 22 |
|
| 23 |
+
$video1 = $this->_getRequest()->getPost('video1');
|
| 24 |
+
$video2 = $this->_getRequest()->getPost('video2');
|
| 25 |
+
$video3 = $this->_getRequest()->getPost('video3');
|
|
|
|
| 26 |
|
| 27 |
+
if((!is_null($video1) || isset($video1)) && (!is_null($video2) || isset($video2)) && (!is_null($video3) || isset($video3)))
|
| 28 |
{
|
| 29 |
+
$videos = Mage::getModel('productvideo/videos')
|
| 30 |
+
->getCollection()
|
| 31 |
+
->addFieldToFilter('product_id', $product->getId())
|
| 32 |
+
->addFieldToFilter('store_id', $product->getStoreId());
|
| 33 |
|
| 34 |
+
foreach ($videos as $video)
|
| 35 |
+
{
|
| 36 |
+
$video->delete();
|
| 37 |
+
}
|
| 38 |
+
}
|
| 39 |
|
| 40 |
// Video 1
|
| 41 |
|
| 42 |
+
|
| 43 |
$model = Mage::getModel('productvideo/videos');
|
| 44 |
|
| 45 |
+
|
| 46 |
try
|
| 47 |
{
|
| 48 |
|
| 63 |
|
| 64 |
// Video 2
|
| 65 |
|
| 66 |
+
|
| 67 |
$model = Mage::getModel('productvideo/videos');
|
| 68 |
try
|
| 69 |
{
|
| 83 |
|
| 84 |
// Video 3
|
| 85 |
|
| 86 |
+
|
| 87 |
$model = Mage::getModel('productvideo/videos');
|
| 88 |
try
|
| 89 |
{
|
app/code/community/Niveus/ProductVideo/etc/config.xml
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
<config>
|
| 4 |
<modules>
|
| 5 |
<Niveus_ProductVideo>
|
| 6 |
-
<version>1.
|
| 7 |
</Niveus_ProductVideo>
|
| 8 |
</modules>
|
| 9 |
|
| 3 |
<config>
|
| 4 |
<modules>
|
| 5 |
<Niveus_ProductVideo>
|
| 6 |
+
<version>1.5.0</version>
|
| 7 |
</Niveus_ProductVideo>
|
| 8 |
</modules>
|
| 9 |
|
package.xml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Niveus_ProductVideo</name>
|
| 4 |
-
<version>1.
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
| 7 |
<channel>community</channel>
|
|
@@ -10,9 +10,9 @@
|
|
| 10 |
<description>Niveus Youtube product Video extension</description>
|
| 11 |
<notes>Installation steps</notes>
|
| 12 |
<authors><author><name>Niveus Solutions</name><user>niveussolutions</user><email>support@niveussolutions.com</email></author></authors>
|
| 13 |
-
<date>2014-
|
| 14 |
-
<time>
|
| 15 |
-
<contents><target name="magecommunity"><dir name="Niveus"><dir name="ProductVideo"><dir name="Block"><dir name="Adminhtml"><dir name="Catalog"><dir name="Product"><dir name="Edit"><dir name="Tab"><file name="Videos.php" hash="0e4ea8296cdf584cf9756cc086acec13"/><file name="Videos.php~" hash="c21edc574c4c186b23dbccc2d067b503"/></dir></dir></dir></dir></dir><dir name="Product"><dir name="View"><file name="Attribute.php~" hash="629d0759593202ee9d8886d863eff0c1"/><file name="List.php~" hash="9f52ae0257c000b26538daa0a6b5320c"/><file name="Media.php" hash="87141206ee837993560d66872c8f80b1"/><file name="Media.php~" hash="a512858484654f67e015b59def270d13"/></dir></dir><dir name="Rewrite"><file name="AdminhtmlCatalogProductEditTabs.php" hash="d4fcf87e7c895f792927b57dd9af9625"/><file name="AdminhtmlCatalogProductEditTabs.php~" hash="01e2d8cbbee88a7bbc68e5c05e933d54"/></dir><file name="Video.php" hash="7427647e5437bfc0bef5754c602c30f4"/><file name="Video.php~" hash="77668e1600fbb49e7884167842e1a6a3"/></dir><dir name="Helper"><file name="Data.php" hash="ab2f4060c3e9182f197f075b8e7faf50"/><file name="Data.php~" hash="ab2f4060c3e9182f197f075b8e7faf50"/></dir><dir name="Model"><dir name="Config"><dir name="Source"><file name="Scrolling.php" hash="1d095e7d24d4e640fb3b11baa4027b77"/><file name="Scrolling.php~" hash="29faa4933274ad9848784b751730b7dc"/><file name="Titleposition.php" hash="af43b76604b69f24c58c4bf35bab40a3"/><file name="Titleposition.php~" hash="eca314ba351356270cd362da50f974f4"/><file name="Transition.php" hash="387dfb1df77743b982bb0cd8de7c85a1"/><file name="Transition.php~" hash="974787453cece93a0a85cf0fc3046c65"/></dir></dir><file name="Observer.php" hash="
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
| 18 |
</package>
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Niveus_ProductVideo</name>
|
| 4 |
+
<version>1.5.0</version>
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
|
| 7 |
<channel>community</channel>
|
| 10 |
<description>Niveus Youtube product Video extension</description>
|
| 11 |
<notes>Installation steps</notes>
|
| 12 |
<authors><author><name>Niveus Solutions</name><user>niveussolutions</user><email>support@niveussolutions.com</email></author></authors>
|
| 13 |
+
<date>2014-07-10</date>
|
| 14 |
+
<time>10:21:27</time>
|
| 15 |
+
<contents><target name="magecommunity"><dir name="Niveus"><dir name="ProductVideo"><dir name="Block"><dir name="Adminhtml"><dir name="Catalog"><dir name="Product"><dir name="Edit"><dir name="Tab"><file name="Videos.php" hash="0e4ea8296cdf584cf9756cc086acec13"/><file name="Videos.php~" hash="c21edc574c4c186b23dbccc2d067b503"/></dir></dir></dir></dir></dir><dir name="Product"><dir name="View"><file name="Attribute.php~" hash="629d0759593202ee9d8886d863eff0c1"/><file name="List.php~" hash="9f52ae0257c000b26538daa0a6b5320c"/><file name="Media.php" hash="87141206ee837993560d66872c8f80b1"/><file name="Media.php~" hash="a512858484654f67e015b59def270d13"/></dir></dir><dir name="Rewrite"><file name="AdminhtmlCatalogProductEditTabs.php" hash="d4fcf87e7c895f792927b57dd9af9625"/><file name="AdminhtmlCatalogProductEditTabs.php~" hash="01e2d8cbbee88a7bbc68e5c05e933d54"/></dir><file name="Video.php" hash="7427647e5437bfc0bef5754c602c30f4"/><file name="Video.php~" hash="77668e1600fbb49e7884167842e1a6a3"/></dir><dir name="Helper"><file name="Data.php" hash="ab2f4060c3e9182f197f075b8e7faf50"/><file name="Data.php~" hash="ab2f4060c3e9182f197f075b8e7faf50"/></dir><dir name="Model"><dir name="Config"><dir name="Source"><file name="Scrolling.php" hash="1d095e7d24d4e640fb3b11baa4027b77"/><file name="Scrolling.php~" hash="29faa4933274ad9848784b751730b7dc"/><file name="Titleposition.php" hash="af43b76604b69f24c58c4bf35bab40a3"/><file name="Titleposition.php~" hash="eca314ba351356270cd362da50f974f4"/><file name="Transition.php" hash="387dfb1df77743b982bb0cd8de7c85a1"/><file name="Transition.php~" hash="974787453cece93a0a85cf0fc3046c65"/></dir></dir><file name="Observer.php" hash="e4f85cd8311b059a2405745735ef16f8"/><file name="Observer.php~" hash="1965676480638ee512c57c03016af894"/><dir name="Resource"><dir name="Eav"><dir name="Mysql4"><file name="Setup.php" hash="0b890d0edf9f635c34d84e80410ab230"/><file name="Setup.php~" hash="392ab06b2156327c4a9e8a3d77160f4a"/></dir></dir><dir name="Videos"><file name="Collection.php" hash="1d5a542d7a919ddeccef1cf3c9607b2f"/><file name="Collection.php~" hash="701b62fdd06add657539e507a3212971"/></dir><file name="Videos.php" hash="4ac319ed11931591649f9ac4569d107b"/><file name="Videos.php~" hash="2d56dcba2e2548597e48bf1afbdb9a58"/></dir><file name="Videos.php" hash="d35074b3b0acd6426ec5df12cf63d077"/><file name="Videos.php~" hash="8bcb8be4da9a0a642722ac4a38ac6729"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="VideosController.php" hash="7174a2ff3564f654110d94a16138bf5a"/><file name="VideosController.php~" hash="d5d5dff399e2a59559e8f635e58258a0"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="a00ffae61be96cd04e435c830cf3fd4d"/><file name="config.xml" hash="a9eebef3488df2782cc227b67371e149"/><file name="system.xml" hash="b8f38b5efc46ec5a9e0ae6c7d02d6232"/></dir><dir name="sql"><dir name="niveus_productvideo_setup"><file name="mysql4-install-1.2.0.php" hash="4022ec194b52e4800bbe6061ecf8d61c"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Niveus_ProductVideo.xml" hash="7d2fb29c666116bb33c0867e383e0788"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="niveusproductvideo.xml" hash="61f41423688de05affbfd3f0287d609d"/></dir><dir name="template"><dir name="niveusproductvideo"><dir name="tab"><file name="videos.phtml" hash="6d36682fbfe653e4aea4c657141ac18a"/></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="niveusproductvideo.xml" hash="fc44f02caa3b18837795fcf2da28a0d5"/></dir><dir name="template"><dir name="niveusproductvideo"><file name="video.phtml" hash="ddefc104ddec1d8173912dcd9c30be55"/></dir></dir></dir></dir></dir></target></contents>
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
|
| 18 |
</package>
|
