浏览代码

git 选号参数

Cherry 1 年之前
父节点
当前提交
c70a80dd3d

+ 2 - 1
application/admin/controller/MobileFlow.php

@@ -174,7 +174,8 @@ class MobileFlow extends Backend
         'not_send_template' => ['integer'],
         'min_age' => ['number', 'egt:0'],
         'max_age' => ['number', 'egt:0'],
-        'link' => ['url']
+        'link' => ['url'],
+        'product_sku' => ['max:50'],
         //'describe'=>['require'],
     ];
     public function add()

+ 6 - 0
application/admin/view/mobile_flow/add.html

@@ -63,6 +63,12 @@
         </div>
     </div>
     <div class="form-group">
+        <label class="control-label col-xs-12 col-sm-2">{:__('选号产品编码')}:</label>
+        <div class="col-xs-12 col-sm-8">
+            <input class="form-control" name="row[product_sku]" type="text" data-rule="length(~60)">
+        </div>
+    </div>
+    <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('只发货地区')}:</label>
         <div class="col-xs-12 col-sm-8">
             <select title="请选择发货地区模板" name="row[send_template]" class="form-control selectpicker">

+ 6 - 0
application/admin/view/mobile_flow/edit.html

@@ -70,6 +70,12 @@
         </div>
     </div>
     <div class="form-group">
+        <label class="control-label col-xs-12 col-sm-2">{:__('选号产品编码')}:</label>
+        <div class="col-xs-12 col-sm-8">
+            <input class="form-control" name="row[product_sku]" type="text" data-rule="length(~60)" value="{$row.product_sku}">
+        </div>
+    </div>
+    <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('只发货地区')}:</label>
         <div class="col-xs-12 col-sm-8">
             <select title="请选择发货地区模板" name="row[send_template]" class="form-control selectpicker">

+ 2 - 2
application/api/controller/MobileController.php

@@ -1113,10 +1113,10 @@ class MobileController extends UserApi
      */
     public function select_num_flow(){
         $data = $this->_validate([
-            'product_no'=>['require'],
+            'product_sku'=>['require'],
         ]);
 
-        $list = GantanhaoService::getSelectNum($data['product_no']);
+        $list = GantanhaoService::getSelectNum($data['product_sku']);
         $this->success('成功',$list);
     }
 }