zdrojowa/revision-module

1.1.1 2020-04-27 06:32 UTC

This package is auto-updated.

Last update: 2024-07-21 21:33:13 UTC


README

Latest Version on Packagist Total Downloads Build Status

Revisions & History

Installation

Via Composer

$ composer require zdrojowa/revision-module

Usage

  • Add in webpack.mix.js
mix.module('RevisionModule', 'vendor/zdrojowa/revision-module');
  • Add module RevisionModule in config/selene.php
'modules' => [
    RevisionModule::class,
],
  • run npm
npm install
npm run prod
  • Dodaj w module akcji
Revision::create([
    'table' => 'pages',
    'action' => 'updated',
    'content_id' => $id,
    'content' => $page,
    'created_at' => now(),
    'user_id' => $request->user()->id
]);
  • Dodaj we view
<link rel="stylesheet" href="{{ mix('vendor/css/RevisionModule.css','') }}">

@include('RevisionModule::revisions', [
    'table'      => 'pages',
    'content_id' => $page->id
])

@javascript('csrf', csrf_token())
<script src="{{ mix('vendor/js/RevisionModule.js') }}"></script>
    

Change log

Please see the changelog for more information on what has changed recently.

Testing

$ composer test

Contributing

Please see contributing.md for details and a todolist.

Security

If you discover any security related issues, please email author email instead of using the issue tracker.

Credits

License

license. Please see the license file for more information.