定制 docirana/tall-datatables 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

docirana/tall-datatables

最新稳定版本:0.0.1

Composer 安装命令:

composer require docirana/tall-datatables

包简介

Tailwind, Alpine.js, Laravel, and Livewire simple datatables

README 文档

README

Tailwind, Alpine.js, Laravel, and Livewire simple datatables

Installation

You can install the TALL Datatables package via composer.

composer require docirana/tall-datatables

Tailwind Configuration

::: info You can skip this step if you are planning to customize the views. :::

The TALL Datatables has views so you need to adjust your Tailwind CSS config.

/** @type {import('tailwindcss').Config} */
module.exports = {
    content: [
        // ...

        "./vendor/docirana/tall-datatables/src/views/**/*.blade.php"
    ]
}

Publishing Views

To make the tables blend into the style of your project, you may wish to make changes to the layout. This can be done by publishing the views and customize them any way you like.

php artisan vendor:publish --provider="Docirana\TallDatatables\Providers\TallDatatablesServiceProvider"

Example

php artisan livewire:make ExampleComponent
<?php

namespace App\Http\Livewire;

use Docirana\TallDatatables\TallDatatables;
use Illuminate\Database\Eloquent\Builder as EloquentBuilder;
use Illuminate\Database\Query\Builder as QueryBuilder;
use Illuminate\Support\Collection;

class ExampleComponent extends TallDatatables
{
    public function headerData(): Collection
    {
        // TODO: Implement headerData() method.
    }

    public function dataRaw(): array|Collection|QueryBuilder|EloquentBuilder
    {
        // TODO: Implement dataRaw() method.
    }
}

!!! by the dataRaw you need to specify only one return type !!! This is depending on your data.

统计信息

  • 总下载量: 11
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: Blade

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-07-04