Download the PHP package cryptodev4/orchid-tables without Composer

On this page you can find all versions of the php package cryptodev4/orchid-tables. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package orchid-tables

OrchidTables

Latest Version on Packagist Total Downloads Build Status StyleCI PHP Composer

An opinionated extension package for Laravel Orchid to extend its table handling capabilities, and some further useful helper methods.

Installation

Via Composer

Usage

This package adds the following new shiny things:

Screen\TdChecklist

Checklist with select-all support. Can select range by pressing shift.

Usage:

TDChecklist::make($name = 'checkbox')

->checkboxSet(key,value)

and almost everything available thats available on TD.

Without further configuration it sends the following:

The provided collection's items must have a getKey():int|string method, which provides the value for the checkbox.

By default the checklist belongs to the main form, which is linked to most of the action buttons, therefore having a Button within Screen@commandBar() will send the selection list too. However the modals are having their own forms, so it will not be included there. Currently only one form is supported. (Feel free to open a ticket if you need support for multiple forms/modals.)

Changing the form of the list to a modal:

Redirecting back with error/success can keep the current selection:

Can mixins:

These are mixed into most of the orchid's makeable and visible things.

can(string[] $permissions...)

Hides the field if the current user has none of the listed permissions.

Shows only if a previous canSee didn't hide it, and if any of the listed permissions are given to the user.

canAll(string[] $permissions...)

Hides the field if the current user has none of the listed permissions.

Shows only if a previous canSee didn't hide it, and if all of the listed permissions are given to the user.

Both can and canAll internally usese canSee, so chaining another canSee after a can will invalidate the permission check.

Using a non-existing permission throws an easily fixable exception during development mode, to help avoid bugs.

Layout mixins:

html

Makes a Layout component, that renders the provided html string (or the value of it, when its a closure.)

Cell mixins:

date

Formats a date string or carbon date to human readable. Format defaults to config('orchid-tables.date_format'), config('app.date_format'), or Y?-m-d H:i. (omits year if its the current year.)

num

Formats a numeric value to a more readable / convinient format.

example:

limit

Keeps the text under the given maximum character count. If its longer, replaces the end with ... (or anything specified in end).

bool()

Shows a green tick, or a red cross, depending on if the column's value has a truthy or falsy value.

Truthy Falsy

keyValues()

Shows a key-value structure (using dl/dt/dd) of a complex object / array / json entry.

Limits max depth, by default to 3.

link($href, $segments = null)

Makes a link/button to the target location. Both $href and $segments can be a closure, or a value.

Example:

renderable()

Tries to render a model, using one of the following:

Formatted exportable cells

These helper methods are useful with formatted excel exports. By default its not activated, as it adds an extra overhead, which is usually not being used. To activate, you can either set it up in the configuration:

or call the following:

Augmented methods:

Furthermore the following helper methods are available:

notExportable($notExportable = true): self

Sets a column to be non-exported.

Its advised to set it on ie. action buttons.

setStyle($style): self

A callback that formats the given row, or the actual formatting. Can be called multiple times, and the result will be merged. Callback can either return with a phpexcel formatted array, or one (or multiple merged together) from the followings:

exportRender(callable $callback): self

Sets the renderer method for excel. Input is the field's value. Must return with a string or stringable.

Example:

QuickExport

Using CryptoDev4\OrchidTables\Exports\QuickExport its possible to set up data exports quickly, without creating extra classes, just by building on an already existing table.

Quick export example:

TableAdvanced

The extended table layout, \CryptoDev4\OrchidTables\Screen\TableAdvanced adds the following functionality:

rowClass($row)

Calculates classlist based on a row. Useful for coloring a whole row.

rowLink($row)

Makes a row clickable.

Example:

Customization

Run the following command to publish the configuration:

Extend or create your overwrites, based on the existing mixins, like \CryptoDev4\OrchidTables\CellMixin. You can turn on or off any of these mixins by setting their key to null.

Change log

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

Testing

Contributing

Please see contributing.md and open tickets for details and a todolist.

Credits

License

MIT. Please see the license file for more information.


All versions of orchid-tables with dependencies

PHP Build Version
Package Version
Requires php Version ^8.0|^8.1
orchid/platform Version ^12.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package cryptodev4/orchid-tables contains the following files

Loading the files please wait ....