kirschbaum-development / nova-inline-relationship

A package to present relationships as inline properties in Nova.
MIT License
196 stars 84 forks source link

Labels shows as array #42

Open nemrutco opened 4 years ago

nemrutco commented 4 years ago

When i use it with BelongsTo relationship, labels are becomes like :

profile[0][id_number] - profile[0][name] ... etc.

nemrutco commented 4 years ago

Seems like it's related to Nova's 2.9.3 update, Nova will now use the give field name first for determining a field's label.. #764

brandonferens commented 4 years ago

@nemrutco Thanks for this info. We'll look into it, but in the meantime feel free to submit a PR for this issue. We enjoy working with the community!

4n70w4 commented 4 years ago

The same problem on create form:

image

kculmback commented 4 years ago

Also experiencing the same issue with Nova 2.10.1

Dixens commented 4 years ago

Also experiencing the same issue with Nova 2.11.1

And really nice package by the way - really should make it into the core.

david-kristin commented 4 years ago

I have the same problem with HasMany relation.

drewwbctz commented 4 years ago

Same issue with Nova 2.12.0

Dixens commented 4 years ago

OK now, even with Nova 2.11.1. Thanks.

genesiscz commented 4 years ago

I just wasted an hour trying to make this work (I had to figure out how to refresh the compiled files), but it seems there's a fix already

https://github.com/kirschbaum-development/nova-inline-relationship/commit/1d9d4872575a6569efda1375cbff6e9da3074aeb

genesiscz commented 4 years ago

here's how I applied this in my project (maybe unsafe):

composer.json:

        "kirschbaum-development/nova-inline-relationship": "dev-master#1d9d4872575a6569efda1375cbff6e9da3074aeb",

or maybe

composer require "kirschbaum-development/nova-inline-relationship=dev-master#1d9d4872575a6569efda1375cbff6e9da3074aeb"
composer install
cd vendor/kirschbaum-development/nova-inline-relationship
npm i
npm run watch
rm -rf node_modules/

done

skoyah commented 4 years ago

Maybe is missing a tag release?

Dixens commented 4 years ago

OK now, even with Nova 2.11.1. Thanks.

Back to labels as arrays for some reason (no update).

gshzn commented 4 years ago

Any idea when this will be pushed to packagist?

cch504 commented 4 years ago

I can confirm this issue.

mauricewaney commented 4 years ago

Any updates or workarounds for this issue?

genesiscz commented 4 years ago

here's how I applied this in my project (maybe unsafe):

composer.json:

        "kirschbaum-development/nova-inline-relationship": "dev-master#1d9d4872575a6569efda1375cbff6e9da3074aeb",

npm install
cd vendor/kirschbaum-development/nova-inline-relationship
npm i
npm run watch
rm -rf node_modules/

done

Try this

vwasteels commented 4 years ago

Hello, I just tried the solution abose, but still see the labels as articles[0][title] Thank you

vwasteels commented 4 years ago

oh it's composer update instead of npm install :

in composer.json:
"kirschbaum-development/nova-inline-relationship": "dev-master#1d9d4872575a6569efda1375cbff6e9da3074aeb",

composer install
cd vendor/kirschbaum-development/nova-inline-relationship
npm i
npm run prod
rm -rf node_modules/
genesiscz commented 4 years ago

ah yeah sorry for that

vwasteels commented 4 years ago

@kirschbaum do you plan to integrate this fix into a future release ?

ragingdave commented 4 years ago

@kirschbaum Just poking this issue once more to try and get a new release if this is in fact already fixed?

Milkhan commented 4 years ago

@kirschbaum Is this repo abandoned? Any help?

NioTeX commented 4 years ago

@brandonferens any chance to get a new release?

genesiscz commented 4 years ago

I forked a forked repo of this repo and compiled the files to make it work out of the box - feel free to add

"repositories": [

        {
            "type": "vcs",
            "url": "https://github.com/genesiscz/nova-inline-relationship"
        }
]

to your composer json and then composer require kirschbaum-development/nova-inline-relationship

jberculo commented 4 years ago

@genesiscz I tried to use your fork, but my HasOne inline now complains about "Too few arguments to function Laravel\Nova\Fields\HasOne::KirschbaumDevelopment\NovaInlineRelationship\{closure}(), 0 passed and exactly 1 expected",

ragingdave commented 4 years ago

@kirschbaum @brandonferens any updates here or is this repo abandoned? There has been no updates/comments from you guys for quite some time, and nothing has happened in this repo for coming up on 6 months. This package is currently broken for Nova v2/3 so basically anyone wanting to use it are currently SOL without maintaining their own fork.

kirschbaum commented 4 years ago

@ragingdave we'd love to work on this more. There are two issues: 1) we're extremely busy at the moment and haven't had time to focus on this yet and b) there are some major issues with how this package needed to be created. It's been making fixing bugs and keeping the package updated very challenging.

If anyone is interested in helping to take these issues on let me know and we can have a quick call with you to discuss. These issues are quite complex and require deep understanding of Laravel and Nova. Would love to see this project move forward and succeed.

ragingdave commented 4 years ago

@kirschbaum I would be interested in helping, as the end result of this package is something that would be very useful to me and my team and I'm sure, based on previous comments, others as well.

genesiscz commented 4 years ago

@genesiscz I tried to use your fork, but my HasOne inline now complains about "Too few arguments to function Laravel\Nova\Fields\HasOne::KirschbaumDevelopment\NovaInlineRelationship{closure}(), 0 passed and exactly 1 expected",

Pass a $request to the inline()

kirschbaum commented 4 years ago

@ragingdave I have sent you an email invite for us all to sync. Let me know if you didn't get it.

trippo commented 3 years ago

@genesiscz Why does sortUsing no longer exist?

Reached commented 3 years ago

Hi guys,

Thanks for providing this package, it's great! However, any updates on fixing this label issue? :)

genesiscz commented 3 years ago

@genesiscz Why does sortUsing no longer exist?

I honestly have no idea. I merged another fork with my own edits and made it work for my use case. You can always debug it and post a pull request to the fork I created.

halberio commented 3 years ago

@genesiscz I passed the $request to the HasMany but it gives me Method Illuminate\Database\Eloquent\Collection::getKeyName does not exist. do you have any idea?

genesiscz commented 3 years ago

Without more info, no, unfortunatelly

cbrinicombe13 commented 3 years ago

Any update on a fix for this issue?

GerhardKotze commented 3 years ago

same problem :(

o1y commented 3 years ago

I forked this repo to build the outdated dist files, which does not contain PR #59.

Add my fork to your composer.json:

"repositories": [
  {
    "type": "vcs",
    "url": "https://github.com/o1y/nova-inline-relationship"
  }
],

and require the package:

composer require kirschbaum-development/nova-inline-relationship
Santukon commented 3 years ago

@o1y Works perfect. If you could include also fix for this bug would be awesome: https://github.com/kirschbaum-development/nova-inline-relationship/issues/87 Regards!

alekmlynek commented 3 years ago

@o1y Thank you, worked great. Hopefully core will get fixed.

Igor-Nosatov commented 3 years ago

Guys, it is easy, just fix vue.js components

RhysLees commented 2 years ago

Still got the same issue