hrjy 2 vuotta sitten
vanhempi
commit
534f3b599d

+ 2 - 2
.constant

@@ -1,3 +1,3 @@
 <?php
-define('INSTALL_DATE',1578360044);
-define('SERIALNUMBER','N2L6Px');
+define('INSTALL_DATE',1667978226);
+define('SERIALNUMBER','5XcHfz');

+ 0 - 1
.example.env

@@ -1 +0,0 @@
-APP_DEBUG = true

[APP]
DEFAULT_TIMEZONE = Asia/Shanghai

[DATABASE]
TYPE = mysql
HOSTNAME = 127.0.0.1
DATABASE = test
USERNAME = username
PASSWORD = password
HOSTPORT = 3306
CHARSET = utf8
DEBUG = true

[LANG]
default_lang = zh-cn

+ 6 - 1
app/admin/controller/store/StoreProduct.php

@@ -211,6 +211,7 @@ class StoreProduct extends AuthController
                     'ot_price' => $single['ot_price'] ?? 0,
                     'stock' => $single['stock'] ?? 0,
                     'bar_code' => $single['bar_code'] ?? '',
+                    'bottle' => $single['bottle'] ?? 0,
                     'weight' => $single['weight'] ?? 0,
                     'volume' => $single['volume'] ?? 0,
                     'brokerage' => $single['brokerage'] ?? 0,
@@ -522,7 +523,7 @@ class StoreProduct extends AuthController
 //            sort($item['detail'], SORT_STRING);
             $suk = implode(',', $item['detail']);
             if ($id) {
-                $sukValue = StoreProductAttrValue::where('product_id', $id)->where('type', 0)->where('suk', $suk)->column('bar_code,cost,price,ot_price,integral,stock,image as pic,weight,volume,brokerage,brokerage_two', 'suk');
+                $sukValue = StoreProductAttrValue::where('product_id', $id)->where('type', 0)->where('suk', $suk)->column('bar_code,cost,price,ot_price,integral,stock,image as pic,weight,volume,brokerage,brokerage_two,bottle', 'suk');
                 if (!count($sukValue)) {
                     $sukValue[$suk]['pic'] = '';
                     $sukValue[$suk]['price'] = 0;
@@ -531,6 +532,7 @@ class StoreProduct extends AuthController
                     $sukValue[$suk]['ot_price'] = 0;
                     $sukValue[$suk]['stock'] = 0;
                     $sukValue[$suk]['bar_code'] = '';
+                    $sukValue[$suk]['bottle'] = 0;
                     $sukValue[$suk]['weight'] = 0;
                     $sukValue[$suk]['volume'] = 0;
                     $sukValue[$suk]['brokerage'] = 0;
@@ -544,6 +546,7 @@ class StoreProduct extends AuthController
                 $sukValue[$suk]['ot_price'] = 0;
                 $sukValue[$suk]['stock'] = 0;
                 $sukValue[$suk]['bar_code'] = '';
+                $sukValue[$suk]['bottle'] = 0;
                 $sukValue[$suk]['weight'] = 0;
                 $sukValue[$suk]['volume'] = 0;
                 $sukValue[$suk]['brokerage'] = 0;
@@ -566,6 +569,7 @@ class StoreProduct extends AuthController
             $valueNew[$count]['ot_price'] = isset($sukValue[$suk]['ot_price']) ? floatval($sukValue[$suk]['ot_price']) : 0;
             $valueNew[$count]['stock'] = $sukValue[$suk]['stock'] ? intval($sukValue[$suk]['stock']) : 0;
             $valueNew[$count]['bar_code'] = $sukValue[$suk]['bar_code'] ?? '';
+            $valueNew[$count]['bottle'] = $sukValue[$suk]['bottle'] ?? 0;
             $valueNew[$count]['weight'] = $sukValue[$suk]['weight'] ?? 0;
             $valueNew[$count]['volume'] = $sukValue[$suk]['volume'] ?? 0;
             $valueNew[$count]['brokerage'] = $sukValue[$suk]['brokerage'] ?? 0;
@@ -579,6 +583,7 @@ class StoreProduct extends AuthController
         $header[] = ['title' => '原价', 'slot' => 'ot_price', 'align' => 'center', 'minWidth' => 140];
         $header[] = ['title' => '库存', 'slot' => 'stock', 'align' => 'center', 'minWidth' => 140];
         $header[] = ['title' => '产品编号', 'slot' => 'bar_code', 'align' => 'center', 'minWidth' => 140];
+        $header[] = ['title' => '瓶数', 'slot' => 'bottle', 'align' => 'center', 'minWidth' => 140];
         $header[] = ['title' => '重量(KG)', 'slot' => 'weight', 'align' => 'center', 'minWidth' => 140];
         $header[] = ['title' => '体积(m³)', 'slot' => 'volume', 'align' => 'center', 'minWidth' => 140];
         $header[] = ['title' => '操作', 'slot' => 'action', 'align' => 'center', 'minWidth' => 70];

+ 1 - 0
app/admin/model/store/StoreProductAttr.php

@@ -97,6 +97,7 @@ class StoreProductAttr extends BaseModel
                 'bar_code' => $value['bar_code'] ?? '',
                 'weight' => $value['weight'] ?? 0,
                 'volume' => $value['volume'] ?? 0,
+                'bottle' => $value['bottle'] ?? 0,
                 'brokerage' => $value['brokerage'] ?? 0,
                 'brokerage_two' => $value['brokerage_two'] ?? 0,
                 'type' => $type,

+ 1 - 1
app/admin/view/index/index.php

@@ -5,7 +5,7 @@
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <meta name="renderer" content="webkit">
     <meta http-equiv="Cache-Control" content="no-siteapp" />
-    <title>Liuniu管理系统</title>
+    <title>微喂国际管理系统</title>
     <!--[if lt IE 9]>
     <meta http-equiv="refresh" content="0;ie.html" />
     <![endif]-->

+ 1 - 1
app/admin/view/login/index.php

@@ -17,7 +17,7 @@
     </script>
 </head>
 <body class="gray-bg login-bg">
-<canvas id="canvas" width="900" height="300" style="position: fixed;top: -50px;width: 60%;left: 20%"></canvas>
+<!--<canvas id="canvas" width="900" height="300" style="position: fixed;top: -50px;width: 60%;left: 20%"></canvas>-->
 <div class="middle-box text-center loginscreen  animated fadeInDown">
     <div class="login-group">
         <h3 class="login-logo">

+ 57 - 37
app/admin/view/store/store_product/create.php

@@ -348,6 +348,7 @@
                                                             <th>原价<i class="red">*</i></th>
                                                             <th>库存<i class="red">*</i></th>
                                                             <th>产品编号</th>
+                                                            <th>瓶数</th>
                                                             <th>重量(KG)</th>
                                                             <th>体积(m³)</th>
                                                         </tr>
@@ -378,6 +379,8 @@
                                                                        class="layui-input"></td>
                                                             <td><input type="text" v-model="formData.attr.bar_code"
                                                                        class="layui-input"></td>
+                                                            <td><input type="text" v-model="formData.attr.bottle"
+                                                                       class="layui-input"></td>
                                                             <td><input type="text" v-model="formData.attr.weight"
                                                                        class="layui-input"></td>
                                                             <td><input type="text" v-model="formData.attr.volume"
@@ -494,6 +497,7 @@
                                                                 <th>原价<i class="red">*</i></th>
                                                                 <th>库存<i class="red">*</i></th>
                                                                 <th>产品编号</th>
+                                                                <th>瓶数</th>
                                                                 <th>重量(KG)</th>
                                                                 <th>体积(m³)</th>
                                                                 <th width="15%" style="text-align: center;">操作</th>
@@ -530,6 +534,10 @@
                                                                     <input type="text" v-model="batchAttr.bar_code"
                                                                            class="layui-input">
                                                                 </td>
+                                                                <td>
+                                                                    <input type="text" v-model="batchAttr.bottle"
+                                                                           class="layui-input">
+                                                                </td>
                                                                 <td>
                                                                     <input type="text" v-model="batchAttr.weight"
                                                                            class="layui-input">
@@ -597,6 +605,8 @@
                                                                     <input type="text" v-model="item.bar_code"
                                                                            class="layui-input">
                                                                 </td>
+                                                                <td><input type="text" v-model="item.bottle"
+                                                                           class="layui-input"></td>
                                                                 <td>
                                                                     <input type="number" v-model="item.weight"
                                                                            class="layui-input">
@@ -697,21 +707,21 @@
                                             </div>
                                         </div>
                                     </div>
-                                    <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">
-                                        <div class="grid-demo grid-demo-bg1">
-                                            <div class="layui-form-item">
-                                                <label class="layui-form-label">佣金设置</label>
-                                                <div class="layui-input-block">
-                                                    <input type="radio" name="is_sub" lay-filter="is_sub" value="1"
-                                                           title="单独设置"
-                                                           :checked="formData.is_sub == 1 ? true : false">
-                                                    <input type="radio" name="is_sub" lay-filter="is_sub" value="0"
-                                                           title="默认设置"
-                                                           :checked="formData.is_sub == 0 ? true : false">
-                                                </div>
-                                            </div>
-                                        </div>
-                                    </div>
+<!--                                    <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">-->
+<!--                                        <div class="grid-demo grid-demo-bg1">-->
+<!--                                            <div class="layui-form-item">-->
+<!--                                                <label class="layui-form-label">佣金设置</label>-->
+<!--                                                <div class="layui-input-block">-->
+<!--                                                    <input type="radio" name="is_sub" lay-filter="is_sub" value="1"-->
+<!--                                                           title="单独设置"-->
+<!--                                                           :checked="formData.is_sub == 1 ? true : false">-->
+<!--                                                    <input type="radio" name="is_sub" lay-filter="is_sub" value="0"-->
+<!--                                                           title="默认设置"-->
+<!--                                                           :checked="formData.is_sub == 0 ? true : false">-->
+<!--                                                </div>-->
+<!--                                            </div>-->
+<!--                                        </div>-->
+<!--                                    </div>-->
                                     <div class="layui-col-xs12 layui-col-sm12 layui-col-md12"
                                          v-if="formData.is_sub == 1 && formData.spec_type == 1">
                                         <div class="grid-demo grid-demo-bg1">
@@ -751,6 +761,7 @@
                                                             <th>原价</th>
                                                             <th>库存</th>
                                                             <th>产品编号</th>
+                                                            <th>瓶数</th>
                                                             <th>重量</th>
                                                             <th>体积</th>
                                                             <th>一级返佣</th>
@@ -771,6 +782,7 @@
                                                             <td>{{formData.attr.ot_price}}</td>
                                                             <td>{{formData.attr.stock}}</td>
                                                             <td>{{formData.attr.bar_code}}</td>
+                                                            <td>{{formData.attr.bottle}}</td>
                                                             <td>{{formData.attr.weight}}</td>
                                                             <td>{{formData.attr.volume}}</td>
                                                             <td><input type="text" v-model="formData.attr.brokerage"
@@ -814,6 +826,7 @@
                                                             <td>{{item.ot_price}}</td>
                                                             <td>{{item.stock}}</td>
                                                             <td>{{item.bar_code}}</td>
+                                                            <td>{{item.bottle}}</td>
                                                             <td>{{item.weight}}</td>
                                                             <td>{{item.volume}}</td>
                                                             <td>
@@ -920,28 +933,28 @@
                                             </div>
                                         </div>
                                     </div>
-                                    <div class="layui-row layui-col-space15">
-                                        <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">
-                                            <div class="grid-demo grid-demo-bg1">
-                                                <div class="layui-form-item">
-                                                    <label class="layui-form-label">活动优先级</label>
-                                                    <div class="layui-input-block">
-                                                        <span class="layui-btn layui-btn-sm layui-btn-normal"
-                                                              :style="'background-color:'+activity[item]"
-                                                              v-for="(item,index) in formData.activity" :key="index"
-                                                              draggable="true"
-                                                              @dragstart="handleDragStart($event, item)"
-                                                              @dragover.prevent="handleDragOver($event, item)"
-                                                              @dragenter="handleDragEnter($event, item)"
-                                                              @dragend="handleDragEnd($event, item)">
-                                                        {{item}}
-                                                    </span>
-                                                        <span class="info">可拖动按钮调整活动的优先展示顺序</span>
-                                                    </div>
-                                                </div>
-                                            </div>
-                                        </div>
-                                    </div>
+<!--                                    <div class="layui-row layui-col-space15">-->
+<!--                                        <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">-->
+<!--                                            <div class="grid-demo grid-demo-bg1">-->
+<!--                                                <div class="layui-form-item">-->
+<!--                                                    <label class="layui-form-label">活动优先级</label>-->
+<!--                                                    <div class="layui-input-block">-->
+<!--                                                        <span class="layui-btn layui-btn-sm layui-btn-normal"-->
+<!--                                                              :style="'background-color:'+activity[item]"-->
+<!--                                                              v-for="(item,index) in formData.activity" :key="index"-->
+<!--                                                              draggable="true"-->
+<!--                                                              @dragstart="handleDragStart($event, item)"-->
+<!--                                                              @dragover.prevent="handleDragOver($event, item)"-->
+<!--                                                              @dragenter="handleDragEnter($event, item)"-->
+<!--                                                              @dragend="handleDragEnd($event, item)">-->
+<!--                                                        {{item}}-->
+<!--                                                    </span>-->
+<!--                                                        <span class="info">可拖动按钮调整活动的优先展示顺序</span>-->
+<!--                                                    </div>-->
+<!--                                                </div>-->
+<!--                                            </div>-->
+<!--                                        </div>-->
+<!--                                    </div>-->
                                 </div>
                             </div>
                         </div>
@@ -1020,6 +1033,7 @@
                     volume: 0,
                     brokerage: 0,
                     brokerage_two: 0,
+                    bottle: 0,
                 },
                 attrs: [],
                 description: '',
@@ -1054,6 +1068,7 @@
                 ot_price: 0,
                 stock: 0,
                 bar_code: '',
+                bottle: 0,
                 weight: 0,
                 volume: 0,
             },
@@ -1166,6 +1181,7 @@
                     ot_price: 0,
                     stock: 0,
                     bar_code: '',
+                    bottle: 0,
                     weight: 0,
                     volume: 0,
                 });
@@ -1197,6 +1213,9 @@
                     if (that.batchAttr.bar_code != '') {
                         item.bar_code = that.batchAttr.bar_code;
                     }
+                    if (that.batchAttr.bottle > 0) {
+                        item.bottle = that.batchAttr.bottle;
+                    }
                     if (that.batchAttr.weight > 0) {
                         item.weight = that.batchAttr.weight;
                     }
@@ -1610,6 +1629,7 @@
                         weight: that.formData.attr.weight,
                         brokerage: that.formData.attr.brokerage,
                         brokerage_two: that.formData.attr.brokerage_two,
+                        bottle: that.formData.attr.bottle,
                     };
                     that.formData.attrs = [attr];
                 } else {

+ 2 - 0
app/wap/.gitignore

@@ -0,0 +1,2 @@
+*
+!.gitignore

+ 0 - 8
public/.htaccess

@@ -1,8 +0,0 @@
-<IfModule mod_rewrite.c>
-  Options +FollowSymlinks -Multiviews
-  RewriteEngine On
-
-  RewriteCond %{REQUEST_FILENAME} !-d
-  RewriteCond %{REQUEST_FILENAME} !-f
-  RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
-</IfModule>

+ 5 - 6
public/nginx.htaccess

@@ -1,6 +1,5 @@
-location / { 
-   if (!-e $request_filename) {
-   rewrite  ^(.*)$  /index.php?s=/$1  last;
-   break;
-    }
- }
+location / {
+        if (!-e $request_filename){
+                rewrite  ^(.*)$  /index.php?s=$1  last;   break;
+        }
+}