Twill CMS

TC

Twill CMS

Join the community to ask questions about Twill CMS and get answers from other members.

Join

Extend bulk actions

Can I extend bulk actions dropdown, in Twill2, for example: Export in custom route? Thanks! 🙂

Multi Language Same Slugs

Can someone give me an idea on how to achieve this. I'm building a multi language site and I want to have the same slugs for all languages. Default language should not have any base like below. Ex:...

Slug creation with special letters

Hey, I tried overwriting HasSlug to add both lower and upper case 'Đ'=>'D' to $char_map but didnt work. My Model with title Đoković has slug okovic instead of dokovic. How can i add that additional letter?

Tiptap Align

HI! Can someone tell me how to add align option to my WYSIWYG Tiptap? I am using twill 3.0.

Is it possible to create a new Media Library Bucket in Twill 3

Hi! I'm a software eng at the Art Institute of Chicago and we use Twill as our CMS. We're trying to separate images into two separate buckets either via a new mediables-esque table or configuring a new S3 bucket connection and having it displayed as a separate tab in the add media modal. We've got something sort of working but the way we're doing it is hacked together. We're building twill and then copying a new version of the media library related code and adding our own versions of the vue's. This isn't the best in terms of maintaining but it's the only way we could get it working. Is there a way in Twill 3 to configure new buckets/tabs in the mediables field so we can differentiate the images? My take on it is to add some sort of differentiator when saving the media in a column or metadata but we're not sure if it's possible....
No description

How to create settings for the site to disable registration and frontend-only offline mode ?

Hello 🙂 I'mm all new to Twill and Laravel and i'm working on a site i'd like to put the frontend offline and disable the registration thanks to a parameter. I try to get solutions from an AI but it just rotates through options and nothing actually works like the example....

Custom

Hello i got a user basic user table from laravel and admin user of twill i want to add crud for the normal user in the twill dashboard but still keep the twill admin user alonside it i try to transform the basic laravel module in one of a module i created a User controller in the Controller/Twill but the routing redirect me to the twill user module...

how to override a default database model class method

Hi team, I’d like to get your opinion on overriding a specific class in Twill. Current approach:...

renderHtml doesn't work in getBrowserTableColumns()

Hello, I'd like to render a small colored div inside browser column but renderHtml(true) doesn't seem to work ```php public function getBrowserTableColumns() : TableColumns {...

Position reordering not working

Hi! I am checking Twill out to see if it's a match for our next project. It looks really promising but I walked into a small problem with the first guide "Building a simple page builder with Laravel Blade". I've successfully ran through it but the section "Adding navigation" gives me a small problem, the code works fine and gives no errors or whatsoever. However, the frontend does not work. When I drag a menu item to a new position or drag it to be a child of another item the frontend will reply that the order has been changed, yet when I reload there is no change. The response of the xhr request contains: variant: 'success', it's just that the database is not updating and reflecting the changes....

Limiting BlockEditor blocks? Possible?

Is it possible to limit block editor blocks somehow? i.e. I have a dynamic column block (i.e. a seciton you can add multiple 'columns' in it up to 4. ```php BlockEditor::make() ->name('columns_content')...

Adding Modules (Controllers, Repositories) in Subfolders

Hi, I’m trying to add my custom modules (e.g., controllers, repositories) inside subfolders. However, I’m encountering an issue where Twill doesn't seem to recognize my controller in the subfolder. I get the error: Target class [App\Http\Controllers\Twill\NewController] does not exist. ...

Add sideFields in settings

Hi , How can I add the 'Clear Cache' button below the 'Update' button?
No description

Seeding into Modules with Media

Whenever you create a module with the twill artisan commands they usually also come with Seeders. My main question here is; Is there a way to also seed media(s) into modules when doing seeding? Can anyone guide me in the right direction for this? This could either be for a repeater or just the cover image....

How to specify medias crops for blocks.

Hi. I've got a block that accepts medias and want to set a crop for it. I've tried doing it within the parent model that the block would be added to but the changes never get saved despite the editor detecting the crop i've configured i.e. I add the block in the block editor, I select an image and set a crop but it never gets linked to the block instance and doesn't render. Am I missing something? Block:...

Prefill field form with default locale content when adding translation

Would it be possible to prefill a translatable field with the saved content of the default language? For example: -Create item in default language -Switch language to fill translatable fields -Text field will be filled with the content from the default language which is already saved...

Showing button on the side of settings page

Hi, I need to show this cache button under the languages but I can't find a way to do it. If anyone could help with any suggestion on how to achieve this, I'd appreciate.
No description

Trying to access file in setting

I have added a file setting field into the settings that I have created but when trying to access it using the TwillAppSettings Face, it always seems to return null when I try to access it. Any idea how else I could access this? TIA....
No description

hideActiveCrop() Not Working in Twill 3.x

Hi, I'm using Twill 3 and trying to disable the cropping option with hideActiveCrop() as shown in the docs https://twillcms.com/docs/api/3.x/A17/Twill/Services/Forms/Fields/Medias.html#method_hideActiveCrop, but it's not working. here's my code ...
No description

Automatically make languages live/remove user control

Use case - on a bilingual site I need to make both configured languages live by default for any item (including settings). I'd also ideally like to remove the ability for admin users to edit this at all. I've spotted a variable called $controlLanguagesPublication in the form layout which seems to hide the language active controls, and am using View::share in AppServiceProvider to globally force this to false . However this seems slightly brutal and I'm not sure if there might be any side effects. Also this doesn't solve selecting all languages as active by default (although I guess I could probably figure that out during save) Could anyone possibly confirm the best way to achieve this?...
Next