Laravel Community Tools by Tighten
Laravel Nova icon Nova Packages
This package has been marked as abandoned on Packagist. Please proceed with care.

Installation Instructions

You can install the package in to a Laravel app that uses Nova via composer:

composer require mattmangoni/nova-recent-posts

Next, you must register the card with Nova. This is typically done in the cards method of the NovaServiceProvider.

// in app/Providers/NovaServiceProvder.php

// ...
public function cards()
{
    return [
        // ...

        // all the parameters are optional
        new \Mattmangoni\RecentPosts\RecentPosts(
            string $authorRelationName = 'user',
            string $dateFormat = 'Y-m-d',
            int $postsNumber = 5,
            string $postModel = 'App\Post',
            string $userUriKey = 'users'
        ),
    ];
}

Readme

Nova Recent Posts Card

Latest Stable Version Total Downloads

What is this package about?

This will add a simple full width card in your dashboard with a list of recent posts.

You obviously need to have a basic blogging system already setup in order to use this. It just need a posts table and a with at least title column in it and a one-to-many relationship with the user.

Both the posts model and the relationship name - as well as other parameters - can be altered from the card constructor.

Installation

You can install the package in to a Laravel app that uses Nova via composer:

composer require mattmangoni/nova-recent-posts

Next, you must register the card with Nova. This is typically done in the cards method of the NovaServiceProvider.

// in app/Providers/NovaServiceProvder.php

// ...
public function cards()
{
    return [
        // ...

        // all the parameters are optional
        new \Mattmangoni\RecentPosts\RecentPosts(
            string $authorRelationName = 'user',
            string $dateFormat = 'Y-m-d',
            int $postsNumber = 5,
            string $postModel = 'App\Post',
            string $userUriKey = 'users'
        ),
    ];
}
Back to Top
Added 7 years ago
Last updated 7 Years Ago
Version v1.1.0
Composer
mattmangoni/nova-recent-posts
GitHub stars 0
Packagist downloads 678

Favorites

1 user favorited

Rating

N/A
(out of 5)
★★★★★
★★★★
★★★
★★
0 ratings

Contributors

Brought to you by Tighten

Issues/Feature Requests Stats Package Ideas