<?php
 namespace App\Http\Controllers\Admin; use TechSoft\Laravel\Admin\Cms\ConfigCms; use TechSoft\Laravel\Admin\Cms\Field\FieldImage; use TechSoft\Laravel\Admin\Cms\Field\FieldSwitch; use TechSoft\Laravel\Admin\Cms\Field\FieldText; use TechSoft\Laravel\Admin\Cms\Field\FieldTextarea; use TechSoft\Laravel\Admin\Support\AdminCheckController; use TechSoft\Laravel\Admin\Traits\ConfigEmailTrait; use TechSoft\Laravel\Admin\Traits\ConfigMemberSettingTrait; use TechSoft\Laravel\Admin\Traits\ConfigOauthTrait; use TechSoft\Laravel\Admin\Traits\ConfigPayTrait; use TechSoft\Laravel\Admin\Traits\ConfigSettingTrait; use TechSoft\Laravel\Admin\Traits\ConfigShareTrait; use TechSoft\Laravel\Admin\Traits\ConfigSmsTrait; use TechSoft\Laravel\Admin\Traits\ConfigSSOTrait; use TechSoft\Laravel\Admin\Traits\ConfigUploadTrait; use TechSoft\Laravel\Admin\Traits\ConfigVisitTrait; class ConfigController extends AdminCheckController { use ConfigSettingTrait; use ConfigVisitTrait; use ConfigEmailTrait; use ConfigSmsTrait; use ConfigMemberSettingTrait; use ConfigOauthTrait; use ConfigSSOTrait; use ConfigPayTrait; use ConfigUploadTrait; use ConfigShareTrait; public function custom(ConfigCms $configCms) { return $configCms->execute($this, [ 'group' => 'custom', 'pageTitle' => '功能设置', 'fields' => [ 'customMemberNoteHistoryKeep' => ['type' => FieldText::class, 'title' => '用户文章历史保存最大数量', 'desc' => '默认为50'], 'customTipEnable' => ['type' => FieldSwitch::class, 'title' => '开启打赏功能', 'desc' => ''], 'customTipCashRate' => ['type' => FieldText::class, 'title' => '打赏提现手续费百分比', 'desc' => '单位%,如填写3表示3%'], 'customPCHomeSideBannerImage' => ['type' => FieldImage::class, 'title' => 'PC首页右侧广告图片', 'desc' => ''], 'customPCHomeSideBannerUrl' => ['type' => FieldText::class, 'title' => 'PC首页右侧广告链接', 'desc' => ''], ] ]); } public function appSetting(ConfigCms $configCms) { return $configCms->execute($this, [ 'group' => 'appSetting', 'pageTitle' => '基本设置', 'fields' => [ 'appSchema' => ['type' => FieldText::class, 'title' => '手机AppSchema', 'desc' => '如 notesns'], ] ]); } public function appAndroid(ConfigCms $configCms) { return $configCms->execute($this, [ 'group' => 'appAndroid', 'pageTitle' => 'Android设置', 'fields' => [ 'appAndroidLatestVersion' => ['type' => FieldText::class, 'title' => 'Android最新版本', 'desc' => ''], 'appAndroidForceUpgrade' => ['type' => FieldSwitch::class, 'title' => 'Android强制升级', 'desc' => ''], 'appAndroidFeature' => ['type' => FieldTextarea::class, 'title' => 'Android特性', 'desc' => '每行一个'], 'appAndroidDownloadUrl' => ['type' => FieldText::class, 'title' => 'Android下载链接', 'desc' => ''], ] ]); } public function appIos(ConfigCms $configCms) { return $configCms->execute($this, [ 'group' => 'appIos', 'pageTitle' => 'iOS设置', 'fields' => [ 'appIosLatestVersion' => ['type' => FieldText::class, 'title' => 'iOS最新版本', 'desc' => ''], 'appIosForceUpgrade' => ['type' => FieldSwitch::class, 'title' => 'iOS强制升级', 'desc' => ''], 'appIosFeature' => ['type' => FieldTextarea::class, 'title' => 'iOS特性', 'desc' => '每行一个'], 'appIosDownloadUrl' => ['type' => FieldText::class, 'title' => 'iOS下载链接', 'desc' => ''], ] ]); } }