2017 © Pedro Peláez
 

library over-seer

preview form data before saving to the db

image

ctf0/over-seer

preview form data before saving to the db

  • Monday, July 23, 2018
  • by ctf0
  • Repository
  • 1 Watchers
  • 18 Stars
  • 14 Installations
  • Vue
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 9 Versions
  • 40 % Grown

The README.md

OverSeer
Latest Stable Version Total Downloads

A tiny package to help preview any form data before submitting to the db., (*1)

If you are looking to have a control over the saved content as well, you may want to give Odin a try too., (*2)


, (*3)

Installation

  • composer require ctf0/over-seer, (*4)

  • (Laravel < 5.5) add the service provider., (*5)

    'providers' => [
        ctf0\OverSeer\OverSeerServiceProvider::class,
    ];
    
  • publish the package assets with, (*6)

    php artisan vendor:publish --provider="ctf0\OverSeer\OverSeerServiceProvider", (*7)

  • install dependencies, (*8)

    yarn add vue form-serialize
    # or
    npm install vue form-serialize --save
    
  • add this one liner to your main js file and run npm run watch to compile your js/css files., (*9)

    • if you are having issues Check.
    window.Vue = require('vue')
    
    require('../vendor/OverSeer/manager')
    
    new Vue({
        el: '#app'
    })
    


, (*10)

Usage

  • add an id to the form you want to collect its content, ex., (*11)

    <form action="..." method="..." id="my-form">
        ...
    </form>
    
  • then add the vue component anywhere near that form, (*12)

    • form-id is the id you gave to your form, in that case my-form
    • template is where you want to display the data, ex views/posts/overseer
    • title optional url title, so instead of just my.app/overseer it would be my.app/overseer/my-awesome-title
    <over-seer form-id="my-form"
        template="posts.overseer"
        title="my-awesome-title"
        csrf="{{ csrf_token() }}">
    
        <button>Preview</button>
    </over-seer>
    
  • now in the view where we will display our data, we can access it like, (*13)

    // for single values
    {{ $data->title }}
    
    // for nested values
    {{ $data->body->en }}
    

    just like you would usually do with any model., (*14)


, (*15)

Notes for WYSIWYG Editors

  • we currently support tinyMCE but if you are using any other editor, PRs are welcome :trophy:


, (*16)

Security

If you discover any security-related issues, please email ctf0-dev@protonmail.com., (*17)

The Versions

23/07 2018

dev-master

9999999-dev https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

29/05 2018

v1.0.7

1.0.7.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

20/02 2018

v1.0.6

1.0.6.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

07/02 2018

v1.0.5

1.0.5.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

17/01 2018

v1.0.4

1.0.4.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

23/12 2017

v1.0.3

1.0.3.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

12/12 2017

v1.0.2

1.0.2.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

09/12 2017

v1.0.1

1.0.1.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0

07/12 2017

v1.0.0

1.0.0.0 https://github.com/ctf0/OverSeer

preview form data before saving to the db

  Sources   Download

MIT

The Requires

 

by Muah

laravel overseer ctf0