Jump to content

marecekloool

Members
  • Posts

    36
  • Joined

  • Last visited

marecekloool's Achievements

Newbie

Newbie (1/14)

5

Reputation

  1. Hi thank you for the script it looks promising but somehow it doesnt work for me. so what i did i put the script int a php file changed the "$conn = new mysqli($servername, $username, $password, $database);" and after i run it i get the successful update message page but none of my products have the text field fixed. in my CSV i have CUSTOMIZABLE PRODUCT set to 1 and TEXT FIELD I have set to 1 after i have them imported i run your script and it shows me its done btu nothing happened. Am I forgetting something? Can someone advice? Thanks <?php // Create connection $conn = new mysqli('xxxxx', 'xxxxx', 'xxxxx', 'xxxxx'); /* check connection */ if ($conn->connect_errno) { printf("Connect failed: %s\n", $mysqli->connect_error); exit(); } echo "Connected successfully<br /><br />"; $conn->query("update ps_category_lang set name=SUBSTRING_INDEX(name, '(', 1) WHERE name REGEXP '([[:digit:]]+)';"); $conn->query("truncate table ps_customization_field;"); $conn->query("INSERT INTO ps_customization_field (id_product,type,required) SELECT id_product,0,0 FROM ps_product WHERE id_shop_default = 1 AND customizable = 1;"); $conn->query("INSERT INTO ps_customization_field (id_product,type,required) SELECT id_product,1,1 FROM ps_product WHERE id_shop_default = 1 AND customizable = 1;"); echo "Added uploadable files & customized field to each item!<br /><br />"; $conn->query("truncate table ps_customization_field_lang;"); $conn->query("INSERT INTO ps_customization_field_lang (id_customization_field, id_lang,id_shop,name) select id_customization_field,1,1,'Upload 1' from ps_customization_field WHERE type = 0;"); $conn->query("INSERT INTO ps_customization_field_lang (id_customization_field, id_lang,id_shop,name) select id_customization_field,1,1,'Field 1' from ps_customization_field WHERE type = 1;"); echo "Added appropriate labeling for each field, for each product!<br /><br />"; echo "<h2>Yay, We're done!</h2>"; $conn->close(); ?>
  2. Ok i googled a lot of topics all over internet i went over official documentation and i still dont know whats the syntax for the CSV for importing products so that they have already a label for the fields. Because in CSV in the column Text fields (0 = No, 1 = Yes) i add a value "2" which gets accepted and the fields are created but they dont show on the frontend until i go in the backoffice open up the product and manually add the text field labels and save them. I found some topics related to this https://www.prestashop.com/forums/topic/439393-csv-import-product-with-text-field/ and similiar ones that suggested something like this "fieldname1"|1, "fieldname2"|1 but either its not working anymore or I am doing something wrong. So what I am asking is is there a way how to import products with lebeled text fields, so I dont have to do it manually for several hundred , possibly thousand products? Is this possible to be done in prestashop's import system or do I have to use external code to update database after import everytime? Any help is very appreciated. Thanks PS: I am runing the latest presta right now ( 1.6.1.6 )
  3. SOLVED yes sorry for this topic i was confused one of my employees manually added shipping cost for EVERY product.. ffs thanks and have a nice day
  4. Ok I created my own carrier and from what I understand if you have shipping according to weight you setup the ranges and when the client is shopping the price of the shipping takes into account the overall weight of the WHOLE order and gives us that price based on that. Now I want to do the same thing but with price instead of weight so as you can see in the picture bellow I changed the calculation to be done by price instead of the total weight. it even says TOTAL PRICE but when i try to purchase something as a client EVERY single product has its own price and its not being calculated properly is this some kind of bug or am I missing something? www.sw33t.sk/sample.jpg For example: my range is set from 0 - 300€ if someone makes a purchase in this range the shipping cost should be 30€ but instead i get the 30€ is being multiplied by the amount of products in the cart.. and I get like 120€ for 4 items. This isnt right why is it being multiplied? Can someone explain ? Thanks
  5. Zdravim mamem rodinnu restauraciu a prave uvazujeme ako spravit obejdnavanie pre nas personal co najjednoduchsie, Je nejaky sposob ako spojit kasu resp zariadenie co bude tlacit blociky (asi termo ale necham si poradit) na zaklade udajov z objednavok v prestashope? Restauracia funguje v CR a budeme predavat pizzu prave dorabame rozhranie s prilohami a este potrebujem nejako vymysliet ci je mozne to nejako tlacit priamo z prestashopu alebo pripadne pohody na ktoru to asi napojime cele. Mate s tym niekto skusenosti vedeli by ste poradit?
  6. Hi guys first off the sample CSVs that you get with presta are plain bad.. you can try download and import them and you just get errors, thats a shame because they are supposed to show you how to create import files. I started from scratch, created a fresh new text file, this time I used commas instead of semicolons (not sure if I wrote that right -> this , instead of this ; ) and it finally works! My main mistake was I was relying on the provided sample CSVs to be working ok, but they aren't. Maybe prestashop should take a look at those, so the other prestausers wont have this problem again. Still not sure what was wrong with them to begin with, but I dont have time to solve this little mystery too, I have a shop to finish! Thanks again for all your help and as Adrenaline said: start from scratch, check if the columns are properly assigned in the import process and skip the first line if you are using column headers.
  7. Hi adrenalin I have been using presta for some years now, I have done many many imports for many eshops but ever since I have started to use 1.5 I can't import anymore and noone will help. I have written multiple threds on this subjects red all the suggested solutions (many people have this same issue as I have) but nothing works. thank you so much for your reply, it gave me hope. anyway I tried it like you said, I created a brand new CSV from scratch,just some basic products to test it out and I am still getting the same error. >> I uploaded the CSV file, I clicked on products/import >> I Choose to import a product entity >> Language is set so is my field separator, everything else stays untouched >> I press NEXT and I check to skip the first line >> I check the columns to correspond with the information type I am importing there >> I press IMPORT and I only get the error message thet all my products could not be saved as shown before.. I am attaching my CSV file that I am using, if someone could check it and tell me what am I doing wrong? Can I please ask you Adrenalin to upload a sample of your product CSV , please I am desperate.. Thanks and may the force be with you all...
  8. Have the same problem.. why cant I reply to this topic ? I have the exact same problem.. After I try to import my file (I uploaded it for you to see here http://eshop.ekoprof...ucts_import.csv ) I get errors: Plastové okno Fixné okno v ráme(Fix v ráme) 1 (ID: 0001) cannot be saved Property Product->available_for_order is not valid Plastové okno Fixné okno v ráme(Fix v ráme) 2 (ID: 0002) cannot be saved Dont know what to do.. I red like 20 discussions on how to solve this issue.. I stripped desription of any tags I even used one simple word for the descritpion columns.. nothing I even downloaded presta anew.. made a fresh installation, went to the CSV import page and downloaded the sample csv .. and then tryed to import that one.. guess what? Same error. Can someone please advise what am I doing wrong? Much appreciated.
  9. Yeah thanks anyway Still, I dont get it. Why is there a column for product's ID in the import csv when in the process presta ignores it completely and generates itself a new one?! Whats the purpose of this? It's even a reqiured field SOLVED: as it turns out presta was using it's own ID because mine had letters in them.. sorry I just assumed that I can use it ID's we had in magento and our stock software.. thanks anyway and have a nicer day than me
  10. Hmm thanks but I am not very good at PHP. I would really love to just change my attribute import file's IDs but alltogether its like 30 000+ combinations and I divided them into multiple files so the import script wouldn't have to handle so much data at once. I dont see this happening. Is this really not a big issue for anyone? Nobody had problems with import like I do? It's hard to believe as this seems pretty essential for everyone's eshop.
  11. Well there isnt much to configure. You cant see it probably because youre on a category without products with atributes. It shows up only on categories that have products with attributes that can be filtered. It shows manufacturers, price ranges, weight ranges and attribute combinations automatically. A good idea is to reindex the items in the module configuration after each import.
  12. question number one: smarty templates compile their files so any chage you make needs to delete the compile folder. there are two ways how to solve your problem: 1. go to: administration > preferences > performance and turn force compilation ON and turn cache OFF and you will have no need for emptying the compile folder to see any changes 2. after each change you make to a tmpl file empty this folder: tools/smarty/compile to see the changes
  13. Hi folks This never was a problem in the past but now it's giving me a lot of headache. Here it is: When importing products, I use my own numbers in the ID column and I use the same numbers in my refference number column. But once they are imported PRESTA assigns a totally different ID number >> a consecutive number... I wouldn't really mind this but when I try to import the attributes witch use my ID numbers the attributes aren't assigned to any products, since my IDs dont match those created by presta in the importining process. Any help is really appreciated. Thanks and a have a nice day!
  14. Zdravim Viete mi niekto poradit preco mi import atributov robi stale problem? Momentalne frcim na najnovsej preste ale stretol som sa s tym aj na starsich verziach. Ked importujem len jednu vlastnost pre dany produkt, napriklad len velkosti ide vsetko fajn. Ked ale importujem kombinacie vlastnosti (farba+velkosti) mam s tym problem, vytrvori dane atributy aj ich hodnoty ale nepriradi ich k produktom podla ID (ID, combinations, quantity) hodnoty oddelujem ciarkami ale skusal som spravit import CSV aj z prikladu ktory som si stiahol a doplnil z administracie Naozaj budem vdacny za akukolvek pomoc nakolko s tym uz dlhsie neviem pohnut a skusal som uz kadeco... EDIT: prave som si vsimol preco mi to robilo problemy... totiz ten sample subor v admine na ukazku toho ako sa importuju atributy ma jednu chybicku.. ma o jednu bodkociarku naviac, akurat za druhym atributom... To ale stale nevyriesilo moj problem. Totiz ked importujete produkty a date do stlpca ID nejaky kod eshop ho akosi ignoruje a vytvori si vlastne IDcko. Miesto toho mojho pouzije poradove cislo produktu. A teda ked dam importovat atributy ktore su viazane na moje IDcka tak sa atributy sice vytvoria ale nepridaju sa k danym produktom. Neviem ako to obist. Prosim skuste mi niekto pomoct, vopred pekne dakujem
×
×
  • Create New...