|
|
@@ -38,6 +38,27 @@ use yii\console\Controller;
|
|
|
class TestController extends Controller
|
|
|
{
|
|
|
|
|
|
+ public function actionStaff()
|
|
|
+ {
|
|
|
+ ini_set('memory_limit', '2045M');
|
|
|
+ set_time_limit(0);
|
|
|
+ $shopList = ShopClass::getAllByCondition(['ptStyle' => 2], null, 'id,mainId', null, true);
|
|
|
+ if (!empty($shopList)) {
|
|
|
+ foreach ($shopList as $shop) {
|
|
|
+ $mainId = $shop->mainId;
|
|
|
+ $staffList = StaffClass::getAllByCondition(['mainId' => $mainId], null, 'id,adminId,mobile', null, true);
|
|
|
+ if (!empty($staffList)) {
|
|
|
+ foreach ($staffList as $staff) {
|
|
|
+ echo $staff->id;die;
|
|
|
+ $adminId = $staff->adminId;
|
|
|
+ $mobile = $staff->mobile;
|
|
|
+ AdminClass::updateById($adminId, ['mobile' => $mobile]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
public function actionCustomBuyAmount()
|
|
|
{
|
|
|
ini_set('memory_limit', '2045M');
|