Page Module - Custom Fields, Not working

  • I have watched the video and followed the instructions to a tee, but I am not seeing the fields show in the edit or create forms.

    What is really strange is it doesn't appear that the Page create/edit screens are using the partial views from itself. When I make any change to Page->Resources->views->admin->partials->create-fields.blade.php directly I don't see the change in the form at all. Even adding a <h1>Hello World</h1> won't display. I can even delete the partials from the Page module admin views and clear all caches and the page still loads with the default form.

    I am slightly mystified by how the create and edit forms load the HTML, I am confident it isn't from views->admin->partials. Which is where the code to look for settings in the config for custom fields lives.

    Any help?

  • Curious about this too....

  • I've brought a working PageExtensions module, from a 2.x version of AsgardCMS I had setup for another project. It does not work anymore in 3.x.

    There is for sure something not aligned in the documentation / video. Does anyone have any insights? Will post if I find anything, but so far no luck.

  • bump

    How can you extend the form views in Page and User modules now that they are all ajaxy with Vue

  • Here's how I added a custom field to the Admin Pages:

    1. console "npm install" at the root of the project
    2. console cd to Themes/Adminlte and "npm install"
    3. create your db migration (I added a field to the page module) and migrate
    4. in the partials for the Page module add your field to edit and create blades
    5. in Modules->Page->Assets->js->components edit the 3 .vue files to add the new field
    6. console cd to root of project "php artisan asgard:module:publish Page"
    7. console cd to Themes/Adminlte and "npm run watch"
    8. console cd to root of project "npm run watch"
    9. house keeping "php artisan cache:clear" and "php artisan view:clear"

    You should now see your field in the create and edit of the backend of your site. Remember to add the translation if the field is translatable.

Log in to reply

Looks like your connection to AsgardCms was lost, please wait while we try to reconnect.