Using the options function in SelecTree.
Hi @blackshadownl , I hope you're well. I am using the select-tree package in one of my projects, first of all thank you for the great job you did. I was able to use the "options" function in the SelectTree form component before the update but now I can't use it, I couldn't see anything in the changes in the code. How should I follow a path, I would appreciate if you can help me, thanks in advance.
23 Replies
Thank you and great to hear you are using the package. Since the big release 3.1.0 i made it only support belongsTo and belongsToMany relationships but i can take a look tomorrow perhaps to bring back the custom options.
Unless you dont need it, what is it you are trying to do exactly?
Actually my relationship is already belongsTo, the reason I use options is that you use null as the parent_id value in the query. I use -1.
I see.. i could maybe make a setting perhaps
Would that resolve it?
Yes, that was actually the first solution I was looking for when I started using the package.
like
nullValue(-1)
where null
is default.Yes, exactly.
The first thing I did was to check the parameters of the relationship function.
Alright i will see if i can release that tomorrow end of day.
Thanks a lot for your quick response and solution.
You're great
No problem! But first i will sleep its 23:00
https://github.com/CodeWithDennis/filament-select-tree/issues/23
Made an issue so you can keep up to date
GitHub
nullValue Β· Issue #23 Β· CodeWithDennis/filament-select-tree
Add the possibility to change the null value for the parentAttribute
Thanks, it's 00:15 here too. Good night.
@afatmustafa i made a draft https://github.com/CodeWithDennis/filament-select-tree/pull/24/files you want to take a look before i merge it π ?
I actually went a head and released the new version.
GitHub
Release v3.1.4 Β· CodeWithDennis/filament-select-tree
What's Changed
Removed unused variable by @CodeWithDennis in #22
Implemented parentNullValue by @CodeWithDennis in #24
Full Changelog: v3.1.3...v3.1.4
I hope this works for you. π
Hi, now that I am available, you have already published it. I'll check it right away.
Resolved π ?
@afatmustafa
I'm sorry, I was able to look at it now, I tried it now, but it gives a 500 error, it didn't write anything in the laravel.log file either.
wut
Oh shit i made a mistake π€‘
GitHub
Release v3.1.5 Β· CodeWithDennis/filament-select-tree
What's Changed
Fixed an issue where tree would go into inf loop by @CodeWithDennis in #25
Full Changelog: v3.1.4...v3.1.5
I released a fix
Let me know if its fixed ;D
Okay, it's working now, thanks.
Nice! Don't forget the Favorite the plugin on Github so more people can find it π
I already did π