Help with loading data into admin grid

Hello,

I have made an admin grid and need help loading the data ijn. I am following the Magento docs closely.

I am using this method

https://github.com/goivvy/admin-grid-tutorial/blob/master/app/code/Dev/Grid/Plugin/AddAttributesToUiDataProvider.php

Can anyone explain to me how that file works.

I want to add searching for a column called `title` in my table, at the moment I can’t load any data in- what might I add into the afterGetSearchResult method?

I basically just wanna do

‘SELECT * FROM myTable WHERE LIKE myTable.title LIKE “B%”‘ and have that load onto the grid UI.

Thanks for your help!

submitted by /u/CuriouslyGeorge17
[link] [comments]

Hours for Magento upgrade from 2.3 to 2.4

Hi all,

We’ve been working with a company for over a year now. The developers are great but I feel the company is overcharging on most tickets because they feel that they can as my knowledge of web development is minimal and they have full control of the server. The latest quote I got from them is to upgrade from version 2.3.7-p2 to the latest version of 2.4. I understand that websites vary vastly in their structure, number of modules etc. but if I can outline the number of hours of development they are quoting us and a rough idea of the website structure, it would be great if somebody could take a look and let me know if this price is roughly fair enough or if they are taking the p*ss!

The quote below is the second quote after I queried the first one

Magento Backend 120hrs (down from 150hrs)

Infrastructure & SysOps 20hours

QA 50 hours

Hypercare (?) 0 down from 20 hours

Deployment 16 hours

Project Management & Specification 32 hours

For a grand total of 238 hour

I’ve read elsewhere that with around 10 extensions, the work could be anywhere between 60 and 90 hours. We have about 20 extensions. I also have a quote from another company who have given me a rough quote of between 70 and 95 hours of work but they don’t know the website as well as our current developer and they’re not specialist magento developers, although they do have 1 guy who would be well versed.

A rough breakdown of the BE work involved:

  • We will update the Magento version, but we will need to check and update all the modules installed.
  • We have seven third-party modules that are mandatory to update due to Magento version compatibility. After updating these modules we will need to check if the functionality used in x project still works and if not we will need to customize it.
  • There are eight custom patches that will need to be revised if they are still needed or need to be updated after updating Magento and the modules.
  • Due to the mandatory updating of PHP to the 8.1 version, we will need to check and update/adapt (if needed), nineteen modules and previous agencies:
    • Ten from x;
    • Two from x;
    • Seven from x;
  • The process of updating and installing the modules requires developer tests.
  • The BE will need to assist and test infra team tasks like upgrades and creating the test environment

I would be grateful if someone could let me know if this quote is completely off the wall or they could be something I’m missing?

Thanks in advance

submitted by /u/Ameliadaddy
[link] [comments]

URL resetting

Hey everyone.

Is there a non-extension way to completely remove, or reset, all of the URLs for products? When editing products via csv, I’m getting 100s of URL errors, even though I don’t alter the URL_key field in the csv file. And whenever I install the “standard” extension for URL management, it causes my site to break and I have to do a hard recovery. Even uninstalling the extension doesn’t restore the site.

I’ve tried Google and stack change, and they all ultimately say the same thing, to use extensions, but this isn’t an option for me. I have DB access and cli experience, so any option would be worth looking into.

Thanks in advance for your input. I greatly appreciate any help you can offer.

submitted by /u/Mr-Bitter
[link] [comments]

Product attributes being modified and not taking affect due to having already been modified at a different scope

We have a client who’s store is running on Magento 2.4.3 currently and a really frustrating issue keeps occurring.

Basically, they are making regular changes to their products and these changes are not taking effect on the website. After some investigating, we discovered that various attributes have been modified at the website store scope overriding the default setting.

This is happening for a lot of products, all different attributes randomly.

The latest instance just today was that customers were actually checking out of the website with products priced at £0. It turns out that these products were disabled at default scope but were enabled at website scope. I found 50 products like this that would have been visible in frontend for free!

Now our client is absolutely insisting that none of them switch the scope when working in the backend – goodness knows how many of their products are in a mess in their catalog because of this (consists of approx 15k products).

So my question really is, has anyone ever come across something similar to this or know of anything in the system at all anywhere that might affect a product’s attribute at a more granular scope than the default?

I can see that affected products are all recently modified and our client states yes, that was them but are saying that they are absolutely not switching scope at all so I’m really a bit stumped on where to go with this… 😅

submitted by /u/zigojacko2
[link] [comments]

M2: layouts and inline html-body data-pb-style css into stylesheet?

Question. So my 2.3 Magento cart used the basic html editor for pages and blocks. Any divs I created, I edited with inline css. I notice 2.4 uses templates with rows, columns, where you can build a page.

The templates have settings where you can assign a border, margins, padding, etc. All this css is put into the page as inline css. Maybe this is better than adding <style> to the bottom of each page and pasting your custom css code but I was thought inline slowed down a site vs a stylesheet.

Is there anyway to put this css into a stylesheet? Or does the templates the cart uses again for blocks and pages rely on inline css?

submitted by /u/kassius79
[link] [comments]

magento 2 configurable product sku and price change

I’m wondering how the below can be done for configurable products as it’s been done for bundled products.

In app/design/frontend/…/…/magento_catalog/template/view there’s a file that displays the sku (let’s say abc123) and a price of £10

And in app/design/frontend/…/…/magento_configurableProduct/template/view/configurable.phtml (I think that’s what it’s called) it shows a dropdown of the configurable products for the related catalog product (lets say the skus are bcd234, cde345 and def456 and the prices being £10, £20, £10 respectively)

Is there a way of dynamically changing the sku/price through pure js?

submitted by /u/MatthewYeend
[link] [comments]

Can I use different prices at store scope rather than website scope?

Is the only way to change the price per product for a different country to setup a new website serving that country?

For example if I have SKU123 that sells for $100 USD on my main site, and I want to sell it for €125 in France and €150 in Germany, do I need:

– website1 – USD / store1 / storeview1 – SKU123 = 100
– website2 – EUR / store2 / storeview2 – SKU123 = 125
– website3 – EUR / store3 / storeview3 – SKU123 = 150

I thought (seemingly incorrectly now) I could do:

– website1 – USD / store1 / storeview1 – SKU123 = 100
– website2 – EUR / store2 / storeview2 – SKU123 = 125
– website2 – ^^^ / store3 / storeview3 – SKU123 = 150

Is that not feasible?
Thanks

submitted by /u/mr_acronym
[link] [comments]

Remove customer account tabs on login screen

Is there an easy way to disable tabs that I don’t need in /customer/account? I am running 2.4. Basically I don’t offer downloadable products, so it’s a meaningless tab. I also don’t deal with newsletter and it’s still there asking people if they want to sign up (not sure why this is here if I don’t again use this feature or have it enabled). I also don’t use WishList. I really want to simplify all of this.

I would like more control over how this page is laid out.

Thanks.

submitted by /u/kassius79
[link] [comments]

Cancelling A Shipment, How?

https://docs.magento.com/user-guide/sales/shipment-cancel.html talks about cancelling a shipment, this documentation is for both community and commerce editions, can shipments be canceled in the community edition? I see other pages online that talk about this but I don’t see any button and can’t find the “Cancel Shipment” anywhere in the source code.

The use case is for when a shipment is made but there was a mistake and it needs to be re-shipped from another source (multi source inventory). I am testing using the “flat rate” shipment method, I don’t see anything in that ship method about not allowing cancellations.

submitted by /u/kjavitz
[link] [comments]