mirror of
https://gitee.com/zoujingli/ThinkAdmin.git
synced 2026-07-14 03:11:07 +08:00
Compare commits
4 Commits
191b4b6f38
...
ef9f90288d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ef9f90288d | ||
|
|
8ae4647205 | ||
|
|
c83bf37ac8 | ||
|
|
734c0fda04 |
@ -47,7 +47,7 @@ class Update extends Controller
|
||||
if (!ModuleService::checkAllowDownload($filename)) {
|
||||
$this->error('下载的文件不在认证规则中!');
|
||||
}
|
||||
if (file_exists($realname = $this->app->getRootPath() . $filename)) {
|
||||
if (file_exists($realname = with_path($filename))) {
|
||||
$this->success('读取文件内容成功!', [
|
||||
'content' => base64_encode(file_get_contents($realname)),
|
||||
]);
|
||||
|
||||
@ -136,7 +136,7 @@ class UserTransfer extends Command
|
||||
'mch_key' => $data['wechat_mch_key'],
|
||||
'ssl_key' => $local->path($file1, true),
|
||||
'ssl_cer' => $local->path($file2, true),
|
||||
'cache_path' => $this->app->getRootPath() . 'runtime' . DIRECTORY_SEPARATOR . 'wechat',
|
||||
'cache_path' => with_path('runtime/wechat'),
|
||||
];
|
||||
}
|
||||
|
||||
@ -151,8 +151,8 @@ class UserTransfer extends Command
|
||||
*/
|
||||
private function getWechatInfo(int $uuid, string $type): ?array
|
||||
{
|
||||
$user = DataUser::mk()->where(['id' => $uuid])->find();
|
||||
if (empty($user)) return null;
|
||||
$user = DataUser::mk()->where(['id' => $uuid])->findOrEmpty();
|
||||
if ($user->isEmpty()) return null;
|
||||
$appid1 = sysconf('data.wxapp_appid');
|
||||
if (strtolower(sysconf('wechat.type')) === 'api') {
|
||||
$appid2 = sysconf('wechat.appid');
|
||||
@ -198,7 +198,7 @@ class UserTransfer extends Command
|
||||
|
||||
/**
|
||||
* 查询更新提现打款状态
|
||||
* @param array $item
|
||||
* @param \think\Model|array $item
|
||||
* @throws \WeChat\Exceptions\InvalidResponseException
|
||||
* @throws \WeChat\Exceptions\LocalCacheException
|
||||
* @throws \think\admin\Exception
|
||||
@ -206,7 +206,7 @@ class UserTransfer extends Command
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
*/
|
||||
private function queryTransferBank(array $item)
|
||||
private function queryTransferBank($item)
|
||||
{
|
||||
$config = $this->getConfig($item['uuid']);
|
||||
[$config['appid'], $config['openid']] = [$item['appid'], $item['openid']];
|
||||
@ -236,7 +236,7 @@ class UserTransfer extends Command
|
||||
|
||||
/**
|
||||
* 查询更新提现打款状态
|
||||
* @param array $item
|
||||
* @param \think\Model|array $item
|
||||
* @throws \WeChat\Exceptions\InvalidResponseException
|
||||
* @throws \WeChat\Exceptions\LocalCacheException
|
||||
* @throws \think\admin\Exception
|
||||
@ -244,7 +244,7 @@ class UserTransfer extends Command
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
*/
|
||||
private function queryTransferWallet(array $item)
|
||||
private function queryTransferWallet($item)
|
||||
{
|
||||
$config = $this->getConfig($item['uuid']);
|
||||
[$config['appid'], $config['openid']] = [$item['appid'], $item['openid']];
|
||||
|
||||
@ -47,7 +47,7 @@ class Wxapp extends Controller
|
||||
$this->config = [
|
||||
'appid' => $option['appid'] ?? '',
|
||||
'appsecret' => $option['appkey'] ?? '',
|
||||
'cache_path' => $this->app->getRootPath() . 'runtime' . DIRECTORY_SEPARATOR . 'wechat',
|
||||
'cache_path' => with_path('runtime/wechat'),
|
||||
];
|
||||
if (empty(UserAdminService::TYPES[$this->type]['auth'])) {
|
||||
$this->error("接口类型[{$this->type}]没有定义规则");
|
||||
|
||||
@ -115,7 +115,7 @@ class WechatPaymentService extends PaymentService
|
||||
'appid' => $this->params['wechat_appid'],
|
||||
'mch_id' => $this->params['wechat_mch_id'],
|
||||
'mch_key' => $this->params['wechat_mch_key'],
|
||||
'cache_path' => $this->app->getRootPath() . 'runtime' . DIRECTORY_SEPARATOR . 'wechat',
|
||||
'cache_path' => with_path('runtime/wechat'),
|
||||
]);
|
||||
return $this;
|
||||
}
|
||||
|
||||
@ -26,7 +26,7 @@
|
||||
"ext-mbstring": "*",
|
||||
"ext-simplexml": "*",
|
||||
"endroid/qr-code": "^1.9",
|
||||
"topthink/framework": "^6.0",
|
||||
"topthink/framework": "^6.1",
|
||||
"topthink/think-view": "^1.0",
|
||||
"zoujingli/ip2region": "^2.0",
|
||||
"zoujingli/think-library": "6.0.x-dev",
|
||||
|
||||
@ -188,6 +188,13 @@ $(function () {
|
||||
var idx = msg ? layer.msg(msg, {icon: 16, scrollbar: false, shade: this.shade, time: 0, end: call}) : layer.load(2, {time: 0, scrollbar: false, shade: this.shade, end: call});
|
||||
return $.msg.idx.push(idx), idx;
|
||||
};
|
||||
/*! Notify 调用入口 */
|
||||
// https://www.jq22.com/demo/jquerygrowl-notification202104021049
|
||||
this.notify = function (title, msg, time, option) {
|
||||
require(['notify'], function (Notify) {
|
||||
Notify.notify(Object.assign({title: title || '', description: msg || '', position: 'top-right', closeTimeout: time || 3000}, (option || {})));
|
||||
});
|
||||
};
|
||||
/*! 页面加载层 */
|
||||
this.page = new function () {
|
||||
this.$body = $('body>.think-page-loader');
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user