Browse Source

清空数据

shish 3 years ago
parent
commit
c7f9ab66d7
1 changed files with 7 additions and 0 deletions
  1. 7 0
      app-ghs/controllers/LabelController.php

+ 7 - 0
app-ghs/controllers/LabelController.php

@@ -9,6 +9,13 @@ use Yii;
 class LabelController extends BaseController
 class LabelController extends BaseController
 {
 {
 
 
+    //清空所有标签 ssh 20230821
+    public function actionClearAll()
+    {
+        $sql = "delete from xhLabel";
+        Yii::$app->db->createCommand($sql)->execute();
+    }
+
     //批量添加电子标 ssh 20230821
     //批量添加电子标 ssh 20230821
     public function actionBatchAddLabel()
     public function actionBatchAddLabel()
     {
     {