shish 6 månader sedan
förälder
incheckning
5a539291a5
1 ändrade filer med 13 tillägg och 0 borttagningar
  1. 13 0
      console/controllers/TestController.php

+ 13 - 0
console/controllers/TestController.php

@@ -32,6 +32,19 @@ use yii\console\Controller;
 class TestController extends Controller
 {
 
+    public function actionShop()
+    {
+        $sql = "select id,shopName,`merchantName` ,ptStyle,mobile from xhShop where ptstyle = 4 and mobile not like '10000%'";
+        $command = Yii::$app->db->createCommand($sql);
+        $data = $command->queryAll();
+        if (empty($data)) {
+            return false;
+        }
+        foreach ($data as $shop) {
+            print_r($shop);
+        }
+    }
+
     public function actionCustom()
     {
         ini_set('memory_limit', '2045M');