Questions tagged [save]

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

Filter by
Sorted by
Tagged with
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
2answers
405 views

Error While Saving Product and doing reindex in Magento2.3

When I run the reindexing command got this error: Fatal error: Uncaught Error: Cannot instantiate interface Magento\InventoryIndexer\Model\StockIndexTableNameResolverInterface in /home/public_html/...
0
votes
1answer
2k views

Magento2: Category Select Attribute Not Saving?

I've registered a custom select option to my categories using the files below in my module. The select option appears in the backend with my custom options however it doesn't save the selected option ...
0
votes
1answer
436 views

Change the URL of save button in the admin grid

In Magento 2.2.5, How to change the URL of save button in the admin grid. Note: I am not creating grid through ui_component, I am creating grid using layout. Reference: Ref 1 Ref 2
0
votes
1answer
345 views

Image upload resulting in empty $_FILES array in magento 2

In my custom module I'm trying to upload an image via my save controller, I added the form in my block with this code: protected function _prepareForm() { $model = $this->_coreRegistry->...
0
votes
1answer
191 views

Added a product as configurable but is is showing as simple? Can I change it?

Using Magento 2. Definitely not an expert but I added a product and selected add configurable, however, once I clicked saved, it was listed as a simple product?
0
votes
1answer
2k views

Magento 2 - Sales Orders afterSave plugin not working

I have created a plugin so that I can process the order and send to a 3rd party after it has been placed. I have hooked into the afterSave functionality and my plugin code looks like this di.xml <...
0
votes
1answer
1k views

Magento 2 REST API: Products not saved correctly

I create products through the REST API (catalogProductRepositoryV1) using a POST request. For some reason there is something different about these products. Just after creating them everything seems ...
0
votes
1answer
845 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
77 views

Magento2 : Product not saving set custom attribute using Observer

I want to set Discount on my product after Save product so I'm using catalog_product_save_after then I am creating an attribute 'discount' and set the calculated value, but when i save the collection ...
0
votes
1answer
180 views

Saving a value without triggering aftersave()

I'm not going in detail about what i'm exactly saving because this question is regards all the possible thing you can save with the ->save() function in each repository. Anyways , when importing data ...
0
votes
1answer
3k views

How to save a image upload to a folder in magento2? [duplicate]

Created a custom tab on admin product edit page. Here added a image upload section. I need to save the uploaded image to a folder.
0
votes
2answers
2k views

Magento 2 not able to save order data in custom table using observer.php with sales_order_place_after

I am trying to save order details in a custom table with sales_order_place_after observer, but its not working. public function execute(\Magento\Framework\Event\Observer $observer) { ...
0
votes
1answer
202 views

Update website id using collection

I have to update website for some items and price. I do it in the loop and fetch data from csv file. I did it this way: $productCollection = Mage::getModel('catalog/product')->getCollection()...
0
votes
1answer
1k views

Magento 2 : How to save data in database

I want to save some data in to custom table.When I use static value to save data then it is going good but If I try to use dynamic data or used any calculation in between then It is going in infinite ...
0
votes
1answer
727 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 ...
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'); $...
0
votes
3answers
31 views

Save Config Button Not work in payment methods

I was trying to add a new payment method klarna. I configured klarna in a proper way and I couldn't save it. Further try to some other changes in stores->setting->configuration->sales->...
0
votes
1answer
29 views

Magento 2.3.3 | unable to save changes on imported products

I just imported a few products in my Magento 2.3.3 Shop and need to change a bit here and there. Unfortunatly i cant save theese changes. After editing everything i wanted to change i click on "save" ...
0
votes
1answer
37 views

Date format issue to save giftcard Lifetime in Magento 2

I am creating giftcard code programmatically. For this in vendor GiftCardAccount Module, the code is: $model = $this->giftCAFactory->create()->setStatus( \Magento\GiftCardAccount\...
0
votes
1answer
39 views

Saved image in the admin grid is not fetching while editing the grid Magento 2

The image is already saved in the uploaded image. But when editing the form it shows No file Chosen. How can I fetch the previously save the image? Here is the save.php code: <?php ...
0
votes
1answer
28 views

Get value changed in admin grid SaveButton magento 2

I created a custom magento 2 form. As far as saving, I would like to take the modified value in the save.php of the controller. Is there any method I can use? This is my save.php controller <?php ...
0
votes
1answer
30 views

Magento 2 : Form data not saving

I have an XML form on the backend. It has the save button the code for which is this - class SaveButton implements \Magento\Framework\View\Element\UiComponent\Control\ButtonProviderInterface { ...
0
votes
1answer
129 views

Unable to save the product stock status as “Out of stock” in magento 2

I have imported a single product via backend. The product stock status is mentioned as 0 ("is_in_stock => 0") in csv sheet which i imported. The product successfully saved. But while opening the ...
0
votes
1answer
42 views

How to override the GroupInterface by creating extension attributes in magento 2

I wish to override Magento\Customer\Api\Data\GroupInterface to add my custom fields. Custom fields are 1.custom_terms 2.handling_fee I have created the below file in etc/extension_attribues.xml &...
0
votes
4answers
2k views

New product attributes value cannot be saved in magento 2

I have created nearly 10 new attributes under product attributes. Its added to attribute set as well. But now, when I update the product information, the data is not getting saved. Instead, after the ...
0
votes
2answers
1k views

Magento 2.2.5: Save and Continue Edit Button doesn't work

I'm doing the Save and Continues button in "Slide" page. So what I've done til now: Everything was perfect, but my Save and Continue Edit button doesn't work. After I click the button, it throws a ...
0
votes
1answer
521 views

Magetno 2 custom module how to Update DB Table row with model

How do I update instead of inserting new row on save using model My code: $question = $this->_objectManager->create('Vendor\HelloWorld\Model\Question'); $question->setTitle('Simple Question'...
0
votes
1answer
82 views

Magento2: I wanted to save order details to my local database

I wanted to Save Orders from magento 2 to my local database or another database when new order is placed in Magento frontend. I need to Save the order details when the new order is placed in magento ...
0
votes
1answer
562 views

Magento 2 controller values save via model in custom table without load model?

I want to call model in controller and save values via model in controller. protected $pageFactory; protected $quesModelFactory; public function __construct( \Magento\Framework\App\Action\...
0
votes
1answer
716 views

Magento2 : How to save system config programmatically [duplicate]

I made a module to add configuration fields to system (system.xml). Some of these fields are dynamic arrays (cf here) which are generated using an extend of \Magento\Config\Model\Config\Backend\...
0
votes
1answer
3k views

How to save upload image file to a folder on product edit page in backend in Magento 2

I have added a custom tab on admin product edit page. And in that custom tab added a image upload field. I need to save the image while saveing the product. Is it possible to do it via ajax and a ...
0
votes
1answer
169 views

How to save custom product tab drop box fields values to database in Magento 2

By using data-form-part="product_form" in input tag, text values are getting. But how gets the drop down values. When i used data-form-part="product_form" same in option, it gives an array with key ...
0
votes
1answer
541 views

Adminhtml - NULL in saveAction() form

I'm creating a new admin module, when i click on save button in my form, he calls saveAction with all paramaters fields but he saves me NULL value. I think that the problem comes from saveAction() but ...
0
votes
1answer
76 views

How can I specify 0000-00-00 as Year-Month-Date while Save

I want to save a time reference in database which date part should be always 0000-00-00. I have below code with me. $entity = Mage::getModel('my_entity_reference')->load(1); $entity->...
0
votes
2answers
554 views

Can't update product value after update attribute's label

So, I updated the "product_length" label attribute and now I can't save a new product value to this attribute. I can't save this value by admin or programatically. $_product = Mage::getModel('catalog/...
0
votes
1answer
3k views

Magento2: Unable to save product

I am unable to save product from magento2 admin Getting below error SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`...
0
votes
1answer
801 views

Magento 2: Custom Module URL Key Magento Function

I'm using Magento 2 CE Version 2.1.0. I'm creating a custom module. For saving data I'm using custom INSERT query. In that INSERT query, i also need to save URL Key/Identifier which is going to ...
0
votes
1answer
41 views

Why do I need to save Configurable Products 2x times?

I am having problems on putting my product in stock. I create it, I associate simple products to it, and it works fine. Visibility and simple products stock are also correct. The big problem here is ...
0
votes
1answer
132 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
773 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
1answer
124 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 ...
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() ...
0
votes
0answers
11 views

Date Attribute not saving for Products in Magento 2

I have created a product attribute in Magento 2, but its value is not saving while saving. I have created a date attribute in Magento backend. But it is not saving, Can anyone guide me
0
votes
0answers
17 views

Save grouped product : Requested product doesn't exist

I am getting an error in a external script when I am trying to save a grouped product : something goes wrong with product save method, the exception is "Requested product doesn't exist". Doing unit ...
0
votes
0answers
16 views

Magento2 what save product button (admin) does more than save programmaticaly?

We have recently converted configurable products in grouped product + get all linked simple product moved. All is ok on front. But in the back office, on the product edit page, the listing of simple ...
0
votes
0answers
26 views

Magento 2.3 Save and Duplicate Product

I wanted to make a duplicate product. SO i did save and duplicate and a product was created. For product 1,SEO url is gin-glasses-pasabahce-timeless For product 2 , SEO url is gin-glasses-pasabahce-...
0
votes
0answers
14 views

Issue saving existing products, 2.2.6

We have 5 - 6 products in our catalog of 3005 which are existing products but we can not save them. It provides a 'technical server error' but it produces no logs or entries. Host has tried to ...
0
votes
0answers
291 views

Magento 2 : Class interceptor does not exist

I have a simple module when I save data then this error : Magepow\Importexport\Controller\Adminhtml\Allimports\Save\Interceptor does not exist [] [] here is save file <?php namespace ...
0
votes
1answer
28 views

Magento 2 Error while saving product

I am getting " DateTime::__construct(): Failed to pass time string (17/06/2019) 0(1):Unexpected character error while saving product. See the Screen shot below Image Here What can be the ...