1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- <?php
- namespace Modules\Common\Services;
- class CommonConfigService
- {
- /**
- * 获取首页列表类型映射
- * @return mixed[]
- * <pre>
- * [
- * 1 => [
- * 'label' => 'xxx',
- * 'value' => 1,
- * ],
- * ]
- * </pre>
- */
- public static function getFirstPageListTypeMap() {
- return collect(config('common.common.firstPageListType'))->keyBy('value')->toArray();
- }
- /**
- * 获取小程序类型映射
- * @return mixed[]
- * <pre>
- * [
- * 1 => [
- * 'label' => 'xxx',
- * 'value' => 1,
- * ],
- * ]
- * </pre>
- */
- public static function getMiniprogramTypeMap() {
- return collect(config('common.common.miniprogramType'))->keyBy('value')->toArray();
- }
- /**
- * 获取支付类型映射
- * @return mixed[]
- * <pre>
- * [
- * 1 => [
- * 'label' => 'xxx',
- * 'value' => 1,
- * ],
- * ]
- * </pre>
- */
- public static function getPayTypeMap() {
- return collect(config('common.common.payType'))->keyBy('value')->toArray();
- }
- }
|