gladjanus43
BulkAction modal width not changeable
Hi, I have made a bulk action for products inside an order. I want to set the width of the modal but it keeps the small size.
I also tried with the MaxWidth::enum but no luck. Is there something else I can try? This api does work with regular modal actions...
4 replies
Action is not called when first clicked on modal with modalContent()
Hi, I have a weird bug where I need to press twice on an action. The first time it does send a request to the server but it is not executing the action. Then every other click on whatever action does instantly open the action. It seems like the action is not loaded/mounted or something.
I have attached a video to explain the problem visually.
The modal opened is an action with a modalContent() where the content is a livewire component with a table. Any help would be appriciated!
14 replies
Select in custom livewire component with searchable removes wire.model
HI, I have a very weird issue. I have a custom livewire form in a modal. Everything is working really well except when I add the searchable to the select
Which results in html generated like this:
<select x-ref="input" class="h-9 w-full rounded-lg border-none bg-transparent !bg-none choices__input" id="data.company_id" hidden="" tabindex="-1" data-choice="active"></select>
However when I remove the searchable method it does add the wire.model to the select input.
<select class .... wire:model="data.company_id">
When the searchable is removed everything works as you would expect, and loading the value from the database into the form. With the searchable it of course stays empty and gives the error
Livewire Entangle Error: Livewire property ['data.company_id'] cannot be found on component: ['app.filament.pages.planning']
Anybody has seen this before? Or is there something i am missing? Help would be appreciated!
12 replies
ViewField in repeater with record data in livewire component
I have a repeater where I have overwritten the add action with a modal. I want to use the Simple layout of the repeater and use a custom viewField with the data of the records. Does anyone know how to pass the data into the viewField? I only want to nicely show the information in the repeater, no logic is applied to the field so I dont think I need a custom field class
Best case I think would be to pass the record to the viewData() property but I cant figure out how to acces the current record of the repeater
5 replies
Execute filament commands inside a filament plugin
Hi, I am making a filament plugin which includes resources, models, relationmanagers, etc...
Is there a possibility to use the filament commands like make:filament-resource inside the package folder and it creating the files in the correct place? I have a src folder, and currently I am copying everything from the main app to the plugin but this is not a very nice way of working...
I allready tried adding a path to the command like /packages/.../.../SomeResource but this still places it in the app folder
Thanks!
4 replies
HasManyThrough repeater relation
I am having the following problem where I want to show results in a repeater from a hasManyThroug relation
Transport Route
id
Transport Order
id
transport Route Id
...
Transport Stop
id
transport order id
...
I want to retrieve the stops in a repeater so I have a draggable list to let the user sort its desirered order for the stops. The has many through relation works on a relationmanager but not in the repeater because it only accepts HasOneOrMany or BelongsToMany
Is there a way arround this to display all stops in the transport route resource?
5 replies
Import action multiple models
Hi, I am working with an importer class. My use case is that one csv is converted to multiple models.
For example one row contains a card number. I first want to insert the card to retrieve a card_id.
I have the following models which need to be inserted based on this csv:
- cards
- cars
- stations
- countries
- and the main one which are rows, containing foreign keys to all the above.
I know I can use the relationship method column but the problem is that for example cars is build up from license_plate. It is only needed in the cars relationship.
I am currently trying this approach, but was wondering if I am doing it wrong:
11 replies
Checkbox List, select at least one
Hi, I have a checkbox list where at least one checkbox needs to be selected. I thought it would be easy using the required but it is allowing me to save the form without one checkbox selected
The checkboxlist is in a custom livewire component
I also tried adding
But I cant get this working either. It never even validates the thing
14 replies
Livewire custom actions
Hi, I have a custom page based on the kanban plugin of Mokosh. I am trying to add quick actions to the cards of the kanban board and would like to use the default filament actions.
The problem is that I have one action per card working, but when I try to add the second one it does not register the action. I have posted the code for the actions below. Is there some restriction or am I doing something wrong? Help would be appreciated!
5 replies
Add requiresConfirmation to custom livewire form when saving
I have a livewire component with a wizard form schema. When saving the form I want to let the user confirm their inputs by using the requiresConfirmation dialog. Is there a way to add it to the save method of the livewire component or directly to the
Thanks!
2 replies