Bläddra i källkod

充值模板的改版

liuzejian 1 år sedan
förälder
incheckning
f402a38ed7
1 ändrade filer med 5 tillägg och 1 borttagningar
  1. 5 1
      modules/Channel/Http/Controllers/PayTemplateController.php

+ 5 - 1
modules/Channel/Http/Controllers/PayTemplateController.php

@@ -44,8 +44,11 @@ class PayTemplateController extends CatchController
             $this->initPayTemplate($uid);
         }
         $name = $request->get('name');
+        // 1-首充模板,2-非首充模板
+        $type = $request->input('type');
         $where = [[
-            'uid','=',$uid
+            'uid','=',$uid,
+            'type', '=', $type,
         ]];
         if($name){
             $where[] = ['name','like','%'.$name.'%'];
@@ -106,6 +109,7 @@ class PayTemplateController extends CatchController
         $this->validate($request, [
             'name' => 'required',
             'options' => 'required',
+            'status' => 'required|in:0,1',
             'type' => 'required|in:1,2'
         ]);
         $uid = $this->getLoginUser()->id;