Version Notes
Stable version
Download this release
Release Info
Developer | muffadal |
Extension | Indianic_Reviewimportexport |
Version | 1.0.0.2 |
Comparing to | |
See all releases |
Code changes from version 1.0.0.1 to 1.0.0.2
- app/code/local/Indianic/Reviewexport/Model/Convert/Adapter/Reviewimport.php +22 -13
- app/code/local/Indianic/Reviewexport/Model/Convert/Parser/Exportorders.php +0 -987
- app/code/local/Indianic/Reviewexport/Model/Convert/Parser/Reviewexport.php +24 -12
- export.pdf +0 -0
- app/code/local/Indianic/Reviewexport/Note/export_review.csv +190 -0
- app/code/local/Indianic/Reviewexport/Note/xml_data_to_paste_info_advanced_profile_export.txt +18 -0
- app/code/local/Indianic/Reviewexport/Note/xml_data_to_paste_into_advanced_profile_import.txt +15 -0
- app/code/local/Indianic/Reviewexport/etc/config.xml +1 -1
- package.xml +4 -4
app/code/local/Indianic/Reviewexport/Model/Convert/Adapter/Reviewimport.php
CHANGED
@@ -7,18 +7,17 @@ class Indianic_Reviewexport_Model_Convert_Adapter_Reviewimport extends Mage_Cata
|
|
7 |
$write = Mage::getSingleton('core/resource')->getConnection('core_write');
|
8 |
$sku = $write->query('select entity_id from `catalog_product_entity` where sku = "'.$data['Sku'].'" ');
|
9 |
$sku = $sku->fetch();
|
|
|
10 |
if($sku)
|
11 |
{
|
12 |
$product_id = $sku['entity_id'];
|
13 |
if($data['customer_id']=='')
|
14 |
{
|
15 |
-
$customerid = NULL;
|
16 |
}
|
17 |
else
|
18 |
{
|
19 |
-
$customerid = $data['customer_id'];
|
20 |
-
/* $_customer = Mage::getModel('customer/customer')->load($customerid);
|
21 |
-
$_session = Mage::getSingleton('customer/session')->setCustomer($_customer)->setCustomerAsLoggedIn($_customer);*/
|
22 |
}
|
23 |
$_review = Mage::getModel('review/review')
|
24 |
->setCreatedAt($data['created_at'])
|
@@ -34,17 +33,27 @@ class Indianic_Reviewexport_Model_Convert_Adapter_Reviewimport extends Mage_Cata
|
|
34 |
->save();
|
35 |
if($data['option_id'])
|
36 |
{
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
42 |
$_review->aggregate();
|
43 |
-
|
44 |
}
|
45 |
|
46 |
}
|
47 |
}
|
48 |
-
|
49 |
-
}
|
50 |
-
|
7 |
$write = Mage::getSingleton('core/resource')->getConnection('core_write');
|
8 |
$sku = $write->query('select entity_id from `catalog_product_entity` where sku = "'.$data['Sku'].'" ');
|
9 |
$sku = $sku->fetch();
|
10 |
+
|
11 |
if($sku)
|
12 |
{
|
13 |
$product_id = $sku['entity_id'];
|
14 |
if($data['customer_id']=='')
|
15 |
{
|
16 |
+
$customerid = NULL;
|
17 |
}
|
18 |
else
|
19 |
{
|
20 |
+
$customerid = $data['customer_id'];
|
|
|
|
|
21 |
}
|
22 |
$_review = Mage::getModel('review/review')
|
23 |
->setCreatedAt($data['created_at'])
|
33 |
->save();
|
34 |
if($data['option_id'])
|
35 |
{
|
36 |
+
$arr_data = explode("@",$data['option_id']);
|
37 |
+
|
38 |
+
if(!empty($arr_data)) {
|
39 |
+
|
40 |
+
foreach($arr_data as $each_data) {
|
41 |
+
|
42 |
+
$arr_rating = explode(":",$each_data);
|
43 |
+
|
44 |
+
if($arr_rating[1] != 0) {
|
45 |
+
|
46 |
+
Mage::getModel('rating/rating')
|
47 |
+
->setRatingId($arr_rating[0])
|
48 |
+
->setReviewId($_review->getId())
|
49 |
+
->setCustomerId($customerid)
|
50 |
+
->addOptionVote($arr_rating[1], $product_id);
|
51 |
+
}
|
52 |
+
}
|
53 |
+
}
|
54 |
$_review->aggregate();
|
|
|
55 |
}
|
56 |
|
57 |
}
|
58 |
}
|
59 |
+
}
|
|
|
|
app/code/local/Indianic/Reviewexport/Model/Convert/Parser/Exportorders.php
DELETED
@@ -1,987 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* ExportOrders.php
|
4 |
-
* CommerceThemes @ InterSEC Solutions LLC.
|
5 |
-
*
|
6 |
-
* NOTICE OF LICENSE
|
7 |
-
*
|
8 |
-
* This source file is subject to the EULA
|
9 |
-
* that is bundled with this package in the file LICENSE.txt.
|
10 |
-
* It is also available through the world-wide-web at this URL:
|
11 |
-
* http://www.commercethemes.com/LICENSE-M1.txt
|
12 |
-
*
|
13 |
-
* @category Orders
|
14 |
-
* @package Exportorders
|
15 |
-
* @copyright Copyright (c) 2003-2009 CommerceThemes @ InterSEC Solutions LLC. (http://www.commercethemes.com)
|
16 |
-
* @license http://www.commercethemes.com/LICENSE-M1.txt
|
17 |
-
*/
|
18 |
-
|
19 |
-
class Intersec_Orderimportexport_Model_Convert_Parser_Exportorders
|
20 |
-
extends Mage_Eav_Model_Convert_Parser_Abstract
|
21 |
-
{
|
22 |
-
const MULTI_DELIMITER = ' , ';
|
23 |
-
|
24 |
-
protected $_resource;
|
25 |
-
|
26 |
-
/**
|
27 |
-
* Product collections per store
|
28 |
-
*
|
29 |
-
* @var array
|
30 |
-
*/
|
31 |
-
protected $_collections;
|
32 |
-
|
33 |
-
protected $_customerModel;
|
34 |
-
protected $_customerAddressModel;
|
35 |
-
protected $_newsletterModel;
|
36 |
-
protected $_store;
|
37 |
-
protected $_storeId;
|
38 |
-
|
39 |
-
protected $_stores;
|
40 |
-
|
41 |
-
/**
|
42 |
-
* Website collection array
|
43 |
-
*
|
44 |
-
* @var array
|
45 |
-
*/
|
46 |
-
protected $_websites;
|
47 |
-
protected $_attributes = array();
|
48 |
-
|
49 |
-
protected $_fields;
|
50 |
-
|
51 |
-
public function getFields()
|
52 |
-
{
|
53 |
-
if (!$this->_fields) {
|
54 |
-
$this->_fields = Mage::getConfig()->getFieldset('customer_dataflow', 'admin');
|
55 |
-
}
|
56 |
-
return $this->_fields;
|
57 |
-
}
|
58 |
-
|
59 |
-
/**
|
60 |
-
* Retrieve customer model cache
|
61 |
-
*
|
62 |
-
* @return Mage_Customer_Model_Customer
|
63 |
-
*/
|
64 |
-
public function getCustomerModel()
|
65 |
-
{
|
66 |
-
if (is_null($this->_customerModel)) {
|
67 |
-
$object = Mage::getModel('customer/customer');
|
68 |
-
$this->_customerModel = Mage::objects()->save($object);
|
69 |
-
}
|
70 |
-
return Mage::objects()->load($this->_customerModel);
|
71 |
-
}
|
72 |
-
|
73 |
-
/**
|
74 |
-
* Retrieve customer address model cache
|
75 |
-
*
|
76 |
-
* @return Mage_Customer_Model_Address
|
77 |
-
*/
|
78 |
-
public function getCustomerAddressModel()
|
79 |
-
{
|
80 |
-
if (is_null($this->_customerAddressModel)) {
|
81 |
-
$object = Mage::getModel('customer/address');
|
82 |
-
$this->_customerAddressModel = Mage::objects()->save($object);
|
83 |
-
}
|
84 |
-
return Mage::objects()->load($this->_customerAddressModel);
|
85 |
-
}
|
86 |
-
|
87 |
-
/**
|
88 |
-
* Retrieve newsletter subscribers model cache
|
89 |
-
*
|
90 |
-
* @return Mage_Newsletter_Model_Subscriber
|
91 |
-
*/
|
92 |
-
public function getNewsletterModel()
|
93 |
-
{
|
94 |
-
if (is_null($this->_newsletterModel)) {
|
95 |
-
$object = Mage::getModel('newsletter/subscriber');
|
96 |
-
$this->_newsletterModel = Mage::objects()->save($object);
|
97 |
-
}
|
98 |
-
return Mage::objects()->load($this->_newsletterModel);
|
99 |
-
}
|
100 |
-
|
101 |
-
/**
|
102 |
-
* Retrieve current store model
|
103 |
-
*
|
104 |
-
* @return Mage_Core_Model_Store
|
105 |
-
*/
|
106 |
-
public function getStore()
|
107 |
-
{
|
108 |
-
if (is_null($this->_store)) {
|
109 |
-
try {
|
110 |
-
$store = Mage::app()->getStore($this->getVar('store'));
|
111 |
-
}
|
112 |
-
catch (Exception $e) {
|
113 |
-
$this->addException(Mage::helper('catalog')->__('Invalid store specified'), Varien_Convert_Exception::FATAL);
|
114 |
-
throw $e;
|
115 |
-
}
|
116 |
-
$this->_store = $store;
|
117 |
-
}
|
118 |
-
return $this->_store;
|
119 |
-
}
|
120 |
-
|
121 |
-
/**
|
122 |
-
* Retrieve store ID
|
123 |
-
*
|
124 |
-
* @return int
|
125 |
-
*/
|
126 |
-
public function getStoreId()
|
127 |
-
{
|
128 |
-
if (is_null($this->_storeId)) {
|
129 |
-
$this->_storeId = $this->getStore()->getId();
|
130 |
-
}
|
131 |
-
return $this->_storeId;
|
132 |
-
}
|
133 |
-
|
134 |
-
public function getStoreById($storeId)
|
135 |
-
{
|
136 |
-
if (is_null($this->_stores)) {
|
137 |
-
$this->_stores = Mage::app()->getStores(true);
|
138 |
-
}
|
139 |
-
if (isset($this->_stores[$storeId])) {
|
140 |
-
return $this->_stores[$storeId];
|
141 |
-
}
|
142 |
-
return false;
|
143 |
-
}
|
144 |
-
|
145 |
-
/**
|
146 |
-
* Retrieve website model by id
|
147 |
-
*
|
148 |
-
* @param int $websiteId
|
149 |
-
* @return Mage_Core_Model_Website
|
150 |
-
*/
|
151 |
-
public function getWebsiteById($websiteId)
|
152 |
-
{
|
153 |
-
if (is_null($this->_websites)) {
|
154 |
-
$this->_websites = Mage::app()->getWebsites(true);
|
155 |
-
}
|
156 |
-
if (isset($this->_websites[$websiteId])) {
|
157 |
-
return $this->_websites[$websiteId];
|
158 |
-
}
|
159 |
-
return false;
|
160 |
-
}
|
161 |
-
|
162 |
-
/**
|
163 |
-
* Retrieve eav entity attribute model
|
164 |
-
*
|
165 |
-
* @param string $code
|
166 |
-
* @return Mage_Eav_Model_Entity_Attribute
|
167 |
-
*/
|
168 |
-
public function getAttribute($code)
|
169 |
-
{
|
170 |
-
if (!isset($this->_attributes[$code])) {
|
171 |
-
$this->_attributes[$code] = $this->getCustomerModel()->getResource()->getAttribute($code);
|
172 |
-
}
|
173 |
-
return $this->_attributes[$code];
|
174 |
-
}
|
175 |
-
|
176 |
-
/**
|
177 |
-
* @return Mage_Catalog_Model_Mysql4_Convert
|
178 |
-
*/
|
179 |
-
public function getResource()
|
180 |
-
{
|
181 |
-
if (!$this->_resource) {
|
182 |
-
$this->_resource = Mage::getResourceSingleton('catalog_entity/convert');
|
183 |
-
#->loadStores()
|
184 |
-
#->loadProducts()
|
185 |
-
#->loadAttributeSets()
|
186 |
-
#->loadAttributeOptions();
|
187 |
-
}
|
188 |
-
return $this->_resource;
|
189 |
-
}
|
190 |
-
|
191 |
-
public function getCollection($storeId)
|
192 |
-
{
|
193 |
-
if (!isset($this->_collections[$storeId])) {
|
194 |
-
$this->_collections[$storeId] = Mage::getResourceModel('customer/customer_collection');
|
195 |
-
$this->_collections[$storeId]->getEntity()->setStore($storeId);
|
196 |
-
}
|
197 |
-
return $this->_collections[$storeId];
|
198 |
-
}
|
199 |
-
|
200 |
-
public function unparse()
|
201 |
-
{
|
202 |
-
#print_r($this->getData());
|
203 |
-
$i="";
|
204 |
-
//NOTE IN SOME RANDOM CASES ->addAttributeToSelect('increment_id') must be ->addAttributeToSelect('*') or data all blank
|
205 |
-
if($this->getVar('date_from') != "" && $this->getVar('date_to') != "" && $this->getVar('filter_by_order_status') != "" ) {
|
206 |
-
|
207 |
-
$date_from = $this->getVar('date_from'). " 00:00:00";
|
208 |
-
$date_to = $this->getVar('date_to'). " 23:59:59";
|
209 |
-
$orders = Mage::getModel('sales/order')->getCollection()
|
210 |
-
->addAttributeToSelect('*')
|
211 |
-
->addAttributeToFilter ( 'created_at' , array( "from" => $date_from, "to" => $date_to, "datetime" => true ))
|
212 |
-
->addFieldToFilter ( 'status' , array( "eq" => $this->getVar('filter_by_order_status') ))
|
213 |
-
->load();
|
214 |
-
} else if($this->getVar('date_from') != "" && $this->getVar('date_to') != "" && $this->getVar('filter_by_store_id') != "") {
|
215 |
-
|
216 |
-
$date_from = $this->getVar('date_from'). " 00:00:00";
|
217 |
-
$date_to = $this->getVar('date_to'). " 23:59:59";
|
218 |
-
$orders = Mage::getModel('sales/order')->getCollection()
|
219 |
-
->addAttributeToSelect('*')
|
220 |
-
->addAttributeToFilter ( 'store_id' , $this->getVar('filter_by_store_id'))
|
221 |
-
->addAttributeToFilter ( 'created_at' , array( "from" => $date_from, "to" => $date_to, "datetime" => true ))
|
222 |
-
->load();
|
223 |
-
} else if($this->getVar('date_from') != "" && $this->getVar('date_to') != "" ) {
|
224 |
-
|
225 |
-
$date_from = $this->getVar('date_from'). " 00:00:00";
|
226 |
-
$date_to = $this->getVar('date_to'). " 23:59:59";
|
227 |
-
$orders = Mage::getModel('sales/order')->getCollection()
|
228 |
-
->addAttributeToSelect('*')
|
229 |
-
->addAttributeToFilter ( 'created_at' , array( "from" => $date_from, "to" => $date_to, "datetime" => true ))
|
230 |
-
->load();
|
231 |
-
} else if($this->getVar('filter_by_order_status') != "" ) {
|
232 |
-
$orders = Mage::getModel('sales/order')->getCollection()
|
233 |
-
->addAttributeToSelect('*')
|
234 |
-
->addFieldToFilter ( 'status' , array( "eq" => $this->getVar('filter_by_order_status') ))
|
235 |
-
->load();
|
236 |
-
} else if($this->getVar('filter_by_store_id') != "" ) {
|
237 |
-
|
238 |
-
$orders = Mage::getModel('sales/order')->getCollection()
|
239 |
-
->addAttributeToSelect('*')
|
240 |
-
->addAttributeToFilter ( 'store_id' , $this->getVar('filter_by_store_id'))
|
241 |
-
->load();
|
242 |
-
} else {
|
243 |
-
$orders = Mage::getModel('sales/order')->getCollection()->addAttributeToSelect('*')->load();
|
244 |
-
#$entityIds = $this->getData();
|
245 |
-
}
|
246 |
-
|
247 |
-
$recordlimit = $this->getVar('recordlimit');
|
248 |
-
$systemFields = array();
|
249 |
-
foreach ($this->getFields() as $code=>$node) {
|
250 |
-
if ($node->is('system')) {
|
251 |
-
$systemFields[] = $code;
|
252 |
-
}
|
253 |
-
}
|
254 |
-
|
255 |
-
|
256 |
-
$overallcount = 1;
|
257 |
-
foreach ($orders as $entityId) {
|
258 |
-
|
259 |
-
if ($overallcount < $recordlimit) {
|
260 |
-
$order = Mage::getModel('sales/order')->load($entityId->getId());
|
261 |
-
#print_r($order);
|
262 |
-
//echo "CUSTOMER ID: " . $order->getData('customer_id');
|
263 |
-
$customerId = $order->getData('customer_id');
|
264 |
-
$store = $this->getStore();
|
265 |
-
$storefromorder = Mage::app()->getStore($order->getStoreId());
|
266 |
-
|
267 |
-
$row = array();
|
268 |
-
|
269 |
-
$row['order_id'] = $order->getData('increment_id');
|
270 |
-
//echo "isguest: " . $order->getCustomerIsGuest();
|
271 |
-
/* THIS HERE GETS ARE INFORMATION IF ITS A GUEST THAT CHECKOUT AND NOT AN ACTUAL CUSTOMER */
|
272 |
-
if ($order->getCustomerIsGuest()) {
|
273 |
-
|
274 |
-
$valueid = $store->getData('website_id');
|
275 |
-
$website = $this->getWebsiteById($valueid);
|
276 |
-
//print($website);
|
277 |
-
$row['website'] = $website->getCode();
|
278 |
-
#$row['website'] = $storefromorder->getCode();
|
279 |
-
$row['group_id'] = $store->getGroup()->getName();
|
280 |
-
|
281 |
-
if(method_exists($order, 'getBillingAddress') && method_exists($order->getBillingAddress(), 'getData')) {
|
282 |
-
$row['prefix'] = $order->getBillingAddress()->getData('prefix');
|
283 |
-
$row['firstname'] = $order->getBillingAddress()->getData('firstname');
|
284 |
-
$row['middlename'] = $order->getBillingAddress()->getData('middlename');
|
285 |
-
$row['lastname'] = $order->getBillingAddress()->getData('lastname');
|
286 |
-
$row['suffix'] = $order->getBillingAddress()->getData('suffix');
|
287 |
-
$row['password'] = "changeme";
|
288 |
-
$row['billing_prefix'] = $order->getBillingAddress()->getData('prefix');
|
289 |
-
$row['billing_firstname'] = $order->getBillingAddress()->getData('firstname');
|
290 |
-
$row['billing_middlename'] = $order->getBillingAddress()->getData('middlename');
|
291 |
-
$row['billing_lastname'] = $order->getBillingAddress()->getData('lastname');
|
292 |
-
$row['billing_suffix'] = $order->getBillingAddress()->getData('suffix');
|
293 |
-
#$row['billing_street_full'] = $order->getBillingAddress()->getData('street');
|
294 |
-
$row['billing_street_full'] = $order->getBillingAddress()->getStreet(1);
|
295 |
-
$row['billing_street_2'] = $order->getBillingAddress()->getStreet(2);
|
296 |
-
$row['billing_city'] = $order->getBillingAddress()->getData('city');
|
297 |
-
$row['billing_region'] = $order->getBillingAddress()->getData('region');
|
298 |
-
$row['billing_country'] = $order->getBillingAddress()->getData('country_id');
|
299 |
-
$row['billing_postcode'] = $order->getBillingAddress()->getData('postcode');
|
300 |
-
$row['billing_telephone'] = $order->getBillingAddress()->getData('telephone');
|
301 |
-
$row['billing_company'] = $order->getBillingAddress()->getData('company');
|
302 |
-
$row['billing_fax'] = $order->getBillingAddress()->getData('fax');
|
303 |
-
} else {
|
304 |
-
$row['prefix'] = $order->getData('prefix');
|
305 |
-
$row['firstname'] = $order->getData('firstname');
|
306 |
-
$row['middlename'] = $order->getData('middlename');
|
307 |
-
$row['lastname'] = $order->getData('lastname');
|
308 |
-
$row['suffix'] = $order->getData('suffix');
|
309 |
-
$row['password'] = "changeme";
|
310 |
-
$row['billing_prefix'] = $order->getData('prefix');
|
311 |
-
$row['billing_firstname'] = $order->getData('firstname');
|
312 |
-
$row['billing_middlename'] = $order->getData('middlename');
|
313 |
-
$row['billing_lastname'] = $order->getData('lastname');
|
314 |
-
$row['billing_suffix'] = $order->getData('suffix');
|
315 |
-
$row['billing_street_full'] = $order->getData('street');
|
316 |
-
$row['billing_street_2'] = "";
|
317 |
-
$row['billing_city'] = $order->getData('city');
|
318 |
-
$row['billing_region'] = $order->getData('region');
|
319 |
-
$row['billing_country'] = $order->getData('country_id');
|
320 |
-
$row['billing_postcode'] = $order->getData('postcode');
|
321 |
-
$row['billing_telephone'] = $order->getData('telephone');
|
322 |
-
$row['billing_company'] = $order->getData('company');
|
323 |
-
$row['billing_fax'] = $order->getData('fax');
|
324 |
-
}
|
325 |
-
//THIS CHECKS TO MAKE SURE WE ALSO HAVE A SHIPPING ADDDRESS FOR THIS ORDER IN SOMECASE WE MAY NOT.
|
326 |
-
if(method_exists($order, 'getShippingAddress') && method_exists($order->getShippingAddress(), 'getData')) {
|
327 |
-
$row['shipping_prefix'] = $order->getShippingAddress()->getData('prefix');
|
328 |
-
$row['shipping_firstname'] = $order->getShippingAddress()->getData('firstname');
|
329 |
-
$row['shipping_middlename'] = $order->getShippingAddress()->getData('middlename');
|
330 |
-
$row['shipping_lastname'] = $order->getShippingAddress()->getData('lastname');
|
331 |
-
$row['shipping_suffix'] = $order->getShippingAddress()->getData('suffix');
|
332 |
-
$row['shipping_street_full'] = $order->getShippingAddress()->getStreet(1);
|
333 |
-
$row['shipping_street_2'] = $order->getShippingAddress()->getStreet(2);
|
334 |
-
$row['shipping_city'] = $order->getShippingAddress()->getData('city');
|
335 |
-
$row['shipping_region'] = $order->getShippingAddress()->getData('region');
|
336 |
-
$row['shipping_country'] = $order->getShippingAddress()->getData('country_id');
|
337 |
-
$row['shipping_postcode'] = $order->getShippingAddress()->getData('postcode');
|
338 |
-
$row['shipping_telephone'] = $order->getShippingAddress()->getData('telephone');
|
339 |
-
$row['shipping_company'] = $order->getShippingAddress()->getData('company');
|
340 |
-
$row['shipping_fax'] = $order->getShippingAddress()->getData('fax');
|
341 |
-
} else {
|
342 |
-
$row['shipping_prefix'] = $order->getData('prefix');
|
343 |
-
$row['shipping_firstname'] = $order->getData('firstname');
|
344 |
-
$row['shipping_middlename'] = $order->getData('middlename');
|
345 |
-
$row['shipping_lastname'] = $order->getData('lastname');
|
346 |
-
$row['shipping_suffix'] = $order->getData('suffix');
|
347 |
-
$row['shipping_street_full'] = $order->getStreet(1);
|
348 |
-
$row['shipping_street_2'] = $order->getStreet(2);
|
349 |
-
$row['shipping_city'] = $order->getData('city');
|
350 |
-
$row['shipping_region'] = $order->getData('region');
|
351 |
-
$row['shipping_country'] = $order->getData('country_id');
|
352 |
-
$row['shipping_postcode'] = $order->getData('postcode');
|
353 |
-
$row['shipping_telephone'] = $order->getData('telephone');
|
354 |
-
$row['shipping_company'] = $order->getData('company');
|
355 |
-
$row['shipping_fax'] = $order->getData('fax');
|
356 |
-
}
|
357 |
-
$row['email'] = $order->getCustomerEmail();
|
358 |
-
$row['customers_id'] = "0";
|
359 |
-
|
360 |
-
} else {
|
361 |
-
$customer = $this->getCustomerModel()
|
362 |
-
->setData(array())
|
363 |
-
->load($customerId);
|
364 |
-
/* @var $customer Mage_Customer_Model_Customer */
|
365 |
-
|
366 |
-
$position = Mage::helper('catalog')->__('Line %d, Email: %s', ($i+1), $customer->getEmail());
|
367 |
-
$this->setPosition($position);
|
368 |
-
|
369 |
-
foreach ($customer->getData() as $field => $value) {
|
370 |
-
//echo "FIELDS: " . $field;
|
371 |
-
if ($field == 'website_id') {
|
372 |
-
$website = $this->getWebsiteById($value);
|
373 |
-
if ($website === false) {
|
374 |
-
$website = $this->getWebsiteById(0);
|
375 |
-
}
|
376 |
-
$row['website'] = $website->getCode();
|
377 |
-
#$row['website'] = $storefromorder->getCode();
|
378 |
-
continue;
|
379 |
-
}
|
380 |
-
if (in_array($field, $systemFields) || is_object($value)) {
|
381 |
-
continue;
|
382 |
-
}
|
383 |
-
|
384 |
-
$attribute = $this->getAttribute($field);
|
385 |
-
if (!$attribute) {
|
386 |
-
continue;
|
387 |
-
}
|
388 |
-
|
389 |
-
if ($attribute->usesSource()) {
|
390 |
-
|
391 |
-
$option = $attribute->getSource()->getOptionText($value);
|
392 |
-
if ($value && empty($option)) {
|
393 |
-
$message = Mage::helper('catalog')->__("Invalid option id specified for %s (%s), skipping the record", $field, $value);
|
394 |
-
$this->addException($message, Mage_Dataflow_Model_Convert_Exception::ERROR);
|
395 |
-
continue;
|
396 |
-
}
|
397 |
-
if (is_array($option)) {
|
398 |
-
$value = join(self::MULTI_DELIMITER, $option);
|
399 |
-
} else {
|
400 |
-
$value = $option;
|
401 |
-
}
|
402 |
-
unset($option);
|
403 |
-
}
|
404 |
-
elseif (is_array($value)) {
|
405 |
-
continue;
|
406 |
-
}
|
407 |
-
$row[$field] = $value;
|
408 |
-
$row['email'] = $order->getCustomerEmail();
|
409 |
-
}
|
410 |
-
$row['password'] = "changeme";
|
411 |
-
|
412 |
-
$defaultBillingId = $customer->getDefaultBilling();
|
413 |
-
$defaultShippingId = $customer->getDefaultShipping();
|
414 |
-
|
415 |
-
$customerAddress = $this->getCustomerAddressModel();
|
416 |
-
|
417 |
-
if (!$defaultBillingId) {
|
418 |
-
foreach ($this->getFields() as $code=>$node) {
|
419 |
-
if ($node->is('billing')) {
|
420 |
-
$row['billing_'.$code] = null;
|
421 |
-
}
|
422 |
-
}
|
423 |
-
}
|
424 |
-
else {
|
425 |
-
$customerAddress->load($defaultBillingId);
|
426 |
-
|
427 |
-
foreach ($this->getFields() as $code=>$node) {
|
428 |
-
if ($node->is('billing')) {
|
429 |
-
if($code == "street_full") {
|
430 |
-
$row['billing_street_full'] = $customerAddress->getDataUsingMethod("street_1");
|
431 |
-
$row['billing_street_2'] = $customerAddress->getDataUsingMethod("street_2");
|
432 |
-
} else {
|
433 |
-
$row['billing_'.$code] = $customerAddress->getDataUsingMethod($code);
|
434 |
-
}
|
435 |
-
}
|
436 |
-
}
|
437 |
-
}
|
438 |
-
|
439 |
-
if (!$defaultShippingId) {
|
440 |
-
foreach ($this->getFields() as $code=>$node) {
|
441 |
-
if ($node->is('shipping')) {
|
442 |
-
$row['shipping_'.$code] = null;
|
443 |
-
}
|
444 |
-
}
|
445 |
-
}
|
446 |
-
else {
|
447 |
-
if ($defaultShippingId != $defaultBillingId) {
|
448 |
-
$customerAddress->load($defaultShippingId);
|
449 |
-
}
|
450 |
-
foreach ($this->getFields() as $code=>$node) {
|
451 |
-
if ($node->is('shipping')) {
|
452 |
-
if($code == "street_full") {
|
453 |
-
$row['shipping_street_full'] = $customerAddress->getDataUsingMethod("street_1");
|
454 |
-
$row['shipping_street_2'] = $customerAddress->getDataUsingMethod("street_2");
|
455 |
-
} else {
|
456 |
-
$row['shipping_'.$code] = $customerAddress->getDataUsingMethod($code);
|
457 |
-
}
|
458 |
-
}
|
459 |
-
}
|
460 |
-
}
|
461 |
-
|
462 |
-
} //if guest end if statement
|
463 |
-
|
464 |
-
$customerId = $order->getData('customer_id');
|
465 |
-
$customer = $this->getCustomerModel()
|
466 |
-
->setData(array())
|
467 |
-
->load($customerId);
|
468 |
-
//print($customer);
|
469 |
-
$store = $this->getStoreById($customer->getStoreId());
|
470 |
-
if ($store === false) {
|
471 |
-
$store = $this->getStoreById(0);
|
472 |
-
}
|
473 |
-
$row['created_in'] = $store->getCode();
|
474 |
-
|
475 |
-
$newsletter = $this->getNewsletterModel()
|
476 |
-
->loadByCustomer($customer);
|
477 |
-
$row['is_subscribed'] = ($newsletter->getId()
|
478 |
-
&& $newsletter->getSubscriberStatus() == Mage_Newsletter_Model_Subscriber::STATUS_SUBSCRIBED)
|
479 |
-
? 1 : 0;
|
480 |
-
/* ADDITIONAL ORDER DETAILS TO EXPORT */
|
481 |
-
#print_r($order);
|
482 |
-
$row['customers_id'] = $customerId;
|
483 |
-
$row['order_id'] = $order->getData('increment_id');
|
484 |
-
$row['created_at'] = $order->getData('created_at');
|
485 |
-
$row['updated_at'] = $order->getData('updated_at');
|
486 |
-
$row['tax_amount'] = $order->getData('tax_amount');
|
487 |
-
$row['shipping_method'] = $order->getData('shipping_method');
|
488 |
-
$row['shipping_amount'] = $order->getData('shipping_amount');
|
489 |
-
$row['discount_amount'] = $order->getData('discount_amount');
|
490 |
-
$row['subtotal'] = $order->getData('subtotal');
|
491 |
-
$row['grand_total'] = $order->getData('grand_total');
|
492 |
-
$row['total_paid'] = $order->getData('total_paid');
|
493 |
-
$row['total_refunded'] = $order->getData('total_refunded');
|
494 |
-
$row['total_qty_ordered'] = $order->getData('total_qty_ordered');
|
495 |
-
$row['total_canceled'] = $order->getData('total_canceled');
|
496 |
-
$row['total_invoiced'] = $order->getData('total_invoiced');
|
497 |
-
$row['total_online_refunded'] = $order->getData('total_online_refunded');
|
498 |
-
$row['total_offline_refunded'] = $order->getData('total_offline_refunded');
|
499 |
-
$row['base_tax_amount'] = $order->getData('base_tax_amount');
|
500 |
-
$row['base_shipping_amount'] = $order->getData('base_shipping_amount');
|
501 |
-
$row['base_discount_amount'] = $order->getData('base_discount_amount');
|
502 |
-
$row['base_subtotal'] = $order->getData('base_subtotal');
|
503 |
-
$row['base_grand_total'] = $order->getData('base_grand_total');
|
504 |
-
$row['base_total_paid'] = $order->getData('base_total_paid');
|
505 |
-
$row['base_total_refunded'] = $order->getData('base_total_refunded');
|
506 |
-
$row['base_total_qty_ordered'] = $order->getData('base_total_qty_ordered');
|
507 |
-
$row['base_total_canceled'] = $order->getData('base_total_canceled');
|
508 |
-
$row['base_total_invoiced'] = $order->getData('base_total_invoiced');
|
509 |
-
$row['base_total_online_refunded'] = $order->getData('base_total_online_refunded');
|
510 |
-
$row['base_total_offline_refunded'] = $order->getData('base_total_offline_refunded');
|
511 |
-
$row['subtotal_refunded'] = $order->getData('subtotal_refunded');
|
512 |
-
$row['subtotal_canceled'] = $order->getData('subtotal_canceled');
|
513 |
-
$row['discount_refunded'] = $order->getData('discount_refunded');
|
514 |
-
$row['discount_invoiced'] = $order->getData('discount_invoiced');
|
515 |
-
$row['tax_refunded'] = $order->getData('tax_refunded');
|
516 |
-
$row['tax_canceled'] = $order->getData('tax_canceled');
|
517 |
-
$row['shipping_refunded'] = $order->getData('shipping_refunded');
|
518 |
-
$row['shipping_canceled'] = $order->getData('shipping_canceled');
|
519 |
-
$row['base_subtotal_refunded'] = $order->getData('base_subtotal_refunded');
|
520 |
-
$row['base_subtotal_canceled'] = $order->getData('base_subtotal_canceled');
|
521 |
-
$row['base_discount_refunded'] = $order->getData('base_discount_refunded');
|
522 |
-
$row['base_discount_canceled'] = $order->getData('base_discount_canceled');
|
523 |
-
$row['base_discount_invoiced'] = $order->getData('base_discount_invoiced');
|
524 |
-
$row['base_tax_refunded'] = $order->getData('base_tax_refunded');
|
525 |
-
$row['base_tax_canceled'] = $order->getData('base_tax_canceled');
|
526 |
-
$row['base_shipping_refunded'] = $order->getData('base_shipping_refunded');
|
527 |
-
$row['base_shipping_canceled'] = $order->getData('base_shipping_canceled');
|
528 |
-
$row['subtotal_invoiced'] = $order->getData('subtotal_invoiced');
|
529 |
-
$row['tax_invoiced'] = $order->getData('tax_invoiced');
|
530 |
-
$row['shipping_invoiced'] = $order->getData('shipping_invoiced');
|
531 |
-
$row['base_subtotal_invoiced'] = $order->getData('base_subtotal_invoiced');
|
532 |
-
$row['base_tax_invoiced'] = $order->getData('base_tax_invoiced');
|
533 |
-
$row['base_shipping_invoiced'] = $order->getData('base_shipping_invoiced');
|
534 |
-
$row['shipping_tax_amount'] = $order->getData('shipping_tax_amount');
|
535 |
-
$row['base_shipping_tax_amount'] = $order->getData('base_shipping_tax_amount');
|
536 |
-
$row['shipping_tax_refunded'] = $order->getData('shipping_tax_refunded');
|
537 |
-
$row['base_shipping_tax_refunded'] = $order->getData('base_shipping_tax_refunded');
|
538 |
-
|
539 |
-
if($order->getStoreId() !="") {
|
540 |
-
#$row['store_id'] = $this->getStoreId();
|
541 |
-
$row['store_id'] = $order->getStoreId();
|
542 |
-
} else {
|
543 |
-
$row['store_id'] = $this->getVar('store');
|
544 |
-
}
|
545 |
-
|
546 |
-
#if(method_exists($order->getPayment(), 'getMethod')) {
|
547 |
-
$row['payment_method'] = $order->getPayment()->getMethod();
|
548 |
-
#} else {
|
549 |
-
#$row['payment_method'] = "";
|
550 |
-
#}
|
551 |
-
$items = $order->getAllItems();
|
552 |
-
$itemscount = 1;
|
553 |
-
$finalproductsorder = "";
|
554 |
-
$finalvaluesfromoptions="";
|
555 |
-
$nonconfigurablesku="";
|
556 |
-
$theseproductsarebundlesimples="";
|
557 |
-
foreach ($items as $itemId => $item)
|
558 |
-
{
|
559 |
-
/*
|
560 |
-
$row['product_name_'.$itemscount.''] = $item->getName();
|
561 |
-
$row['product_price_'.$itemscount.''] = $item->getPrice();
|
562 |
-
$row['product_sku_'.$itemscount.''] = $item->getSku();
|
563 |
-
$row['product_id_'.$itemscount.''] = $item->getProductId();
|
564 |
-
$row['product_qty_'.$itemscount.''] = $item->getQtyToInvoice();
|
565 |
-
#$row['product_qty_'.$itemscount.''] = $item->getQtyOrdered();
|
566 |
-
//echo "TEST: " . $item->getData('product_options');
|
567 |
-
$itemscount++;
|
568 |
-
*/
|
569 |
-
#echo "SKU: " . $item->getSku();
|
570 |
-
#echo "TYPE: " . $item->getProductType();
|
571 |
-
|
572 |
-
$productoptionsfromconfigurables = unserialize($item->getData('product_options'));
|
573 |
-
|
574 |
-
if(isset($productoptionsfromconfigurables['attributes_info'])) {
|
575 |
-
foreach ($productoptionsfromconfigurables['attributes_info'] as $configurablesitemId => $configurablesitem)
|
576 |
-
{
|
577 |
-
#print_r($configurablesitem);
|
578 |
-
$finalvaluesfromoptions .= $configurablesitem['value'] . ":";
|
579 |
-
}
|
580 |
-
}
|
581 |
-
if ($item->getProductType() == "configurable") {
|
582 |
-
#print_r($item->getData('product_id'));
|
583 |
-
#$productconfigItem = Mage::getModel('catalog/product')->load($item->getData('product_id'));
|
584 |
-
#$configskuforexport = $productconfigItem->getSku();
|
585 |
-
$configskuforexport = $item->getSku();
|
586 |
-
$configskuforexport1 = $item->getSku(). "config"; //for when oddly simple and config skus match
|
587 |
-
#echo "CONFIG SKU: " . $configskuforexport . "<br/>";
|
588 |
-
$nonconfigurablesku = $item->getProductOptionByCode('simple_sku');
|
589 |
-
}
|
590 |
-
if ($item->getProductType() == "bundle") {
|
591 |
-
|
592 |
-
#print_r($item->getData());
|
593 |
-
$finalbundleoptions = "";
|
594 |
-
$theseproductsarebundlesimples = false;
|
595 |
-
#$productbundleItem = Mage::getModel('catalog/product')->load($item->getData('product_id'));
|
596 |
-
#$bundleskuforexport = $productbundleItem->getSku();
|
597 |
-
$bundleskuforexport = $item->getSku();
|
598 |
-
#echo "BUNDLE SKU: " . $bundleskuforexport . "<br/>";
|
599 |
-
#echo "BUNDLE SIMPLE SKU: " . $item->getSku();
|
600 |
-
$bundle_simple_skus = explode('-',$item->getSku());
|
601 |
-
foreach ($bundle_simple_skus as $bundle_single_sku_data) {
|
602 |
-
if($bundleskuforexport != $bundle_single_sku_data && $nonconfigurablesku != $bundle_single_sku_data) {
|
603 |
-
#echo "T: " . $bundle_single_sku_data . "~" .$item->getQtyOrdered(). "^";
|
604 |
-
$finalbundleoptions .= $bundle_single_sku_data . "~" .$item->getQtyOrdered(). "^";
|
605 |
-
$theseproductsarebundlesimples = true;
|
606 |
-
}
|
607 |
-
}
|
608 |
-
$final_bundle_simple_skus = substr_replace($finalbundleoptions,"",-1);
|
609 |
-
|
610 |
-
$productoptionsfrombundles = unserialize($item->getData('product_options'));
|
611 |
-
#print_r($productoptionsfrombundles['info_buyRequest']);
|
612 |
-
|
613 |
-
if(isset($productoptionsfrombundles['info_buyRequest']['bundle_option'])) {
|
614 |
-
foreach ($productoptionsfrombundles['info_buyRequest'] as $bundleitemId => $bundleitem)
|
615 |
-
{
|
616 |
-
#echo "T: " . $bundleitemId . "<br/>";
|
617 |
-
#echo "T2: " . $bundleitem . "<br/>";
|
618 |
-
#print_r($bundleitem);
|
619 |
-
}
|
620 |
-
}
|
621 |
-
}
|
622 |
-
//for when simple and config oddly match
|
623 |
-
if($finalvaluesfromoptions !="" && $item->getProductType() == "configurable" && $nonconfigurablesku != $configskuforexport1) {
|
624 |
-
#if($finalvaluesfromoptions !="" && $item->getProductType() == "configurable" && $nonconfigurablesku != $configskuforexport) {
|
625 |
-
$okcleanedfinalvalues = substr_replace($finalvaluesfromoptions,"",-1);
|
626 |
-
|
627 |
-
if($this->getVar('export_product_pricing') == "true") {
|
628 |
-
$finalproductsorder .= $configskuforexport . ":" . $item->getQtyOrdered() . ":configurable:" . $okcleanedfinalvalues . "^" . $item->getPrice() . "^" . $item->getName() . "|";
|
629 |
-
} else {
|
630 |
-
$finalproductsorder .= $configskuforexport . ":" . $item->getQtyOrdered() . ":configurable:" . $okcleanedfinalvalues . "|";
|
631 |
-
}
|
632 |
-
|
633 |
-
} else if($item->getProductType() == "bundle") {
|
634 |
-
if($this->getVar('export_product_pricing') == "true") {
|
635 |
-
$finalproductsorder .= $bundleskuforexport . ":" . $item->getQtyOrdered() . ":bundle:" . $final_bundle_simple_skus;
|
636 |
-
} else {
|
637 |
-
$finalproductsorder .= $bundleskuforexport . ":" . $item->getQtyOrdered() . ":bundle:" . $final_bundle_simple_skus;
|
638 |
-
}
|
639 |
-
} else if($nonconfigurablesku != $item->getSku() && $theseproductsarebundlesimples != true) {
|
640 |
-
|
641 |
-
#$arrayofsimpleproductcustomoptios = $item->getProductOptions();
|
642 |
-
$currentoptionscount=0;
|
643 |
-
#$productsimplecustomItem = Mage::getModel('catalog/product')->load($item->getData('product_id'));
|
644 |
-
#if($productsimplecustomItem['has_options']) {
|
645 |
-
$itemsOptions = $item->getProductOptions();
|
646 |
-
#print_r($itemsOptions);
|
647 |
-
if(is_array($itemsOptions) && !empty($itemsOptions['options'])) {
|
648 |
-
#if($productsimplecustomItem->getTypeInstance(true)->hasOptions($productsimplecustomItem)) {
|
649 |
-
$finalsimpleoptionsexport = "";
|
650 |
-
foreach ($item->getProductOptions() as $option)
|
651 |
-
{
|
652 |
-
#print_r($option);
|
653 |
-
#echo "SKU: " . $item->getSku() . " ID: " . $order->getData('increment_id') . "<br/>";
|
654 |
-
if (isset($option[$currentoptionscount]['label']) && isset($option[$currentoptionscount]['value'])) {
|
655 |
-
$itemsoptionscount=1;
|
656 |
-
foreach ($option as $optionchoices) {
|
657 |
-
if (isset($optionchoices['label'])) {
|
658 |
-
//echo $optionchoices['label'];
|
659 |
-
$finalsimpleoptionsexport .= $optionchoices['value'] .":";
|
660 |
-
$itemsoptionscount++;
|
661 |
-
}
|
662 |
-
}
|
663 |
-
$currentoptionscount++;
|
664 |
-
|
665 |
-
if($this->getVar('export_product_pricing') == "true") {
|
666 |
-
$finalproductsorder .= $item->getSku() . ":" . $item->getQtyOrdered() . ":simple:" . substr_replace($finalsimpleoptionsexport,"",-1) . "^" . $item->getPrice() . "^" . $item->getName() . "|";
|
667 |
-
} else {
|
668 |
-
$finalproductsorder .= $item->getSku() . ":" . $item->getQtyOrdered() . ":simple:" . substr_replace($finalsimpleoptionsexport,"",-1) . "|";
|
669 |
-
}
|
670 |
-
}
|
671 |
-
}
|
672 |
-
} else {
|
673 |
-
|
674 |
-
if($this->getVar('export_product_pricing') == "true") {
|
675 |
-
$finalproductsorder .= $item->getSku() . ":" . $item->getQtyOrdered() . ":" . $item->getPrice() . ":" . $item->getName() . "|";
|
676 |
-
} else {
|
677 |
-
$finalproductsorder .= $item->getSku() . ":" . $item->getQtyOrdered() . "|";
|
678 |
-
}
|
679 |
-
}
|
680 |
-
}
|
681 |
-
|
682 |
-
#$finalproductsorder .= $item->getSku() .":" . $item->getQtyOrdered() . "|";
|
683 |
-
}
|
684 |
-
$row['products_ordered'] = substr_replace($finalproductsorder,"",-1);
|
685 |
-
|
686 |
-
//get product options
|
687 |
-
/*
|
688 |
-
print_r($item);
|
689 |
-
foreach ($item->getProductOptions() as $option)
|
690 |
-
{
|
691 |
-
//print_r($option);
|
692 |
-
if (isset($option[$currentoptionscount]['label']) && isset($option[$currentoptionscount]['value'])) {
|
693 |
-
$itemsoptionscount=1;
|
694 |
-
foreach ($option as $optionchoices) {
|
695 |
-
if (isset($optionchoices['label'])) {
|
696 |
-
//echo $optionchoices['label'];
|
697 |
-
$row['product_options_'.$itemsoptionscount.''] = $optionchoices['label'];
|
698 |
-
$row['product_options_'.$itemsoptionscount.''] .= " (".$optionchoices['value'].")";
|
699 |
-
$itemsoptionscount++;
|
700 |
-
}
|
701 |
-
}
|
702 |
-
$currentoptionscount++;
|
703 |
-
}
|
704 |
-
}
|
705 |
-
*/
|
706 |
-
$row['order_status'] = $order->getStatus();
|
707 |
-
|
708 |
-
$batchExport = $this->getBatchExportModel()
|
709 |
-
->setId(null)
|
710 |
-
->setBatchId($this->getBatchModel()->getId())
|
711 |
-
->setBatchData($row)
|
712 |
-
->setStatus(1)
|
713 |
-
->save();
|
714 |
-
$overallcount+=1;
|
715 |
-
} #ends check on count of orders being exported
|
716 |
-
}
|
717 |
-
|
718 |
-
return $this;
|
719 |
-
}
|
720 |
-
|
721 |
-
public function getExternalAttributes()
|
722 |
-
{
|
723 |
-
$internal = array(
|
724 |
-
'store_id',
|
725 |
-
'entity_id',
|
726 |
-
'website_id',
|
727 |
-
'group_id',
|
728 |
-
'created_in',
|
729 |
-
'default_billing',
|
730 |
-
'default_shipping',
|
731 |
-
'country_id'
|
732 |
-
);
|
733 |
-
|
734 |
-
$entityTypeId = Mage::getSingleton('eav/config')->getEntityType('customer')->getId();
|
735 |
-
$customerAttributes = Mage::getResourceModel('eav/entity_attribute_collection')
|
736 |
-
->setEntityTypeFilter($entityTypeId)
|
737 |
-
->load()->getIterator();
|
738 |
-
|
739 |
-
$entityTypeId = Mage::getSingleton('eav/config')->getEntityType('customer_address')->getId();
|
740 |
-
$addressAttributes = Mage::getResourceModel('eav/entity_attribute_collection')
|
741 |
-
->setEntityTypeFilter($entityTypeId)
|
742 |
-
->load()->getIterator();
|
743 |
-
|
744 |
-
$attributes = array(
|
745 |
-
'website' => 'website',
|
746 |
-
'email' => 'email',
|
747 |
-
'group' => 'group',
|
748 |
-
'create_in' => 'create_in',
|
749 |
-
'is_subscribed' => 'is_subscribed'
|
750 |
-
);
|
751 |
-
|
752 |
-
foreach ($customerAttributes as $attr) {
|
753 |
-
$code = $attr->getAttributeCode();
|
754 |
-
if (in_array($code, $internal) || $attr->getFrontendInput()=='hidden') {
|
755 |
-
continue;
|
756 |
-
}
|
757 |
-
$attributes[$code] = $code;
|
758 |
-
}
|
759 |
-
$attributes['password_hash'] = 'password_hash';
|
760 |
-
|
761 |
-
foreach ($addressAttributes as $attr) {
|
762 |
-
$code = $attr->getAttributeCode();
|
763 |
-
if (in_array($code, $internal) || $attr->getFrontendInput()=='hidden') {
|
764 |
-
continue;
|
765 |
-
}
|
766 |
-
$attributes['billing_'.$code] = 'billing_'.$code;
|
767 |
-
}
|
768 |
-
$attributes['billing_country'] = 'billing_country';
|
769 |
-
|
770 |
-
foreach ($addressAttributes as $attr) {
|
771 |
-
$code = $attr->getAttributeCode();
|
772 |
-
if (in_array($code, $internal) || $attr->getFrontendInput()=='hidden') {
|
773 |
-
continue;
|
774 |
-
}
|
775 |
-
$attributes['shipping_'.$code] = 'shipping_'.$code;
|
776 |
-
}
|
777 |
-
$attributes['shipping_country'] = 'shipping_country';
|
778 |
-
|
779 |
-
return $attributes;
|
780 |
-
}
|
781 |
-
|
782 |
-
|
783 |
-
|
784 |
-
/**
|
785 |
-
* @deprecated not used anymore
|
786 |
-
*/
|
787 |
-
public function parse()
|
788 |
-
{
|
789 |
-
$data = $this->getData();
|
790 |
-
|
791 |
-
$entityTypeId = Mage::getSingleton('eav/config')->getEntityType('customer')->getId();
|
792 |
-
$result = array();
|
793 |
-
foreach ($data as $i=>$row) {
|
794 |
-
$this->setPosition('Line: '.($i+1));
|
795 |
-
try {
|
796 |
-
|
797 |
-
// validate SKU
|
798 |
-
if (empty($row['email'])) {
|
799 |
-
$this->addException(Mage::helper('customer')->__('Missing email, skipping the record'), Varien_Convert_Exception::ERROR);
|
800 |
-
continue;
|
801 |
-
}
|
802 |
-
$this->setPosition('Line: '.($i+1).', email: '.$row['email']);
|
803 |
-
|
804 |
-
// try to get entity_id by sku if not set
|
805 |
-
/*
|
806 |
-
if (empty($row['entity_id'])) {
|
807 |
-
$row['entity_id'] = $this->getResource()->getProductIdBySku($row['email']);
|
808 |
-
}
|
809 |
-
*/
|
810 |
-
|
811 |
-
// if attribute_set not set use default
|
812 |
-
if (empty($row['attribute_set'])) {
|
813 |
-
$row['attribute_set'] = 'Default';
|
814 |
-
}
|
815 |
-
|
816 |
-
// get attribute_set_id, if not throw error
|
817 |
-
$row['attribute_set_id'] = $this->getAttributeSetId($entityTypeId, $row['attribute_set']);
|
818 |
-
if (!$row['attribute_set_id']) {
|
819 |
-
$this->addException(Mage::helper('customer')->__("Invalid attribute set specified, skipping the record"), Varien_Convert_Exception::ERROR);
|
820 |
-
continue;
|
821 |
-
}
|
822 |
-
|
823 |
-
if (empty($row['group'])) {
|
824 |
-
$row['group'] = 'General';
|
825 |
-
}
|
826 |
-
|
827 |
-
if (empty($row['firstname'])) {
|
828 |
-
$this->addException(Mage::helper('customer')->__('Missing firstname, skipping the record'), Varien_Convert_Exception::ERROR);
|
829 |
-
continue;
|
830 |
-
}
|
831 |
-
//$this->setPosition('Line: '.($i+1).', Firstname: '.$row['firstname']);
|
832 |
-
|
833 |
-
if (empty($row['lastname'])) {
|
834 |
-
$this->addException(Mage::helper('customer')->__('Missing lastname, skipping the record'), Varien_Convert_Exception::ERROR);
|
835 |
-
continue;
|
836 |
-
}
|
837 |
-
//$this->setPosition('Line: '.($i+1).', Lastname: '.$row['lastname']);
|
838 |
-
|
839 |
-
/*
|
840 |
-
// get product type_id, if not throw error
|
841 |
-
$row['type_id'] = $this->getProductTypeId($row['type']);
|
842 |
-
if (!$row['type_id']) {
|
843 |
-
$this->addException(Mage::helper('catalog')->__("Invalid product type specified, skipping the record"), Varien_Convert_Exception::ERROR);
|
844 |
-
continue;
|
845 |
-
}
|
846 |
-
*/
|
847 |
-
|
848 |
-
// get store ids
|
849 |
-
$storeIds = $this->getStoreIds(isset($row['store']) ? $row['store'] : $this->getVar('store'));
|
850 |
-
if (!$storeIds) {
|
851 |
-
$this->addException(Mage::helper('customer')->__("Invalid store specified, skipping the record"), Varien_Convert_Exception::ERROR);
|
852 |
-
continue;
|
853 |
-
}
|
854 |
-
|
855 |
-
// import data
|
856 |
-
$rowError = false;
|
857 |
-
foreach ($storeIds as $storeId) {
|
858 |
-
$collection = $this->getCollection($storeId);
|
859 |
-
//print_r($collection);
|
860 |
-
$entity = $collection->getEntity();
|
861 |
-
|
862 |
-
$model = Mage::getModel('customer/customer');
|
863 |
-
$model->setStoreId($storeId);
|
864 |
-
if (!empty($row['entity_id'])) {
|
865 |
-
$model->load($row['entity_id']);
|
866 |
-
}
|
867 |
-
foreach ($row as $field=>$value) {
|
868 |
-
$attribute = $entity->getAttribute($field);
|
869 |
-
if (!$attribute) {
|
870 |
-
continue;
|
871 |
-
#$this->addException(Mage::helper('catalog')->__("Unknown attribute: %s", $field), Varien_Convert_Exception::ERROR);
|
872 |
-
|
873 |
-
}
|
874 |
-
|
875 |
-
if ($attribute->usesSource()) {
|
876 |
-
$source = $attribute->getSource();
|
877 |
-
$optionId = $this->getSourceOptionId($source, $value);
|
878 |
-
if (is_null($optionId)) {
|
879 |
-
$rowError = true;
|
880 |
-
$this->addException(Mage::helper('customer')->__("Invalid attribute option specified for attribute %s (%s), skipping the record", $field, $value), Varien_Convert_Exception::ERROR);
|
881 |
-
continue;
|
882 |
-
}
|
883 |
-
$value = $optionId;
|
884 |
-
}
|
885 |
-
$model->setData($field, $value);
|
886 |
-
|
887 |
-
}//foreach ($row as $field=>$value)
|
888 |
-
|
889 |
-
|
890 |
-
$billingAddress = $model->getPrimaryBillingAddress();
|
891 |
-
$customer = Mage::getModel('customer/customer')->load($model->getId());
|
892 |
-
|
893 |
-
|
894 |
-
if (!$billingAddress instanceof Mage_Customer_Model_Address) {
|
895 |
-
$billingAddress = new Mage_Customer_Model_Address();
|
896 |
-
if ($customer->getId() && $customer->getDefaultBilling()) {
|
897 |
-
$billingAddress->setId($customer->getDefaultBilling());
|
898 |
-
}
|
899 |
-
}
|
900 |
-
|
901 |
-
$regions = Mage::getResourceModel('directory/region_collection')->addRegionNameFilter($row['billing_region'])->load();
|
902 |
-
if ($regions) foreach($regions as $region) {
|
903 |
-
$regionId = $region->getId();
|
904 |
-
}
|
905 |
-
|
906 |
-
$billingAddress->setFirstname($row['firstname']);
|
907 |
-
$billingAddress->setLastname($row['lastname']);
|
908 |
-
$billingAddress->setCity($row['billing_city']);
|
909 |
-
$billingAddress->setRegion($row['billing_region']);
|
910 |
-
$billingAddress->setRegionId($regionId);
|
911 |
-
$billingAddress->setCountryId($row['billing_country']);
|
912 |
-
$billingAddress->setPostcode($row['billing_postcode']);
|
913 |
-
$billingAddress->setStreet(array($row['billing_street1'],$row['billing_street2']));
|
914 |
-
if (!empty($row['billing_telephone'])) {
|
915 |
-
$billingAddress->setTelephone($row['billing_telephone']);
|
916 |
-
}
|
917 |
-
|
918 |
-
if (!$model->getDefaultBilling()) {
|
919 |
-
$billingAddress->setCustomerId($model->getId());
|
920 |
-
$billingAddress->setIsDefaultBilling(true);
|
921 |
-
$billingAddress->save();
|
922 |
-
$model->setDefaultBilling($billingAddress->getId());
|
923 |
-
$model->addAddress($billingAddress);
|
924 |
-
if ($customer->getDefaultBilling()) {
|
925 |
-
$model->setDefaultBilling($customer->getDefaultBilling());
|
926 |
-
} else {
|
927 |
-
$shippingAddress->save();
|
928 |
-
$model->setDefaultShipping($billingAddress->getId());
|
929 |
-
$model->addAddress($billingAddress);
|
930 |
-
|
931 |
-
}
|
932 |
-
}
|
933 |
-
|
934 |
-
$shippingAddress = $model->getPrimaryShippingAddress();
|
935 |
-
if (!$shippingAddress instanceof Mage_Customer_Model_Address) {
|
936 |
-
$shippingAddress = new Mage_Customer_Model_Address();
|
937 |
-
if ($customer->getId() && $customer->getDefaultShipping()) {
|
938 |
-
$shippingAddress->setId($customer->getDefaultShipping());
|
939 |
-
}
|
940 |
-
}
|
941 |
-
|
942 |
-
$regions = Mage::getResourceModel('directory/region_collection')->addRegionNameFilter($row['shipping_region'])->load();
|
943 |
-
if ($regions) foreach($regions as $region) {
|
944 |
-
$regionId = $region->getId();
|
945 |
-
}
|
946 |
-
|
947 |
-
$shippingAddress->setFirstname($row['firstname']);
|
948 |
-
$shippingAddress->setLastname($row['lastname']);
|
949 |
-
$shippingAddress->setCity($row['shipping_city']);
|
950 |
-
$shippingAddress->setRegion($row['shipping_region']);
|
951 |
-
$shippingAddress->setRegionId($regionId);
|
952 |
-
$shippingAddress->setCountryId($row['shipping_country']);
|
953 |
-
$shippingAddress->setPostcode($row['shipping_postcode']);
|
954 |
-
$shippingAddress->setStreet(array($row['shipping_street1'], $row['shipping_street2']));
|
955 |
-
$shippingAddress->setCustomerId($model->getId());
|
956 |
-
if (!empty($row['shipping_telephone'])) {
|
957 |
-
$shippingAddress->setTelephone($row['shipping_telephone']);
|
958 |
-
}
|
959 |
-
|
960 |
-
if (!$model->getDefaultShipping()) {
|
961 |
-
if ($customer->getDefaultShipping()) {
|
962 |
-
$model->setDefaultShipping($customer->getDefaultShipping());
|
963 |
-
} else {
|
964 |
-
$shippingAddress->save();
|
965 |
-
$model->setDefaultShipping($shippingAddress->getId());
|
966 |
-
$model->addAddress($shippingAddress);
|
967 |
-
|
968 |
-
}
|
969 |
-
$shippingAddress->setIsDefaultShipping(true);
|
970 |
-
}
|
971 |
-
|
972 |
-
if (!$rowError) {
|
973 |
-
$collection->addItem($model);
|
974 |
-
}
|
975 |
-
|
976 |
-
} //foreach ($storeIds as $storeId)
|
977 |
-
|
978 |
-
} catch (Exception $e) {
|
979 |
-
if (!$e instanceof Mage_Dataflow_Model_Convert_Exception) {
|
980 |
-
$this->addException(Mage::helper('customer')->__("Error during retrieval of option value: %s", $e->getMessage()), Mage_Dataflow_Model_Convert_Exception::FATAL);
|
981 |
-
}
|
982 |
-
}
|
983 |
-
}
|
984 |
-
$this->setData($this->_collections);
|
985 |
-
return $this;
|
986 |
-
}
|
987 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
app/code/local/Indianic/Reviewexport/Model/Convert/Parser/Reviewexport.php
CHANGED
@@ -1,5 +1,4 @@
|
|
1 |
<?php
|
2 |
-
|
3 |
class Indianic_Reviewexport_Model_Convert_Parser_Reviewexport extends Mage_Eav_Model_Convert_Parser_Abstract
|
4 |
{
|
5 |
const MULTI_DELIMITER = ' , ';
|
@@ -12,9 +11,7 @@ class Indianic_Reviewexport_Model_Convert_Parser_Reviewexport extends Mage_Eav_M
|
|
12 |
->load();
|
13 |
$csv_fields = array();
|
14 |
|
15 |
-
|
16 |
-
|
17 |
-
$write = Mage::getSingleton('core/resource')->getConnection('core_write');
|
18 |
foreach($reviews as $review)
|
19 |
{
|
20 |
$sku = $write->query('select sku from `catalog_product_entity` where entity_id = "'.$review->getEntity_pk_value().'" ');
|
@@ -24,21 +21,35 @@ class Indianic_Reviewexport_Model_Convert_Parser_Reviewexport extends Mage_Eav_M
|
|
24 |
$ratingCollection = Mage::getModel('rating/rating_option_vote')
|
25 |
->getResourceCollection()
|
26 |
->setReviewFilter($review->getId());
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
32 |
$csv_fields['created_at'] = $review->getCreated_at();
|
33 |
-
$csv_fields['Sku'] = $sku['sku'];
|
34 |
$csv_fields['status_id'] = $review->getStatus_id();
|
35 |
$csv_fields['title'] = $review->getTitle();
|
36 |
$csv_fields['detail'] = $review->getDetail();
|
37 |
$csv_fields['nickname'] = $review->getNickname();
|
38 |
$csv_fields['customer_id'] = $review->getCustomer_id();
|
39 |
-
$csv_fields['option_id'] = $
|
40 |
-
|
|
|
41 |
}
|
|
|
42 |
$batchExport = $this->getBatchExportModel()
|
43 |
->setId(null)
|
44 |
->setBatchId($this->getBatchModel()->getId())
|
@@ -46,6 +57,7 @@ class Indianic_Reviewexport_Model_Convert_Parser_Reviewexport extends Mage_Eav_M
|
|
46 |
->setStatus(1)
|
47 |
->save();
|
48 |
}
|
|
|
49 |
return $this;
|
50 |
}
|
51 |
public function parse()
|
1 |
<?php
|
|
|
2 |
class Indianic_Reviewexport_Model_Convert_Parser_Reviewexport extends Mage_Eav_Model_Convert_Parser_Abstract
|
3 |
{
|
4 |
const MULTI_DELIMITER = ' , ';
|
11 |
->load();
|
12 |
$csv_fields = array();
|
13 |
|
14 |
+
$write = Mage::getSingleton('core/resource')->getConnection('core_write');
|
|
|
|
|
15 |
foreach($reviews as $review)
|
16 |
{
|
17 |
$sku = $write->query('select sku from `catalog_product_entity` where entity_id = "'.$review->getEntity_pk_value().'" ');
|
21 |
$ratingCollection = Mage::getModel('rating/rating_option_vote')
|
22 |
->getResourceCollection()
|
23 |
->setReviewFilter($review->getId());
|
24 |
+
|
25 |
+
$rating_val = "";
|
26 |
+
$option = "";
|
27 |
+
$option_value = '';
|
28 |
+
foreach($ratingCollection as $rating)
|
29 |
+
{
|
30 |
+
|
31 |
+
$option = $rating->getOptionId();
|
32 |
+
$rating_val = $rating->getRatingId();
|
33 |
+
|
34 |
+
if(!empty($option_value) && $option_value != '')
|
35 |
+
$option_value = $option_value."@".$rating_val.":".$option;
|
36 |
+
else
|
37 |
+
$option_value = $rating_val.":".$option;
|
38 |
+
|
39 |
+
}
|
40 |
+
|
41 |
$csv_fields['created_at'] = $review->getCreated_at();
|
42 |
+
$csv_fields['Sku'] = $sku['sku'];
|
43 |
$csv_fields['status_id'] = $review->getStatus_id();
|
44 |
$csv_fields['title'] = $review->getTitle();
|
45 |
$csv_fields['detail'] = $review->getDetail();
|
46 |
$csv_fields['nickname'] = $review->getNickname();
|
47 |
$csv_fields['customer_id'] = $review->getCustomer_id();
|
48 |
+
$csv_fields['option_id'] = $option_value;
|
49 |
+
$csv_fields['entity_id'] = $review->getId();
|
50 |
+
|
51 |
}
|
52 |
+
|
53 |
$batchExport = $this->getBatchExportModel()
|
54 |
->setId(null)
|
55 |
->setBatchId($this->getBatchModel()->getId())
|
57 |
->setStatus(1)
|
58 |
->save();
|
59 |
}
|
60 |
+
|
61 |
return $this;
|
62 |
}
|
63 |
public function parse()
|
export.pdf
ADDED
Binary file
|
app/code/local/Indianic/Reviewexport/Note/export_review.csv
ADDED
@@ -0,0 +1,190 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
"created_at","Sku","status_id","title","detail","nickname","customer_id","option_id","entity_id"
|
2 |
+
"2013-04-20 07:07:40","bar1234","1","test","test","John","1","2:10@1:3@3:12","671"
|
3 |
+
"2008-04-18 20:56:56","LX.FR206.001","1","el mejor prodducto por el mejor precio","el mejor prodducto por el mejor precio","will","","1:3@3:14@2:10","113"
|
4 |
+
"2008-04-18 14:42:13","cn","1","perfect and cool","nice shoes, i recommend to y'all.
|
5 |
+
|
6 |
+
","turgen","","1:3@3:13@2:8","112"
|
7 |
+
"2008-04-18 04:10:58","QC-2185","1","good","oh yeah, so so cheesy","gib","","1:3@3:14@2:8","111"
|
8 |
+
"2008-04-17 22:26:01","LX.FR206.001","1","Awful Product","I have had nothing but problems with this product. When I received the computer the box was broken. I didn't think anything of it but when powered on the computer had a loud whirling sound. A few hours later it refused to turn on. It appears the cheap internal fan broke. I got a new one 2 weeks later. This time the optical drive broke 3 weeks later. I was beginning to become frustrated. After calling customer service they refused to give me a full refund because it had been over 60 days since I first bought it. I hesitantly accepted a third replacement. This one works but the shift button broke already and power cord no longer fits into the computer snugly. I ended up selling it to my cousin and buying a Mac.","SupaStar","","1:1@3:12@2:6","110"
|
9 |
+
"2008-04-17 20:57:16","sw810i","1","Loved It","Awesome Phone!","Phonelover","1","","109"
|
10 |
+
"2008-04-17 20:44:48","LX.FR206.001","1","Fantasticly Expensive","Great product, bit rip off","Joe Gimp","","1:5@3:11@2:8","108"
|
11 |
+
"2008-04-17 16:26:09","ac674","1","Pretty darn good","this is an amazing product with great features and superbly priced - i like it a lot!!","Danners","","1:5@3:13@2:9","107"
|
12 |
+
"2008-04-17 05:54:45","VGN-TXN27N/B","1","Good choice","I think this is the best laptop i've ever tried","Ata","","1:3@3:14@2:10","106"
|
13 |
+
"2008-04-16 00:12:49","1111","1","great website","great website","smerphy","1","1:3@3:14@2:9","105"
|
14 |
+
"2008-04-15 13:42:40","sw810i","1","Ist in Ordnung","ganz nette Funktionen","Müller","","1:2@3:13@2:8","104"
|
15 |
+
"2008-04-15 03:05:03","n2610","1","Meh","Not great, not awful.","Nick Name","","1:3@3:13@2:8","103"
|
16 |
+
"2008-04-15 01:49:03","ac674","1","can't do without","i can't take photos without this tripod now that i have one. great product!! ","gibbo","","1:4@3:13@2:9","102"
|
17 |
+
"2008-04-14 20:50:43","Rebel XT","1","This is a great camera","This camera rocks, Solid. beautiful pictures ","bob","","1:5@3:14@2:8","101"
|
18 |
+
"2008-04-14 17:01:49","1111","1","Word ottoman ever","I know because I am king of the Ottoman Empire","Xerses","1","1:1@3:11@2:6","100"
|
19 |
+
"2008-04-13 14:37:39","MA464LL/A","1","Apple has done it again!","The MacBook Pro is Apple's latest notebook and their first with Intel's new attempt at notebook dominance, the Core Duo. It represents the near peak of current notebook technology in terms of power, making only a few compromises for the sake of a slim profile and a better battery life. I am a college student who has been lusting over notebooks for the past two years, but with so many choices and every promising notebook seemingly always lacking in an essential area I was paralyzed by indecision (and a lack of funds). I will be attending Law School next fall and the time has finally come when owning a notebook is no longer an option. Luckily, notebook technology is better than ever, and I finally had some notebooks to choose from that represent nearly everything I have wanted since I first got the idea in my head that I needed one. I have simple needs: gaming capable graphics card, near desktop power, low weight, bright screen, decent battery life, and sweet looks (you know, the basics).
|
20 |
+
|
21 |
+
Once I saw the Core Duo I knew the day had arrived and that any laptop I bought was going to have it. I have to have a laptop before August so that took out waiting for the 64bit Core Duo sequel that is coming out sometime later this year or early next year (Merom).
|
22 |
+
|
23 |
+
The notebooks I considered getting were the W3J, the Acer 8204, and the new MacBook Pro from Apple, all top of the line machines which had the Radeon X1600 and the new Core Duo. The Apple wasn't really an option because the Law School I am attending requires a Windows machine. The Acer just had too many complaints of a poor screen and other problems, although I know people who are enjoying the machine just fine. I actually ordered the W3J last week but was dismayed to discover that my preorder wasn't made quite soon enough and I was going to have to wait even longer if I wanted that option. My preorder was cancelled about 4 days after the announcement of Boot Camp, which was not just a hack, but the promise of an (in the future) officially supported dual boot program. I'm no fool, and I wasn't going to spit the notebook gods in the face. I had been given a sign, and 24 hours later I picked up my (educationally discounted at $2,299) brand new MacBook Pro. This is my first Apple ever, but with the safety net of Boot Camp, I figured the time to dive in was now.","Stephen Lee","","1:5@3:13@2:9","99"
|
24 |
+
"2008-04-12 03:30:29","cn","1","nice","this is nice","mikey","","1:2@3:13@2:7","98"
|
25 |
+
"2008-04-11 00:14:14","nine_3","1","her the summary","that's my best review ;-)","lagad","1","","97"
|
26 |
+
"2008-04-08 00:11:16","1112","1","Amazing","Holy-Moly.","Crazy Pants","","1:5@3:15@2:10","96"
|
27 |
+
"2008-04-04 20:50:44","VGN-TXN27N/B","1","test","that's a very good product","swisswine","","1:5@3:14@2:9","95"
|
28 |
+
"2008-04-04 07:28:14","8525PDA","1","I got 'em","I got suspenders with mine","Mr Green Jeans","","1:5@3:14@2:9","94"
|
29 |
+
"2008-04-03 23:49:19","steve","1","They match my poodle's collar!","Now Sweetums and I are a perfect match!","Toodles","","1:1@3:11@2:6","93"
|
30 |
+
"2008-04-03 06:47:13","zol","1","It sucks","Its too small.","Dramatic Goefer","","1:2@3:11@2:8","92"
|
31 |
+
"2008-04-02 09:18:33","MM-A900M","1","great","great phone
|
32 |
+
with rich features","ashwani","1","1:5@3:14@2:9","91"
|
33 |
+
"2008-04-01 20:55:22","n2610","1","Sucks ","Sucks","Sucks","","1:1@3:11@2:6","90"
|
34 |
+
"2008-03-31 16:44:39","M285-E","1","Not Bad","perhaps i should have bought six instead of sixty six","Burt","","1:2@3:13@2:9","89"
|
35 |
+
"2008-03-31 14:23:41","Rebel XT","1","A little expensive for what you get","To be honest, the quality of the pictures it takes is excellent. But there are other cameras out there that do just a good a job for $100 less.","JohnnyBoy","","1:4@3:12@2:8","88"
|
36 |
+
"2008-03-30 19:14:06","VGN-TXN27N/B","1","i love this product","i love this product","german","","1:5@3:15@2:10","87"
|
37 |
+
"2008-03-30 06:58:03","VGN-TXN27N/B","1","A typical Sony product","Review goes here...","chucker","1","1:4@3:14@2:9","86"
|
38 |
+
"2008-03-28 04:33:06","ana","1","Look good but wow are they expensive for what they are!","These sandalls look good, very photogenenic, but would anybody seriously pay this price for them?","Pete","","1:3@3:11@2:6","85"
|
39 |
+
"2008-03-28 00:49:45","VGN-TXN27N/B","1","Cool application","This looks very nice I'll have to check out the back end","Nick","","1:4@3:13@2:8","84"
|
40 |
+
"2008-03-27 19:05:22","ana","1","The best!","Wow! Amazing shoes if I ever saw ones: great for those cold, dreary winter months, keep your feet warm and dry!","Jane Austin","","","83"
|
41 |
+
"2008-03-26 13:32:31","coal_sm","1","Love the shirt and print - but a bit too pricey","I'm a heavy spender of t-shirts and love the quality and prints offered, but the combinded price handling, shipping and item price is very high compared to desigener t-shirts","Dynamo","","1:5@3:13@2:10","82"
|
42 |
+
"2008-03-23 16:31:37","steve","1","Nice","I particulary liked the stylish color/design implementation of these Pumps.
|
43 |
+
|
44 |
+
I look forward to use them on the next Weekend Party!","Diane","","1:4@3:15@2:9","81"
|
45 |
+
"2008-03-22 22:20:12","ecco","1","These shoes rock","I was walking down the street one day, and I looked down at these shoes and thought, ""these are so great.""","Joe","","1:4@3:13@2:10","80"
|
46 |
+
"2008-03-21 18:33:56","nine_3","1","Increased my profit margins by 15%","These shoes are great....I was in so much demand with my usal tricks...I could put my prices up by 15%... These shoes will definitely work wonders on your Supply and Demand curve on your local turf :)","Lady of the night","","1:5@3:15@2:10","79"
|
47 |
+
"2008-03-19 22:27:53","ana","1","Mega shoes","I like it ...","Tester","1","1:5@3:15@2:10","78"
|
48 |
+
"2008-03-19 00:40:18","VGN-TXN27N/B","1","This notebook is great","This very high quality notebook great for office and business applications. ","tane","","1:5@3:14@2:10","77"
|
49 |
+
"2007-09-01 15:52:54","VGN-TXN27N/B","1","Excellent quality","The Sony producs have alway had an excellent quality and value.","Dr. Gish","","1:5@2:9@3:13","76"
|
50 |
+
"2007-09-01 12:54:58","ana","1","very cool","I love these","ilja","","1:1@2:6@3:11","75"
|
51 |
+
"2007-09-01 05:31:23","coal_1","1","Amazing","What a cool shirt, i wear it everyday","Me","","1:5@2:9@3:14","74"
|
52 |
+
"2007-09-01 01:56:36","ana","1","Good shoes","great look, solid design","Terry","","1:5@2:10@3:15","73"
|
53 |
+
"2007-08-31 17:11:41","coal_sm","1","Greattt","Very good product !","Moimeme","","1:4@2:9@3:15","72"
|
54 |
+
"2007-08-31 14:11:44","1111","1","Looks Good","Looks good and nice. Highly recommended ;)","devx","","1:5@2:10@3:15","71"
|
55 |
+
"2007-08-31 14:08:15","1114","1","This ist great - Love the style","I`ve been looking for such a couch for months now I've found it!","JBrunner","1","1:5@2:9@3:14","70"
|
56 |
+
"2007-08-31 14:07:13","4fasd5f5","1","Nice","very coll design","dimsal","","1:4@2:7@3:14","69"
|
57 |
+
"2007-08-31 13:41:07","384822","1","nice deal","made my living room looks great again","lopsta.com","","1:5@2:8@3:11","68"
|
58 |
+
"2007-08-31 13:28:56","nine_3","1","Top of the top","I've been wearing these shoes since 1912 and believe me, they're hot !","Didier","","1:4@2:9@3:15","67"
|
59 |
+
"2007-08-31 13:27:17","VGN-TXN27N/B","1","not bad","yeah it's alright I suppose","ryhrhrh","","1:4@2:8@3:13","66"
|
60 |
+
"2007-08-31 13:06:10","VGN-TXN27N/B","1","Solid Laptop","Expensive but solidly built laptop","Tommy","1","1:5@2:8@3:12","65"
|
61 |
+
"2007-08-31 12:44:35","ken","1","Kenneth Cole Slip Ons are a good choice for Work","I dont like them personally
|
62 |
+
","Zapateria","","1:3@2:9@3:13","64"
|
63 |
+
"2007-08-31 12:29:09","nine_3","1","These look great","I was the hottest drag model at the show","Johnny","","1:5@2:9@3:15","63"
|
64 |
+
"2007-08-31 12:10:10","LX.FR206.001","1","sounds great","what a great laptop!","Joe","1","1:5@2:10@3:15","62"
|
65 |
+
"2007-08-31 09:39:21","VGN-TXN27N/B","1","Light-weight small laptop","Sony VAIO TX serie is amazing light-weight laptop that I've ever seen it. But TZ is lastest and lighter than TX series.","Tarzan","1","1:4@2:9@3:13","61"
|
66 |
+
"2007-08-29 20:02:17","nine_6","1","I wear these as I walk down the Boardwalk","Sexy shoes that always draw attention to my legs... ","Fransisco","1","1:3@2:9@3:15","60"
|
67 |
+
"2007-08-29 19:57:44","steve","1","Sexy affordable shoes!","These a very sexy comfortable shoes... buy them and go out dancing!","Lady Jazz","1","1:4@2:9@3:14","59"
|
68 |
+
"2007-08-29 19:54:28","ken","1","All around comfort","these are great - whether in the office or a stroll to the store... wear these everywhere","Bret","1","1:4@2:8@3:13","58"
|
69 |
+
"2007-08-29 19:52:24","ecco","1","Great shoes, but a little expensive!","These are great... very comfortable. But a little expensive","Best Golfer Ever","1","1:3@2:9@3:13","57"
|
70 |
+
"2007-08-29 19:47:33","cn","1","My Party Shoes","So comfortable i were them when I go out. Whether your dancing or working in the garden, these are the perfect shoe!","J Mo","1","1:4@2:10@3:13","56"
|
71 |
+
"2007-08-29 19:44:17","zol","1","Makes me relive my rocker days!!!","The cat kind of looks like me... Great quality shirt at a good price...","Tetris","1","1:5@2:10@3:15","55"
|
72 |
+
"2007-08-29 19:40:20","ink","1","A little see thru","The shirt is a little transparent but is extremely comfortable.
|
73 |
+
One of my favorite shirts!","Linda","1","1:4@2:9@3:14","54"
|
74 |
+
"2007-08-29 19:37:46","coal_1","1","Comfortable!!!","This is the most comfortable shirt I own... I will buy many of these shirts","Essentl","1","1:4@2:8@3:14","53"
|
75 |
+
"2007-08-28 23:34:06","1113","1","Great inexpensive Couch","I love this couch... extremely comfortable and easy to clean
|
76 |
+
","Toish","1","1:4@2:9@3:13","52"
|
77 |
+
"2007-08-28 23:31:42","750","1","Good Camera","
|
78 |
+
77 of 82 people found the following review helpful:
|
79 |
+
Good Camera, October 11, 2006
|
80 |
+
By Steve (FL) - See all my reviews
|
81 |
+
Got it yesterday. In green. Actually it's a shiney yellowish-green. Nice feel. Fits well in shirt pocket. Very light; particullarly compared to my Pentax Optio 550. Good, nice size LCD. Easy to use yet with nice availability of choices for customization. Well written manual (you can find online thru google) and onboard help menu. Photos come out fairly nice. Tried indoors in low light with several scene settings, outdoors, macro, and supermacro. Colors look true, fairly sharp without noticable artifact. Used in South Florida morning daylight outside without any trouble with LCD viewing (camera has no classic viewfinder). Have read reviews of washout in bright sun: have not tried that yet. Overall, I'm happy with the camera thus far. ","Jenella","1","1:4@2:10@3:13","51"
|
82 |
+
"2007-08-28 23:29:57","A630","1","Amazing camera value!","This is one of those nice cameras that's so well done, it's easier to talk about what the camera ISN'T, rather than what it IS! This camera is not a small, shirt pocket camera, and might be a bit bigger than a woman would wish to carry in a purse. It's not a super-tele camera, but it does have a respectable, bit longer than average 4x optical zoom. ","Juan","1","1:5@2:10@3:14","50"
|
83 |
+
"2007-08-28 23:28:35","C530","1","great for everyday use","I purchased this camera a few months ago because I like to have a camera on hand always. My DSLR and 35 mm SLR cameras are too bulky for everyday. The price and MPs were right, as well as the small size which fits into the clean pockets of any of my purses- no need to worry about lens scratch. For those who don't carry a purse and are concerned about the lens, a very small case will do the trick. The images are clean although I've only printed up to 8.5 X 11 so far.","Stull","1","1:2@2:9@3:13","49"
|
84 |
+
"2007-08-28 23:06:56","MA464LL/A","1","I can't believe they still make PC's....","These Mac's are so much better than PC's it's unbelievable!!! Obviously designed for the user... less clicks to get to everything. amazing!!!","Terry Ferguson","1","1:5@2:10@3:14","48"
|
85 |
+
"2007-08-28 22:07:23","1111","1","I love this Ottoman","Best Ottoman ever!!!!","Terry Ferguson","1","1:4@1:4@2:4@3:4","47"
|
86 |
+
"2007-08-28 21:38:11","ana_9","1","These are the best sandals!","They were delivered really quickly and are just what I was expecting. The are great quality and so comfortable!","Jenna","1","1:5@2:5@3:5","46"
|
87 |
+
"2007-08-28 18:45:01","ana_9","1","great, comfy flip flops!","Very comfortable flip flops! I wear a size 10-11 and the ""extra-large"" was too small. Most stores don't carry the 10 or 11 (beyond extra-large) but I was able to find them on Amazon. Don't give up if you need a bigger size than the extra-large!","Erika","1","1:3@2:3@3:3","45"
|
88 |
+
"2007-08-28 16:40:25","Rebel XT","1"," The best thing I've ever bought","The XT is amazing. The battery comes partly charged so you can immedietly start using the camera (thank you Canon!) I've already shot about 200 pictures with it and the battery hasn't died yet.
|
89 |
+
|
90 |
+
|
91 |
+
|
92 |
+
|
93 |
+
","Al","1","1:5@2:5@3:5","44"
|
94 |
+
"2007-08-28 16:39:40","Rebel XT","1"," Another stunning winner from the bright minds at Canon","I spent three hours yesterday playing with the brand-new Canon Digital Rebel XT digital SLR camera, and man, was I impressed.
|
95 |
+
|
96 |
+
I hadn't been too impressed with the original Digital Rebel, except for its revolutionarily low price (for a d-SLR), because it was slow and felt slimsy. The new DR XT is quite different. Even though it's 3 ounces lighter than the original DR -- mostly due to the use of a smaller battery; see below -- its smaller form factor actually makes it feel more solid and ""real"". In other word, unlike the original DR, this one feels professional, not toy-like at all.
|
97 |
+
|
98 |
+
|
99 |
+
","Mira","1","1:4@2:3@3:3","43"
|
100 |
+
"2007-08-27 21:07:02","bar1234","1"," Excellent!"," Excellent wood bed and drawer set. Excellent value, fast shipping and a quality product. Awesome! ","David","1","1:5@2:4@3:3","42"
|
101 |
+
"2007-08-27 21:05:48","bar1234","1"," its a modern bed!","actually my bf and i we were looking for a king size bed..when i saw this bed it was beautiful and thats the color i like and also its a modern style....
|
102 |
+
","Gertrude","1","1:4@2:3@3:5","41"
|
103 |
+
"2007-08-27 21:02:45","384822","1","Buy this now!!!","This is a beautiful dresser with a rustic feel","Juan","1","1:4@2:4@3:3","40"
|
104 |
+
"2007-08-27 21:01:53","384822","1","Pretty Nice","This is great looking and functional dresser. I love it.","matt","1","1:3@2:3@3:3","39"
|
105 |
+
"2007-08-27 20:47:44","4fasd5f5","1"," !!!!!!","this is exactly what i wanted from a sweatshirt.
|
106 |
+
|
107 |
+
it has a tight figure with a full sized hood
|
108 |
+
and its really warm and comfortable. ","Sanchez","1","1:5@2:4@3:3","38"
|
109 |
+
"2007-08-27 20:46:21","ken_8","1","Top leather scuffed on first wear","The shoes look and wear great. However, the leather is pretty weak. I think I must have kicked a table leg or something on my frist outing in them. Now the tip of my left shoe has a quarter-size scuff on it. I will have to try to cover it up by oiling it. Obviously I don't think this pair will last long at all.","Lian","1","1:4@2:3@3:3","37"
|
110 |
+
"2007-08-27 20:45:54","ken_8","1"," Great Purchase. Best value and very comfortable,","I purchased a pair and have been using it everyday from the past six months. The shoes are very comfortable and look very professional. Love them.","Arun","1","1:3@2:3@3:3","36"
|
111 |
+
"2007-08-27 20:43:22","ecco_3","1","womens golf shoes","These shoes are my first pair of golf shoes.I have bad feet and wear orthotics so I really wanted a pair of shoes that would feel great on my feet. These are really nice and are a great price for this brand.","Moqilka","1","1:3@2:4@3:3","35"
|
112 |
+
"2007-08-27 20:42:47","ecco_3","1","Comfortable, good-looking","This is a sharp-looking shoe that is very comfortable for walking and provides a good alternative to the traditional, boring ""golf shoe.""
|
113 |
+
","Kathryn","1","1:3@2:3@3:3","34"
|
114 |
+
"2007-08-27 20:42:27","ecco_3","1"," lite golf shoe","nice shoe. A little tight in the width","Tippy","1","1:3@2:3@3:3","33"
|
115 |
+
"2007-08-27 20:40:56","nine_3","1","Classic and Cute","This shoe is comfortable and the way the front of the shoe is cut makes it a little more interesting.....","Vanessa","1","1:3@2:3@3:3","32"
|
116 |
+
"2007-08-27 20:38:21","steve_4","1","Good, Sexy Shoe","These shoes are beautiful, the bright ruby red color complimented by outfit nicely. It did take some breaking in but after which they were as comfortable as pumps can get.","Shoes!!!","1","1:3@2:4@3:4","31"
|
117 |
+
"2007-08-27 20:37:39","steve_4","1","Love the look and was comfy for heels!","Would give them 5 stars if not for the toe cleavage issue. Loved them enough to keep them though. Very cute!","Shoe Lover","1","1:3@2:3@3:3","30"
|
118 |
+
"2007-08-27 20:35:03","cn_3","1"," Beach Clogs,","I received these today in the mail and am pleased with the way these feel on my feet,they are so comfortable and so easy to slide on.","Laurie","1","1:2@2:4@3:3","29"
|
119 |
+
"2007-08-27 20:33:59","cn_3","1","Inexpensive and very light weight clog","This clog was inexpensive compared to crocs, but I found it did not fit my foot very well. It is, however, very light weight and would otherwise be comfortable. It is also not very attractive. I would not wear this one anywhere but my own yard for gardening, etc.","Loren","1","1:3@2:3@3:3","28"
|
120 |
+
"2007-08-27 20:30:12","zol_r_sm","1"," Well made, affordable. . .you can't go wrong!","I am very hard on my t-shirts, and therefore, I need the best quality t-shirt on the market. I've tried them all (except Hanes). Durable, strong, and surprisingly flattering to those of us lugging around a spare tire, if you get my drift.","Mike","1","1:5@2:2@3:3","27"
|
121 |
+
"2007-08-27 20:26:54","oc_sm","1","Great, affordable product","These tee shirts are generously cut, hold their color, stand up to repeated washings and are very comfortable. In addition, they are comfortable, extremely affordable and maintain their shape. I highly recommend them.","Patrick","1","1:3@2:3@3:3","26"
|
122 |
+
"2007-08-27 20:25:51","oc_sm","1","Perfect Cotton Feel","My friend really liked the Tee shirt.he did'nt think that I would be able to get it in his size but I was able to.I really made my friends day when I told him that I was able to find the tee shirt in the size he wanted.","Adam","1","1:3@2:3@3:3","25"
|
123 |
+
"2007-08-27 20:22:24","oc_sm","1","excellent","The T-shirt is a very good one. its comfortable and easy to wash, doesn't even soften the cloth when washed daily. i love it and good stuff","A Review","1","1:4@2:2@3:3","24"
|
124 |
+
"2007-08-27 20:20:11","ink_sm","1","Extremely Comfortable!!!","i love this T-shirt
|
125 |
+
the quality is nice
|
126 |
+
and it's very soft without tag
|
127 |
+
|
128 |
+
i bought the white one
|
129 |
+
it can be see through just like other custom's review.
|
130 |
+
|
131 |
+
also i think their size small is a little bigger than other brand
|
132 |
+
but it's not a big deal though! ","Robin","1","1:4@2:4@3:3","23"
|
133 |
+
"2007-08-26 21:58:49","coal_sm","1","Love it!!! get it!!!","You got to have one of these they come in green","yochan","1","1:5@2:4@3:3","22"
|
134 |
+
"2007-08-26 20:14:43","M285-E","1","Solid and reliable","At first, I wasn't terribly impressed. I had been accustomed to working
|
135 |
+
with a Toshiba Protege M405 at home and when I purchased the Gateway for
|
136 |
+
exclusive use at the office, my initial impression of the machine when
|
137 |
+
I put it into action was noticeably lacking in enthusiasm or excitement.
|
138 |
+
|
139 |
+
I've since come to appreciate this notebook for something much more
|
140 |
+
impressive that I couldn't gauge out of the box, and that was its
|
141 |
+
amazing reliability and performance over time.
|
142 |
+
|
143 |
+
This machine is solid. It does not crash.
|
144 |
+
|
145 |
+
","Mendez","1","1:4@2:4@3:4","21"
|
146 |
+
"2007-08-26 20:11:48","VGN-TXN27N/B","1","Sleek compact design for business travelers on the go.","I waited to get this notebook loaded with Vista. I have mixed feelings. The notebook hardware design is quite sleek and handsome. I am not so impressed with Vista running on this machine though. It just feels that Vista is a resource hog and is constantly running the CPU at 100% which causes the fan to run endlessly. I think the issue is that Sony used the same hardware specs as the previous TX series just to get a Vista version out quickly, but it really is not equipped to handle the new Vista OS as well. So I was disappointed when I upgraded to this notebook thinking that it would run faster, but actually it runs slower than my previous Vaio running Win XP. Though there are some improvements with Vista over XP, Vista probably runs better on a Duo Intel chipset than the Solo that is used in this notebook. The poor notebook is contantly working overtime just to do very simple normal every day applications and it takes forever to start up or reboot. If you just base it on looks alone, then it gets a 4 start rating.","Steven","1","1:3@2:3@3:3","20"
|
147 |
+
"2007-08-26 20:11:21","VGN-TXN27N/B","1","Vision of Vaio...","If you're buying this laptop, it's undoubtedly partially for the design, style and lightweight features of the TX series. You can get cheaper, better performing options at about the same weight, but it won't have the ""wow"" factor of this TXN27N. That being said let's get right into the pros and cons.
|
148 |
+
|
149 |
+
As a side note, if you're wondering about differences between the 25,27, 29 TX models, it's pretty straightforward. The 25 has 1GB RAM and 80GB hard drive, the 27 has 2GB RAM, 100 GB hard drive, the 29 is the same as the 27 except it comes with a carrying case and the exterior has a sleek special shiny coating. IMO, the 27N is the best value among the 3 when you look at the price points.
|
150 |
+
|
151 |
+
","Chen","1","1:3@2:3@3:3","19"
|
152 |
+
"2007-08-26 20:08:25","LX.FR206.001","1"," Not happy at all","I purchased the Red Ferrari Laptop and had nothing but problems form the start. I was supposed to get a free matching mouse, when I received the mouse it looked two years old. When I got laptop working the wrist rest pad right next to the mouse pad was heating up to an uncomfortable level. When I notified PCmode, the supplier of the laptop, they agreed to replace it with another laptop. When I asked if it had the same problems, they told me it headed up as all laptops heat up. The agreed to replace the laptop with another laptop but with a 50% lesser value than the one I purchased.
|
153 |
+
|
154 |
+
I will never buy from these people again... ","Cappello","1","1:3@2:3@3:3","18"
|
155 |
+
"2007-08-26 20:07:51","LX.FR206.001","1","It's worked phenominally for me so far...","Fortunately, the computer worked and worked well from the start for me. The performance is phenomenal, the craftsmanship and style are only slightly short of amazing. (sturdy and stylish, but heavy and heats up quickly.) I hope I never have to deal with customer service but the product performs. The worse thing is that if you have it set to use full power all of the time you get maybe an hour and a half of battery time. Still like my PowerBook better though.","Next","1","1:3@2:3@3:3","17"
|
156 |
+
"2007-08-26 19:57:30","MA464LL/A","1"," The Fastest Mac Notebook Ever","It's the most stunning idea, isn't it? This top of the line MacBook Pro is the fastest Mac Notebook ever, and probably one of the fastest Macs period.
|
157 |
+
|
158 |
+
When Steve Jobs announced the new Macs, with Intel Core Duo processors I was almost certain I wanted to buy one. Why? Macs are well known for ease of use and capabilities, but they have managed all that for years, with processors that are not always top-notch. That all changed in January 2006.
|
159 |
+
|
160 |
+
","Stephen","1","1:5@2:5@3:3","16"
|
161 |
+
"2007-08-26 19:32:56","n2610","1","Great phone - unless you are outside or in the car","I only needed a basic phone - no MP3, camera, or FM radio. This phone delivered with great reception, good sound quality, great battery life, and a very small size. Inside a building it works great. Why the low score? The tinted plastic over the display makes it impossible to see the display outdoors and in the car. If the sun is out, forget it! I even managed to figure out how to remove all of the wallpaper backgrounds and to maximize the contrast. Still, don't plan to use this outdoors. Nokia should recall this product to replace the tinted cover. Update: Yesterday this phone took was accidently dropped onto a very hard ceramic tile floor and it still works perfectly! A similar drop ended the life of my digital camera a few months ago. So, if I were to rate this cell phone now I would give it 3 stars, maybe even 4 stars. I like reliable, sturdy stuff and this cell seems to be unusually well made.","Sheridan","1","1:4@2:4@3:3","15"
|
162 |
+
"2007-08-26 19:29:16","MM-A900M","1","MJS","Yeah it looks cool, but it's got terrible sound quality, even with an ear-piece. Additionally, they've crammed a lot of stuff into the menus that would probably be desirable to some people, but if you don't want it, it's just more junk to have to navigate through.","Looks can be deceiving","1","1:3@2:3@3:3","14"
|
163 |
+
"2007-08-26 19:28:40","MM-A900M","1"," A crippled cell phone","1, you can not synchronize the phonebook with your PC in a convenient way. I had to code a program to generate single vcard files and send them over bluetooth ONE BY ONE. There seems to be no way to do it without bluetooth.
|
164 |
+
|
165 |
+
2, you can not apply mp3 files as ringtones. However you can download mp3/aac ringtones from sprint (for a fee). Oh the original ringtones that came with the phone? They are just awful.
|
166 |
+
|
167 |
+
","bessel","1","1:4@2:4@3:3","13"
|
168 |
+
"2007-08-26 19:28:11","MM-A900M","1","Fouch","I wouldn't normally write a review, but everyone is giving this phone a bad rap.. I think people that buy into those reviews are getting cheated out of an excellent phone. I've know several people with Razors that ALL like this much much better. The battery life is absolutely fine, and my phone is on vibrate all day. Maybe other reviewers are on the phone constantly on full blast playing mp3s and shooting video.. I don't get it. I've had this phone the better part of a year and never ran out of charge during the day. I plug it in at night. I work as an architect and am on the phone all day long and beat the living hell out of it.. which is another huge plus about this phone. It has a *sturdy* metal housing.. not thin toy crap a la razors or plastic like most phones. I don't do a lot of bluetooth, computer syncing, etc, just use the phone in a fairly conventional way, with regular camera use, and for that it is *easily* far and away the best phone I've ever owned.","solid phone","1","1:4@2:4@3:3","12"
|
169 |
+
"2007-08-26 19:19:19","bb8100","1","Sweet!","What I love:
|
170 |
+
============
|
171 |
+
- Form factor: It is beautiful, it is cute and catchy! It turns heads. Enough said.
|
172 |
+
- Size: Size is one of the strongest points considering all it does. It neatly slips into a shirt pocket or sits well on the belt.
|
173 |
+
- Keys: Could be a bit small but I could use it pretty easily though my fingers are bordering on 'butterfingers'.
|
174 |
+
- Trackball: Awesome! Just don't press it too hard while using it. Just 'roll-it'!. It is great while you have to move around the screen from control to control
|
175 |
+
- Voice-dialing: Has worked for me very well the 10 or so times I have tried in my van on the road and off. You have to first choose the voice dialing option from the list of icons on the main menu. I read you can ","Ashwini","1","1:4@2:4@3:3","11"
|
176 |
+
"2007-08-26 19:06:40","8525PDA","1","Worth the upgrade!!!","I've had this phone now for 2 weeks and it has met all of my expectations and exceeded them even. I upgraded from the 8125 and just about everything is a huge improvement!
|
177 |
+
The 3G(UMTS) is very impressive with it's speed. I even use this phone as a modem on my home pc and it's nearly identical in speed as DSL when surfing the net or downloading file/music etc.
|
178 |
+
Camera is very impressive with clear resolutions for a camera phone with the 2MP.
|
179 |
+
I also use a bluetooth headset 2.0 with this and mine works wonderfully with sony erriccson; it's quite intuitive and picks up the signal instantly. The 'blackberry' scroll wheel is a huge plus on this phone and I find myself using this feature more than any other buttons. ","Armstrong","1","1:3@2:3@3:3","10"
|
180 |
+
"2007-08-26 19:00:33","sw810i","1"," Ultimate Cell Phone","Wow....What a great cell phone. I really like.....no no.....LOVE this Phone. The Functions and usability of this one are too cool. The MP3 Player palys nice with good user interface. The 2.0 MP Camera is very good, I have stopped taking my Digi Cam to my trips. I never have anytype of problem during the phone call. So considering the +ve points, I truly recommend it to any one.","Ananda","1","1:3@2:4@3:3","9"
|
181 |
+
"2007-08-26 19:00:08","sw810i","1","Awesome Phone","The phone is awesome. Fully Loaded & sounds really great, camera is also good.2MP.
|
182 |
+
Excellent!!! ","Panda","1","1:3@2:3@3:3","8"
|
183 |
+
"2007-08-26 18:59:23","sw810i","1","Great all around phone","Hello all. Just received my phone a few days ago, was super fast shipping using the 2 day shipping option (which by the way is free!! So make sure you select that, as the discount is only shown when you are about to place the final purchase). Luckily I ordered my phone right before the phone was about in low stock.
|
184 |
+
PHONE: So can't really complain about much of anything. Phone has really intuitive interface, very easy to navigate as the arrow keys all function as shortcuts (to calls, file folders, aim, etc..). The walkman button is very convenient as it leads right to the music player. ","John Johnson","1","1:3@2:3@3:3","7"
|
185 |
+
"2007-08-25 19:33:12","asc_8","1","It's a pitty they don't have large sizes","You wont believe it, my show size is 13 so it's impossible for me to get a new pa","Seba's","1","1:3@2:3@3:3","6"
|
186 |
+
"2007-08-25 19:13:42","MM-A900M","1","Not an i-phone","cest ci nest pas une i-phone.","Udini","1","1:3@2:3@3:3","5"
|
187 |
+
"2007-08-25 19:07:26","coal_sm","1","chics dig ribs","Ever since buying this shirt chics cant take their hands off me. I don't know what it is it must be sprayed with axe - the seductive body spray for men. I'm the last one to believe commercials but I tell you you won't regret buying this shirt. I ordered it n every color.","udini","1","1:3@2:3@3:3","4"
|
188 |
+
"2007-08-25 19:03:22","ink_sm","1","Cute, but see through","Cute design, but material is too thin.","Natashenka","1","1:3@2:3@3:3","3"
|
189 |
+
"2007-08-25 16:53:30","8525PDA","1","I feel strange holding a television to my head","I feel strange holding a television to my head. This product should come with free suspenders","Starbuck","1","1:3@2:4@3:3","2"
|
190 |
+
"2007-08-25 15:09:12","coal_sm","1","I love this shirt!","This shirts if really great. Especially with the spinal diagram, finally I can see myself for who I really am! ","Sandra Doe","1","1:3@2:3@3:3","1"
|
app/code/local/Indianic/Reviewexport/Note/xml_data_to_paste_info_advanced_profile_export.txt
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<action type="Indianic_Reviewexport_Model_Convert_Parser_Reviewexport" method="unparse">
|
2 |
+
<var name="store"><![CDATA[0]]></var>
|
3 |
+
</action>
|
4 |
+
|
5 |
+
<action type="dataflow/convert_mapper_column" method="map">
|
6 |
+
</action>
|
7 |
+
|
8 |
+
<action type="dataflow/convert_parser_csv" method="unparse">
|
9 |
+
<var name="delimiter"><![CDATA[,]]></var>
|
10 |
+
<var name="enclose"><![CDATA["]]></var>
|
11 |
+
<var name="fieldnames">true</var>
|
12 |
+
</action>
|
13 |
+
|
14 |
+
<action type="dataflow/convert_adapter_io" method="save">
|
15 |
+
<var name="type">file</var>
|
16 |
+
<var name="path">var/export</var>
|
17 |
+
<var name="filename"><![CDATA[export_review.csv]]></var>
|
18 |
+
</action>
|
app/code/local/Indianic/Reviewexport/Note/xml_data_to_paste_into_advanced_profile_import.txt
ADDED
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<action type="dataflow/convert_adapter_io" method="load">
|
2 |
+
<var name="type">file</var>
|
3 |
+
<var name="path">var/import</var>
|
4 |
+
<var name="filename"><![CDATA[export_review.csv]]></var>
|
5 |
+
<var name="format"><![CDATA[csv]]></var>
|
6 |
+
</action>
|
7 |
+
|
8 |
+
<action type="dataflow/convert_parser_csv" method="parse">
|
9 |
+
<var name="delimiter"><![CDATA[,]]></var>
|
10 |
+
<var name="enclose"><![CDATA["]]></var>
|
11 |
+
<var name="fieldnames">true</var>
|
12 |
+
<var name="store"><![CDATA[0]]></var>
|
13 |
+
<var name="adapter">Indianic_Reviewexport_Model_Convert_Adapter_Reviewimport</var>
|
14 |
+
<var name="method">parse</var>
|
15 |
+
</action>
|
app/code/local/Indianic/Reviewexport/etc/config.xml
CHANGED
@@ -9,7 +9,7 @@
|
|
9 |
<config>
|
10 |
<modules>
|
11 |
<Indianic_Reviewexport>
|
12 |
-
<version>0.
|
13 |
</Indianic_Reviewexport>
|
14 |
</modules>
|
15 |
|
9 |
<config>
|
10 |
<modules>
|
11 |
<Indianic_Reviewexport>
|
12 |
+
<version>1.0.0.2</version>
|
13 |
</Indianic_Reviewexport>
|
14 |
</modules>
|
15 |
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Indianic_Reviewimportexport</name>
|
4 |
-
<version>1.0.0.
|
5 |
<stability>stable</stability>
|
6 |
<license>OSL v3.0</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>Import/export customer review from one magento set up to another</description>
|
11 |
<notes>Stable version</notes>
|
12 |
<authors><author><name>Mufaddal kapadiya</name><user>muffadal</user><email>muffadal.kapadiya@indianic.com</email></author></authors>
|
13 |
-
<date>2013-04-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magelocal"><dir name="Indianic"><dir name="Reviewexport"><dir name="Model"><dir name="Convert"><dir name="Adapter"><file name="Reviewimport.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php><package><name>Mage_core_modules</name><channel>community</channel><min>1.6.0.0</min><max>1.7</max></package><extension><name>gd</name><min>2.0.28</min><max>3.0</max></extension></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Indianic_Reviewimportexport</name>
|
4 |
+
<version>1.0.0.2</version>
|
5 |
<stability>stable</stability>
|
6 |
<license>OSL v3.0</license>
|
7 |
<channel>community</channel>
|
10 |
<description>Import/export customer review from one magento set up to another</description>
|
11 |
<notes>Stable version</notes>
|
12 |
<authors><author><name>Mufaddal kapadiya</name><user>muffadal</user><email>muffadal.kapadiya@indianic.com</email></author></authors>
|
13 |
+
<date>2013-04-20</date>
|
14 |
+
<time>09:03:44</time>
|
15 |
+
<contents><target name="magelocal"><dir name="Indianic"><dir name="Reviewexport"><dir name="Model"><dir name="Convert"><dir name="Adapter"><file name="Reviewimport.php" hash="df78142c6a66d38f954a6d002085fc4a"/></dir><dir name="Parser"><file name="Reviewexport.php" hash="efa149b91bef85039e75ebd22ff16310"/></dir></dir><file name="Reviewexport.php" hash="ef06553339bdd5c61640916e67bd7d9b"/></dir><dir name="Note"><file name="HOW TO INSTALL - setup advanced profiles for magento bulk product review import and export.pdf" hash="945f39143f75d4c4d8ea3c7b9f3e2f11"/><file name="export_review.csv" hash="926ab8b1be3f72f89f860834d6ae50c8"/><file name="xml_data_to_paste_info_advanced_profile_export.txt" hash="1a2c48111c80427a1a6516f386751d82"/><file name="xml_data_to_paste_into_advanced_profile_import.txt" hash="0b58c4fbfb0d150609022bc93b39906f"/></dir><dir name="etc"><file name="config.xml" hash="958b792c051c328185284a42141b9058"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Indianic_Review.xml" hash="9bc68c0dd9d6127a23cdd29ec9b6a650"/></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php><package><name>Mage_core_modules</name><channel>community</channel><min>1.6.0.0</min><max>1.7</max></package><extension><name>gd</name><min>2.0.28</min><max>3.0</max></extension></required></dependencies>
|
18 |
</package>
|