1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465 |
- <?php
- namespace App\Admin\Actions\Grid;
- use App\Admin\Forms\AppearanceImPortForm;
- use Dcat\Admin\Grid\RowAction;
- use Dcat\Admin\Widgets\Modal;
- use Illuminate\Http\Request;
- use App\Admin\Repositories\DistAppearance;
- use App\Admin\Repositories\DistAppearanceTemplate;
- class AppearanceImport extends RowAction
- {
- public $sourcePath;
- public $appearanceId;
-
- public function title()
- {
- return admin_trans_label('import_tmpl');
- }
-
- public function render()
- {
- $form = AppearanceImPortForm::make()->payload(['id' => $this->getKey()]);
-
- return Modal::make()
- ->lg()
- ->title($this->title)
- ->body($form)
-
- ->button($this->title());
- }
- public function confirm()
- {
- return [
- "Are you sure you want to import?",
- $this->row->title,
- ];
- }
-
- public function parameters()
- {
- return [
-
- 'title' => $this->row->title,
- 'folder' => $this->row->folder
- ];
- }
- }
|