添加货运单和订单的标签
parent
e8cc9ccc82
commit
298e5f20f8
|
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Actions\Grid;
|
||||
|
||||
use App\Admin\Forms\Tags\OrderPackageTag as OrderPackageTagForm;
|
||||
use App\Models\OrderPackage;
|
||||
use Dcat\Admin\Grid\RowAction;
|
||||
use Dcat\Admin\Widgets\Modal;
|
||||
|
||||
class OrderPackageSetTag extends RowAction
|
||||
{
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
protected $title = '<i class="feather icon-tag grid-action-icon"></i>';
|
||||
|
||||
public function title()
|
||||
{
|
||||
if ($this->title) {
|
||||
return $this->title.' 标签';
|
||||
}
|
||||
|
||||
return '标签';
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Model|Authenticatable|HasPermissions|null $user
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
protected function authorize($user): bool
|
||||
{
|
||||
return $user->can('dcat.admin.order_packages.tags');
|
||||
}
|
||||
|
||||
public function render()
|
||||
{
|
||||
$form = OrderPackageTagForm::make()->payload(['id'=>$this->getKey(), 'type'=>OrderPackage::class]);
|
||||
return Modal::make()
|
||||
->lg()
|
||||
->title($this->title())
|
||||
->body($form)
|
||||
->button($this->title());
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Actions\Grid;
|
||||
|
||||
use App\Admin\Forms\Tags\OrderTag as OrderTagForm;
|
||||
use App\Models\Order;
|
||||
use Dcat\Admin\Grid\RowAction;
|
||||
use Dcat\Admin\Widgets\Modal;
|
||||
|
||||
class OrderSetTag extends RowAction
|
||||
{
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
protected $title = '<i class="feather icon-tag grid-action-icon"></i>';
|
||||
|
||||
public function title()
|
||||
{
|
||||
if ($this->title) {
|
||||
return $this->title.' 标签';
|
||||
}
|
||||
|
||||
return '标签';
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Model|Authenticatable|HasPermissions|null $user
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
protected function authorize($user): bool
|
||||
{
|
||||
return $user->can('dcat.admin.orders.tags');
|
||||
}
|
||||
|
||||
public function render()
|
||||
{
|
||||
$form = OrderTagForm::make()->payload(['id'=>$this->getKey(), 'type'=>Order::class]);
|
||||
return Modal::make()
|
||||
->lg()
|
||||
->title($this->title())
|
||||
->body($form)
|
||||
->button($this->title());
|
||||
}
|
||||
}
|
||||
|
|
@ -3,6 +3,7 @@
|
|||
namespace App\Admin\Controllers;
|
||||
|
||||
use App\Admin\Actions\Grid\CreateOrderPackage;
|
||||
use App\Admin\Actions\Grid\OrderSetTag;
|
||||
use App\Admin\Actions\Show\OrderConsigneeInfo;
|
||||
use App\Admin\Actions\Show\OrderCreatePackage;
|
||||
use App\Admin\Actions\Show\OrderPay;
|
||||
|
|
@ -14,6 +15,7 @@ use App\Models\Order as OrderModel;
|
|||
use App\Models\OrderLog;
|
||||
use App\Models\OrderPackage;
|
||||
use App\Models\OrderProduct;
|
||||
use App\Models\Tag;
|
||||
use Dcat\Admin\Admin;
|
||||
use Dcat\Admin\Form;
|
||||
use Dcat\Admin\Grid;
|
||||
|
|
@ -32,10 +34,17 @@ class OrderController extends AdminController
|
|||
*/
|
||||
protected function grid()
|
||||
{
|
||||
$builder = Order::with('user');
|
||||
$builder = Order::with(['user', 'tags']);
|
||||
return Grid::make($builder, function (Grid $grid) {
|
||||
$grid->column('id')->sortable();
|
||||
$grid->column('sn');
|
||||
$grid->column('tags', '标签')->display(function ($tags) {
|
||||
$array = [];
|
||||
foreach ($this->tags as $key => $tag) {
|
||||
$array[] = $tag->name;
|
||||
}
|
||||
return $array;
|
||||
})->label();
|
||||
$grid->column('user.phone');
|
||||
$grid->column('total_amount')->display(function ($value) {
|
||||
return bcdiv($value, 100, 2);
|
||||
|
|
@ -107,12 +116,20 @@ class OrderController extends AdminController
|
|||
|
||||
$grid->actions(function (Grid\Displayers\Actions $actions) {
|
||||
$actions->disableView(false);
|
||||
if (Admin::user()->can('dcat.admin.orders.tags')) {
|
||||
$actions->append(new OrderSetTag());
|
||||
}
|
||||
// $actions->append(new CreateOrderPackage());
|
||||
});
|
||||
|
||||
$grid->filter(function (Grid\Filter $filter) {
|
||||
$filter->panel();
|
||||
$filter->equal('sn')->width(3);
|
||||
$filter->where('tags', function ($query) {
|
||||
$query->whereHas('tags', function ($q) {
|
||||
$q->whereIn('tags.id', $this->input);
|
||||
});
|
||||
}, '标签')->multipleSelect(Tag::orderTag()->pluck('name', 'id'))->width(3);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,11 +4,13 @@ namespace App\Admin\Controllers;
|
|||
|
||||
use App\Admin\Actions\Grid\KuaidiInfo;
|
||||
use App\Admin\Actions\Grid\OrderPackageFailed;
|
||||
use App\Admin\Actions\Grid\OrderPackageSetTag;
|
||||
use App\Admin\Renderable\PackageProductSimpleTable;
|
||||
use App\Admin\Repositories\OrderPackage;
|
||||
use App\Exceptions\BizException;
|
||||
use App\Models\Order;
|
||||
use App\Models\OrderPackage as OrderPackageModel;
|
||||
use App\Models\Tag;
|
||||
use Dcat\Admin\Admin;
|
||||
use Dcat\Admin\Form;
|
||||
use Dcat\Admin\Grid;
|
||||
|
|
@ -25,10 +27,17 @@ class OrderPackageController extends AdminController
|
|||
*/
|
||||
protected function grid()
|
||||
{
|
||||
$builder = OrderPackage::with('order');
|
||||
$builder = OrderPackage::with(['order', 'tags']);
|
||||
return Grid::make($builder, function (Grid $grid) {
|
||||
// $grid->column('id')->sortable();
|
||||
$grid->column('order.sn');
|
||||
$grid->column('tags', '标签')->display(function ($tags) {
|
||||
$array = [];
|
||||
foreach ($this->tags as $key => $tag) {
|
||||
$array[] = $tag->name;
|
||||
}
|
||||
return $array;
|
||||
})->label();
|
||||
$grid->column('order.consignee_name');
|
||||
$grid->column('order.consignee_telephone');
|
||||
$grid->column('address', '收货地址')->display(function () {
|
||||
|
|
@ -85,9 +94,15 @@ class OrderPackageController extends AdminController
|
|||
$grid->actions(function (Grid\Displayers\Actions $actions) {
|
||||
$actions->disableDelete(Admin::user()->cannot('dcat.admin.order_packages.destroy'));
|
||||
$actions->disableQuickEdit(Admin::user()->cannot('dcat.admin.order_packages.edit'));
|
||||
if (!$actions->row->is_failed && !in_array($actions->row->status, [OrderPackageModel::STATUS_CHECK, OrderPackageModel::STATUS_AUTOCHECK])) {
|
||||
if (!$actions->row->is_failed
|
||||
&& !in_array($actions->row->status, [OrderPackageModel::STATUS_CHECK, OrderPackageModel::STATUS_AUTOCHECK])
|
||||
&& Admin::user()->can('dcat.admin.order_packages.failed')
|
||||
) {
|
||||
$actions->append(new OrderPackageFailed());
|
||||
}
|
||||
if (Admin::user()->can('dcat.admin.order_packages.tags')) {
|
||||
$actions->append(new OrderPackageSetTag());
|
||||
}
|
||||
});
|
||||
|
||||
/** 查询 **/
|
||||
|
|
@ -95,6 +110,11 @@ class OrderPackageController extends AdminController
|
|||
$filter->panel();
|
||||
$filter->like('order.sn')->width(3);
|
||||
$filter->like('shipping_number')->width(3);
|
||||
$filter->where('tags', function ($query) {
|
||||
$query->whereHas('tags', function ($q) {
|
||||
$q->whereIn('tags.id', $this->input);
|
||||
});
|
||||
}, '标签')->multipleSelect(Tag::orderPackageTag()->pluck('name', 'id'))->width(3);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,111 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Controllers;
|
||||
|
||||
use App\Admin\Repositories\Tag;
|
||||
use App\Exceptions\BizException;
|
||||
use App\Models\Taggable;
|
||||
use Dcat\Admin\Admin;
|
||||
use Dcat\Admin\Form;
|
||||
use Dcat\Admin\Grid;
|
||||
use Dcat\Admin\Http\Controllers\AdminController;
|
||||
use Dcat\Admin\Show;
|
||||
use Illuminate\Support\Facades\Request;
|
||||
|
||||
class TagController extends AdminController
|
||||
{
|
||||
/**
|
||||
* Make a grid builder.
|
||||
*
|
||||
* @return Grid
|
||||
*/
|
||||
protected function grid()
|
||||
{
|
||||
return Grid::make(new Tag(), function (Grid $grid) {
|
||||
$grid->column('id')->sortable();
|
||||
$grid->column('type')->using([
|
||||
1=>'订单',
|
||||
2=>'货运',
|
||||
3=>'售后',
|
||||
])->label();
|
||||
$grid->column('name');
|
||||
$grid->column('created_at')->sortable();
|
||||
|
||||
// dd(Request::Input('type', 0));
|
||||
/** 操作 **/
|
||||
$grid->model()->setConstraints([
|
||||
'type' => Request::Input('type', 0),
|
||||
]);
|
||||
//新增
|
||||
if (Admin::user()->can('dcat.admin.tags.create')) {
|
||||
$grid->disableCreateButton(false);
|
||||
$grid->enableDialogCreate();
|
||||
}
|
||||
//修改
|
||||
$grid->showQuickEditButton(Admin::user()->can('dcat.admin.tags.edit'));
|
||||
//删除以及自定义操作
|
||||
$grid->actions(function (Grid\Displayers\Actions $actions) {
|
||||
$actions->disableDelete(Admin::user()->cannot('dcat.admin.tags.destroy'));
|
||||
});
|
||||
|
||||
$grid->filter(function (Grid\Filter $filter) {
|
||||
$filter->panel();
|
||||
$filter->expand(false);
|
||||
$filter->equal('type')->select([
|
||||
1=>'订单',
|
||||
2=>'货运',
|
||||
3=>'售后',
|
||||
])->width(3);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Make a show builder.
|
||||
*
|
||||
* @param mixed $id
|
||||
*
|
||||
* @return Show
|
||||
*/
|
||||
protected function detail($id)
|
||||
{
|
||||
return Show::make($id, new Tag(), function (Show $show) {
|
||||
$show->field('id');
|
||||
$show->field('type');
|
||||
$show->field('name');
|
||||
$show->field('created_at');
|
||||
$show->field('updated_at');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Make a form builder.
|
||||
*
|
||||
* @return Form
|
||||
*/
|
||||
protected function form()
|
||||
{
|
||||
return Form::make(new Tag(), function (Form $form) {
|
||||
$type = Request::Input('type', 0);
|
||||
$form->display('id');
|
||||
$form->radio('type')->options([
|
||||
1=>'订单',
|
||||
2=>'货运',
|
||||
3=>'售后',
|
||||
])->default($type)->required();
|
||||
$form->text('name')->required();
|
||||
|
||||
$form->display('created_at');
|
||||
$form->display('updated_at');
|
||||
});
|
||||
}
|
||||
|
||||
public function destroy($id)
|
||||
{
|
||||
//如果有子分类或者分类下有文章则不允许删除
|
||||
if (Taggable::where('tag_id', $id)->count() > 0) {
|
||||
throw new BizException('当前标签还在使用,无法删除');
|
||||
}
|
||||
return parent::destroy($id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Forms\Tags;
|
||||
|
||||
use Dcat\Admin\Traits\LazyWidget;
|
||||
|
||||
class OrderPackageTag extends Tag
|
||||
{
|
||||
use LazyWidget;
|
||||
|
||||
protected function authorize($user): bool
|
||||
{
|
||||
return $user->can('dcat.admin.packages.tags');
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Forms\Tags;
|
||||
|
||||
use Dcat\Admin\Traits\LazyWidget;
|
||||
|
||||
class OrderTag extends Tag
|
||||
{
|
||||
use LazyWidget;
|
||||
|
||||
protected function authorize($user): bool
|
||||
{
|
||||
return $user->can('dcat.admin.orders.tags');
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Forms\Tags;
|
||||
|
||||
use App\Models\Tag as TagModel;
|
||||
use App\Models\Taggable;
|
||||
use Dcat\Admin\Contracts\LazyRenderable;
|
||||
use Dcat\Admin\Traits\LazyWidget;
|
||||
use Dcat\Admin\Widgets\Form;
|
||||
|
||||
class Tag extends Form implements LazyRenderable
|
||||
{
|
||||
use LazyWidget;
|
||||
|
||||
/**
|
||||
* Handle the form request.
|
||||
*
|
||||
* @param array $input
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle(array $input)
|
||||
{
|
||||
//删除现有所有标签
|
||||
$type = $input['type'];
|
||||
$a = [];
|
||||
array_map(function ($value) use ($type, &$a) {
|
||||
return $a[$value] = [
|
||||
'taggable_type'=>$type,
|
||||
];
|
||||
}, $input['tags']);
|
||||
$type::findOrFail($input['id'])->tags()->sync($a);
|
||||
return $this->response()
|
||||
->success(__('admin.update_succeeded'))
|
||||
->refresh();
|
||||
}
|
||||
|
||||
/**
|
||||
* Build a form here.
|
||||
*/
|
||||
public function form()
|
||||
{
|
||||
$id = $this->payload['id'] ?? 0;
|
||||
$type = $this->payload['type'];
|
||||
$tags = Taggable::where('taggable_id', $id)->where('taggable_type', $type)->get();
|
||||
$scopeTag = lcfirst(class_basename($type)).'Tag';
|
||||
$this->multipleSelect('tags')
|
||||
->options(TagModel::$scopeTag()->pluck('name', 'id'))
|
||||
->customFormat(function () use ($tags) {
|
||||
return array_column($tags->toArray(), 'tag_id');
|
||||
});
|
||||
$this->hidden('id')->value($id);
|
||||
$this->hidden('type')->value($type);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
<?php
|
||||
|
||||
namespace App\Admin\Repositories;
|
||||
|
||||
use App\Models\Tag as Model;
|
||||
use Dcat\Admin\Repositories\EloquentRepository;
|
||||
|
||||
class Tag extends EloquentRepository
|
||||
{
|
||||
/**
|
||||
* Model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $eloquentClass = Model::class;
|
||||
}
|
||||
|
|
@ -111,6 +111,10 @@ Route::group([
|
|||
'index', 'create', 'store', 'edit', 'update', 'destroy',
|
||||
])->names('share_bgs');
|
||||
|
||||
$router->resource('tags', 'TagController')->only([
|
||||
'index', 'create', 'store', 'edit', 'update', 'destroy',
|
||||
]);
|
||||
|
||||
/** api接口 **/
|
||||
$router->get('api/product-categories', 'ProductCategoryController@categories')->name('api.product_categories');
|
||||
$router->get('api/product-group-details', 'ProductGroupController@details')->name('api.product_group_details');
|
||||
|
|
|
|||
|
|
@ -141,6 +141,14 @@ class Order extends Model
|
|||
return $this->hasMany(OrderRefundLog::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* 属于此订单的标签
|
||||
*/
|
||||
public function tags()
|
||||
{
|
||||
return $this->belongsToMany(Tag::class, 'taggables', 'taggable_id', 'tag_id')->wherePivot('taggable_type', self::class)->withTimestamps();
|
||||
}
|
||||
|
||||
/**
|
||||
* 此订单是否待付款
|
||||
*
|
||||
|
|
|
|||
|
|
@ -79,6 +79,14 @@ class OrderPackage extends Model
|
|||
return $this->belongsToMany(OrderProduct::class, 'order_package_products', 'order_package_id', 'order_product_id');
|
||||
}
|
||||
|
||||
/**
|
||||
* 属于此货运单单的标签
|
||||
*/
|
||||
public function tags()
|
||||
{
|
||||
return $this->belongsToMany(Tag::class, 'taggables', 'taggable_id', 'tag_id')->wherePivot('taggable_type', self::class)->withTimestamps();
|
||||
}
|
||||
|
||||
/**
|
||||
* 确认此包裹是否已签收
|
||||
*
|
||||
|
|
|
|||
|
|
@ -0,0 +1,41 @@
|
|||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Dcat\Admin\Traits\HasDateTimeFormatter;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Tag extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
use HasDateTimeFormatter;
|
||||
|
||||
// /**
|
||||
// * 标签下的订单
|
||||
// *
|
||||
// */
|
||||
// public function orders()
|
||||
// {
|
||||
// return $this->morphedByMany(Order::class, 'taggable');
|
||||
// }
|
||||
|
||||
// /**
|
||||
// * 标签下的包裹
|
||||
// *
|
||||
// */
|
||||
// public function packages()
|
||||
// {
|
||||
// return $this->morphedByMany(OrderPackage::class, 'taggable');
|
||||
// }
|
||||
|
||||
public function scopeOrderTag()
|
||||
{
|
||||
return $this->where('type', 1);
|
||||
}
|
||||
|
||||
public function scopeOrderPackageTag()
|
||||
{
|
||||
return $this->where('type', 2);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Taggable extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
public function tag()
|
||||
{
|
||||
return $this->belongsTo(Tag::class);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class CreateTagsTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('tags', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->unsignedBigInteger('type')->comment('标签分类:1订单,2货运,3售后');
|
||||
$table->string('name')->comment('标签名称');
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('tags');
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class CreateTaggablesTable extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::create('taggables', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->unsignedBigInteger('tag_id')->comment('标签ID');
|
||||
$table->unsignedBigInteger('taggable_id')->comment('模型ID');
|
||||
$table->string('taggable_type')->comment('模型名称');
|
||||
$table->timestamps();
|
||||
|
||||
$table->index(['taggable_id', 'tag_id']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('taggables');
|
||||
}
|
||||
}
|
||||
|
|
@ -166,6 +166,11 @@ class AdminMenuSeeder extends Seeder
|
|||
'icon' => '',
|
||||
'uri' => 'orders',
|
||||
],
|
||||
[
|
||||
'title' =>'订单标签',
|
||||
'icon' => '',
|
||||
'uri' => 'tags?type=1',
|
||||
],
|
||||
[
|
||||
'title' =>'调价范围权限',
|
||||
'icon' => '',
|
||||
|
|
@ -183,6 +188,11 @@ class AdminMenuSeeder extends Seeder
|
|||
'icon' => '',
|
||||
'uri' => 'order-packages',
|
||||
],
|
||||
[
|
||||
'title' =>'货运标签',
|
||||
'icon' => '',
|
||||
'uri' => 'tags?type=2',
|
||||
],
|
||||
],
|
||||
],
|
||||
[
|
||||
|
|
|
|||
|
|
@ -197,6 +197,7 @@ class AdminPermissionSeeder extends Seeder
|
|||
'remark'=>['name' =>'订单备注'],
|
||||
'consignee'=>['name' =>'修改地址'],
|
||||
'create_package'=>['name' =>'发货'],
|
||||
'tags'=>['name' =>'标签设置'],
|
||||
],
|
||||
],
|
||||
'order_reduce_ranges'=>[
|
||||
|
|
@ -208,6 +209,7 @@ class AdminPermissionSeeder extends Seeder
|
|||
'curd' =>['index', 'edit', 'update', 'destroy'],
|
||||
'children' => [
|
||||
'failed' => ['name' =>'作废'],
|
||||
'tags'=>['name' =>'标签设置'],
|
||||
],
|
||||
],
|
||||
'app_versions'=>[
|
||||
|
|
@ -218,6 +220,10 @@ class AdminPermissionSeeder extends Seeder
|
|||
'name'=>'分享背景',
|
||||
'curd' => ['index', 'create', 'store', 'edit', 'update', 'destroy'],
|
||||
],
|
||||
'tags'=>[
|
||||
'name' =>'标签管理',
|
||||
'curd' => ['index', 'create', 'store', 'edit', 'update', 'destroy'],
|
||||
],
|
||||
];
|
||||
try {
|
||||
DB::begintransaction();
|
||||
|
|
|
|||
|
|
@ -49,6 +49,7 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection image
|
||||
* @property Grid\Column|Collection jump_link
|
||||
* @property Grid\Column|Collection jump_type
|
||||
* @property Grid\Column|Collection remarks
|
||||
* @property Grid\Column|Collection sort
|
||||
* @property Grid\Column|Collection after_sale_id
|
||||
* @property Grid\Column|Collection desc
|
||||
|
|
@ -57,7 +58,6 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection num
|
||||
* @property Grid\Column|Collection order_id
|
||||
* @property Grid\Column|Collection order_product_id
|
||||
* @property Grid\Column|Collection remarks
|
||||
* @property Grid\Column|Collection sn
|
||||
* @property Grid\Column|Collection state
|
||||
* @property Grid\Column|Collection tracking_number
|
||||
|
|
@ -122,6 +122,7 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection gift_for_sku_id
|
||||
* @property Grid\Column|Collection reduced_amount
|
||||
* @property Grid\Column|Collection remain_quantity
|
||||
* @property Grid\Column|Collection sales_value
|
||||
* @property Grid\Column|Collection sell_price
|
||||
* @property Grid\Column|Collection sku_id
|
||||
* @property Grid\Column|Collection specs
|
||||
|
|
@ -157,6 +158,7 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection reviewer_id
|
||||
* @property Grid\Column|Collection buynote_id
|
||||
* @property Grid\Column|Collection cost_price
|
||||
* @property Grid\Column|Collection growth_value
|
||||
* @property Grid\Column|Collection market_price
|
||||
* @property Grid\Column|Collection media
|
||||
* @property Grid\Column|Collection release_at
|
||||
|
|
@ -176,6 +178,9 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection template_id
|
||||
* @property Grid\Column|Collection expires_at
|
||||
* @property Grid\Column|Collection phone
|
||||
* @property Grid\Column|Collection tag_id
|
||||
* @property Grid\Column|Collection tag_log_id
|
||||
* @property Grid\Column|Collection tag_log_type
|
||||
* @property Grid\Column|Collection m_cid
|
||||
* @property Grid\Column|Collection u_cid
|
||||
* @property Grid\Column|Collection coupon_amount
|
||||
|
|
@ -186,7 +191,6 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection gender
|
||||
* @property Grid\Column|Collection inviter_id
|
||||
* @property Grid\Column|Collection nickname
|
||||
* @property Grid\Column|Collection growth_value
|
||||
* @property Grid\Column|Collection vip_id
|
||||
* @property Grid\Column|Collection email
|
||||
* @property Grid\Column|Collection email_verified_at
|
||||
|
|
@ -195,6 +199,16 @@ namespace Dcat\Admin {
|
|||
* @property Grid\Column|Collection phone_verified_at
|
||||
* @property Grid\Column|Collection register_ip
|
||||
* @property Grid\Column|Collection status_remark
|
||||
* @property Grid\Column|Collection action
|
||||
* @property Grid\Column|Collection before_balance
|
||||
* @property Grid\Column|Collection fee
|
||||
* @property Grid\Column|Collection loggable_id
|
||||
* @property Grid\Column|Collection loggable_type
|
||||
* @property Grid\Column|Collection wallet_id
|
||||
* @property Grid\Column|Collection balance
|
||||
* @property Grid\Column|Collection total_expenses
|
||||
* @property Grid\Column|Collection total_revenue
|
||||
* @property Grid\Column|Collection withdrawable
|
||||
*
|
||||
* @method Grid\Column|Collection created_at(string $label = null)
|
||||
* @method Grid\Column|Collection dimensions(string $label = null)
|
||||
|
|
@ -234,6 +248,7 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection image(string $label = null)
|
||||
* @method Grid\Column|Collection jump_link(string $label = null)
|
||||
* @method Grid\Column|Collection jump_type(string $label = null)
|
||||
* @method Grid\Column|Collection remarks(string $label = null)
|
||||
* @method Grid\Column|Collection sort(string $label = null)
|
||||
* @method Grid\Column|Collection after_sale_id(string $label = null)
|
||||
* @method Grid\Column|Collection desc(string $label = null)
|
||||
|
|
@ -242,7 +257,6 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection num(string $label = null)
|
||||
* @method Grid\Column|Collection order_id(string $label = null)
|
||||
* @method Grid\Column|Collection order_product_id(string $label = null)
|
||||
* @method Grid\Column|Collection remarks(string $label = null)
|
||||
* @method Grid\Column|Collection sn(string $label = null)
|
||||
* @method Grid\Column|Collection state(string $label = null)
|
||||
* @method Grid\Column|Collection tracking_number(string $label = null)
|
||||
|
|
@ -307,6 +321,7 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection gift_for_sku_id(string $label = null)
|
||||
* @method Grid\Column|Collection reduced_amount(string $label = null)
|
||||
* @method Grid\Column|Collection remain_quantity(string $label = null)
|
||||
* @method Grid\Column|Collection sales_value(string $label = null)
|
||||
* @method Grid\Column|Collection sell_price(string $label = null)
|
||||
* @method Grid\Column|Collection sku_id(string $label = null)
|
||||
* @method Grid\Column|Collection specs(string $label = null)
|
||||
|
|
@ -342,6 +357,7 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection reviewer_id(string $label = null)
|
||||
* @method Grid\Column|Collection buynote_id(string $label = null)
|
||||
* @method Grid\Column|Collection cost_price(string $label = null)
|
||||
* @method Grid\Column|Collection growth_value(string $label = null)
|
||||
* @method Grid\Column|Collection market_price(string $label = null)
|
||||
* @method Grid\Column|Collection media(string $label = null)
|
||||
* @method Grid\Column|Collection release_at(string $label = null)
|
||||
|
|
@ -361,6 +377,9 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection template_id(string $label = null)
|
||||
* @method Grid\Column|Collection expires_at(string $label = null)
|
||||
* @method Grid\Column|Collection phone(string $label = null)
|
||||
* @method Grid\Column|Collection tag_id(string $label = null)
|
||||
* @method Grid\Column|Collection tag_log_id(string $label = null)
|
||||
* @method Grid\Column|Collection tag_log_type(string $label = null)
|
||||
* @method Grid\Column|Collection m_cid(string $label = null)
|
||||
* @method Grid\Column|Collection u_cid(string $label = null)
|
||||
* @method Grid\Column|Collection coupon_amount(string $label = null)
|
||||
|
|
@ -371,7 +390,6 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection gender(string $label = null)
|
||||
* @method Grid\Column|Collection inviter_id(string $label = null)
|
||||
* @method Grid\Column|Collection nickname(string $label = null)
|
||||
* @method Grid\Column|Collection growth_value(string $label = null)
|
||||
* @method Grid\Column|Collection vip_id(string $label = null)
|
||||
* @method Grid\Column|Collection email(string $label = null)
|
||||
* @method Grid\Column|Collection email_verified_at(string $label = null)
|
||||
|
|
@ -380,6 +398,16 @@ namespace Dcat\Admin {
|
|||
* @method Grid\Column|Collection phone_verified_at(string $label = null)
|
||||
* @method Grid\Column|Collection register_ip(string $label = null)
|
||||
* @method Grid\Column|Collection status_remark(string $label = null)
|
||||
* @method Grid\Column|Collection action(string $label = null)
|
||||
* @method Grid\Column|Collection before_balance(string $label = null)
|
||||
* @method Grid\Column|Collection fee(string $label = null)
|
||||
* @method Grid\Column|Collection loggable_id(string $label = null)
|
||||
* @method Grid\Column|Collection loggable_type(string $label = null)
|
||||
* @method Grid\Column|Collection wallet_id(string $label = null)
|
||||
* @method Grid\Column|Collection balance(string $label = null)
|
||||
* @method Grid\Column|Collection total_expenses(string $label = null)
|
||||
* @method Grid\Column|Collection total_revenue(string $label = null)
|
||||
* @method Grid\Column|Collection withdrawable(string $label = null)
|
||||
*/
|
||||
class Grid {}
|
||||
|
||||
|
|
@ -424,6 +452,7 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection image
|
||||
* @property Show\Field|Collection jump_link
|
||||
* @property Show\Field|Collection jump_type
|
||||
* @property Show\Field|Collection remarks
|
||||
* @property Show\Field|Collection sort
|
||||
* @property Show\Field|Collection after_sale_id
|
||||
* @property Show\Field|Collection desc
|
||||
|
|
@ -432,7 +461,6 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection num
|
||||
* @property Show\Field|Collection order_id
|
||||
* @property Show\Field|Collection order_product_id
|
||||
* @property Show\Field|Collection remarks
|
||||
* @property Show\Field|Collection sn
|
||||
* @property Show\Field|Collection state
|
||||
* @property Show\Field|Collection tracking_number
|
||||
|
|
@ -497,6 +525,7 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection gift_for_sku_id
|
||||
* @property Show\Field|Collection reduced_amount
|
||||
* @property Show\Field|Collection remain_quantity
|
||||
* @property Show\Field|Collection sales_value
|
||||
* @property Show\Field|Collection sell_price
|
||||
* @property Show\Field|Collection sku_id
|
||||
* @property Show\Field|Collection specs
|
||||
|
|
@ -532,6 +561,7 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection reviewer_id
|
||||
* @property Show\Field|Collection buynote_id
|
||||
* @property Show\Field|Collection cost_price
|
||||
* @property Show\Field|Collection growth_value
|
||||
* @property Show\Field|Collection market_price
|
||||
* @property Show\Field|Collection media
|
||||
* @property Show\Field|Collection release_at
|
||||
|
|
@ -551,6 +581,9 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection template_id
|
||||
* @property Show\Field|Collection expires_at
|
||||
* @property Show\Field|Collection phone
|
||||
* @property Show\Field|Collection tag_id
|
||||
* @property Show\Field|Collection tag_log_id
|
||||
* @property Show\Field|Collection tag_log_type
|
||||
* @property Show\Field|Collection m_cid
|
||||
* @property Show\Field|Collection u_cid
|
||||
* @property Show\Field|Collection coupon_amount
|
||||
|
|
@ -561,7 +594,6 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection gender
|
||||
* @property Show\Field|Collection inviter_id
|
||||
* @property Show\Field|Collection nickname
|
||||
* @property Show\Field|Collection growth_value
|
||||
* @property Show\Field|Collection vip_id
|
||||
* @property Show\Field|Collection email
|
||||
* @property Show\Field|Collection email_verified_at
|
||||
|
|
@ -570,6 +602,16 @@ namespace Dcat\Admin {
|
|||
* @property Show\Field|Collection phone_verified_at
|
||||
* @property Show\Field|Collection register_ip
|
||||
* @property Show\Field|Collection status_remark
|
||||
* @property Show\Field|Collection action
|
||||
* @property Show\Field|Collection before_balance
|
||||
* @property Show\Field|Collection fee
|
||||
* @property Show\Field|Collection loggable_id
|
||||
* @property Show\Field|Collection loggable_type
|
||||
* @property Show\Field|Collection wallet_id
|
||||
* @property Show\Field|Collection balance
|
||||
* @property Show\Field|Collection total_expenses
|
||||
* @property Show\Field|Collection total_revenue
|
||||
* @property Show\Field|Collection withdrawable
|
||||
*
|
||||
* @method Show\Field|Collection created_at(string $label = null)
|
||||
* @method Show\Field|Collection dimensions(string $label = null)
|
||||
|
|
@ -609,6 +651,7 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection image(string $label = null)
|
||||
* @method Show\Field|Collection jump_link(string $label = null)
|
||||
* @method Show\Field|Collection jump_type(string $label = null)
|
||||
* @method Show\Field|Collection remarks(string $label = null)
|
||||
* @method Show\Field|Collection sort(string $label = null)
|
||||
* @method Show\Field|Collection after_sale_id(string $label = null)
|
||||
* @method Show\Field|Collection desc(string $label = null)
|
||||
|
|
@ -617,7 +660,6 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection num(string $label = null)
|
||||
* @method Show\Field|Collection order_id(string $label = null)
|
||||
* @method Show\Field|Collection order_product_id(string $label = null)
|
||||
* @method Show\Field|Collection remarks(string $label = null)
|
||||
* @method Show\Field|Collection sn(string $label = null)
|
||||
* @method Show\Field|Collection state(string $label = null)
|
||||
* @method Show\Field|Collection tracking_number(string $label = null)
|
||||
|
|
@ -682,6 +724,7 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection gift_for_sku_id(string $label = null)
|
||||
* @method Show\Field|Collection reduced_amount(string $label = null)
|
||||
* @method Show\Field|Collection remain_quantity(string $label = null)
|
||||
* @method Show\Field|Collection sales_value(string $label = null)
|
||||
* @method Show\Field|Collection sell_price(string $label = null)
|
||||
* @method Show\Field|Collection sku_id(string $label = null)
|
||||
* @method Show\Field|Collection specs(string $label = null)
|
||||
|
|
@ -717,6 +760,7 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection reviewer_id(string $label = null)
|
||||
* @method Show\Field|Collection buynote_id(string $label = null)
|
||||
* @method Show\Field|Collection cost_price(string $label = null)
|
||||
* @method Show\Field|Collection growth_value(string $label = null)
|
||||
* @method Show\Field|Collection market_price(string $label = null)
|
||||
* @method Show\Field|Collection media(string $label = null)
|
||||
* @method Show\Field|Collection release_at(string $label = null)
|
||||
|
|
@ -736,6 +780,9 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection template_id(string $label = null)
|
||||
* @method Show\Field|Collection expires_at(string $label = null)
|
||||
* @method Show\Field|Collection phone(string $label = null)
|
||||
* @method Show\Field|Collection tag_id(string $label = null)
|
||||
* @method Show\Field|Collection tag_log_id(string $label = null)
|
||||
* @method Show\Field|Collection tag_log_type(string $label = null)
|
||||
* @method Show\Field|Collection m_cid(string $label = null)
|
||||
* @method Show\Field|Collection u_cid(string $label = null)
|
||||
* @method Show\Field|Collection coupon_amount(string $label = null)
|
||||
|
|
@ -746,7 +793,6 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection gender(string $label = null)
|
||||
* @method Show\Field|Collection inviter_id(string $label = null)
|
||||
* @method Show\Field|Collection nickname(string $label = null)
|
||||
* @method Show\Field|Collection growth_value(string $label = null)
|
||||
* @method Show\Field|Collection vip_id(string $label = null)
|
||||
* @method Show\Field|Collection email(string $label = null)
|
||||
* @method Show\Field|Collection email_verified_at(string $label = null)
|
||||
|
|
@ -755,6 +801,16 @@ namespace Dcat\Admin {
|
|||
* @method Show\Field|Collection phone_verified_at(string $label = null)
|
||||
* @method Show\Field|Collection register_ip(string $label = null)
|
||||
* @method Show\Field|Collection status_remark(string $label = null)
|
||||
* @method Show\Field|Collection action(string $label = null)
|
||||
* @method Show\Field|Collection before_balance(string $label = null)
|
||||
* @method Show\Field|Collection fee(string $label = null)
|
||||
* @method Show\Field|Collection loggable_id(string $label = null)
|
||||
* @method Show\Field|Collection loggable_type(string $label = null)
|
||||
* @method Show\Field|Collection wallet_id(string $label = null)
|
||||
* @method Show\Field|Collection balance(string $label = null)
|
||||
* @method Show\Field|Collection total_expenses(string $label = null)
|
||||
* @method Show\Field|Collection total_revenue(string $label = null)
|
||||
* @method Show\Field|Collection withdrawable(string $label = null)
|
||||
*/
|
||||
class Show {}
|
||||
|
||||
|
|
|
|||
|
|
@ -22,4 +22,5 @@ return [
|
|||
OrderProduct::class => '订单商品',
|
||||
AfterSale::class => '售后订单',
|
||||
Article::class => '文章',
|
||||
OrderPackage::class => '包裹',
|
||||
];
|
||||
|
|
|
|||
|
|
@ -0,0 +1,14 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'labels' => [
|
||||
'Tag' => '标签管理',
|
||||
'tags' => '标签管理',
|
||||
],
|
||||
'fields' => [
|
||||
'type' => '标签分类',
|
||||
'name' => '标签名称',
|
||||
],
|
||||
'options' => [
|
||||
],
|
||||
];
|
||||
Loading…
Reference in New Issue