2017 © Pedro Peláez
 

library activity-logger

An activity logger for Laravel

image

jeroen-g/activity-logger

An activity logger for Laravel

  • Friday, October 6, 2017
  • by JeroenG
  • Repository
  • 1 Watchers
  • 11 Stars
  • 131 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 8 Versions
  • 0 % Grown

The README.md

Activity Logger

A simple activity logger for Laravel., (*1)

Scrutinizer Quality Score Latest Stable Version License, (*2)

Installation

Via Composer ``` bash $ composer require jeroen-g/activity-logger, (*3)


The following command installs the package without the testing requirements. ``` bash $ composer require jeroen-g/activity-logger --update-no-dev

Laravel 5.5 automatically installs the package, for previous versions, follow the next two steps. After that, don't forget to run php artisan migrate Add the service provider in config/app.php:, (*4)

JeroenG\ActivityLogger\ActivityLoggerServiceProvider::class,

And in the same file, add the alias:, (*5)

'Activity' =>  JeroenG\ActivityLogger\Facades\ActivityLogger::class,

Usage

Log an activity

Activity::log($message, $context, $date);

Message is required, the rest is optional. $context is an array which can contain any data you want to save. $date is a timestamp, it defaults to the current timestamp., (*6)

Get all logs

Activity::getAllLogs();

Get one log

You only need to pass the id of a log., (*7)

Activity::getLog(1);

Get all logs within timespan

$yesterday = Carbon\Carbon::yesterday();
$tomorrow = Carbon\Carbon::tomorrow();

Activity::getLogsBetween($yesterday, $tomorrow);

This function needs two parameters, all logs created between these timestamps are returned., (*8)

Get the most recent logs

Activity::getRecentLogs(10);

The default of 5 logs is used when no number is passed., (*9)

The Versions

06/10 2017

dev-master

9999999-dev https://github.com/Jeroen-G/activity-logger

An activity logger for Laravel

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

laravel logger activity

02/10 2017

v2.1

2.1.0.0 https://github.com/Jeroen-G/activity-logger

An activity logger for Laravel

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

laravel logger activity

02/10 2017

dev-analysis-XZrJAR

dev-analysis-XZrJAR https://github.com/Jeroen-G/activity-logger

An activity logger for Laravel

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

laravel logger activity

12/06 2015

v2.0

2.0.0.0 https://github.com/Jeroen-G/activity-logger

An activity logger for Laravel

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

laravel logger activity

10/09 2014

v1.0.3

1.0.3.0

An activity logger for Laravel.

  Sources   Download

EUPL-1.1

The Requires

 

by Jeroen G

13/03 2014

v1.0.2

1.0.2.0

An activity logger for Laravel.

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

13/03 2014

v1.0.1

1.0.1.0

An activity logger for Laravel.

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G

10/03 2014

v1.0

1.0.0.0

An activity logger for Laravel.

  Sources   Download

EUPL-1.1

The Requires

 

The Development Requires

by Jeroen G