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
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();
1
vote
1answer
80 views

Assign Website Id without calling save();

I am doing a custom function for magento Admin. The function is when author finished setup a product and save, the product will automatically assigned to certain websiteId when the conditions is met. ...
1
vote
2answers
2k views

Magento not saving CMS page [closed]

I've been running into this issue lately where I cannot save content in a CMS page if it contains the word 'Select' or any variant of the page. Whenever I try and save a page with the word 'Select in ...
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
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 ...
1
vote
0answers
39 views

Need to save all simple products via admin or programatically

I need to be able to re save all simple products in order to update a custom attribute via some custom code, the attribute is only updated when a product is sold or saved or an order is cancelled. The ...
0
votes
1answer
826 views

products added to category not saved

Catalog > Manage Categories I select a category and go to "Category Products" tab. I reset filters and select one or more product to add to category. Then hit "Save Category" button and the category ...
0
votes
1answer
752 views

Onepage checkout update payment section on radio button click

How can i update payment section if user click (check) radio button of payment. So i want that magento safe the new selected payment method and reload the payment section.
0
votes
2answers
2k views

How to save the PDF file into Magento root folder

$pdf = Mage::getModel('sales/order_pdf_invoice')->getPdf($invoicesSet); $this->_prepareDownloadResponse('invoice'.Mage::getSingleton('core/date')->date('Y-m-d_H-i-s'). '.pdf', ...
0
votes
1answer
125 views

Can't save products after setting related items (Invalid argument supplied for foreach())

I'm trying to set related products programatically, using the following code: $product = Mage::registry('current_product'); $id="549"; $data=array($id=>array('position'=>1)); $product->...
0
votes
1answer
100 views

Save Configurable Products automatically

My configurable product prices are updated with Lowest Price simple product on Save. As I have thousands of configurable products I can't manually open and save all of them. Is there any way I can ...
0
votes
1answer
720 views

Magento 2 how can magento core module save product details? [closed]

I'm writing a module for setting tier price for segments by modelling tier price for groups in Magento 2's core module. But I got confused when I following the codes for saving product details in 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 ...
1
vote
1answer
358 views

Transactions - need id from saved objects

I have a transaction which saves 2 order objects. The benefit of which is obviously that if any fail then it is all rolled back. However, there are associated objects which need to reference the ids ...
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
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')->...
0
votes
0answers
128 views

Batch insert products (import multiple products at once)

I have an excel file with 125.125 rows in it. I loop through all the rows and save/update the products in my magento website. Now the problem is that I save the product every time I loop through a ...
0
votes
1answer
3k views

500 Internal Server Error on /checkout/onepage/saveOrder/ redirects to cart without emptying

I am facing 500 Internal Server Error on /checkout/onepage/saveOrder/form_key/xxxx at the time of clicking place order button at checkout page. I have found the same issue at this link http://forum....
1
vote
1answer
50 views

Getting current data after calling save()

I'm experiencing some trouble with saving data to some of my custom columns in the sales_flat_order_payment table. After quite some time I realized that when I call $this->payment->save(), the ...
0
votes
1answer
766 views

Please Wait… When trying to edit a large Categories' name?

I'm editing a bunch of categories for this Magento site and I am hitting a wall. I'm only trying to change the Name, the status of the Is Active and the Includes in Navigation Menu. On the ...
0
votes
0answers
52 views

Strange issue with Product custome attribute

From last 5 days, I am facing problem with related to product custom attribute. I have created some extra attribute for product and "Donation"(Mandatory field) attribute is one of them. It was working ...
0
votes
1answer
1k views

Storing multi-value custom product attribute

I have a custom attribute for my products called 'car_model'. This is a multi-value field. Now I try to create a synchronization script to synchronize this data between Magento and another system. I ...
0
votes
1answer
122 views

Is there a limit to the number of tier prices of a product?

I am using Magento 1.9.2.0. I have many (35) customer groups because I want to set different discounts for each group. For each customer group there are a number of tier prices for a product. And here ...
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/...
2
votes
1answer
985 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
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 ...
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[...
0
votes
1answer
2k views

setting all active quotes to inactive , for the logged user

This is the code I use, which is not working, in order to make all of active quotes for the logged user to inactive, but it keeps taking only one quote. $quote = Mage::getSingleton('sales/quote'); $...
1
vote
2answers
3k views

How to create Magento editable grid?

I couldn't find a better tutorial for creating an admin grid which is editable. And the grid column contains dropdown boxes. And there's only one save button for the entire grid. (Means there's no ...
0
votes
1answer
567 views

How to change attribute value in one product and save it only to this product?

I am doing a small external script site for my magento to get informations and do small tasks without navigationg through the magento backend (eg. show qty of all products). What I want to do now 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....
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 ...
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/...
1
vote
1answer
84 views

Singed integers are not saving properly?

I have a custom table with column 'discount_percentage', which is a signed integer. e.g. +5 , -2 likewise I have defined the data type as Varchar for this field. But it's not saving the value ...
1
vote
1answer
948 views

billing.save(); not firing as guest

I'm using the rwd theme that came with Magento 1.9. I just modified the styling a bit. The problem is now, if I want to buy a product the checkout is working fine. But if I want to order something as ...
0
votes
1answer
3k views

use of getId() & setId() in mage_core_model_abstract

I want to understand functions of mage_core_model_abstract. For this I'm using Mage::log() function in different places. and I'm using custom module with model. I'm thinking getId() & setId() ...
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::...
1
vote
2answers
3k views

Overriding Magento Save method

We have a attribute 'short-description' in our product listing page. We want to escape html characters e.g. "&" => "&" , and append information to it when our admin hit 'save' in product ...
1
vote
2answers
281 views

How to save XML code snippet in customer session?

I want to save a piece of XML code in the customer session. So far I tried with the following code. // Get customer session. $customerSession = Mage::getSingleton('customer/session'); // $xml ...
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 ...