Kirin 3 år sedan
förälder
incheckning
d36bbf1df0

+ 1 - 0
app/admin/controller/system/SystemStore.php

@@ -137,6 +137,7 @@ class SystemStore extends AuthController
             ['latlng', ''],
             ['valid_time', []],
             ['day_time', []],
+            ['radius', 0],
             ['leader', ''],
             ['pictures', []],
             ['recharge_award_ratio', 0],

+ 14 - 0
app/admin/view/system/system_store/add.php

@@ -122,6 +122,18 @@
                                     </i-Col>
                                 </Row>
                             </Form-Item>
+                            <Form-Item>
+                                <Row>
+                                    <i-Col span="4">
+                                        <span style="float: left">配送半径</span>
+
+                                    </i-Col>
+                                    <i-Col span="20">
+                                        <i-Input placeholder="配送半径(单位:米)" v-model="form.radius" style="width: 80%"
+                                                 type="number" step="0.01"></i-Input>
+                                    </i-Col>
+                                </Row>
+                            </Form-Item>
                             <Form-Item>
                                 <Row>
                                     <i-Col span="13">
@@ -177,6 +189,7 @@
                         latlng:storeData.latlng || '',
                         valid_time:storeData.valid_time || [],
                         day_time:storeData.day_time || [],
+                        radius: storeData.radius || '',
                         recharge_award_ratio:storeData.recharge_award_ratio || 0,
                     },
                     visible:false,
@@ -236,6 +249,7 @@
                     if(!that.form.valid_time) return  $eb.message('error','请选择核销时效');
                     if(!that.form.day_time) return  $eb.message('error','请选择门店营业时间');
                     if(!that.form.latlng) return  $eb.message('error','请选择门店经纬度!');
+                    if (!that.form.radius) return $eb.message('error', '请输入门店配送半径!');
                     var index = layer.load(1, {
                         shade: [0.5,'#fff']
                     });

+ 2 - 0
app/api/controller/user/UserController.php

@@ -246,6 +246,8 @@ class UserController
             ['post_code', ''],
             ['phone', ''],
             ['detail', ''],
+            ['longitude', 0],
+            ['latitude', 0],
             ['id', 0],
             ['type', 0]
         ], $request);