Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Plugin: Google Export & Data Feeds | Include " Eur" In List Price Value Rate Topic   - - - - -

 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 03 July 2019 - 01:55 PM #1

Hi there!, we enabled the "Data Feeds" & the "Google Export" feature in order to export to google ads our products, and everything seems to be fine except one issue..

(from the image attached google_export_01.jpg)

we would like at the end of the products to be 

....,15.00 EUR,7.50 EUR

etc..

and in google_export_01.jpg is our config in the panel

so we would like the export in csv of the field "List price" to be like "Google Price"

the website is mariedore.gr and we use CS-Cart 4.8.2.SP2. is it easy to be done?

thank you in advance

Attached Files



 
  • soft-solid
  • Junior Member
  • Members
  • Join Date: 19-Apr 10
  • 897 posts

Posted 03 July 2019 - 02:23 PM #2

Hello

 

Maybe this addon will meet your expectations

 

https://cs-cart.pl/m...s-to-languages/

 

Best regards

Robert


Team of SoftSolid
cs-cart.pl

 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 03 July 2019 - 02:38 PM #3

of course but i believe it can be done with a line of code or 2 in the current addon.. thanks for the solution :)



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19782 posts

Posted 04 July 2019 - 04:54 AM #4

Just install built-in Google Export addons and you will see new parameter - Google price. It includes currency in the value


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 04 July 2019 - 07:11 AM #5

please read carefully my post :)



 
  • Flow
  • Super Duper and Amazingly Sexy Senior
  • Members
  • Join Date: 13-Oct 10
  • 2306 posts

Posted 04 July 2019 - 09:13 AM #6

please read carefully my post :)

 

ecomlabs is correct.


When life hands you lemons, bring on the Tequila baby!


 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 04 July 2019 - 10:00 AM #7

i need price & list price and the google_export addon ads the Google price (which is the sale price) only. i need in the csv the list_price value with the (blank)EUR included... see the attachments pls... 



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19782 posts

Posted 04 July 2019 - 01:30 PM #8

app/addons/google_export/schemas/exim_data_feeds/google_export.php

 

try to add the following code

 

$schema['export_fields']['Google list price'] = array(
    'db_field' => 'list_price',
    'process_get' => array('fn_exim_google_export_format_price', '#this', '#key', false, false),
    'export_only' => true,
);

 

before

 

return $schema;

Then clear cache and check the result

 

(!) Not tested


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 04 July 2019 - 04:10 PM #9

i tested it and it works but the value is from the price and not the list_price..

i also tested adding the     'table' => 'products', before the db_field and i got db error.. :/ but i believe we are close enough.. thanks ecom labs! 



 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 04 July 2019 - 06:00 PM #10

so... i will post my solution which is a little bit anorthodox... but basicly it works just fine.. (i will also post it to save my solution for future use)

 

step 1

(i dont want to advertise anything but everyone posts addons)

we already had this addon purchased

https://www.netikon....duct-feeds.html

 

we could not use the link that this addon was creating us even if the csv was correct (dynamic link) because google was not accepting that specific type of url (that's why we were looking for data_feeds & google_export addons to work but got stuck with the list_price value ending in EUR...)

 

step 2

we created a new xml feed (under products > xml feeds)

in the File Stracture we added whatever we needed and in the file type we selected "csv"

(image google_export_02.jpg)

 

step 3

i created a php file (getcsv.php) and added the following code

<?php
$file = file_get_contents('https://mariedore.gr/index.php?dispatch=nt_product_feeds.get_feed&feed_id=3&password=yellow_pages_2019');
file_put_contents('/home/XX___USER___XX/public_html/feed/googlefeed-final.csv', $file);
?>

step 4

in cpanel i added a cron job with the following code:

/usr/local/bin/php /home/XX__USER__XX/public_html/feed/getcsv.php

and configured the cron to be executed twice a day.. so we have our dynamic to .csv file converted !!!!

https://mariedore.gr...efeed-final.csv

 

voila!!! :) :) 



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19782 posts

Posted 05 July 2019 - 05:54 AM #11

The correct solution is

 

app/addons/google_export/schemas/exim_data_feeds/google_export.php

 

add the following code

 
$schema['export_fields']['Google list price'] = array(
    'db_field' => 'list_price',
    'process_get' => array('fn_ecl_exim_google_export_format_price', '#this'),
    'export_only' => true,
);
before
 
return $schema;

- app/addons/google_export/schemas/exim_data_feeds/products.functions.php

 

add to the end

 

function fn_ecl_exim_google_export_format_price($product_price)
{
    $price = fn_format_price($product_price, CART_PRIMARY_CURRENCY, null, false);
    return $price . ' ' . CART_PRIMARY_CURRENCY;
}

- clear cache and check


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • kamvas
  • Advanced Member
  • Trial users
  • Join Date: 12-May 15
  • 63 posts

Posted 05 July 2019 - 06:34 AM #12

YES! thanks eCom Labs! it did the trick! anyway now we have 2 csv ready to play!



 
  • akistdm
  • Senior Member
  • Trial users
  • Join Date: 09-Oct 11
  • 235 posts

Posted 05 July 2019 - 09:48 AM #13

Ecomlabs once again has the solution...
You are really helping people you guys!!!
Keep on!!!

 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19782 posts

Posted 05 July 2019 - 01:05 PM #14

You are welcome and have a good weekend!


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • Mongoose
  • Senior Member
  • Members
  • Join Date: 08-Mar 13
  • 991 posts

Posted 04 November 2019 - 04:27 PM #15

You are welcome and have a good weekend!

 

Guys

 

I tried the solution that you offer and implement the changes in the google_export.php file however it does not lead to the desired exported csv file we can use to upload on to the merchant center.

 

I presume you use the option to export Data


running CS Cart V4.10.3.SP1 


 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19782 posts

Posted 05 November 2019 - 06:10 AM #16

Do you see new field in the list of available fields? Do you see default Google price parameter?


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.