Version Notes
Magmodules_Sooqr
Download this release
Release Info
Developer | Magmodules |
Extension | Magmodules_Sooqr |
Version | 1.1.7 |
Comparing to | |
See all releases |
Code changes from version 1.1.6 to 1.1.7
- app/code/community/Magmodules/Sooqr/Block/Adminhtml/Widget/Info/Info.php +0 -4
- app/code/community/Magmodules/Sooqr/Helper/Data.php +58 -18
- app/code/community/Magmodules/Sooqr/Model/Adminhtml/System/Config/Source/{Image.php → Cms.php} +6 -6
- app/code/community/Magmodules/Sooqr/Model/Adminhtml/System/Config/Source/Cmspages.php +45 -0
- app/code/community/Magmodules/Sooqr/Model/Common.php +2 -2
- app/code/community/Magmodules/Sooqr/Model/Sooqr.php +33 -2
- app/code/community/Magmodules/Sooqr/etc/config.xml +1 -1
- app/code/community/Magmodules/Sooqr/etc/system.xml +12 -2
- package.xml +4 -4
app/code/community/Magmodules/Sooqr/Block/Adminhtml/Widget/Info/Info.php
CHANGED
@@ -61,10 +61,6 @@ class Magmodules_Sooqr_Block_Adminhtml_Widget_Info_Info extends Mage_Adminhtml_B
|
|
61 |
<td height="30">Sooqr Support</td>
|
62 |
<td><a href="http://support.sooqr.com/support/home" target="_blank">Sooqr Support</a> or <a href="mailto:support@sooqr.com" target="_blank">support@sooqr.com</a></td>
|
63 |
</tr>
|
64 |
-
<tr>
|
65 |
-
<td height="30"> </td>
|
66 |
-
<td> </td>
|
67 |
-
</tr>
|
68 |
</table>
|
69 |
</div>';
|
70 |
|
61 |
<td height="30">Sooqr Support</td>
|
62 |
<td><a href="http://support.sooqr.com/support/home" target="_blank">Sooqr Support</a> or <a href="mailto:support@sooqr.com" target="_blank">support@sooqr.com</a></td>
|
63 |
</tr>
|
|
|
|
|
|
|
|
|
64 |
</table>
|
65 |
</div>';
|
66 |
|
app/code/community/Magmodules/Sooqr/Helper/Data.php
CHANGED
@@ -173,20 +173,30 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
173 |
|
174 |
public function getProductUrl($product, $config, $parent)
|
175 |
{
|
|
|
176 |
if(!empty($parent)) {
|
177 |
-
if($parent->
|
178 |
-
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $parent->getUrlKey()));
|
179 |
-
}
|
180 |
-
if($product->getRequestPath()) {
|
181 |
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $parent->getRequestPath()));
|
182 |
}
|
183 |
-
|
184 |
-
|
185 |
-
|
|
|
186 |
}
|
|
|
187 |
if($product->getRequestPath()) {
|
188 |
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $product->getRequestPath()));
|
189 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
190 |
}
|
191 |
if(!empty($parent) && !empty($config['conf_switch_urls'])) {
|
192 |
if($parent->getTypeId() == 'configurable') {
|
@@ -231,27 +241,26 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
231 |
}
|
232 |
}
|
233 |
}
|
234 |
-
} else {
|
235 |
if($product->getThumbnail()) {
|
236 |
if($product->getThumbnail() != 'no_selection') {
|
237 |
$image = $config['media_image_url'] . $product->getThumbnail();
|
238 |
-
$image_data['image']['
|
239 |
}
|
240 |
}
|
241 |
if($product->getSmallImage()) {
|
242 |
if($product->getSmallImage() != 'no_selection') {
|
243 |
$image = $config['media_image_url'] . $product->getSmallImage();
|
244 |
-
$image_data['image']['
|
245 |
}
|
246 |
}
|
247 |
if($product->getImage()) {
|
248 |
if($product->getImage() != 'no_selection') {
|
249 |
$image = $config['media_image_url'] . $product->getImage();
|
250 |
-
$image_data['image']['
|
251 |
}
|
252 |
}
|
253 |
}
|
254 |
-
|
255 |
if(!empty($config['images'])) {
|
256 |
$image_data['image_link'] = $image;
|
257 |
$container = new Varien_Object(array('attribute' => new Varien_Object(array('id' => $config['media_gallery_id']))));
|
@@ -269,7 +278,11 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
269 |
}
|
270 |
return $image_data;
|
271 |
} else {
|
272 |
-
|
|
|
|
|
|
|
|
|
273 |
}
|
274 |
}
|
275 |
}
|
@@ -508,8 +521,20 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
508 |
if(!empty($config['category_replace'])) {
|
509 |
$attributes[] = $config['category_replace'];
|
510 |
}
|
511 |
-
|
512 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
513 |
$_categories = array();
|
514 |
|
515 |
foreach($categories as $cat) {
|
@@ -653,6 +678,11 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
653 |
{
|
654 |
$type_prices = array();
|
655 |
if(!empty($config['conf_enabled'])) {
|
|
|
|
|
|
|
|
|
|
|
656 |
foreach($products as $product) {
|
657 |
if($product->getTypeId() == 'configurable') {
|
658 |
$attributes = $product->getTypeInstance(true)->getConfigurableAttributes($product);
|
@@ -662,9 +692,9 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
662 |
$prices = $attribute->getPrices();
|
663 |
foreach ($prices as $price){
|
664 |
if ($price['is_percent']) {
|
665 |
-
$att_prices[$price['value_index']] = (float)$price['pricing_value'] * $base_price / 100;
|
666 |
} else {
|
667 |
-
$att_prices[$price['value_index']] = (float)$price['pricing_value'];
|
668 |
}
|
669 |
}
|
670 |
}
|
@@ -678,7 +708,7 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
678 |
$total_price += $att_prices[$value];
|
679 |
}
|
680 |
}
|
681 |
-
$type_prices[$sProduct->getEntityId()] = number_format($total_price, 2, '.', '') .
|
682 |
}
|
683 |
}
|
684 |
}
|
@@ -731,4 +761,14 @@ class Magmodules_Sooqr_Helper_Data extends Mage_Core_Helper_Abstract {
|
|
731 |
return $store_id;
|
732 |
}
|
733 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
734 |
}
|
173 |
|
174 |
public function getProductUrl($product, $config, $parent)
|
175 |
{
|
176 |
+
$url = '';
|
177 |
if(!empty($parent)) {
|
178 |
+
if($parent->getRequestPath()) {
|
|
|
|
|
|
|
179 |
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $parent->getRequestPath()));
|
180 |
}
|
181 |
+
if(empty($url)) {
|
182 |
+
if($parent->getUrlKey()) {
|
183 |
+
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $parent->getUrlKey()));
|
184 |
+
}
|
185 |
}
|
186 |
+
} else {
|
187 |
if($product->getRequestPath()) {
|
188 |
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $product->getRequestPath()));
|
189 |
}
|
190 |
+
if(empty($url)) {
|
191 |
+
if($product->getUrlKey()) {
|
192 |
+
$url = Mage::helper('core')->escapeHtml(trim($config['website_url'] . $product->getUrlKey()));
|
193 |
+
}
|
194 |
+
}
|
195 |
+
}
|
196 |
+
if(!empty($config['product_url_suffix'])) {
|
197 |
+
if(strpos($url, $config['product_url_suffix']) === false) {
|
198 |
+
$url = $url . $config['product_url_suffix'];
|
199 |
+
}
|
200 |
}
|
201 |
if(!empty($parent) && !empty($config['conf_switch_urls'])) {
|
202 |
if($parent->getTypeId() == 'configurable') {
|
241 |
}
|
242 |
}
|
243 |
}
|
244 |
+
} else {
|
245 |
if($product->getThumbnail()) {
|
246 |
if($product->getThumbnail() != 'no_selection') {
|
247 |
$image = $config['media_image_url'] . $product->getThumbnail();
|
248 |
+
$image_data['image']['thumbnail'] = $image;
|
249 |
}
|
250 |
}
|
251 |
if($product->getSmallImage()) {
|
252 |
if($product->getSmallImage() != 'no_selection') {
|
253 |
$image = $config['media_image_url'] . $product->getSmallImage();
|
254 |
+
$image_data['image']['small_image'] = $image;
|
255 |
}
|
256 |
}
|
257 |
if($product->getImage()) {
|
258 |
if($product->getImage() != 'no_selection') {
|
259 |
$image = $config['media_image_url'] . $product->getImage();
|
260 |
+
$image_data['image']['image'] = $image;
|
261 |
}
|
262 |
}
|
263 |
}
|
|
|
264 |
if(!empty($config['images'])) {
|
265 |
$image_data['image_link'] = $image;
|
266 |
$container = new Varien_Object(array('attribute' => new Varien_Object(array('id' => $config['media_gallery_id']))));
|
278 |
}
|
279 |
return $image_data;
|
280 |
} else {
|
281 |
+
if(!empty($image_data['image'][$config['image_source']])) {
|
282 |
+
return $image_data['image'][$config['image_source']];
|
283 |
+
} else {
|
284 |
+
return $image;
|
285 |
+
}
|
286 |
}
|
287 |
}
|
288 |
}
|
521 |
if(!empty($config['category_replace'])) {
|
522 |
$attributes[] = $config['category_replace'];
|
523 |
}
|
524 |
+
|
525 |
+
if(!empty($config['filter_enabled'])) {
|
526 |
+
$type = $config['filter_type'];
|
527 |
+
$f_categories = explode(',', $config['filter_cat']);
|
528 |
+
if($type && $f_categories) {
|
529 |
+
if($type == 'include') {
|
530 |
+
$categories = Mage::getModel('catalog/category')->setStoreId($storeId)->getCollection()->addAttributeToSelect($attributes)->addFieldToFilter('is_active', array('eq' => 1))->addAttributeToFilter('entity_id', array('in' => $f_categories));
|
531 |
+
} else {
|
532 |
+
$categories = Mage::getModel('catalog/category')->setStoreId($storeId)->getCollection()->addAttributeToSelect($attributes)->addFieldToFilter('is_active', array('eq' => 1))->addAttributeToFilter('entity_id', array('nin' => $f_categories));
|
533 |
+
}
|
534 |
+
}
|
535 |
+
} else {
|
536 |
+
$categories = Mage::getModel('catalog/category')->setStoreId($storeId)->getCollection()->addAttributeToSelect($attributes)->addFieldToFilter('is_active', array('eq' => 1));
|
537 |
+
}
|
538 |
$_categories = array();
|
539 |
|
540 |
foreach($categories as $cat) {
|
678 |
{
|
679 |
$type_prices = array();
|
680 |
if(!empty($config['conf_enabled'])) {
|
681 |
+
if(!empty($config['hide_currency'])) {
|
682 |
+
$currency = '';
|
683 |
+
} else {
|
684 |
+
$currency = ' ' . $config['currency'];
|
685 |
+
}
|
686 |
foreach($products as $product) {
|
687 |
if($product->getTypeId() == 'configurable') {
|
688 |
$attributes = $product->getTypeInstance(true)->getConfigurableAttributes($product);
|
692 |
$prices = $attribute->getPrices();
|
693 |
foreach ($prices as $price){
|
694 |
if ($price['is_percent']) {
|
695 |
+
$att_prices[$price['value_index']] = (float)(($price['pricing_value'] * $base_price / 100) * $config['markup']);
|
696 |
} else {
|
697 |
+
$att_prices[$price['value_index']] = (float)($price['pricing_value'] * $config['markup']);
|
698 |
}
|
699 |
}
|
700 |
}
|
708 |
$total_price += $att_prices[$value];
|
709 |
}
|
710 |
}
|
711 |
+
$type_prices[$sProduct->getEntityId()] = number_format(($total_price * $config['markup']), 2, '.', '') . $currency;
|
712 |
}
|
713 |
}
|
714 |
}
|
761 |
return $store_id;
|
762 |
}
|
763 |
|
764 |
+
public function getProductUrlSuffix($storeId)
|
765 |
+
{
|
766 |
+
$suffix = Mage::getStoreConfig('catalog/seo/product_url_suffix', $storeId);
|
767 |
+
if(!empty($suffix)) {
|
768 |
+
if($suffix[0] != '.') {
|
769 |
+
$suffix = '.' . $suffix;
|
770 |
+
}
|
771 |
+
}
|
772 |
+
return $suffix;
|
773 |
+
}
|
774 |
}
|
app/code/community/Magmodules/Sooqr/Model/Adminhtml/System/Config/Source/{Image.php → Cms.php}
RENAMED
@@ -15,15 +15,15 @@
|
|
15 |
* =============================================================
|
16 |
*/
|
17 |
|
18 |
-
class
|
19 |
|
20 |
public function toOptionArray()
|
21 |
{
|
22 |
-
$
|
23 |
-
$
|
24 |
-
$
|
25 |
-
$
|
26 |
-
return $
|
27 |
}
|
28 |
|
29 |
}
|
15 |
* =============================================================
|
16 |
*/
|
17 |
|
18 |
+
class Magmodules_Sooqr_Model_Adminhtml_System_Config_Source_Cms {
|
19 |
|
20 |
public function toOptionArray()
|
21 |
{
|
22 |
+
$cms = array();
|
23 |
+
$cms[] = array('value'=> '0', 'label'=> Mage::helper('sooqr')->__('No'));
|
24 |
+
$cms[] = array('value'=> '1', 'label'=> Mage::helper('sooqr')->__('Yes, all'));
|
25 |
+
$cms[] = array('value'=> '2', 'label'=> Mage::helper('sooqr')->__('Yes, selection'));
|
26 |
+
return $cms;
|
27 |
}
|
28 |
|
29 |
}
|
app/code/community/Magmodules/Sooqr/Model/Adminhtml/System/Config/Source/Cmspages.php
ADDED
@@ -0,0 +1,45 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Magmodules.eu - http://www.magmodules.eu - info@magmodules.eu
|
4 |
+
* =============================================================
|
5 |
+
* NOTICE OF LICENSE [Single domain license]
|
6 |
+
* This source file is subject to the EULA that is
|
7 |
+
* available through the world-wide-web at:
|
8 |
+
* http://www.magmodules.eu/license-agreement/
|
9 |
+
* =============================================================
|
10 |
+
* @category Magmodules
|
11 |
+
* @package Magmodules_Sooqr
|
12 |
+
* @author Magmodules <info@magmodules.eu>
|
13 |
+
* @copyright Copyright (c) 2016 (http://www.magmodules.eu)
|
14 |
+
* @license http://www.magmodules.eu/license-agreement/
|
15 |
+
* =============================================================
|
16 |
+
*/
|
17 |
+
|
18 |
+
class Magmodules_Sooqr_Model_Adminhtml_System_Config_Source_Cmspages {
|
19 |
+
|
20 |
+
public function toOptionArray()
|
21 |
+
{
|
22 |
+
$store_id = '';
|
23 |
+
$cms = array();
|
24 |
+
$code = Mage::app()->getRequest()->getParam('store');
|
25 |
+
if(!empty($code)) {
|
26 |
+
$store_id = Mage::getModel('core/store')->load($code)->getId();
|
27 |
+
} else {
|
28 |
+
$code = Mage::app()->getRequest()->getParam('website');
|
29 |
+
if(!empty($code)) {
|
30 |
+
$website_id = Mage::getModel('core/website')->load($code)->getId();
|
31 |
+
$store_id = Mage::app()->getWebsite($website_id)->getDefaultStore()->getId();
|
32 |
+
}
|
33 |
+
}
|
34 |
+
if($store_id) {
|
35 |
+
$cmspages = Mage::getModel('cms/page')->getCollection()->addStoreFilter($store_id);
|
36 |
+
} else {
|
37 |
+
$cmspages = Mage::getModel('cms/page')->getCollection();
|
38 |
+
}
|
39 |
+
foreach($cmspages as $page) {
|
40 |
+
$cms[] = array('value' => $page->getId(), 'label' => $page->getTitle() . ' (' . $page->getIdentifier() . ')');
|
41 |
+
}
|
42 |
+
return $cms;
|
43 |
+
}
|
44 |
+
|
45 |
+
}
|
app/code/community/Magmodules/Sooqr/Model/Common.php
CHANGED
@@ -117,8 +117,8 @@ class Magmodules_Sooqr_Model_Common extends Mage_Core_Helper_Abstract {
|
|
117 |
}
|
118 |
}
|
119 |
}
|
120 |
-
|
121 |
-
$collection->joinTable('cataloginventory/stock_item', 'product_id=entity_id', array("qty" => "qty", "stock_status" => "is_in_stock", "manage_stock" => "manage_stock", "use_config_manage_stock" => "use_config_manage_stock"))->addAttributeToSelect(array('qty', 'stock_status', 'manage_stock', 'use_config_manage_stock'));
|
122 |
$collection->getSelect()->group('e.entity_id');
|
123 |
return $collection->load();
|
124 |
}
|
117 |
}
|
118 |
}
|
119 |
}
|
120 |
+
|
121 |
+
$collection->joinTable('cataloginventory/stock_item', 'product_id=entity_id', array("qty" => "qty", "stock_status" => "is_in_stock", "manage_stock" => "manage_stock", "use_config_manage_stock" => "use_config_manage_stock", "use_config_backorders" => "use_config_backorders", "backorders" => "backorders"))->addAttributeToSelect(array('qty', 'stock_status', 'manage_stock', 'use_config_manage_stock', 'use_config_backorders', 'backorders'));
|
122 |
$collection->getSelect()->group('e.entity_id');
|
123 |
return $collection->load();
|
124 |
}
|
app/code/community/Magmodules/Sooqr/Model/Sooqr.php
CHANGED
@@ -81,7 +81,11 @@ class Magmodules_Sooqr_Model_Sooqr extends Magmodules_Sooqr_Model_Common {
|
|
81 |
$config['filter_cat'] = Mage::getStoreConfig('sooqr_connect/products/categories', $storeId);
|
82 |
$config['filter_type'] = Mage::getStoreConfig('sooqr_connect/products/category_type', $storeId);
|
83 |
$config['cms_pages'] = Mage::getStoreConfig('sooqr_connect/products/cms_pages', $storeId);
|
|
|
84 |
$config['filters'] = @unserialize(Mage::getStoreConfig('sooqr_connect/products/advanced', $storeId));
|
|
|
|
|
|
|
85 |
|
86 |
// PRICE
|
87 |
$config['price_scope'] = Mage::getStoreConfig('catalog/price/scope');
|
@@ -241,7 +245,25 @@ class Magmodules_Sooqr_Model_Sooqr extends Magmodules_Sooqr_Model_Common {
|
|
241 |
}
|
242 |
return $assoc_id;
|
243 |
}
|
244 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
245 |
protected function getCategoryData($product_data, $config)
|
246 |
{
|
247 |
$category = array();
|
@@ -278,6 +300,10 @@ class Magmodules_Sooqr_Model_Sooqr extends Magmodules_Sooqr_Model_Common {
|
|
278 |
if($_assoc_id = $this->getAssocId($product_data)) {
|
279 |
$_extra = array_merge($_extra, $_assoc_id);
|
280 |
}
|
|
|
|
|
|
|
|
|
281 |
return $_extra;
|
282 |
}
|
283 |
|
@@ -330,7 +356,12 @@ class Magmodules_Sooqr_Model_Sooqr extends Magmodules_Sooqr_Model_Common {
|
|
330 |
public function getCmspages($config)
|
331 |
{
|
332 |
$cmspages = array();
|
333 |
-
|
|
|
|
|
|
|
|
|
|
|
334 |
foreach($pages as $page) {
|
335 |
$cmspages[] = array('content_type' => 'cms', 'id' => 'CMS-' . $page->getId(), 'title' => $page->getTitle(), 'content' => Mage::helper('sooqr')->cleanData($page->getContent(), 'striptags'), 'url' => $config['website_url'] . $page->getIdentifier());
|
336 |
}
|
81 |
$config['filter_cat'] = Mage::getStoreConfig('sooqr_connect/products/categories', $storeId);
|
82 |
$config['filter_type'] = Mage::getStoreConfig('sooqr_connect/products/category_type', $storeId);
|
83 |
$config['cms_pages'] = Mage::getStoreConfig('sooqr_connect/products/cms_pages', $storeId);
|
84 |
+
$config['cms_include'] = Mage::getStoreConfig('sooqr_connect/products/cms_include', $storeId);
|
85 |
$config['filters'] = @unserialize(Mage::getStoreConfig('sooqr_connect/products/advanced', $storeId));
|
86 |
+
$config['product_url_suffix'] = $feed->getProductUrlSuffix($storeId);
|
87 |
+
$config['stock_manage'] = Mage::getStoreConfig('cataloginventory/item_options/manage_stock');
|
88 |
+
$config['backorders'] = Mage::getStoreConfig('cataloginventory/item_options/backorders');
|
89 |
|
90 |
// PRICE
|
91 |
$config['price_scope'] = Mage::getStoreConfig('catalog/price/scope');
|
245 |
}
|
246 |
return $assoc_id;
|
247 |
}
|
248 |
+
|
249 |
+
protected function getStockData($product_data, $config, $product)
|
250 |
+
{
|
251 |
+
$stock_data = array();
|
252 |
+
if($product->getUseConfigManageStock()) {
|
253 |
+
$stock_data['manage_stock'] = (string)$config['stock_manage'];
|
254 |
+
} else {
|
255 |
+
$stock_data['manage_stock'] = (string)$product->getManageStock();
|
256 |
+
}
|
257 |
+
|
258 |
+
if($product->getUseConfigBackorders()) {
|
259 |
+
$stock_data['backorders'] = (string)$config['backorders'];
|
260 |
+
} else {
|
261 |
+
$stock_data['backorders'] = (string)$product->getBackorders();
|
262 |
+
}
|
263 |
+
return $stock_data;
|
264 |
+
}
|
265 |
+
|
266 |
+
|
267 |
protected function getCategoryData($product_data, $config)
|
268 |
{
|
269 |
$category = array();
|
300 |
if($_assoc_id = $this->getAssocId($product_data)) {
|
301 |
$_extra = array_merge($_extra, $_assoc_id);
|
302 |
}
|
303 |
+
if($_stock_data = $this->getStockData($product_data, $config, $product)) {
|
304 |
+
$_extra = array_merge($_extra, $_stock_data);
|
305 |
+
}
|
306 |
+
|
307 |
return $_extra;
|
308 |
}
|
309 |
|
356 |
public function getCmspages($config)
|
357 |
{
|
358 |
$cmspages = array();
|
359 |
+
if($config['cms_pages'] == 1) {
|
360 |
+
$pages = Mage::getModel('cms/page')->getCollection()->addStoreFilter($config['store_id'])->addFieldToFilter('is_active', 1)->addFieldToFilter('identifier', array(array('nin' => array('no-route','enable-cookies'))));
|
361 |
+
} else {
|
362 |
+
$cms_include = explode(',', $config['cms_include']);
|
363 |
+
$pages = Mage::getModel('cms/page')->getCollection()->addStoreFilter($config['store_id'])->addFieldToFilter('is_active', 1)->addFieldToFilter('page_id', array('in' => $cms_include));
|
364 |
+
}
|
365 |
foreach($pages as $page) {
|
366 |
$cmspages[] = array('content_type' => 'cms', 'id' => 'CMS-' . $page->getId(), 'title' => $page->getTitle(), 'content' => Mage::helper('sooqr')->cleanData($page->getContent(), 'striptags'), 'url' => $config['website_url'] . $page->getIdentifier());
|
367 |
}
|
app/code/community/Magmodules/Sooqr/etc/config.xml
CHANGED
@@ -19,7 +19,7 @@
|
|
19 |
<config>
|
20 |
<modules>
|
21 |
<Magmodules_Sooqr>
|
22 |
-
<version>1.1.
|
23 |
</Magmodules_Sooqr>
|
24 |
</modules>
|
25 |
<global>
|
19 |
<config>
|
20 |
<modules>
|
21 |
<Magmodules_Sooqr>
|
22 |
+
<version>1.1.7</version>
|
23 |
</Magmodules_Sooqr>
|
24 |
</modules>
|
25 |
<global>
|
app/code/community/Magmodules/Sooqr/etc/system.xml
CHANGED
@@ -474,12 +474,22 @@
|
|
474 |
<cms_pages translate="label">
|
475 |
<label>Enable</label>
|
476 |
<frontend_type>select</frontend_type>
|
477 |
-
<source_model>
|
478 |
<sort_order>81</sort_order>
|
479 |
<show_in_default>1</show_in_default>
|
480 |
<show_in_website>1</show_in_website>
|
481 |
<show_in_store>1</show_in_store>
|
482 |
-
</cms_pages>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
483 |
</fields>
|
484 |
</products>
|
485 |
<generate translate="label" module="sooqr">
|
474 |
<cms_pages translate="label">
|
475 |
<label>Enable</label>
|
476 |
<frontend_type>select</frontend_type>
|
477 |
+
<source_model>sooqr/adminhtml_system_config_source_cms</source_model>
|
478 |
<sort_order>81</sort_order>
|
479 |
<show_in_default>1</show_in_default>
|
480 |
<show_in_website>1</show_in_website>
|
481 |
<show_in_store>1</show_in_store>
|
482 |
+
</cms_pages>
|
483 |
+
<cms_include translate="label">
|
484 |
+
<label>Only include</label>
|
485 |
+
<frontend_type>multiselect</frontend_type>
|
486 |
+
<source_model>sooqr/adminhtml_system_config_source_cmspages</source_model>
|
487 |
+
<sort_order>82</sort_order>
|
488 |
+
<show_in_default>1</show_in_default>
|
489 |
+
<show_in_website>1</show_in_website>
|
490 |
+
<show_in_store>1</show_in_store>
|
491 |
+
<depends><cms_pages>2</cms_pages></depends>
|
492 |
+
</cms_include>
|
493 |
</fields>
|
494 |
</products>
|
495 |
<generate translate="label" module="sooqr">
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Magmodules_Sooqr</name>
|
4 |
-
<version>1.1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.magmodules.eu/license-agreement/">Single Server License</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>Magmodules_Sooqr</description>
|
11 |
<notes>Magmodules_Sooqr</notes>
|
12 |
<authors><author><name>Magmodules</name><user>magmodules</user><email>info@magmodules.nl</email></author></authors>
|
13 |
-
<date>2016-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Magmodules"><dir name="Sooqr"><dir name="Block"><dir name="Adminhtml"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Extra.php" hash="e583284820c631015ed78c131bf3cfa8"/><file name="Filter.php" hash="e21c1f53da21d4f3afbfe7691efce06e"/></dir><dir name="Renderer"><file name="Select.php" hash="69d71d66aaf7b842ef482affd484ec48"/></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Feeds.php" hash="29007ed679b14e737b5dd784fc0eb668"/><file name="Heading.php" hash="a89db4f294f9c9e6785745163b1aed5f"/><file name="Note.php" hash="f131e40d8a0f4ed2e444d9e692a91ed5"/><file name="Version.php" hash="5832a42f30122977420d722683211f66"/></dir></dir></dir></dir><dir name="Widget"><dir name="Info"><file name="Info.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Magmodules_Sooqr</name>
|
4 |
+
<version>1.1.7</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://www.magmodules.eu/license-agreement/">Single Server License</license>
|
7 |
<channel>community</channel>
|
10 |
<description>Magmodules_Sooqr</description>
|
11 |
<notes>Magmodules_Sooqr</notes>
|
12 |
<authors><author><name>Magmodules</name><user>magmodules</user><email>info@magmodules.nl</email></author></authors>
|
13 |
+
<date>2016-09-21</date>
|
14 |
+
<time>15:21:26</time>
|
15 |
+
<contents><target name="magecommunity"><dir name="Magmodules"><dir name="Sooqr"><dir name="Block"><dir name="Adminhtml"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Extra.php" hash="e583284820c631015ed78c131bf3cfa8"/><file name="Filter.php" hash="e21c1f53da21d4f3afbfe7691efce06e"/></dir><dir name="Renderer"><file name="Select.php" hash="69d71d66aaf7b842ef482affd484ec48"/></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Feeds.php" hash="29007ed679b14e737b5dd784fc0eb668"/><file name="Heading.php" hash="a89db4f294f9c9e6785745163b1aed5f"/><file name="Note.php" hash="f131e40d8a0f4ed2e444d9e692a91ed5"/><file name="Version.php" hash="5832a42f30122977420d722683211f66"/></dir></dir></dir></dir><dir name="Widget"><dir name="Info"><file name="Info.php" hash="df58de5e54657b1a78c85376b74af7be"/></dir></dir></dir><file name="Search.php" hash="2acb516fec2f419e260240e8647c5999"/></dir><dir name="Helper"><file name="Data.php" hash="4a1d6273260af178848ebc8abe6af927"/></dir><dir name="Model"><dir name="Adminhtml"><dir name="System"><dir name="Config"><dir name="Backend"><dir name="Design"><file name="Extra.php" hash="3e262b80ccc673e415bf51bf172c72d4"/><file name="Filter.php" hash="e6fac56290f6d0d7be78553e75cb18a3"/></dir><dir name="Sooqr"><file name="Cron.php" hash="cbc4182eca99a768636f52e2122e8c32"/></dir></dir><dir name="Source"><file name="Action.php" hash="ef9830d9c1a98c94991626c4cc4909c9"/><file name="Attribute.php" hash="6f3736cd2f7de23b9d74356d7c1c557f"/><file name="Cacheresize.php" hash="86a916189abef3a670e58f3a8298f894"/><file name="Category.php" hash="92b245d0758fbe075b79c397a96d8567"/><file name="Categorytype.php" hash="8bc5f054db86f543019a6762a6a98562"/><file name="Cms.php" hash="34197c03a013a67112fa4f2c8415ed2b"/><file name="Cmspages.php" hash="d9cc6034c3d777cc896ff28f1a29f88d"/><file name="Condition.php" hash="bd66be4fe74f549d5fa6c213bd9b64f6"/><file name="Conditions.php" hash="502fe20b60e397240b8d552fd5ea4d81"/><file name="Configurable.php" hash="34a165474618953e44fd1de305371907"/><file name="Frequency.php" hash="f03bd90b098412026b21884e72c89aaf"/><file name="Identifier.php" hash="cdf5bd32696cb92a6f3be396ce5b3a6d"/><file name="Images.php" hash="08658a5e913e334959ec476a61e2891f"/><file name="Pricemodel.php" hash="dbbeabc2853a7caecab3fc42a557766b"/><file name="Productid.php" hash="e4b431e0183d91bdd4f186f001119e77"/><file name="Producttype.php" hash="88d0e8386f59d7c0ea62a19cbf800fa4"/><file name="Resize.php" hash="1a0824757d8c87f85225f063de3a025b"/><file name="Selectattribute.php" hash="bcae6eff0788821f7d3dbf7d224b59e4"/><file name="Status.php" hash="2f474fe7188e3b1cf1d1714ffebcd9e8"/><file name="Tax.php" hash="c6e19d702751bc0c616768fceaf53855"/><file name="Textattribute.php" hash="9645d5652679a972a280cf337ab8662b"/><file name="Varcharattribute.php" hash="37a9253e8ea806f3402052a0b0744707"/><file name="Version.php" hash="906736f8f04f03421ab56a0c042639aa"/><file name="Visibility.php" hash="67f20c3b4581144b11ca8696c885b97d"/><file name="Weight.php" hash="fbc88d0b6bd073d00dc6e4a05ce1b4df"/></dir></dir></dir></dir><file name="Common.php" hash="f9c26c5efa9dafe962c48654db7120c1"/><file name="Observer.php" hash="3aaaef864111e5d83f0b4d55c7618967"/><file name="Sooqr.php" hash="1513787d320d0ee925c955f451629bee"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="SooqrController.php" hash="13d562363e6e665825fed5b86f9d470f"/></dir><file name="InstallationController.php" hash="a96e58cbab2c7b6a3a4c9b42de62a59f"/></dir><dir name="etc"><file name="adminhtml.xml" hash="cf4313a4daa72837c48e137b51b11eba"/><file name="config.xml" hash="0712424026b18c913b04e9aa4ec1c89c"/><file name="system.xml" hash="607bd506200d025a64efe2587da063d9"/></dir></dir></dir></target><target name="magelocale"><dir><dir name="en_US"><file name="Magmodules_Sooqr.csv" hash="38992a5f4cf87eeee3d06ab38ead900b"/></dir><dir name="nl_NL"><file name="Magmodules_Sooqr.csv" hash="7f45989fad8c6e6ad552a827757d5161"/></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Magmodules_Sooqr.xml" hash="eeec89a005c4ccb1ed86bf90c446e3ef"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="magmodules"><dir name="sooqr"><file name="form.mini.phtml" hash="dfb86fc52128baeef3c81f1f1eb6cc1c"/></dir></dir></dir><dir name="layout"><file name="magmodules_sooqr.xml" hash="62a14cd61d3d74653b8d883d4d6b9d8d"/></dir></dir></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|