-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2,111 changed files
with
15,296 additions
and
9,601 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1,610 changes: 1,601 additions & 9 deletions
1,610
crmeb/app/adminapi/controller/UpgradeController.php
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,7 +57,13 @@ public function getRefundList() | |
/** | ||
* 订单详情 | ||
* @param $uni | ||
* @return mixed | ||
* @return \think\Response | ||
* @throws \think\db\exception\DataNotFoundException | ||
* @throws \think\db\exception\DbException | ||
* @throws \think\db\exception\ModelNotFoundException | ||
* @author 吴汐 | ||
* @email [email protected] | ||
* @date 2023/03/02 | ||
*/ | ||
public function getRefundInfo($uni) | ||
{ | ||
|
@@ -163,12 +169,12 @@ public function refundPrice(Request $request, StoreOrderServices $services, $id) | |
return app('json')->fail(400147); | ||
} | ||
$refund_price = $data['refund_price']; | ||
} | ||
|
||
$data['refunded_price'] = bcadd($data['refund_price'], $orderRefund['refunded_price'], 2); | ||
$bj = bccomp((string)$orderRefund['refund_price'], (string)$data['refunded_price'], 2); | ||
if ($bj < 0) { | ||
return app('json')->fail(400148); | ||
} | ||
$data['refunded_price'] = bcadd($data['refund_price'], $orderRefund['refunded_price'], 2); | ||
$bj = bccomp((string)$orderRefund['refund_price'], (string)$data['refunded_price'], 2); | ||
if ($bj < 0) { | ||
return app('json')->fail(400148); | ||
} | ||
|
||
unset($data['type']); | ||
|
@@ -184,7 +190,7 @@ public function refundPrice(Request $request, StoreOrderServices $services, $id) | |
$refund_data['open_id'] = $wechatUserServices->uidToOpenid((int)$order['uid'], 'routine') ?? ''; | ||
$refund_data['refund_no'] = $orderRefund['order_id']; | ||
//修改订单退款状态 | ||
unset($data['refund_price']); | ||
$data['refund_price'] = $data['refunded_price']; | ||
if ($this->services->agreeRefund($id, $refund_data)) { | ||
$this->services->update($id, $data); | ||
return app('json')->success(400149); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
<?php | ||
|
||
namespace app\adminapi\controller\v1\system; | ||
|
||
use app\adminapi\controller\AuthController; | ||
use app\services\system\crontab\SystemCrontabServices; | ||
use think\facade\App; | ||
|
||
class SystemCrontab extends AuthController | ||
{ | ||
public function __construct(App $app, SystemCrontabServices $services) | ||
{ | ||
parent::__construct($app); | ||
$this->services = $services; | ||
} | ||
|
||
/** | ||
* 获取定时任务列表 | ||
* @return mixed | ||
*/ | ||
public function getTimerList() | ||
{ | ||
$where = ['is_del' => 0]; | ||
return app('json')->success($this->services->getTimerList($where)); | ||
} | ||
|
||
/** | ||
* 获取定时任务详情 | ||
* @param $id | ||
* @return mixed | ||
*/ | ||
public function getTimerInfo($id) | ||
{ | ||
return app('json')->success($this->services->getTimerInfo($id)); | ||
} | ||
|
||
/** | ||
* 获取定时任务类型 | ||
* @return mixed | ||
*/ | ||
public function getMarkList() | ||
{ | ||
return app('json')->success($this->services->getMarkList()); | ||
} | ||
|
||
/** | ||
* 保存定时任务 | ||
* @return mixed | ||
*/ | ||
public function saveTimer() | ||
{ | ||
$data = $this->request->postMore([ | ||
['id', 0], | ||
['name', ''], | ||
['mark', ''], | ||
['content', ''], | ||
['type', 0], | ||
['is_open', 0], | ||
['week', 0], | ||
['day', 0], | ||
['hour', 0], | ||
['minute', 0], | ||
['second', 0], | ||
]); | ||
$this->services->saveTimer($data); | ||
return app('json')->success(100000); | ||
} | ||
|
||
/** | ||
* 删除定时任务 | ||
* @param $id | ||
* @return mixed | ||
*/ | ||
public function delTimer($id) | ||
{ | ||
$this->services->delTimer($id); | ||
return app('json')->success(100002); | ||
} | ||
|
||
/** | ||
* 设置定时任务状态 | ||
* @param $id | ||
* @param $is_open | ||
* @return mixed | ||
*/ | ||
public function setTimerStatus($id, $is_open) | ||
{ | ||
$this->services->setTimerStatus($id, $is_open); | ||
return app('json')->success(100014); | ||
} | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.