This commit is contained in:
2025-12-25 23:30:14 +08:00
parent 7c1d6d447e
commit 7439a4a794
7 changed files with 24 additions and 8 deletions
+1 -1
View File
@@ -83,7 +83,7 @@ class BaseController
//多文件上传 //多文件上传
$files = $request->file(); $files = $request->file();
try { try {
$result = Storage::adapter('minio') $result = Storage::adapter('oss')
->path($savePath) ->path($savePath)
->size($maxsize) ->size($maxsize)
->extYes($mimetype) ->extYes($mimetype)
+1 -1
View File
@@ -122,7 +122,7 @@ class Auth implements MiddlewareInterface
]); ]);
$IM = new \support\OpenImSdk\Client([ $IM = new \support\OpenImSdk\Client([
'host' => 'http://127.0.0.1:10002', // OpenIM API地址 'host' => 'http://127.0.0.1:10002', // OpenIM API地址
'secret' => 'openIM123', // OpenIM密钥 'secret' => 'n1e5a6s6m7', // OpenIM密钥
]); ]);
$request->IM = $IM; $request->IM = $IM;
$response = $next($request); $response = $next($request);
+17 -2
View File
@@ -76,15 +76,30 @@ return [
'url' => 'http://156.238.245.175:10005/openim' // 静态文件访问域名 'url' => 'http://156.238.245.175:10005/openim' // 静态文件访问域名
], ],
'oss' => [ 'oss' => [
'driver' => \Shopwwi\WebmanFilesystem\Adapter\AliyunOssAdapterFactory::class,
'accessId' => 'LTAI5tAAVVWAyavjFEpjSqjP',
'accessSecret' => 'qBOXJLe5xFGbH01UdcTYVZ1JKDV4ia',
'bucket' => 'shunliao',
'endpoint' => 'oss-cn-shenzhen.aliyuncs.com',
'url' => '//shunliao.oss-accelerate.aliyuncs.com', // 静态文件访问域名
// 'timeout' => 3600,
// 'connectTimeout' => 10,
'isCName' => false,
// 'token' => null,
// 'proxy' => null,
'prefix' => '',
],
'ossmy' => [
'driver' => \Shopwwi\WebmanFilesystem\Adapter\AliyunOssAdapterFactory::class, 'driver' => \Shopwwi\WebmanFilesystem\Adapter\AliyunOssAdapterFactory::class,
'accessId' => 'LTAI5tLsFoJAda5juPabytuU', 'accessId' => 'LTAI5tLsFoJAda5juPabytuU',
'accessSecret' => 'ZyiKpt6lqLBfHPZcvHd7SWM7eENRJW', 'accessSecret' => 'ZyiKpt6lqLBfHPZcvHd7SWM7eENRJW',
'bucket' => 'wjba', 'bucket' => 'wjba',
'endpoint' => 'oss-cn-hongkong.aliyuncs.com', 'endpoint' => 'oss-cn-hongkong.aliyuncs.com',
'url' => '//wjba.oss-accelerate.aliyuncs.com' // 静态文件访问域名 'url' => '//wjba.oss-accelerate.aliyuncs.com', // 静态文件访问域名
// 'timeout' => 3600, // 'timeout' => 3600,
// 'connectTimeout' => 10, // 'connectTimeout' => 10,
// 'isCName' => false, 'isCName' => false,
'prefix' => '',
// 'token' => null, // 'token' => null,
// 'proxy' => null, // 'proxy' => null,
], ],
@@ -92,7 +92,7 @@ class FilesController extends Crud
} }
$mimetype = explode(',',Config('site.upload_mimetype')); $mimetype = explode(',',Config('site.upload_mimetype'));
$maxsize = Config('site.upload_maxsize')*1024*1024; $maxsize = Config('site.upload_maxsize')*1024*1024;
$result = Storage::adapter('minio') $result = Storage::adapter('oss')
->path($savePath) ->path($savePath)
->size($maxsize) ->size($maxsize)
->extYes($mimetype) ->extYes($mimetype)
+1
View File
@@ -15,6 +15,7 @@
var require = { var require = {
config: {$config| json_encode=JSON_UNESCAPED_UNICODE|raw} config: {$config| json_encode=JSON_UNESCAPED_UNICODE|raw}
}; };
window.Config = require.config;
var user = {$user|json_encode|raw}; var user = {$user|json_encode|raw};
</script> </script>
</head> </head>
+2 -2
View File
@@ -5,7 +5,7 @@ requirejs.config({
baseUrl: window.Config.cdnurl+window.Config.admin_path+'/js/', baseUrl: window.Config.cdnurl+window.Config.admin_path+'/js/',
packages: [{ packages: [{
name: 'moment', name: 'moment',
location: '../libs/moment', location: window.Config.admin_path+'/libs/moment',
main: 'moment' main: 'moment'
}], }],
paths: { paths: {
@@ -48,7 +48,7 @@ requirejs.config({
}, },
map: { map: {
'*': { '*': {
'css': '../libs/require-css.min.js' // or whatever the path to require-css is 'css': window.Config.admin_path+'/libs/require-css.min.js' // or whatever the path to require-css is
} }
}, },
shim: { shim: {
+1 -1
View File
@@ -98,7 +98,7 @@ define(['lightyear','multitabs', '../libs/Chart','form','bootstrap'], function (
init: [{ init: [{
type: 'main', type: 'main',
title: '首页', title: '首页',
url: 'index/'+Config.fixedpage url: Fast.api.fixurl('index/'+Config.fixedpage)
}] }]
}); });