Questions tagged [crud]

The tag has no usage guidance.

15 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
0answers
68 views

Magento 2 : How to get top 10 repeated values in a column using CRUD instead of sql?

I want to get top 10 most repeated values in a column of my table, I can do so using sql but I need to do it using CRUD i.e using collections or model as magento coding standard doesn't allow naked ...
2
votes
0answers
30 views

Magento 2 - Can I have to create API, Interface & Resource Model for relational table

I am creating a module which have three tables let's say for example table1 -------- id int(13) PRIMARY_KEY title varchar(50) table2 -------- id int(13) PRIMARY_KEY title varchar(255) table3 `...
2
votes
2answers
68 views

Cusotm module edit action redirects it to the dashborard

I created Grid using UI Components and provide Edit action using < actionsColumn > in vendormodulename_entity_list.xml <actionsColumn name="actions" class="Vendor\Modulename\Ui\Component\...
2
votes
1answer
387 views

CRUD logic in Controller or Block?

I have referred several blogs which explains CRUD functionality, some of the blogs write code like saving a model, in a Controller and some in a Block. Blogs CRUD functionality in Block : http://...
2
votes
0answers
84 views

How to go around “Incorrect namespace usage(s)” in static tests

I have a simple CRUD module for Magento 2. When I run the static tests I get the following error/warning. "Incorrect namespace usage(s) found in file..... <Vendor>_<Module>". The ...
1
vote
0answers
115 views

Magento 2 API - crud for all tables

Is it possible to create a new REST API to update or create data in all magento tables from a xml added in POST : <data> <row table="Nom_Table_1" key="Nom_Champ_Key_1"> <...
1
vote
2answers
709 views

Updating product in the catalog

I've some code to import some products: if the prodocut is new, I've insert it in the catalog, otherwise, I've to update the product if there are some changes. Code is the following: <?php ...
0
votes
1answer
6 views

Cannot update product name using productRepository in Admin Store ( Store 0 )

I'm trying to update a product using productRepository ( migrating from a flow using product factory with load ). Problem is tha when updating the name it is updating in store 1 ( default store ) but ...
0
votes
0answers
9 views

how to securely store data created by javascript code to the database

I would like to store some GDPR related data in the database for guest or registered users when consent is given. My question is regarding safety precautions I should take. The idea is that when ...
0
votes
1answer
28 views

How To Upload Images and Show Their Thumbnails From Custom Module Admin Form

I have a custom grid. Need to upload product images from admin form of the custom module. Here is the grid Edit file at: app\code\local\Crud\Banner\Block\Adminhtml\Banner\Edit\Form.php $...
0
votes
0answers
21 views

Create CRUD operations for a specific product attribute

Is it possible to create a CRUD operations just for a particular product attribute options . Say in the above Screenshot, I have generated some output in the product edit page using phtml . I need to ...
0
votes
0answers
32 views

Block class is not getting loaded in magento 2.3.4

I created a simple layout where I specify the block class and the template to be rendered. But it seems like the block and template is not getting rendered. Below is the code. I am trying the CRUD ...
0
votes
1answer
78 views

How to add a pay until date to invoice in Magento2?

Please excuse me if I am asking a dumb question, but I am new to Magento and frankly, my first impression is that it is over-designed and poorly documented. Maybe this is part of their business model, ...
0
votes
1answer
392 views

Connect Ionic App to Magento 2.3 REST API

I'm a Magento developer and I need to connect an app developed in Ionic with the Magento 2 REST API. I need to make an extension that grants more access to a customer token, additionally, I need to ...
0
votes
1answer
478 views

How to store dropdown value in database and display selected when edit item?

I am developing custom module. Other fields are saving data in database but i have issue with Dropdown field. It's not saving value in database. My code as following: $elements['target'] = $fieldset-&...