We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [save]

Questions related to save action, most commonly used in form submit

Filter by
Sorted by
Tagged with
11
votes
1answer
1k views

Avoiding save in a loop in mass action

I've created my own CRUD module that contains an inline edit action similar to the one for CMS pages Everything works OK, but when running phpsniffer with the EcgM2 standard I get this warning: ...
7
votes
1answer
3k views

Magento 2: How to Insert Multiple Records to custom table?

I have created a new table in Magento2: my_custom_table with 4 fields: id: primary key, product_id: int(11), customer_id: int(11) status:int(11) I want to save multiple records at a time. Here is ...
7
votes
3answers
2k views

Magento Enterprise Slow Product Save (/w and /wo Solr Integration)

Issue: Product save has become incrementally slower over the past 12 months Background: Magento Enterprise 1.14.1 (Issue also present in 1.13.0.2) ~15,000 Products, ~700 Categories, 2 Stores Solr 3....
6
votes
3answers
4k views

Product stock is not saved when creating a product programmatically

I'm creating products programatically on Magento CE 1.8.1. The form works fine except every once in a while we get a nasty error that comes and goes away, and does not affect all users. :"SQLSTATE[...
5
votes
2answers
3k views

Magento2 : user define customer attribute not save value while create / save from admin

I have created two customer attribute one "abc" and second is "xyz" this two attribute display properly in customer admin. also attributes are created in database table "eav_attribute". But while save ...
5
votes
1answer
534 views

Category with 20000 product not save

I have a category with 20000 products and 50 subcategories, while I tried to save that category at that time Magento go into infinite loop and after 10-15 min getting 500 error. I have set 18000 max ...
5
votes
1answer
577 views

Magento Configurable Product Save Not Working

On configurable product creation, when I hit the save button, I'm getting the error Fatal error: Call to a member function getStoreLabel() on a non-object in /app/code/core/Mage/Catalog/Model/Product/...
4
votes
1answer
2k views

Magento 2 : Could not save admin form contents into the DB

I have added an admin form using Ui component. example_example_edit.xml <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:...
4
votes
1answer
4k views

Magento 2 : Use aftersave and beforesave method

I want to add aftersave and beforesave method of Magento 2 in my model. How can I do this and which model I have to called ?
4
votes
2answers
563 views

Magento 225 :Notice: Array to string conversion

When I try to create a new record in my custom module I get the below mentioned error Something went wrong while saving the item.Notice: Array to string conversion in /opt/lampp/htdocs/...
4
votes
4answers
709 views

Whenever I save a product I get “Something went wrong” and in the report I get this error

I got this in my error report: > a:4:{i:0;s:37:"Object DOMDocument should be created.";i:1;s:5172:"#0 > /data/web/magento2/vendor/magento/framework/View/Element/UiComponent/Config/Reader.php(95)...
4
votes
2answers
440 views

Magento 2. Catalog product edit save button not working

admin/catalog/product/save button is not working anymore. I'm unable to edit/save product. No output whatsoever in var/log/* No output whatsoever in browser console No activity in browser network ...
4
votes
0answers
213 views

No ID parameter in model save controller when saving after edit

I've written a model object and I cannot edit and save an existing object, a new object is always created. I can create and delete, but editing doesn't work. I'm pretty sure that this is because the "...
3
votes
1answer
2k views

Magento 2 Fail to save the value of a newly added Yes/No customer attribute

The customer attribute shows up but cannot save it because there are no records about this attribute in eav_entity_attribute table, when I manually add a row for the attribute, it can be saved. How to ...
3
votes
1answer
665 views

Difference between catalog_product_prepare_save and catalog_product_save_before

What is the difference between catalog_product_prepare_save and catalog_product_save_before? I have an observer that updates some attributes when a product is saved. It works great when I save a ...
3
votes
1answer
2k views

Magento 1.9.2.4 - SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY' while saving categories

I got the below error while saving some categories(not all categories) 2016-12-14T12:56:58+00:00 ERR (3): exception 'PDOException' with message 'SQLSTATE[23000]: Integrity constraint violation: ...
3
votes
1answer
2k views

Can't PUT customer in Rest Api Magento2 - fails to complete

How do you PUT (update) a customer using the rest api? I have a ticket open on github, but I was wondering if I'm just doing this wrong.. https://github.com/magento/magento2/issues/5115 I've ...
3
votes
1answer
2k views

Send Email and Save Data to database table with custom form

I have created the module with a form in front end on submit it send email and its working fine, now i also want to save the current form data to a Database table and keep the email functionality too ...
3
votes
1answer
352 views

Magento 2 - CMS Content Won't Save

I'm having a crazy issue where I'm trying to copy over CMS content and it seems that when there are certain words, the content does not save. It just refreshes the admin page and brings me back to ...
3
votes
1answer
1k views

How does $customer->save() actually work?

So ,i am developing some extension for the company I work for on Magento (enterprise) and I was testing some code in an Observer going like this: $_customer=Mage::getModel("customer/customer")->...
3
votes
2answers
4k views

Custom Field Value not saving on sales_flat_quote & sales_flat_order

I have created a custom field from sales_flat_quote & sales_flat_order tables and in checkout page have field called delivery_date. When an order is being placed, it's not saving my custom field ...
3
votes
3answers
1k views

Magento 2.3 : How to set qty for multiple sources (Multi source inventory) programmatically

I have a site with 3 inventory sources. I want to add and update product inventory to each source by product sku. Please help me
3
votes
1answer
511 views

Issues in loading and saving Customer addresses where customer is linked to many addresses (200+)

My customer has 200+ addresses, the page takes a long time to respond(this is one issue),and other is when I try to save some changes,I am getting error as shown in pic.If customer has few addresses, ...
3
votes
1answer
3k views

On customer address save, get origin data

I'm working on an observer of the customer_address_save_before event. On customer address saving, i've to check if there's changes before doing some actions. I did something similar for the customer/...
3
votes
1answer
578 views

Magento 2 : Admin form using ui component not able to do edit and save

I have created an admin form using ui component and I could save a new form using the following code. But now I am facing an issue with edit form save. ext_form.xml <fieldset name="ext_details"&...
3
votes
2answers
2k views

Saving product deletes tier price and group price

I've got a problem when programatically saving a product. While loading the product with help of the product collection or the model (by attribute), setting some value and then saving it, I'm losing ...
3
votes
1answer
194 views

Magento 2: How to save data in DB from admin through UI component?

I can not save the data in the database when editing the record, the data remains the same as it was before Ronis\Feedback\Api\Feedback\FeedbackInterface.php <?php namespace Ronis\Feedback\Api\...
3
votes
1answer
687 views

URL key for specified store already exists on Category edit in Magento in Magento 2.1.6

I working on a project on which I get the error URL key for the specified store already exists While editing category on store 2. I get this error only on store 2 Arabic first category and also ...
2
votes
2answers
9k views

Programatically update a single attribute in Store View Scope

If you load a product in Store View scope, all the inherited data ("Use Default Values") comes with it... which makes perfect sense, so far so good. $_product = Mage::getModel('catalog/product')->...
2
votes
2answers
10k views

How to save customer attribute value in custom script in Magento 2

How to save customer attribute value in custom script in Magento 2. The prerequisite is to add first your new attribute programatically. To do add a customer attribute please review these: Magento2 ...
2
votes
1answer
2k views

Insert multiple rows without calling model save inside loop

Following code is working fine. $data = $this->_customDataSave->create(); $data->setUsername($this->getUsername()); $data->setFullname($this->getFullname()); $data->setEmail($...
2
votes
1answer
5k views

How to create a productrepository using object manager in Magento 2?

I want to save/update the product in phtml file and I need to create productRepository using object manager. I don't want any controller to be called. Is there any possibility to save product in phtml ...
2
votes
2answers
6k views

magento 2 - How to create new object Product?

How to create new object Product ? Example: $product = new Product(); $product->sku = 'fdfds'; ... $product->save();
2
votes
1answer
2k views

How do you get the new product ID after programmatically creating the product?

I have a configurable product and am trying to programmatically create a new simple product and then associate it with my configurable product. This is what I have so far... $newProduct = $this->...
2
votes
2answers
185 views

How to save an EAV entity from controller?

I'm trying to build a custom module that contains an EAV entity in Magento 2 for learning purposes. I have troubles performing a proper save from an admin controller. I'm trying to avoid code like: $...
2
votes
3answers
497 views

Magento admin custom form with multiple entry

I have a custom form in Magento admin. When I submit the form with multiple click of the save button the multiple entry are inserted in my table, even if I have a form key. if ($data = $this->...
2
votes
2answers
1k views

Magento 2.2.2 On product save i get error ''Invalid Form Key. Please refresh the page'

I add some custom option in sample product. I save this product and add changes in custom option. But I can not save the product. and get this error, Invalid Form Key. Please refresh the page.
2
votes
2answers
2k views

How to fix Invalid method Varien_Object::save() in product saving?

I got following error when tried to save product from collection: Invalid method Varien_Object::save(Array()) And here is full code (I know, that it is ugly, but now I try refactor it): public ...
2
votes
1answer
17k views

How can i quick update of qty and stock and all inventory fields in Magento

I want quick update of product on MAGENTO C.E 1.7 I know about the quick update of product attribute value using below code: getResource()->saveAttribute() just like $product=Mage::...
2
votes
1answer
295 views

Magento2 make simple afterSave action plugin of custom module

I am trying to create afterSave plugin for my admin form save action controller of my custom module. The purpose of this is to save some data into second table once all data completely save in first ...
2
votes
1answer
2k views

How to add save and continue button in ui-form in Magento 2?

I have created admin grid and form using ui component. Now I need to add save and continue button, How do I add it? Please provide me a solution
2
votes
1answer
2k views

How to create a Magento 2.1 custom payment to save credit card information

I am unable to use Authorize.net or PayPal in the country my store is working. I'm migrating from magento 1.9 to magento 2.1; and I manually process all my payments from credit cards using the Save CC ...
2
votes
1answer
77 views

Product Page 404 - product re-save needed

After updating some products by importing csv file, there are some of them that display 404 error in frontend product view page. Saving these products manually solves the issue. Saving these ...
2
votes
1answer
428 views

How to save additional column field in core table in magento 2

I have created custom module for product review. I have added additional coloumn in review_detail table in DB. I got all submitted values from form including my custom column value in Controller. But ...
2
votes
1answer
1k views

Magento 2 how to save product?

UPDATE SCRIPT WORKS The issue was with google experiments being enabled I am trying to save a product after updating the price via a new module in admin. I can update and view the prices from the ...
2
votes
1answer
984 views

OnePage Checkout Page Wrong Totals After Product Save

This has proved to be quite the challenge to solve! I am working on a Magento site with a multi-store setup with custom shipping and totals calculations using extensions and a OnePage checkout. I ...
2
votes
1answer
311 views

Magento 2: How to get product old and new data on product save button in admin backend?

I am working on Admin Actions Log Extension. For the reference, I am using the link below https://amasty.com/admin-actions-log-for-magento-2.html I want to get old and new data of products while we ...
2
votes
0answers
69 views

di.xml ExtensionPool create/read handlers Conflicts

I am creating extensionpool handlers to save data in multiple tables. There are total 3 tables : 1 : Sliders 2 : SliderItems 3 : SliderSelectedItems When I create/update Slider, list of selected ...
2
votes
1answer
83 views

Something went wrong while saving this configuration: Area is already set magento 2.3

I am facing this error in version magento 2.3 while saving header logo. Actually this issue is resolved as per gihub but even it is coming.link
2
votes
0answers
202 views

How to select values in parent grid magento 2 from ui component modal?

I have a custom product listing grid, on clicking add products, I have created a (slider) modal, Where I check the products from another grid and click add selected products, then the selected items ...