承接 doctype_admin/settings 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

doctype_admin/settings

Composer 安装命令:

composer require doctype_admin/settings

包简介

Doctype Admin Panel Settings Plugin

README 文档

README

Doctype Admin Setting Issues Stars Downloads

Laravel 7 Admin Panel Settings Plugin for lazy developers.

Contains : -

  • Setting Management System

Installation

Run Composer Require Command

composer require doctype_admin/settings

Then migrate database

php artisan migrate

To use specific seed use(publish them first)

php artisan db:seed --class=SettingsTableSeeder

If you want to modify Stuffs do..

Install package assets

Install all assets

php artisan DoctypeAdminSetting:install -a

This command will publish

  • config file named Setting.php
  • views files of setting
  • migrations files
  • seed files

Install config file only

php artisan DoctypeAdminSetting:install -c

Install view files only

php artisan DoctypeAdminSetting:install -f

Install migrations files only

php artisan DoctypeAdminSetting:install -m

Install seed files only

php artisan DoctypeAdminSetting:install -d

Note

If seed class is not found try running composer dump-autoload

To add the package route link to be accesable from sidemenu just add following on config/adminlte.php under key 'menu'

        [
            'text' => 'Setting',
            'icon' => 'fas fa-cog',
            'url' => 'admin/setting'
        ],

Setting Plugin Consists following input fields

  • Text Field
  • Rich Textarea
  • Image
  • Select
  • Radio
  • Checkbox

How to access setting value ?

We can access setting's assigned value globally by simply using blade directive like

{{@setting('setting_name')}} // setting_name is one you make while you are creating setting (should be lower cap with space replaced by underscore(_) : Recommended)

e.g

if we have a setting and you name that setting "Site name" then to use the value assigned to that setting use

{{@setting('site_name')}}

Customization

It uses JSON object to customize the input fields.

Customization Objects

Objects Function
value Retives all featured posts
placeholder Gives the input field placeholder
class Adds the given class
id Adds the given id
style Gives the styling
default Makes the mention value as default value eg like in select dropdown or checkbox
checked Makes the checkbox checked as default
options Options given for select options, radio options

Example

Simple Text Field Setting Customization

{
  "class" : "my_class",
  "id" : "my_id",
  "value" : "Doctype Admin",
  "placeholder" : "Site Title Here!!",
  "style" : {
    "color" : "red"
  }
}

Simple Rich Textarea Setting Customization

{
  "class" : "my_class",
  "id" : "another_id",
  "placeholder" : "Rich Text Placeholder",
  "style" : {
    "color" : "red"
  }

Simple Select Field Setting Customization

{
  "default" : "1",
  "options" : {
    "1" : "option 1",
    "2" : "option 2"
  }
}

Simple Radio Field Setting Customization Note type object is mandatory defining whetjer the value to be stored is integer or string type

{
  "type" : "integer",
   "checked" : "1",
  "options" : {
  "1" : "Pratik Shrestha",
  "2" : "DRH2SO4"
            },
"style": {
  "color" : "red"
      }
}

Simple Image Field Setting Customization

{
  "image" : {
    "fit" : {
      "width" : "300",
      "height" : "300"
    },
    "quality" : "80"
  }
}

Note

When using select and radio giving options object in customization is mandatory

Admin Panel Screenshot

Doctype Admin Setting Doctype Admin Setting Doctype Admin Setting

Todos

  • Better Confile File Control
  • Maintainabilty
  • More flexible customization
  • Adding Exceptions

Package Used

License

MIT

DOCTYPE NEPAL ||DR.H2SO4

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-06-29

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固