|
|
@@ -24,11 +24,37 @@ use yii\console\Controller;
|
|
|
class TestController extends Controller
|
|
|
{
|
|
|
|
|
|
+ //更新时间
|
|
|
+ public function actionExpendTime()
|
|
|
+ {
|
|
|
+ $list = \bizGhs\order\classes\OrderClass::getAllByCondition(['payTime>' => '2024-04-01 23:35:00'], null, '*', 'payTime asc', true);
|
|
|
+ if (!empty($list)) {
|
|
|
+ foreach ($list as $info) {
|
|
|
+ $customId = $info->customId ?? 0;
|
|
|
+ $ghsId = $info->ghsId ?? 0;
|
|
|
+ $custom = \bizGhs\custom\classes\CustomClass::getById($customId, true);
|
|
|
+ $payTime = $info->payTime;
|
|
|
+ $orderSn = $info->orderSn ?? '';
|
|
|
+ if (!empty($custom)) {
|
|
|
+ $custom->recentExpend = $payTime;
|
|
|
+ $custom->save();
|
|
|
+ echo $orderSn . ' ' . $payTime . " custom {$custom->id} ok \n";
|
|
|
+ }
|
|
|
+ $ghs = \bizGhs\ghs\classes\GhsClass::getById($ghsId, true);
|
|
|
+ if (!empty($ghs)) {
|
|
|
+ $ghs->recentExpend = $payTime;
|
|
|
+ $ghs->save();
|
|
|
+ echo $orderSn . ' ' . $payTime . " ghs {$ghs->id} ok \n";
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
public function actionBelong()
|
|
|
{
|
|
|
ini_set('memory_limit', '2045M');
|
|
|
set_time_limit(0);
|
|
|
- $shopList = ShopClass::getAllByCondition(['id' => ['in', [23580, 11094, 520, 1489,8596,4608,7855,21486,1585,10649,10768,8249,447,763,1421]]], null, '*', null, true);
|
|
|
+ $shopList = ShopClass::getAllByCondition(['id' => ['in', [23580, 11094, 520, 1489, 8596, 4608, 7855, 21486, 1585, 10649, 10768, 8249, 447, 763, 1421]]], null, '*', null, true);
|
|
|
if (!empty($shopList)) {
|
|
|
foreach ($shopList as $shop) {
|
|
|
$mainId = $shop->mainId ?? 0;
|