Skip to content

Lodpod print template visual editor LodPod打印模板Web可视化编辑器扩展

License

Notifications You must be signed in to change notification settings

laravel-admin-extensions/lodpod-editor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lodpod-Editor

It's a laravel-admin extension, use for lodpod print templates editing.

Installation

$ composer require xiewenfeng/lodpod-editor

$ php artisan admin:import lodpod-editor

Usage

/**
     * Make a form builder.
     *
     * @return Form
     */
    protected function form()
    {
        $form = new Form(new LodpodEditorTemplate);
        $form->text('name', __('Name'));
        $form->lodpod_editor('data', __('Data'))
        	->config([ // background width and height setting
        		'widthField'     =>'width',
        		'heightField'    =>'height',
        		'backgroundField'=>'background'
        	])
        	->fields([ // left items
	        	[
				'id'=>'sender', 
				'text'=>trans('admin.lodpod_editor.sender')
				],
	        	[
				'id'=>'sender_mobile',
				'text'=>trans('admin.lodpod_editor.sender_mobile')
				],
	        	['id'=>'sender_address',
				'text'=>trans('admin.lodpod_editor.sender_address')
				],
	        	['id'=>'sender_company',
				'text'=>trans('admin.lodpod_editor.sender_company')
				],
	        	['id'=>'sender_zip_code',
				'text'=>trans('admin.lodpod_editor.sender_zip_code')
				],
	        ]);
        return $form;
    }

Demo

demo

About

Lodpod print template visual editor LodPod打印模板Web可视化编辑器扩展

Resources

License

Stars

Watchers

Forks

Packages

No packages published