medusajs / medusa

The world's most flexible commerce platform.
https://medusajs.com
MIT License
26.23k stars 2.67k forks source link

Can't open discount details in admin on v1.20.3 #6805

Closed luluhoc closed 8 months ago

luluhoc commented 8 months ago

Bug report

Can't open discount details in admin on v1.20.3

Describe the bug

A clear and concise description of what the bug is.

Unexpected Application Error!
Cannot read properties of undefined (reading 'length')
TypeError: Cannot read properties of undefined (reading 'length')
    at sT (https://admin.xxx.com/230.1598d062.chunk.js:1:395054)
    at oO (https://admin.xxx.com/main.a79938b1.js:18:60913)
    at u (https://admin.xxx.com/main.a79938b1.js:18:119430)
    at sI (https://admin.xxx.com/main.a79938b1.js:18:99083)
    at https://admin.xxx.com/main.a79938b1.js:18:98950
    at sN (https://admin.xxx.com/main.a79938b1.js:18:98957)
    at sE (https://admin.xxx.com/main.a79938b1.js:18:95709)
    at sA (https://admin.xxx.com/main.a79938b1.js:18:96098)
    at n4 (https://admin.xxx.com/main.a79938b1.js:18:44823)
    at https://admin.xxx.com/main.a79938b1.js:18:93609
children: n.regions.length.toLocaleString("en-US")

System information

Medusa version (including plugins): v1.20.3 Node.js version: 18 Database:POSTGRES Operating system: mac Browser (if relevant):

Expected behavior

A clear and concise description of what you expected to happen

Screenshots

image

If applicable, add screenshots to help explain your problem

Code snippets

If applicable, add code samples to help explain your problem

Additional context

Add any other context about the problem here

mezzat11 commented 8 months ago

same here

ensidialabs commented 8 months ago

same error

Uncaught runtime errors:
×
ERROR
Cannot read properties of undefined (reading 'length')
TypeError: Cannot read properties of undefined (reading 'length')
    at E (http://localhost:7001/node_modules_moment_locale_sync_recursive_-_cache_admin_src_pages_a_tsx.chunk.js:667:6588)
    at ll (http://localhost:7001/main.bundle.js:510:66998)
    at http://localhost:7001/main.bundle.js:510:108622
    at c7 (http://localhost:7001/main.bundle.js:510:109964)
    at HTMLUnknownElement.g (http://localhost:7001/main.bundle.js:498:48294)
    at Object.r1 (http://localhost:7001/main.bundle.js:498:48619)
    at r9 (http://localhost:7001/main.bundle.js:498:49572)
    at ef (http://localhost:7001/main.bundle.js:510:169867)
    at fF (http://localhost:7001/main.bundle.js:510:155810)
    at http://localhost:7001/main.bundle.js:510:155531
ERROR
Cannot read properties of undefined (reading 'length')
TypeError: Cannot read properties of undefined (reading 'length')
    at E (http://localhost:7001/node_modules_moment_locale_sync_recursive_-_cache_admin_src_pages_a_tsx.chunk.js:667:6588)
    at ll (http://localhost:7001/main.bundle.js:510:66998)
    at http://localhost:7001/main.bundle.js:510:108622
    at c7 (http://localhost:7001/main.bundle.js:510:109964)
    at HTMLUnknownElement.g (http://localhost:7001/main.bundle.js:498:48294)
    at Object.r1 (http://localhost:7001/main.bundle.js:498:48619)
    at r9 (http://localhost:7001/main.bundle.js:498:49572)
    at ef (http://localhost:7001/main.bundle.js:510:169867)
    at fF (http://localhost:7001/main.bundle.js:510:155810)
    at http://localhost:7001/main.bundle.js:510:155531
ensidialabs commented 8 months ago

Discounts stopped working altogether. I create a discount, but it doesn't show up in product page.

olivermrbl commented 8 months ago

I create a discount, but it doesn't show up in product page.

What exactly do you mean by this?

We've identified the first issue and will release a patch asap.

ensidialabs commented 8 months ago

I create a discount, but it doesn't show up in product page.

What exactly do you mean by this?

We've identified the first issue and will release a patch asap.

I apologize. I looked in the wrong place. The error is only the one described above.

olivermrbl commented 8 months ago

If you urgently need the fix, you can use this snapshot: @medusajs/admin@7.1.12-next-20240326102954.

We will cut a patch release later today containing this. Pleasee be aware, the release as a whole has not yet been thoroughly tested, so use it with caution.