zhanglinxin 1 سال پیش
والد
کامیت
2470dc50f8
84فایلهای تغییر یافته به همراه254 افزوده شده و 5523 حذف شده
  1. 104 3
      application/api/controller/Common.php
  2. 24 5
      application/api/view/common/index_1.html
  3. 4 1
      application/api/view/common/index_10.html
  4. 4 1
      application/api/view/common/index_11.html
  5. 4 1
      application/api/view/common/index_2.html
  6. 25 5
      application/api/view/common/index_3.html
  7. 25 5
      application/api/view/common/index_4.html
  8. 4 1
      application/api/view/common/index_5.html
  9. 4 1
      application/api/view/common/index_6.html
  10. 4 1
      application/api/view/common/index_7.html
  11. 4 1
      application/api/view/common/index_8.html
  12. 4 1
      application/api/view/common/index_9.html
  13. 20 1
      application/approve/controller/Goods.php
  14. 6 6
      application/approve/view/approve_info/form_3.html
  15. 12 12
      application/approve/view/approve_info_log/form_3.html
  16. 0 122
      application/car/controller/CarFlow.php
  17. 0 142
      application/car/controller/CarInfo.php
  18. 0 47
      application/car/view/car_flow/form.html
  19. 0 64
      application/car/view/car_flow/index.html
  20. 0 30
      application/car/view/car_flow/index_search.html
  21. 0 39
      application/car/view/car_info/approve.html
  22. 0 55
      application/car/view/car_info/form.html
  23. 0 88
      application/car/view/car_info/index.html
  24. 0 41
      application/car/view/car_info/index_search.html
  25. 1 2
      application/common/service/ApproveInfoService.php
  26. 0 122
      application/leave/controller/Flow.php
  27. 0 149
      application/leave/controller/LeaveInfo.php
  28. 0 136
      application/leave/controller/LeaveType.php
  29. 0 47
      application/leave/view/flow/form.html
  30. 0 64
      application/leave/view/flow/index.html
  31. 0 30
      application/leave/view/flow/index_search.html
  32. 0 39
      application/leave/view/leave_info/approve.html
  33. 0 58
      application/leave/view/leave_info/form.html
  34. 0 82
      application/leave/view/leave_info/index.html
  35. 0 59
      application/leave/view/leave_info/index_search.html
  36. 0 31
      application/leave/view/leave_type/form.html
  37. 0 63
      application/leave/view/leave_type/index.html
  38. 0 69
      application/leave/view/leave_type/index_search.html
  39. 0 138
      application/mall/controller/GoodsCate.php
  40. 0 144
      application/mall/controller/GoodsTwoCate.php
  41. 0 291
      application/mall/controller/StoreGoods.php
  42. 0 31
      application/mall/view/goods_cate/form.html
  43. 0 69
      application/mall/view/goods_cate/index.html
  44. 0 16
      application/mall/view/goods_cate/index_search.html
  45. 0 31
      application/mall/view/goods_two_cate/form.html
  46. 0 69
      application/mall/view/goods_two_cate/index.html
  47. 0 16
      application/mall/view/goods_two_cate/index_search.html
  48. 0 422
      application/mall/view/store_goods/form.html
  49. 0 87
      application/mall/view/store_goods/form_style.html
  50. 0 104
      application/mall/view/store_goods/index.html
  51. 0 18
      application/mall/view/store_goods/index_search.html
  52. 0 76
      application/mall/view/store_goods/param.html
  53. 0 64
      application/mall/view/store_goods/stock.html
  54. 0 136
      application/synth/controller/ContractType.php
  55. 0 144
      application/synth/controller/Document.php
  56. 0 148
      application/synth/controller/Evection.php
  57. 0 126
      application/synth/controller/Flow.php
  58. 0 144
      application/synth/controller/Maintain.php
  59. 0 149
      application/synth/controller/Offer.php
  60. 0 136
      application/synth/controller/OfferType.php
  61. 0 31
      application/synth/view/contract_type/form.html
  62. 0 63
      application/synth/view/contract_type/index.html
  63. 0 39
      application/synth/view/document/approve.html
  64. 0 66
      application/synth/view/document/form.html
  65. 0 83
      application/synth/view/document/index.html
  66. 0 44
      application/synth/view/document/index_search.html
  67. 0 39
      application/synth/view/evection/approve.html
  68. 0 100
      application/synth/view/evection/form.html
  69. 0 85
      application/synth/view/evection/index.html
  70. 0 59
      application/synth/view/evection/index_search.html
  71. 0 48
      application/synth/view/flow/form.html
  72. 0 64
      application/synth/view/flow/index.html
  73. 0 30
      application/synth/view/flow/index_search.html
  74. 0 39
      application/synth/view/maintain/approve.html
  75. 0 66
      application/synth/view/maintain/form.html
  76. 0 81
      application/synth/view/maintain/index.html
  77. 0 44
      application/synth/view/maintain/index_search.html
  78. 0 39
      application/synth/view/offer/approve.html
  79. 0 78
      application/synth/view/offer/form.html
  80. 0 81
      application/synth/view/offer/index.html
  81. 0 59
      application/synth/view/offer/index_search.html
  82. 0 31
      application/synth/view/offer_type/form.html
  83. 0 63
      application/synth/view/offer_type/index.html
  84. 5 8
      public/1.html

+ 104 - 3
application/api/controller/Common.php

@@ -2,6 +2,7 @@
 
 namespace app\api\controller;
 
+use AliPay\App;
 use app\common\constant\CommonConstant;
 use app\common\constant\MaintainConstant;
 use app\common\model\Goods;
@@ -17,6 +18,7 @@ use PhpOffice\PhpSpreadsheet\Reader\Xlsx;
 use think\db\exception\BindParamException;
 use think\Exception;
 use think\exception\PDOException;
+use think\Db;
 
 /**
  * @Apidoc\Title("公用")
@@ -346,7 +348,100 @@ class Common extends Base
     }
 
     /**
-     * 重置合同编号(定时任务 每年1月1日0点1分执行一次)
+     * 导入1
+     */
+    public function import1()
+    {
+        $file = $this->request->post('file');
+        if (!$file) {
+            $this->error('请选择文件');
+        }
+        $filePath = $_SERVER['DOCUMENT_ROOT'] . '/' . $file;
+        if (!is_file($filePath)) {
+            $this->error('文件未找到');
+        }
+        //实例化reader
+        $ext = pathinfo($filePath, PATHINFO_EXTENSION);
+        if (!in_array($ext, ['csv', 'xls', 'xlsx'])) {
+            $this->error('未知的数据格式');
+        }
+        if ($ext === 'csv') {
+            $file = fopen($filePath, 'r');
+            $filePath = tempnam(sys_get_temp_dir(), 'import_csv');
+            $fp = fopen($filePath, 'w');
+            $n = 0;
+            while ($line = fgets($file)) {
+                $line = rtrim($line, "\n\r\0");
+                $encoding = mb_detect_encoding($line, ['utf-8', 'gbk', 'latin1', 'big5']);
+                if ($encoding !== 'utf-8') {
+                    $line = mb_convert_encoding($line, 'utf-8', $encoding);
+                }
+                if ($n == 0 || preg_match('/^".*"$/', $line)) {
+                    fwrite($fp, $line . "\n");
+                } else {
+                    fwrite($fp, '"' . str_replace(['"', ','], ['""', '","'], $line) . "\"\n");
+                }
+                $n++;
+            }
+            fclose($file) || fclose($fp);
+
+            $reader = new Csv();
+        } elseif ($ext === 'xls') {
+            $reader = new Xls();
+        } else {
+            $reader = new Xlsx();
+        }
+
+        //加载文件
+        $insert = [];
+        try {
+            if (!$PHPExcel = $reader->load($filePath)) {
+                $this->error('未知的数据格式!');
+            }
+            $currentSheet = $PHPExcel->getSheet(0);  //读取文件中的第一个工作表
+            $allColumn = $currentSheet->getHighestDataColumn(); //取得最大的列号
+            $allRow = $currentSheet->getHighestRow(); //取得一共有多少行
+            $maxColumnNumber = Coordinate::columnIndexFromString($allColumn);
+
+            for ($currentRow = 2; $currentRow <= $allRow; $currentRow++) {
+                $values = [];
+                for ($currentColumn = 1; $currentColumn <= $maxColumnNumber; $currentColumn++) {
+                    $val = $currentSheet->getCellByColumnAndRow($currentColumn, $currentRow)->getValue();
+                    $values[] = is_null($val) ? '' : trim($val); // 消除空格
+                }
+                $values = array_filter($values); // 过滤空值
+
+                $first[$values[0]] = $values[0];
+                $second[$values[0]][$values[1]] = $values[1];
+                $third[$values[1]][$values[2]] = $values[2];
+            }
+        } catch (Exception $exception) {
+            $this->error('出现错误:' . $exception->getMessage());
+        }
+//        p($first);
+//        p($second);
+//        p($third);
+//        exit;
+        foreach ($first as $key=>$val){
+            if(array_key_exists($val,$second)){
+                $first1 = Db::table('dd_category_job')->insertGetId(['name'=>$val]);
+                $second_list = $second[$val];
+                foreach ($second_list as $v){
+                    if(array_key_exists($v,$third)){
+                        $second1 = Db::table('dd_category_job')->insertGetId(['pid'=>$first1,'name'=>$v]);
+                        $third_list = $third[$v];
+                        foreach ($third_list as $vv){
+                            Db::table('dd_category_job')->insertGetId(['pid'=>$second1,'name'=>$vv]);
+                        }
+                    }
+                }
+            }
+        }
+        $this->success('导入成功');
+    }
+
+    /**
+     * 重置合同编号(定时任务 每年1月1日0点1分执行)
      *
      * @Apidoc\Method("POST")
      **/
@@ -364,8 +459,14 @@ class Common extends Base
     public function test()
     {
         $id = input('id') ?: 0;
-        $data = ApproveInfoService::download($id);
-        $this->success('测试',$data);
+        $data = '';
+        $name = '';
+        $html = ApproveInfoService::get_html($data);
+        $realpath = ApproveInfoService::getPath($name);
+        $pdf = new \TCPDF();
+        $pdf = ApproveInfoService::setPdfAttr($pdf);
+        ApproveInfoService::exportPdf($pdf, $html, $realpath);
+        $this->success('success',['url' => $realpath, 'fullurl' => 'https://' . $_SERVER['HTTP_HOST'] . $realpath]);
     }
 
 }

+ 24 - 5
application/api/view/common/index_1.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;
@@ -81,11 +84,27 @@
         <td class="content">支付方式</td>
         <td class="content">{$get_pay_type_list[$vo.module_info.pay_type]|default='--'}</td>
     </tr>
-    {notempty name='vo.data'}
+</table>
+{notempty name='vo.data'}
+<table cellpadding="8">
     <tr>
-        <td class="content">申购明细</td>
-        <td class="content"></td>
+        <td class="content with-30"></td>
+        <td class="content with-20">商品名称</td>
+        <td class="content with-20">总金额(元)</td>
+        <td class="content with-30">商品规格、单价、数量</td>
     </tr>
-    {/notempty}
+    {foreach $vo.data as $k=>$v}
+    <tr>
+        {if ($k eq 0)}<td class="content with-30" rowspan="{:count($vo.data)}">申购明细</td>{/if}
+        <td class="content with-20">{$v.goods_name}</td>
+        <td class="content with-20">{$v.total_price}</td>
+        <td class="content with-30">
+            {notempty name='v.goods_stock_text'}
+            {foreach name="v.goods_stock_text" item="vv"}规格:{$vv.name|default='--'} 单价:{$vv.price|default='--'} 数量:{$vv.stock|default='--'}<br/>{/foreach}
+            {/notempty}
+        </td>
+    </tr>
+    {/foreach}
 </table>
+{/notempty}
 {include file='common/index_approve'}

+ 4 - 1
application/api/view/common/index_10.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_11.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_2.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 25 - 5
application/api/view/common/index_3.html

@@ -14,8 +14,14 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
+    .with-50{
+        width:50%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;
@@ -68,11 +74,25 @@
         <td class="content">其它补充说明</td>
         <td class="content">{$vo.module_info.remark|default='--'}</td>
     </tr>
-    {notempty name='vo.data'}
+</table>
+{notempty name='vo.data'}
+<table cellpadding="8">
+    <tr>
+        <td class="content with-30"></td>
+        <td class="content with-20">商品名称</td>
+        <td class="content with-50">商品规格、数量</td>
+    </tr>
+    {foreach $vo.data as $k=>$v}
     <tr>
-        <td class="content">入库明细</td>
-        <td class="content"></td>
+        {if ($k eq 0)}<td class="content with-30" rowspan="{:count($vo.data)}">入库明细</td>{/if}
+        <td class="content with-20">{$v.goods_name}</td>
+        <td class="content with-50">
+            {notempty name='v.goods_stock_text'}
+            {foreach name="v.goods_stock_text" item="vv"}规格:{$vv.name|default='--'} 数量:{$vv.stock|default='--'}<br/>{/foreach}
+            {/notempty}
+        </td>
     </tr>
-    {/notempty}
+    {/foreach}
 </table>
+{/notempty}
 {include file='common/index_approve'}

+ 25 - 5
application/api/view/common/index_4.html

@@ -14,8 +14,14 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
+    .with-50{
+        width:50%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;
@@ -61,11 +67,25 @@
         <td class="content">其它补充说明</td>
         <td class="content">{$vo.module_info.remark|default='--'}</td>
     </tr>
-    {notempty name='vo.data'}
+</table>
+{notempty name='vo.data'}
+<table cellpadding="8">
+    <tr>
+        <td class="content with-30"></td>
+        <td class="content with-20">商品名称</td>
+        <td class="content with-50">商品规格、数量</td>
+    </tr>
+    {foreach $vo.data as $k=>$v}
     <tr>
-        <td class="content">领用明细</td>
-        <td class="content"></td>
+        {if ($k eq 0)}<td class="content with-30" rowspan="{:count($vo.data)}">领用明细</td>{/if}
+        <td class="content with-20">{$v.goods_name}</td>
+        <td class="content with-50">
+            {notempty name='v.goods_stock_text'}
+            {foreach name="v.goods_stock_text" item="vv"}规格:{$vv.name|default='--'} 数量:{$vv.stock|default='--'}<br/>{/foreach}
+            {/notempty}
+        </td>
     </tr>
-    {/notempty}
+    {/foreach}
 </table>
+{/notempty}
 {include file='common/index_approve'}

+ 4 - 1
application/api/view/common/index_5.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_6.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_7.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_8.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 4 - 1
application/api/view/common/index_9.html

@@ -14,8 +14,11 @@
     .with-30{
         width:30%;
     }
+    .with-20{
+        width:20%;
+    }
     .with-70{
-        width:60%;
+        width:70%;
     }
     .align-center {
         text-align: center;

+ 20 - 1
application/approve/controller/Goods.php

@@ -16,6 +16,9 @@
 namespace app\approve\controller;
 
 use app\common\constant\CommonConstant;
+use app\common\model\ApproveApplyGoods;
+use app\common\model\ApproveStockGoods;
+use app\common\model\ApproveUseGoods;
 use app\common\model\Goods as model;
 use app\common\model\GoodsStock;
 use app\common\service\GoodsCategoryService;
@@ -262,7 +265,23 @@ class Goods extends Controller
     public function remove()
     {
         $this->applyCsrfToken();
-        // TODO 删除商品,检验申请数据
+        // 删除商品时,检验申请数据
+        $id = input('id') ?: 0;
+        $apply = ApproveApplyGoods::where('goods_id',$id)->column('info_id');
+        $stock = ApproveStockGoods::where('goods_id',$id)->column('info_id');
+        $use = ApproveUseGoods::where('goods_id',$id)->column('info_id');
+        $data = array_merge($apply,$stock);
+        $info_id = array_merge($data,$use);
+        if($info_id){
+            $approve = \app\common\model\ApproveInfo::field('id')
+                ->where('id','in',$info_id)
+                ->where('status',CommonConstant::STATUS_2)
+                ->where('is_deleted',CommonConstant::IS_DELETED_0)
+                ->find();
+            if($approve){
+                $this->error('存在有审批中的申请单,不能删除');
+            }
+        }
         $this->_delete($this->table);
     }
 

+ 6 - 6
application/approve/view/approve_info/form_3.html

@@ -112,24 +112,24 @@
                                 <td>商品品牌</td>
                                 <td>{$v.goods_brand|default='--'}</td>
                             </tr>
-                            <tr>
-                                <td>总金额</td>
-                                <td>{$v.total_price|default='--'}</td>
-                            </tr>
+<!--                            <tr>-->
+<!--                                <td>总金额</td>-->
+<!--                                <td>{$v.total_price|default='&#45;&#45;'}</td>-->
+<!--                            </tr>-->
                             <tr>
                                 <td>商品规格</td>
                                 <td>
                                     <table class="layui-table">
                                         <tr>
                                             <td>规格名称</td>
-                                            <td>单价</td>
+<!--                                            <td>单价</td>-->
                                             <td>数量</td>
                                         </tr>
                                         {notempty name='v.goods_stock_text'}
                                         {foreach name="v.goods_stock_text" item="vv"}
                                         <tr>
                                             <td>{$vv.name|default='--'}</td>
-                                            <td>{$vv.price|default='--'}</td>
+<!--                                            <td>{$vv.price|default='&#45;&#45;'}</td>-->
                                             <td>{$vv.stock|default='--'}</td>
                                         </tr>
                                         {/foreach}

+ 12 - 12
application/approve/view/approve_info_log/form_3.html

@@ -64,24 +64,24 @@
                                             <td>商品品牌</td>
                                             <td>{$v.goods_brand|default='--'}</td>
                                         </tr>
-                                        <tr>
-                                            <td>总金额</td>
-                                            <td>{$v.total_price|default='--'}</td>
-                                        </tr>
+<!--                                        <tr>-->
+<!--                                            <td>总金额</td>-->
+<!--                                            <td>{$v.total_price|default='&#45;&#45;'}</td>-->
+<!--                                        </tr>-->
                                         <tr>
                                             <td>商品规格</td>
                                             <td>
                                                 <table class="layui-table">
                                                     <tr>
                                                         <td>规格名称</td>
-                                                        <td>单价</td>
+<!--                                                        <td>单价</td>-->
                                                         <td>数量</td>
                                                     </tr>
                                                     {notempty name='v.goods_stock_text'}
                                                     {foreach name="v.goods_stock_text" item="vv"}
                                                     <tr>
                                                         <td>{$vv.name|default='--'}</td>
-                                                        <td>{$vv.price|default='--'}</td>
+<!--                                                        <td>{$vv.price|default='&#45;&#45;'}</td>-->
                                                         <td>{$vv.stock|default='--'}</td>
                                                     </tr>
                                                     {/foreach}
@@ -171,24 +171,24 @@
                                             <td>商品品牌</td>
                                             <td>{$v.goods_brand|default='--'}</td>
                                         </tr>
-                                        <tr>
-                                            <td>总金额</td>
-                                            <td>{$v.total_price|default='--'}</td>
-                                        </tr>
+<!--                                        <tr>-->
+<!--                                            <td>总金额</td>-->
+<!--                                            <td>{$v.total_price|default='&#45;&#45;'}</td>-->
+<!--                                        </tr>-->
                                         <tr>
                                             <td>商品规格</td>
                                             <td>
                                                 <table class="layui-table">
                                                     <tr>
                                                         <td>规格名称</td>
-                                                        <td>单价</td>
+<!--                                                        <td>单价</td>-->
                                                         <td>数量</td>
                                                     </tr>
                                                     {notempty name='v.goods_stock'}
                                                     {foreach name="v.goods_stock" item="vv"}
                                                     <tr>
                                                         <td>{$vv.name|default='--'}</td>
-                                                        <td>{$vv.price|default='--'}</td>
+<!--                                                        <td>{$vv.price|default='&#45;&#45;'}</td>-->
                                                         <td>{$vv.stock|default='--'}</td>
                                                     </tr>
                                                     {/foreach}

+ 0 - 122
application/car/controller/CarFlow.php

@@ -1,122 +0,0 @@
-<?php
-namespace app\car\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 用车流程
- * Class CarFlow
- * @package app\car\controller
- */
-class CarFlow extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'CarFlow';
-
-    /**
-     * 流程列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '管理';
-        $sel_type = input('sel_type');
-        $query = $this->_query($this->table)
-            ->alias('f')
-            ->field('f.*,u.name,u.headimg')
-            ->leftJoin('store_member u','u.id = f.user_id')
-            ->order('sort asc,id desc')
-            ->where('is_deleted',0)
-            ->when($sel_type,function ($query)use ($sel_type){
-                if($sel_type) $query->where('type',$sel_type);
-            })->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_delete($this->table);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet()) {
-            $this->all_user = User::where('is_deleted',0)->column('name','id');
-        }
-    }
-
-}

+ 0 - 142
application/car/controller/CarInfo.php

@@ -1,142 +0,0 @@
-<?php
-namespace app\car\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 用车列表
- * Class CarInfo
- * @package app\car\controller
- */
-class CarInfo extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'CarInfo';
-
-    /**
-     * 类型列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '列表管理';
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        if($status = input('status')) $sel_where[] = ['u.status','=',$status];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-        }
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('CarApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.car_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 47
application/car/view/car_flow/form.html

@@ -1,47 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批类型</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="type" >
-                        {foreach [1=>'审批人',2=>'抄送人'] as $tk=>$tv}
-                         <option value="{$tk}" {if isset($vo.type) && $vo.type == $tk}selected{/if}>{$tv}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批人/抄送人</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="user_id" >
-                        {foreach $all_user as $user_id=>$user_name}
-                            <option value="{$user_id}" {if isset($vo.user_id) && $vo.user_id == $user_id}selected{/if}>{$user_name}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批顺序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入审批序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 64
application/car/view/car_flow/index.html

@@ -1,64 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='car_flow/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 60%">类型</th>
-            <th class='text-left nowrap' >审批人/抄送人</th>
-            <th class='text-left nowrap'>审批顺序</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>
-                {eq name ='vo.type' value = '1'}审批人{/eq}
-                {eq name ='vo.type' value = '2'}抄送人{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.name|default=''}</td>
-            <td class='text-left nowrap'>{$vo.sort|default=''}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/car/car_flow/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 30
application/car/view/car_flow/index_search.html

@@ -1,30 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="sel_type">
-                    <option  value="0">全部</option>
-                    {foreach [1=>'审批人',2=>'抄送人'] as $k=>$v}
-                        {if $Think.get.sel_type eq $k}
-                            <option selected value="{$k}">{$v}</option>
-                        {else}
-                            <option  value="{$k}">{$v}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-
-    </form>
-    <script>
-        form.render();
-    </script>
-</fieldset>

+ 0 - 39
application/car/view/car_info/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap'>审批人</th>
-            <th class='text-left nowrap'>类型</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class='text-left nowrap'>审批时间</th>
-            <th class='text-left nowrap'>审批备注</th>
-            <th class='text-left nowrap'>审批时长</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 55
application/car/view/car_info/form.html

@@ -1,55 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">开始时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.start_time|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">结束时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.end_time|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">出发地址</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.departure|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">到达地址</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.arrive|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">返回地址</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.back_address|default=''}"/>
-                </div>
-            </div>
-
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 88
application/car/view/car_info/index.html

@@ -1,88 +0,0 @@
-{extend name='admin@main'}
-
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='car_info/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>用车员工</th>
-            <th class='text-left nowrap'>用车时间</th>
-            <th class='text-left nowrap'>用车地址</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    员工ID:{$vo.user_id|default='--'}<br><br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>
-                <div class="inline-block">
-                    开始时间:{$vo.start_time|default='--'}<br><br>
-                    结束时间:{$vo.end_time|default='--'}
-                </div>
-            </td>
-            <td class='text-left nowrap'>
-                <div class="inline-block">
-                    出发地址:{$vo.departure|default='--'}<br>
-                    到达地址:{$vo.arrive|default='--'}<br>
-                    返回地址:{$vo.back_address|default='--'}<br>
-                </div>
-            </td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/car/car_info/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 41
application/car/view/car_info/index_search.html

@@ -1,41 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                    {if $Think.get.status && $Think.get.status eq $k}
-                    <option selected value="{$k}">{$v}</option>
-                    {else}
-                    <option  value="{$k}">{$v}</option>
-                    {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-       <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 1 - 2
application/common/service/ApproveInfoService.php

@@ -1492,7 +1492,6 @@ class ApproveInfoService
         $title = $get_module_list[$data['module']];
         $name = $data['create_user']['name'] . '提交的' . $title . '审批单';
         $data = compact('vo', 'template', 'get_module_list', 'get_approve_status_list', 'get_approve_status_list_admin', 'get_is_who_list', 'get_pay_type_list', 'get_degree_list', 'get_type_list');
-
         $html = self::get_html($data);
         $realpath = self::getPath($name);
         $pdf = new \TCPDF();
@@ -1504,7 +1503,7 @@ class ApproveInfoService
     // 获取html
     public static function get_html($data)
     {
-//        $htmlUrl = app()->getRootPath() . 'public/1.html';
+//        $htmlUrl = app()->getRootPath() . 'public/2.html';
 //        $html = file_get_contents($htmlUrl);
         $html = view('common/' . $data['template'], $data)->getContent();
         return $html;

+ 0 - 122
application/leave/controller/Flow.php

@@ -1,122 +0,0 @@
-<?php
-namespace app\leave\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 请假流程
- * Class Flow
- * @package app\leave\controller
- */
-class Flow extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'LeaveFlow';
-
-    /**
-     * 流程列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '管理';
-        $sel_type = input('sel_type');
-        $query = $this->_query($this->table)
-            ->alias('f')
-            ->field('f.*,u.name,u.headimg')
-            ->leftJoin('store_member u','u.id = f.user_id')
-            ->order('sort asc,id desc')
-            ->where('is_deleted',0)
-            ->when($sel_type,function ($query)use ($sel_type){
-                if($sel_type) $query->where('type',$sel_type);
-            })->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_delete($this->table);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet()) {
-            $this->all_user = User::where('is_deleted',0)->column('name','id');
-        }
-    }
-
-}

+ 0 - 149
application/leave/controller/LeaveInfo.php

@@ -1,149 +0,0 @@
-<?php
-namespace app\leave\controller;
-use app\common\model\LeaveApprove;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 请假列表
- * Class LeaveInfo
- * @package app\leave\controller
- */
-class LeaveInfo extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'LeaveInfo';
-
-    /**
-     * 类型列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '列表管理';
-        $all_type = \app\common\model\LeaveType::getAllType();
-        $this->all_type = array_column($all_type,null,'id');
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        if($type = input('type')) $sel_where[] = ['a.type','=',$type];
-        if($status = input('status')) $sel_where[] = ['a.status','=',$status];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['start_str'] = $data['start_date'].'--'.$data['start_time'];
-            $data['end_str'] = $data['end_date'].'--'.$data['end_time'];
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-        }
-
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('LeaveApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.info_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 136
application/leave/controller/LeaveType.php

@@ -1,136 +0,0 @@
-<?php
-namespace app\leave\controller;
-use library\Controller;
-use think\Db;
-/**
- * 请假类型
- * Class LeaveType
- * @package app\leave\controller
- */
-class LeaveType extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'LeaveType';
-
-    /**
-     * 类型列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '分类管理';
-        $query = $this->_query($this->table)->where('is_deleted',0)->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-    /**
-     * 禁用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function forbidden()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-    /**
-     * 启用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function enable()
-    {
-        $this->_save($this->table, ['status' => '1']);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-
-    }
-
-}

+ 0 - 47
application/leave/view/flow/form.html

@@ -1,47 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批类型</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="type" >
-                        {foreach [1=>'审批人',2=>'抄送人'] as $tk=>$tv}
-                         <option value="{$tk}" {if isset($vo.type) && $vo.type == $tk}selected{/if}>{$tv}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批人/抄送人</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="user_id" >
-                        {foreach $all_user as $user_id=>$user_name}
-                            <option value="{$user_id}" {if isset($vo.user_id) && $vo.user_id == $user_id}selected{/if}>{$user_name}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批顺序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入审批序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 64
application/leave/view/flow/index.html

@@ -1,64 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='flow/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 60%">类型</th>
-            <th class='text-left nowrap' >审批人/抄送人</th>
-            <th class='text-left nowrap'>审批顺序</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>
-                {eq name ='vo.type' value = '1'}审批人{/eq}
-                {eq name ='vo.type' value = '2'}抄送人{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.name|default=''}</td>
-            <td class='text-left nowrap'>{$vo.sort|default=''}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/leave/flow/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 30
application/leave/view/flow/index_search.html

@@ -1,30 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="sel_type">
-                    <option  value="0">全部</option>
-                    {foreach [1=>'审批人',2=>'抄送人'] as $k=>$v}
-                        {if $Think.get.sel_type eq $k}
-                            <option selected value="{$k}">{$v}</option>
-                        {else}
-                            <option  value="{$k}">{$v}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-
-    </form>
-    <script>
-        form.render();
-    </script>
-</fieldset>

+ 0 - 39
application/leave/view/leave_info/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-            <tr>
-                <th class='text-left nowrap'>审批人</th>
-                <th class='text-left nowrap'>类型</th>
-                <th class='text-left nowrap'>审批状态</th>
-                <th class='text-left nowrap'>审批时间</th>
-                <th class='text-left nowrap'>审批备注</th>
-                <th class='text-left nowrap'>审批时长</th>
-            </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 58
application/leave/view/leave_info/form.html

@@ -1,58 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">请假员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">开始时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.start_str|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">结束时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.end_str|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">文件</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.document|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">图片</label>
-                <div class="layui-input-block">
-                    <table class="layui-table" style="width:auto">
-                        <thead>
-                        <tr>
-                            <td width="auto" class="text-left"><input name="images" type="hidden" value="{$vo.images|default=''}"></td>
-                        </tr>
-                        </thead>
-                    </table>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请事由</label>
-                <div class="layui-input-block">
-                    <textarea  name="content" rows="10" cols="100">{$vo.reason}</textarea>
-                </div>
-            </div>
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-        $('[name="images"]').uploadMultipleImage();
-    </script>
-</div>

+ 0 - 82
application/leave/view/leave_info/index.html

@@ -1,82 +0,0 @@
-{extend name='admin@main'}
-
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='leave_info/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>请假员工</th>
-            <th class='text-left nowrap'>请假类型</th>
-            <th class='text-left nowrap'>请假时间</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    员工ID:{$vo.user_id|default='--'}<br><br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>{$all_type[$vo.type]['title']|default=''}</td>
-            <td class='text-left nowrap'>
-                <div class="inline-block">
-                    开始时间:{$vo.start_date|default='--'}--{$vo.start_time|default='--'}<br><br>
-                    结束时间:{$vo.end_date|default='--'}--{$vo.end_time|default='--'}<br>
-                </div>
-            </td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/leave/leave_info/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 59
application/leave/view/leave_info/index_search.html

@@ -1,59 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">请假类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="type">
-                        <option value="0">全部</option>
-                        {foreach $all_type as $v}
-                            {if $Think.get.type > -1 && $Think.get.type eq $v.id}
-                            <option selected value="{$v.id}">{$v.title}</option>
-                            {else}
-                            <option  value="{$v.id}">{$v.title}</option>
-                            {/if}
-                        {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                        {if $Think.get.status && $Think.get.status eq $k}
-                            <option selected value="{$k}">{$v}</option>
-                        {else}
-                            <option  value="{$k}">{$v}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-       <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 0 - 31
application/leave/view/leave_type/form.html

@@ -1,31 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">类型名称</label>
-                <div class="layui-input-block">
-                    <input name="title" maxlength="20"  value='{$vo.title|default=""}' placeholder="请输入类型名称" class="layui-input">
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">排序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入排序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 63
application/leave/view/leave_type/index.html

@@ -1,63 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 75%">分类名称</th>
-            <th class='text-left nowrap' >状态</th>
-            <th class="text-left nowrap" >操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.title|default=''}</td>
-            <td class='text-left nowrap'>{$vo.status == 1 ?'已启用' :'已禁用'}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                {if $vo.status == 1}
-                <span class="layui-btn layui-btn-sm layui-btn-warm"  onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
-                {else}
-                <span class="layui-btn layui-btn-sm layui-btn-sm"  onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
-                {/if}
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/leave/leave_type/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 69
application/leave/view/leave_type/index_search.html

@@ -1,69 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">姓名</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入微信昵称" class="layui-input">
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">手机号</label>
-            <div class="layui-input-inline">
-                <input name="phone" value="{$Think.get.phone|default=''}" placeholder="请输入手机号" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">注册时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择注册时间" class="layui-input">
-            </div>
-        </div>
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-       <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-        <div class="layui-form-item layui-inline" style="margin-left: 5px;">
-            <div  data-title="导出" class='layui-btn layui-btn-sm layui-btn-primary' id="download">导出</div>
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-        layui.use('upload', function(){
-            var upload = layui.upload;
-            //执行实例
-            var uploadInst = upload.render({
-                elem: '#import' //绑定元素
-                ,url: '/user/member/import'
-                ,accept: 'file' //普通文件,
-                ,data:{
-                    subject_id:function(){
-                        return $('#subject').val();
-                    }
-                }
-                ,before: function(obj){ //obj参数包含的信息,跟 choose回调完全一致,可参见上文。
-                }
-                ,done: function(res){
-                    if(res.code == 0){
-                        layer.msg(res.info);
-                    }else{
-                        layer.msg('导入成功');
-                        setTimeout(function(){
-                            location.reload();
-                        },2000);
-                    }
-                }
-                ,error: function(){
-                    layer.msg('上传失败');
-                }
-            });
-        });
-        $('#download').click(function () {
-            window.location.href = "{:url('export')}?phone={$Think.get.phone|default=''}&name={$Think.get.name|default=''}&create_at={$Think.get.create_at|default=''}&account_type={$Think.get.create_at|default='0'}" + $(this).parents('form').serialize();
-        });
-    </script>
-</fieldset>

+ 0 - 138
application/mall/controller/GoodsCate.php

@@ -1,138 +0,0 @@
-<?php
-namespace app\mall\controller;
-
-use library\Controller;
-use library\service\MenuService;
-use library\tools\Data;
-use think\Db;
-
-/**
- * 一级分类管理
- * Class GoodsCate
- * @package app\admin\controller
- */
-class GoodsCate extends Controller
-{
-
-    /**
-     * 当前操作数据库
-     * @var string
-     */
-    protected $table = 'GoodsCate';
-
-    /**
-     * 一级分类管理
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '一级分类管理';
-        $query = $this->_query($this->table)->like('title');
-        $query->where('level',1)->where('is_deleted',0)->order('id asc')->page();
-    }
-
-    /**
-     * 列表数据处理
-     * @param array $data
-     */
-    protected function _index_page_filter(&$data)
-    {
-    }
-
-    /**
-     * 添加分类
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function add()
-    {
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     * 编辑分类
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function edit()
-    {
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     * 表单数据处理
-     * @param array $vo
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$vo)
-    {
-        if ($this->request->isGet()) {
-
-        }
-        if($this->request->isPost() && in_array($this->request->action(),['add','edit'])){
-
-        }
-    }
-
-    /**
-     * 启用
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function enable()
-    {
-        $this->_save($this->table, ['status' => '1']);
-    }
-
-    /**
-     * 禁用
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbExceptionn
-     */
-    public function forbidden()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_delete($this->table);
-    }
-
-}

+ 0 - 144
application/mall/controller/GoodsTwoCate.php

@@ -1,144 +0,0 @@
-<?php
-namespace app\mall\controller;
-
-use library\Controller;
-use library\service\MenuService;
-use library\tools\Data;
-use think\Db;
-
-/**
- * 二级分类管理
- * Class GoodsCate
- * @package app\admin\controller
- */
-class GoodsTwoCate extends Controller
-{
-
-    /**
-     * 当前操作数据库
-     * @var string
-     */
-    protected $table = 'GoodsCate';
-
-    /**
-     * 二级分类管理
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '二级分类管理';
-        $id = input('id');
-        if(empty($id)){
-            $this->error('非法操作');
-        }
-        $this->app->session->set('pid',$id);
-        $query = $this->_query($this->table)->like('title');
-        $query->where('level',2)->where('pid',$id)->where('is_deleted',0)->order('id asc')->page();
-    }
-
-    /**
-     * 列表数据处理
-     * @param array $data
-     */
-    protected function _index_page_filter(&$data)
-    {
-    }
-
-    /**
-     * 添加分类
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function add()
-    {
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     * 编辑分类
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function edit()
-    {
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     * 表单数据处理
-     * @param array $data
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if ($this->request->isGet()) {
-
-        }
-        if($this->request->isPost() && in_array($this->request->action(),['add','edit'])){
-            $data['pid'] = $this->app->session->get('pid');
-            $data['level'] = 2;
-        }
-    }
-
-    /**
-     * 启用
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function enable()
-    {
-        $this->_save($this->table, ['status' => '1']);
-    }
-
-    /**
-     * 禁用
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbExceptionn
-     */
-    public function forbidden()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @throws \ReflectionException
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_delete($this->table);
-    }
-
-}

+ 0 - 291
application/mall/controller/StoreGoods.php

@@ -1,291 +0,0 @@
-<?php
-namespace app\mall\controller;
-use app\common\model\GoodsSeason;
-use app\common\model\GoodsTerritory;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-use app\common\model\GoodsCate;
-use app\common\model\StoreGoodsItem;
-use library\tools\Data;
-
-/**
- * 商品管理
- * Class StoreGoods
- * @package app\mall\controller
- */
-class StoreGoods extends Controller
-{
-
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'StoreGoods';
-
-    /**
-     * 商品列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '商品管理';
-        $where = [];
-        $where['is_deleted'] = 0;
-        $query = $this->_query($this->table)->where($where)->like('name');
-        $query->dateBetween('create_at')->order('sort desc , id desc')->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        $this->clist = GoodsCate::getCateTree();
-        $list = Db::name('StoreGoodsItem')->where('status', '1')->whereIn('goods_id', array_unique(array_column($data, 'id')))->select();
-        foreach ($data as &$vo) {
-            list($vo['list'], $vo['cate']) = [[], []];
-            foreach ($list as $goods){
-                if ($goods['goods_id'] === $vo['id']) array_push($vo['list'], $goods);
-            }
-        }
-    }
-
-
-    /**
-     * 添加商品
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function add()
-    {
-        $this->title = '添加商品';
-        $this->isAddMode = '1';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     * 编辑商品
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    function edit()
-    {
-        $this->title = '编辑商品';
-        $this->isAddMode = '0';
-        $this->_form($this->table, 'form');
-    }
-
-
-
-
-
-    /**
-     * 表单数据处理
-     * @param array $data
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet()){
-            $fields = 'goods_spec,goods_id,status,original_price,sell_price,virtual,cover pic,goods_no sku,weight';
-            $defaultValues = [];
-            if(isset_full($data,'id')) $defaultValues = Db::name('StoreGoodsItem')->where(['goods_id' => $data['id']])->column($fields);
-            $this->defaultValues = json_encode($defaultValues, JSON_UNESCAPED_UNICODE);
-            $this->goods_cate = GoodsCate::getCateTree();
-        }
-        // 添加或编辑商品
-        if($this->request->isPost() && in_array($this->request->action(),['add','edit'])){
-            list($data) = [$this->request->post()];
-            $check_price = true;
-            foreach (json_decode($data['lists'], true) as $vo){
-                if( $vo[0]['sell_price'] <=0 )$check_price = false;
-            }
-            if(!$check_price) $this->error('价格设置有误');
-        }
-
-    }
-
-
-
-
-    /**
-     * 商品上架
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function up()
-    {
-        $this->_save($this->table, ['status' => '1','is_edit'=>0]);
-    }
-
-    /**
-     * 商品下架
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function down()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-
-
-    /**
-     * 商品删除
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-    /**
-     * 商品库存入库
-     * @auth true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function stock()
-    {
-        if ($this->request->isGet()) {
-            $goods_id = $this->request->get('id');
-            $goods_info = Db::name('StoreGoods')->where(['id' => $goods_id])->find();
-            empty($goods_info) && $this->error('无效的商品信息,请稍候再试!');
-            $goods_info['list'] = Db::name('StoreGoodsItem')->where(['goods_id' => $goods_id])->select();
-            $this->fetch('', ['vo' => $goods_info]);
-        } else {
-            list($post, $data) = [$this->request->post(), []];
-            if (isset($post['id']) && isset($post['goods_id']) && is_array($post['goods_id'])) {
-                foreach (array_keys($post['goods_id']) as $key) {
-                    if ($post['goods_number'][$key] > 0) array_push($data, [
-                        'goods_id'     => $post['goods_id'][$key],
-                        'goods_spec'   => $post['goods_spec'][$key],
-                        'number_stock' => $post['goods_number'][$key],
-                    ]);
-                }
-                if (!empty($data)) {
-                    Db::name('GoodsStock')->insertAll($data);
-                    foreach ($data as $dv) {
-                        Db::name('StoreGoodsItem')->where(['goods_id'=>$dv['goods_id'],'goods_spec'=>$dv['goods_spec']])->setInc('stock',$dv['number_stock']);
-                        Db::name('StoreGoodsItem')->where(['goods_id'=>$dv['goods_id'],'goods_spec'=>$dv['goods_spec']])->setInc('base_stock',$dv['number_stock']);
-                    }
-                    Db::name('StoreGoods')->where('id',$post['id'])->setInc('stock',array_sum(array_column($data,'number_stock')));
-                    Db::name('StoreGoods')->where('id',$post['id'])->setInc('base_stock',array_sum(array_column($data,'number_stock')));
-                    $this->success('商品信息入库成功!');
-                }
-            }
-            $this->error('没有需要商品入库的数据!');
-        }
-    }
-
-    /**
-     * 商品参数设置
-     * @auth true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function param()
-    {
-        if ($this->request->isGet()) {
-            $goods_id = $this->request->get('id');
-            $goods_info = Db::name('StoreGoods')->where(['id' => $goods_id])->find();
-            empty($goods_info) && $this->error('无效的商品信息,请稍候再试!');
-            $param =  Db::name('goods_param')->where('goods_id',$goods_id)->find();
-            $param_set = !$param ? [['title'=>'','value'=>'']]:json_decode($param['goods_param'],true);
-            $this->fetch('', ['goods_info' => $goods_info,'param_set'=>$param_set]);
-        }else{
-            $goods_id = input('post.goods_id');
-            $title_arr= input('post.title');
-            $value_arr= input('post.value');
-            if(empty($title_arr)) $this->error('请设置商品参数');
-            $param_post = [];
-            foreach ($title_arr as $k=>$t){
-                $param_post[] = ['title'=>$t,'value'=>$value_arr[$k]];
-            }
-            Data::save('GoodsParam',['goods_id'=>$goods_id,'goods_param'=>json_encode($param_post)],'goods_id',['goods_id'=>$goods_id]);
-            $this->success('保存成功!');
-        }
-    }
-
-
-
-    /**
-     * 添加完成商品之后逻辑处理
-     * @param $result
-     */
-    protected function _form_result($result)
-    {
-        if ($result && $this->request->isPost() && in_array($this->request->action(),['add','edit'])) {
-            list($data) = [$this->request->post()];
-            $data['id'] = $result;
-            $low_price = 0;
-            foreach (json_decode($data['lists'], true) as $vo){
-                if($low_price == 0 || $vo[0]['sell_price'] < $low_price )$low_price =  $vo[0]['sell_price'];
-                Data::save('StoreGoodsItem', [
-                    'goods_id'          => $data['id'],
-                    'goods_spec'        => $vo[0]['key'],
-                    'goods_no'          => $vo[0]['sku'],
-                    'original_price'    => $vo[0]['original_price'],
-                    'sell_price'        => $vo[0]['sell_price'],
-                    'virtual'           => $vo[0]['virtual'],
-                    'status'            => $vo[0]['status'] ? 1 : 0,
-                    'weight'            => $vo[0]['weight'] ? $vo[0]['weight'] : 0,
-                ], 'goods_spec', ['goods_id' => $data['id']]);
-            }
-            Db::name('StoreGoods')->where(['id'=>$data['id']])->update(['low_price'=>$low_price]);
-            $this->success('商品编辑成功!', 'javascript:history.back()');
-        }
-    }
-
-
-
-
-
-
-
-
-}

+ 0 - 31
application/mall/view/goods_cate/form.html

@@ -1,31 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">名称</label>
-                <div class="layui-input-block">
-                    <input name="title" maxlength="20"  value='{$vo.title|default=""}' placeholder="请输入分类名称" class="layui-input">
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">排序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入排序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 69
application/mall/view/goods_cate/index.html

@@ -1,69 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加一级分类</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='goods_cate/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td' style="width: 10%">
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap' style="width: 30%">分类名称</th>
-            <th class='text-left nowrap' style="width: 30%">状态</th>
-            <th class="text-left nowrap" style="width: 30%">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>{$vo.title|default=''}</td>
-            <td class='text-left nowrap'>{$vo.status == 1 ?'已启用' :'已禁用'}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                <a data-title="二级分类" class="layui-btn layui-btn-sm layui-btn-normal" data-open='{:url("mall/goods_two_cate/index")}?id={$vo.id}'>二级分类</a>
-                {if $vo.status == 1}
-                <span class="layui-btn layui-btn-sm layui-btn-warm"  onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
-                {else}
-                <span class="layui-btn layui-btn-sm layui-btn-sm"  onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
-                {/if}
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/mall/goods_cate/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 16
application/mall/view/goods_cate/index_search.html

@@ -1,16 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">分类名称</label>
-            <div class="layui-input-inline">
-                <input name="title" value="{$Think.get.title|default=''}" placeholder="请输入分类名称" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-    </form>
-    <script>form.render()</script>
-</fieldset>

+ 0 - 31
application/mall/view/goods_two_cate/form.html

@@ -1,31 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">名称</label>
-                <div class="layui-input-block">
-                    <input name="title" maxlength="20"  value='{$vo.title|default=""}' placeholder="请输入分类名称" class="layui-input">
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">排序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入排序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 69
application/mall/view/goods_two_cate/index.html

@@ -1,69 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加二级分类</button>
-<a href="javascript:history.go(-1);"  data-title="返 回" class='layui-btn layui-btn-sm layui-btn-primary'>返 回</a>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='goods_two_cate/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td' style="width: 10%">
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap' style="width: 30%">分类名称</th>
-            <th class='text-left nowrap' style="width: 30%">状态</th>
-            <th class="text-left nowrap" style="width: 30%">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>{$vo.title|default=''}</td>
-            <td class='text-left nowrap'>{$vo.status == 1 ?'已启用' :'已禁用'}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                {if $vo.status == 1}
-                <span class="layui-btn layui-btn-sm layui-btn-warm"  onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
-                {else}
-                <span class="layui-btn layui-btn-sm layui-btn-sm"  onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
-                {/if}
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/mall/goods_cate/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 16
application/mall/view/goods_two_cate/index_search.html

@@ -1,16 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">分类名称</label>
-            <div class="layui-input-inline">
-                <input name="title" value="{$Think.get.title|default=''}" placeholder="请输入分类名称" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-    </form>
-    <script>form.render()</script>
-</fieldset>

+ 0 - 422
application/mall/view/store_goods/form.html

@@ -1,422 +0,0 @@
-{extend name='admin@main'}
-
-{block name="content"}
-
-{include file='mall@store_goods/form_style'}
-<style>
-    .layui-form-radio{
-
-        margin: 0 !important;
-        padding-right:0 !important;
-    }
-    .layui-form-select{
-        margin-right: 10px !important;
-    }
-</style>
-<form onsubmit="return false;" id="GoodsForm" data-auto="true" method="post" class='layui-form layui-card' autocomplete="off">
-
-    <div class="layui-card-body think-box-shadow padding-left-40">
-        <div class="layui-tab">
-            <ul class="layui-tab-title">
-                <li class="layui-this">基础设置</li>
-                <li>规格设置</li>
-            </ul>
-                <div class="layui-tab-content">
-                    <!--基础设置-->
-                    <div class="layui-tab-item layui-show">
-                    <!--基础设置start-->
-                        <div class="layui-form-item layui-row layui-col-space15">
-
-                            <label class="layui-col-xs9 relative">
-                                <span class="color-green">商品名称</span>
-                                <input name="name" required class="layui-input" placeholder="请输入商品名称" value="{$vo.name|default=''}">
-                            </label>
-                        </div>
-
-                        <div class="layui-form-item layui-row layui-col-space15">
-                            <label class="layui-col-xs9 relative">
-                                <span class="color-green">副标题</span>
-                                <input name="desc" required class="layui-input" placeholder="请输入商品副标题" value="{$vo.desc|default=''}">
-                            </label>
-                        </div>
-
-                       <!-- 商品分类-->
-                        <div class="layui-form-item layui-row layui-col-space15">
-                            <label class="layui-col-xs9 relative" style="width: 100%;">
-                                <span class="color-green">商品分类</span>
-                            </label>
-                            <div style="width: 100%">
-                                <div style="width: 15%;float: left;">
-                                    <select class="layui-select"  id="first_classify" name="first_classify" lay-filter="first_classify" lay-search>
-                                        <option selected data-first_key="-1" selected value="0">请选择</option>
-                                        {if !empty($goods_cate)}
-                                        {foreach $goods_cate as $ck=>$cv}
-                                        {if isset_full_check($vo,'first_classify',$cv['id'])}
-                                        <option selected data-first_key="{$ck}" value="{$cv['id']}">{$cv['title']}</option>
-                                        {else}
-                                        <option data-first_key="{$ck}" value="{$cv['id']}">{$cv['title']}</option>
-                                        {/if}
-                                        {/foreach}
-                                        {/if}
-                                    </select>
-                                </div>
-                            </div>
-                        </div>
-
-                        <div class="layui-form-item">
-                            <span class="color-green label-required-prev">商品LOGO及轮播展示图片</span>
-                            <table class="layui-table">
-                                <thead>
-                                <tr>
-                                    <th class="text-center">LOGO</th>
-                                    <th class="text-left">展示图片</th>
-                                </tr>
-                                <tr>
-                                    <td width="90px" class="text-center"><input name="cover" type="hidden" value="{$vo.cover|default=''}"></td>
-                                    <td width="auto" class="text-left"><input name="image" type="hidden" value="{$vo.image|default=''}"></td>
-                                </tr>
-                                </thead>
-                            </table>
-                            <script>$('[name="cover"]').uploadOneImage(), $('[name="image"]').uploadMultipleImage()</script>
-                        </div>
-
-                        <div class="layui-form-item">
-                            <span class="color-green label-required-prev">商品详情图</span>
-                            <table class="layui-table">
-                                <thead>
-                                <tr>
-
-                                    <th class="text-left">展示图片</th>
-                                </tr>
-                                <tr>
-                                    <td width="auto" class="text-left"><input name="content" type="hidden" value="{$vo.content|default=''}"></td>
-                                </tr>
-                                </thead>
-                            </table>
-                            <script>$('[name="content"]').uploadMultipleImage()</script>
-                        </div>
-                </div>
-                    <!--规格设置start-->
-                    <div class="layui-tab-item">
-                        <div class="layui-form-item">
-                            <span class="color-green label-required-prev">商品规格及商品SKU绑定<span class="color-red font-s12">(规格填写后不允许再次修改)</span></span>
-                            <div ng-repeat="x in specs track by $index" style="display:none" class="margin-bottom-10" ng-class="{true:'layui-show'}[isAddMode&&specs.length>0]">
-                                <div class="goods-spec-box padding-10 margin-0 relative" style="background:#ddd">
-                                    <span class="text-center goods-spec-title">分组</span>
-                                    <label class="label-required-null inline-block"><input ng-blur="x.name=trimSpace(x.name)" ng-model="x.name" required placeholder="请输入分组名称"></label>
-                                    <div class="pull-right">
-                                        <a class="layui-btn layui-btn-sm layui-btn-primary goods-spec-btn" ng-click="addSpecVal(x.list)">增加</a>
-                                        <a class="layui-btn layui-btn-sm layui-btn-primary goods-spec-btn" ng-class="{false:'layui-bg-gray'}[$index>0]" ng-click="upSpecRow(specs,$index)">上移</a>
-                                        <a class="layui-btn layui-btn-sm layui-btn-primary goods-spec-btn" ng-class="{false:'layui-bg-gray'}[$index<specs.length-1]" ng-click="dnSpecRow(specs,$index)">下移</a>
-                                        <a class="layui-btn layui-btn-sm layui-btn-primary goods-spec-btn" ng-click="delSpecRow(specs,$index)" ng-if="specs.length>1">删除</a>
-                                    </div>
-                                </div>
-                                <div class="goods-spec-box padding-10 margin-0 layui-bg-gray block relative" ng-if="x.list && x.list.length > 0">
-                                    <label class="label-required-null inline-block margin-right-10 margin-bottom-5 relative nowrap" ng-repeat="xx in x.list">
-                                        <input type="checkbox" lay-ignore ng-model="xx.check" ng-click="xx.check=checkListChecked(x.list,$event.target.checked)">
-                                        <input type="text" ng-blur="xx.name=trimSpace(xx.name)" ng-model="xx.name" ng-keyup="xx.name=$event.target.value" required placeholder="请输入规格">
-                                        <a ng-if="x.list.length>1" ng-click="x.list=delSpecVal(x.list,$index)" class="layui-icon layui-icon-close font-s12 goods-spec-close"></a>
-                                    </label>
-                                </div>
-                            </div>
-                          <!--  <a ng-if="isAddMode&&specs.length<3" class="layui-btn layui-btn-sm layui-btn-primary" ng-click="addSpecRow(specs)">增加分组</a>
-                         -->
-                            <table class="layui-table margin-top-10">
-                                <thead>
-                                <tr>
-                                    <th ng-repeat="x in specsTreeNava track by $index" class="nowrap" ng-bind="x"></th>
-                                    <th width="10%" class="text-center nowrap">商品SKU <a ng-click="batchSet('sku',null)" data-tips-text="批量设置" class="layui-icon">&#xe63c;</a></th>
-                                    <th width="10%" class="text-center nowrap">市场价格 <a ng-click="batchSet('original_price',2)" data-tips-text="批量设置" class="layui-icon">&#xe63c;</a></th>
-                                    <th width="10%" class="text-center nowrap">销售价格 <a ng-click="batchSet('sell_price',2)" data-tips-text="批量设置" class="layui-icon">&#xe63c;</a></th>
-                                    <th width="10%" class="text-center nowrap">虚拟销量 <a ng-click="batchSet('virtual',0)" data-tips-text="批量设置" class="layui-icon">&#xe63c;</a></th>
-                                    <th width="10%" class="text-center nowrap">重量(KG)<a ng-click="batchSet('weight',2)" data-tips-text="批量设置" class="layui-icon">&#xe63c;</a></th>
-                                    <th width="10%" class="text-center nowrap">销售状态</th>
-                                </tr>
-                                </thead>
-                                <tbody>
-                                <tr ng-repeat="rows in specsTreeData track by $index">
-                                    <td class="layui-bg-gray" ng-if="td.show" rowspan="{{td.span}}" ng-repeat="td in rows" ng-bind="td.name"></td>
-                                    <td class="padding-0">
-                                        <label class="padding-0 margin-0">
-                                            <input ng-blur="rows[0].sku=setValue(rows[0].key,'sku',$event.target.value)" class="layui-input border-0 padding-left-0 text-center" ng-model="rows[0].sku">
-                                        </label>
-                                    </td>
-                                    <td class="padding-0">
-                                        <label class="padding-0 margin-0">
-                                            <input ng-blur="rows[0].original_price=setValue(rows[0].key,'original_price',$event.target.value,'(parseFloat(_)||0).toFixed(2)')" class="layui-input border-0 padding-left-0 text-center" ng-model="rows[0].original_price">
-                                        </label>
-                                    </td>
-                                    <td class="padding-0">
-                                        <label class="padding-0 margin-0">
-                                            <input ng-blur="rows[0].sell_price=setValue(rows[0].key,'sell_price',$event.target.value,'(parseFloat(_)||0).toFixed(2)')" class="layui-input border-0 padding-left-0 text-center" ng-model="rows[0].sell_price">
-                                        </label>
-                                    </td>
-                                    <td class="padding-0">
-                                        <label class="padding-0 margin-0">
-                                            <input ng-blur="rows[0].virtual=setValue(rows[0].key,'virtual',$event.target.value,'(parseInt(_)||0)')" class="layui-input border-0 padding-left-0 text-center" ng-model="rows[0].virtual">
-                                        </label>
-                                    </td>
-                                    <td class="padding-0">
-                                        <label class="padding-0 margin-0">
-                                            <input ng-blur="rows[0].weight=setValue(rows[0].key,'weight',$event.target.value,'(parseInt(_)||0).toFixed(2)')" class="layui-input border-0 padding-left-0 text-center" ng-model="rows[0].weight">
-                                        </label>
-                                    </td>
-                                    <td class="text-center layui-bg-gray">
-                                        <label class="think-checkbox margin-0 full-width full-height block"><input lay-ignore type="checkbox" ng-model="rows[0].status"></label>
-                                    </td>
-                                </tr>
-                                </tbody>
-                            </table>
-                            <p class="color-desc">请从仓储平台获取商品SKU与商品条码,请注意尽量不要重复,也不能产生订单后再修改!</p>
-                            <textarea class="layui-textarea layui-hide" name="specs">{{specs}}</textarea>
-                            <textarea class="layui-textarea layui-hide" name="lists">{{specsTreeData}}</textarea>
-                        </div>
-
-
-                        <div class="layui-form-item layui-row layui-col-space15">
-                            <label class="layui-col-xs9 relative">
-                                <span class="color-green">详情</span>
-                                <textarea name="detail">{$vo.detail|default=""}</textarea>
-                            </label>
-                        </div>
-
-                        <div class="layui-form-item text-center">
-                            {notempty name='vo.id'}<input type="hidden" name="id" value="{$vo.id}">{/notempty}
-                            <button class="layui-btn" type="submit">保存商品</button>
-                            <button class="layui-btn layui-btn-danger" type='button' onclick="history.go(-1)" data-close>返回</button>
-                        </div>
-
-                    </div>
-                </div>
-            </div>
-     </div>
-</form>
-{/block}
-
-{block name='script'}
-<textarea class="layui-hide" id="goods-specs">{$vo.specs|raw|default=''}</textarea>
-<textarea class="layui-hide" id="goods-value">{$defaultValues|raw|default=''}</textarea>
-<script>
-    window.form.render();
-    layui.use('form', function () {
-        var form = layui.form;
-        //日期时间范围
-        laydate.render({
-            elem: '#sell_time'
-            ,type: 'datetime'
-        });
-
-        //监听指定开关
-        form.on('radio(freight_type)', function(data) {
-            if (data.value == 1) {
-                $(".freight_mud").show();
-                $(".postage").hide();
-            } else {
-                $(".freight_mud").hide();
-                $(".postage").show();
-            }
-        })
-        //监听指定开关
-
-    })
-
-    require(['ckeditor', 'angular'], function () {
-        //window.createEditor('[name="content"]', {height: 500});
-
-        var app = angular.module("GoodsForm", []).run(callback);
-        angular.bootstrap(document.getElementById(app.name), [app.name]);
-        function getRand(length, prefix) {
-            return (function (time, code) {
-                code += parseInt(time.substr(0, 1)) + parseInt(time.substr(1, 1)) + time.substr(2, 8);
-                while (code.length < length) code += Math.round(Math.random() * 10);
-                return code;
-            })(Date.now().toString(), prefix || '' + '')
-        }
-
-        function callback($rootScope) {
-            $rootScope.isAddMode = parseInt('{$isAddMode|default=0}');
-            $rootScope.maps = JSON.parse(angular.element('#goods-value').val() || '[]') || {};
-            $rootScope.specs = JSON.parse(angular.element('#goods-specs').val() || '[{"name":"默认分组","list":[{"name":"默认规格","check":true}]}]');
-            // 批量设置数值
-            $rootScope.batchSet = function (type, fixed) {
-                layer.prompt({title: '请输入数值', formType: 0}, function (value, index) {
-                    $rootScope.$apply(function () {
-                        var val = (parseFloat(value) || 0).toFixed(fixed);
-                        for (var i in $rootScope.specsTreeData) for (var j in $rootScope.specsTreeData[i]) {
-                            $rootScope.specsTreeData[i][j][type] = val;
-                        }
-                    });
-                    layer.close(index);
-                });
-            };
-            // 返回商品列表
-            $rootScope.hsitoryBack = function () {
-                $.msg.confirm('确定要取消编辑吗?', function (index) {
-                    history.back(), $.msg.close(index);
-                });
-            };
-            // 设置默认值
-            $rootScope.setValue = function (key, type, value, call) {
-                $rootScope.maps[key] || ($rootScope.maps[key] = {});
-                return $rootScope.maps[key][type] = eval(call.replace('_', "'" + value + "'"));
-            };
-            // 读取默认值
-            $rootScope.getValue = function (key, callback) {
-                if (typeof callback === 'function') {
-                    return callback($rootScope.maps[key] || {});
-                }
-                return {};
-            };
-            // 去除空白字符
-            $rootScope.trimSpace = function (value) {
-                return (value + '').replace(/\s*/ig, '');
-            };
-            // 生成交叉表格数据
-            $rootScope.specsTreeData = [];
-            $rootScope.specsTreeNava = [];
-            // 当前商品规格发生变化时重新计算规格列表
-            $rootScope.$watch('specs', function () {
-                var data = $rootScope.specs, list = [], navs = [], table = [[]];
-                // 过滤无效记录
-                for (var i in data) {
-                    var tmp = [];
-                    for (var j in data[i].list) if (data[i].list[j].check && data[i].list[j].name.length > 0) {
-                        data[i].list[j].span = 1, data[i].list[j].show = true, data[i].list[j].group = data[i].name;
-                        tmp.push(data[i].list[j]);
-                    }
-                    list.push(tmp), navs.push(data[i].name);
-                }
-                $rootScope.specsTreeNava = navs;
-                // 表格交叉
-                for (var i in list) {
-                    var tmp = [];
-                    for (var j in table) for (var k in list[i]) tmp.push(table[j].concat(list[i][k]));
-                    table = tmp;
-                }
-                // 表格合并
-                list = angular.fromJson(angular.toJson(table));
-                for (var i in list) {
-                    var key = [], _key = '';
-                    for (var td in list[i]) key.push(list[i][td].group + '::' + list[i][td].name);
-                    for (var td in list[i]) if (_key.length === 0) {
-                        list[i][0].key = _key = key.join(';;');
-                        list[i][0].sku = $rootScope.getValue(_key, function (data) {
-                            return data.sku || getRand(14, 'D')
-                        });
-                        list[i][0].virtual = $rootScope.getValue(_key, function (data) {
-                            return data.virtual || '0';
-                        });
-                        list[i][0].express = $rootScope.getValue(_key, function (data) {
-                            return data.express || '1';
-                        });
-                        list[i][0].original_price = $rootScope.getValue(_key, function (data) {
-                            return data.original_price || '0.00';
-                        });
-                        list[i][0].sell_price = $rootScope.getValue(_key, function (data) {
-                            return data.sell_price || '0.00';
-                        });
-                        list[i][0].status = $rootScope.getValue(_key, function (data) {
-                            return !!(typeof data.status !== 'undefined' ? data.status : true);
-                        });
-                        list[i][0].weight = $rootScope.getValue(_key, function (data) {
-                            return data.weight || '0.00';
-                        });
-                        list[i][0].goods_no = $rootScope.getValue(_key, function (data) {
-                            return data.goods_no || '';
-                        });
-                    }
-                }
-                $rootScope.specsTreeData = list;
-            }, true);
-            // 判断规则是否能取消选择
-            $rootScope.checkListChecked = function (list, check) {
-                for (var i in list) if (list[i].check) return check;
-                return true;
-            };
-            // 增加整行规格分组
-            $rootScope.addSpecRow = function (data) {
-                data.push({name: '规格分组', list: [{name: '规格属性', check: true}]})
-            };
-            // 下移整行规格分组
-            $rootScope.dnSpecRow = function (data, $index) {
-                var tmp = [], cur = data[$index];
-                if ($index > data.length - 2) return false;
-                for (var i in data) {
-                    (parseInt(i) !== parseInt($index)) && tmp.push(data[i]);
-                    (parseInt(i) === parseInt($index) + 1) && tmp.push(cur);
-                }
-                return $rootScope.specs = tmp;
-            };
-            // 上移整行规格分组
-            $rootScope.upSpecRow = function (data, $index) {
-                var tmp = [], cur = data[$index];
-                if ($index < 1) return false;
-                for (var i in data) {
-                    (parseInt(i) === parseInt($index) - 1) && tmp.push(cur);
-                    (parseInt(i) !== parseInt($index)) && tmp.push(data[i]);
-                }
-                return $rootScope.specs = tmp;
-            };
-            // 移除整行规格分组
-            $rootScope.delSpecRow = function (data, $index) {
-                var tmp = [];
-                for (var i in data) if (parseInt(i) !== parseInt($index)) tmp.push(data[i]);
-                return $rootScope.specs = tmp;
-            };
-            // 增加分组的属性
-            $rootScope.addSpecVal = function (list) {
-                list.push({name: '规格属性', check: true});
-            };
-            // 移除分组的属性
-            $rootScope.delSpecVal = function (data, $index) {
-                var temp = [];
-                for (var i in data) if (parseInt(i) !== parseInt($index)) temp.push(data[i]);
-                return temp;
-            };
-        }
-    })
-
-
-    layui.use('element', function(){
-        var $ = layui.jquery
-            ,element = layui.element;
-        var active = {
-            tabAdd: function(){
-                element.tabAdd('demo', {
-                    title: '新选项'+ (Math.random()*1000|0)
-                    ,content: '内容'+ (Math.random()*1000|0)
-                    ,id: new Date().getTime()
-                })
-            }
-            ,tabDelete: function(othis){
-                element.tabDelete('demo', '44');
-                othis.addClass('layui-btn-disabled');
-            }
-            ,tabChange: function(){
-                element.tabChange('demo', '22');
-            }
-        };
-
-        $('.site-demo-active').on('click', function(){
-            var othis = $(this), type = othis.data('type');
-            active[type] ? active[type].call(this, othis) : '';
-        });
-
-        //Hash地址的定位
-        var layid = location.hash.replace(/^#test=/, '');
-        element.tabChange('test', layid);
-
-        element.on('tab(test)', function(elem){
-            location.hash = 'test='+ $(this).attr('lay-id');
-        });
-
-    });
-
-    require(['ckeditor', 'angular'], function () {
-        window.createEditor('[name="detail"]', {
-            height: 500,
-
-        });
-    })
-</script>
-{/block}

+ 0 - 87
application/mall/view/store_goods/form_style.html

@@ -1,87 +0,0 @@
-<style>
-    .inner-input {
-        width: 80px;
-        height: 14px;
-        padding: 1px 5px;
-        line-height: 12px;
-    }
-
-    .goods-spec-box {
-        position: relative;
-        margin: 0 10px 10px 0;
-        vertical-align: middle;
-    }
-
-    .goods-spec-title {
-        z-index: 2;
-        width: 40px;
-        color: #fff;
-        height: 28px;
-        position: absolute;
-        background: #999;
-        line-height: 28px;
-    }
-
-    .goods-spec-close {
-        right: 8px;
-        z-index: 2;
-        line-height: 28px;
-        position: absolute;
-        display: inline-block
-    }
-
-    .goods-spec-btn {
-        height: 28px;
-        margin-left: 5px !important;
-        line-height: 26px !important;
-    }
-
-    .goods-spec-box input {
-        z-index: 1;
-        width: 120px;
-        position: relative;
-        border: 1px solid #999;
-        padding: 5px 0 5px 45px;
-        display: inline-block !important;
-    }
-
-    .goods-spec-box input[type=checkbox] {
-        z-index: 2;
-        width: 40px;
-        height: 28px;
-        border: none;
-        cursor: pointer;
-        appearance: none;
-        position: absolute;
-        -webkit-appearance: none;
-    }
-
-    .goods-spec-box input[type=checkbox]:before {
-        top: 1px;
-        left: 1px;
-        width: 40px;
-        height: 26px;
-        content: ' ';
-        position: absolute;
-        background: #c9c9c9;
-    }
-
-    .goods-spec-box input[type=checkbox]:after {
-        top: 1px;
-        left: 1px;
-        color: #999;
-        width: 40px;
-        height: 26px;
-        content: '\e63f';
-        font-size: 16px;
-        line-height: 26px;
-        position: absolute;
-        text-align: center;
-        font-family: 'layui-icon';
-    }
-
-    .goods-spec-box input[type=checkbox]:checked:after {
-        color: #333;
-        content: '\e605';
-    }
-</style>

+ 0 - 104
application/mall/view/store_goods/index.html

@@ -1,104 +0,0 @@
-{extend name='admin@main'}
-{block name="button"}
-<button data-open='{:url("add")}' data-title="添加商品" class='layui-btn layui-btn-sm layui-btn-primary'>添加商品</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='store_goods/index_search'}
-    <table class="layui-table margin-top-10" lay-skin="line">
-        {notempty name='list'}
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap' width="10%">商品详情</th>
-            <th class='text-left nowrap' width="10%">商品状态</th>
-            <th class='text-left nowrap padding-0 relative' style="min-width:400px">
-                <div class="layui-row" style="line-height:28px">
-                    <div class="layui-col-xs6 text-center layui-elip">商品规格</div>
-                    <div class="layui-col-xs3 text-center layui-elip">市价 / 售价</div>
-                    <div class="layui-col-xs3 text-center layui-elip">库存 / 销量</div>
-                </div>
-            </th>
-            <th></th>
-        </tr>
-        </thead>
-        {/notempty}
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr data-dbclick>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                {notempty name='vo.cover'}
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.cover|default=''}" class="margin-right-5 text-top">
-                {/notempty}
-                <div class="inline-block">
-                    商品ID:{$vo.id|default='--'}<br>
-                    商品名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>
-                销售状态:{eq name='vo.status' value='0'}<span class="layui-badge">已下架</span>{else}<span class="layui-badge layui-bg-green">销售中</span>{/eq}<br>
-            </td>
-            <td class='text-left nowrap padding-0 relative'>
-                <div style="overflow:auto;max-height:68px;padding:5px 0">
-                    {foreach $vo.list as $goods}
-                    <div class="layui-row" style="line-height:23px">
-                        <div class="layui-col-xs6 text-center layui-elip font-s10">{:str_replace(['::',';;'],[':',';'],$goods.goods_spec)}</div>
-                        <div class="layui-col-xs3 text-center layui-elip color-blue font-s10">{$goods.original_price+0} / {$goods.sell_price+0}</div>
-                        <div class="layui-col-xs3 text-center layui-elip color-blue font-s10">{$goods.stock+0} / {$goods.sale_num+0}</div>
-                    </div>
-                    {/foreach}
-                </div>
-            </td>
-            <td class='text-left nowrap'>
-
-                <div class="nowrap margin-bottom-5">
-                    {if auth("mall/store_goods/edit")}
-                    <a data-dbclick class="layui-btn layui-btn-sm" data-open='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                    {else}
-                    <a data-tips-text="您没有编辑商品的权限哦!" class="layui-btn layui-btn-sm layui-btn-primary layui-disabled">编 辑</a>
-                    {/if}
-                    {if isset($vo.status) and $vo.status eq 1}
-                    <!--{if auth("mall/store_goods/down")}-->
-                    <a class="layui-btn layui-btn-sm layui-btn-warm" data-action="{:url('down')}" data-value="id#{$vo.id};status#0">下 架</a>
-                    <!--{else}-->
-                    <a data-tips-text="您没有下架商品的权限哦!" class="layui-btn layui-btn-sm layui-btn-primary layui-disabled">下 架</a>
-                    <!--{/if}-->
-                    {else}
-                    <!--{if auth("mall/store_goods/up")}-->
-                    <a class="layui-btn layui-btn-sm layui-btn-warm" data-action="{:url('up')}" data-value="id#{$vo.id};status#1">上 架</a>
-                    <!--{else}-->
-                    <a data-tips-text="您没有上架商品的权限哦!" class="layui-btn layui-btn-sm layui-btn-primary layui-disabled">上 架</a>
-                    <!--{/if}-->
-                    {/if}
-                </div>
-
-                <div class="nowrap margin-bottom-5">
-
-                    {if auth("mall/store_goods/stock")}
-                    <a class="layui-btn layui-btn-sm layui-btn-normal" data-title="商品入库" data-modal='{:url("stock")}?id={$vo.id}'>入 库</a>
-                    {else}
-                    <a data-tips-text="您没有商品入库的权限哦!" class="layui-btn layui-btn-sm layui-btn-primary layui-disabled">入 库</a>
-                    {/if}
-
-                    {if auth("mall/store_goods/remove")}
-                    <a class="layui-btn layui-btn-sm layui-btn-danger" data-confirm="确定要删除数据吗?" data-action="{:url('remove')}" data-value="id#{$vo.id}">删 除</a>
-                    {else}
-                    <a data-tips-text="您没有删除商品的权限哦!" class="layui-btn layui-btn-sm layui-btn-primary layui-disabled">删 除</a>
-                    {/if}
-
-                </div>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-
-</div>
-{/block}

+ 0 - 18
application/mall/view/store_goods/index_search.html

@@ -1,18 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">商品名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入商品名称" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-    </form>
-    <script>
-        form.render();
-    </script>
-</fieldset>

+ 0 - 76
application/mall/view/store_goods/param.html

@@ -1,76 +0,0 @@
-<form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-
-    <div class="layui-card-body">
-
-        <div class="layui-form-item">
-            <label class="layui-form-label">商品名称</label>
-            <div class="layui-input-block">
-                <div class="layui-input layui-bg-gray">{$goods_info.name}</div>
-                <input type="hidden" name="goods_id" value="{$goods_info.id|default='0'}"/>
-            </div>
-        </div>
-
-        <div class="layui-form-item">
-            <label class="layui-form-label">参数详情</label>
-            <div class="layui-input-block">
-                <table class="layui-table param">
-                    <thead>
-                    <tr>
-                        <th class="text-left" width="15%">参数名</th>
-                        <th class="text-center" width="60%">参数值</th>
-                        <th class="text-center">
-                            <a class="layui-btn layui-btn-sm layui-btn-normal"  onclick="add_param()">添 加</a>
-                        </th>
-                    </tr>
-                    </thead>
-                    <!--{foreach $param_set as $param}-->
-                    <tr class="param_index">
-                        <td class="padding-0" >
-                            <input class="layui-input  border-0" name="title[]" value="{$param.title|default=''}">
-                        </td>
-                        <td class="padding-0">
-                            <input class="layui-input  border-0" name="value[]" value="{$param.value|default=''}">
-                        </td>
-                        <td class="padding-0 text-center">
-                            <a class="layui-btn layui-btn-sm layui-btn-danger del">删 除</a>
-                        </td>
-                    </tr>
-                    <!--{/foreach}-->
-                </table>
-            </div>
-        </div>
-
-    </div>
-
-    <div class="hr-line-dashed"></div>
-
-    <div class="layui-form-item text-center">
-        <button class="layui-btn" type='submit'>确 定</button>
-        <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定要取消吗?" data-close>取 消</button>
-    </div>
-
-</form>
-<script>
-    var html = '<tr class="param_index">\n' +
-        '                        <td class="padding-0" >\n' +
-        '                            <input class="layui-input  border-0" name="title[]" value="">\n' +
-        '                        </td>\n' +
-        '                        <td class="padding-0">\n' +
-        '                            <input class="layui-input  border-0" name="value[]" value="">\n' +
-        '                        </td>\n' +
-        '                        <td class="padding-0 text-center">\n' +
-        '                            <a class="layui-btn layui-btn-sm layui-btn-danger del"  >删 除</a>\n' +
-        '                        </td>\n' +
-        '                    </tr>';
-    function add_param() {
-        $(".param").append(html);
-        layer.render();
-    }
-
-    // 删除设置
-    $(document).on('click',".del",function (){
-        var index= $(".del").index(this);
-        $(".param_index").eq(index).remove();
-        layer.render();
-    })
-</script>

+ 0 - 64
application/mall/view/store_goods/stock.html

@@ -1,64 +0,0 @@
-<form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-
-    <div class="layui-card-body">
-
-        <div class="layui-form-item">
-            <label class="layui-form-label">商品名称</label>
-            <div class="layui-input-block">
-                <div class="layui-input layui-bg-gray">{$vo.name}</div>
-            </div>
-        </div>
-
-        <div class="layui-form-item">
-            <label class="layui-form-label">规格详情</label>
-            <div class="layui-input-block">
-                <table class="layui-table">
-                    <thead>
-                    <tr>
-                        <th class="text-left">商品规格</th>
-                        <th class="text-center">销售价格</th>
-                        <th class="text-center">库存统计</th>
-                        <th class="text-center">总销统计</th>
-                        <th class="text-center">库存剩余</th>
-                        <th class="text-center">入库数量</th>
-                    </tr>
-                    </thead>
-                    <!--{foreach $vo.list as $goods}-->
-                    <tr>
-                        <td class="padding-0" width="50%">
-                            <input class="layui-input layui-bg-gray border-0" disabled value="{$goods.goods_spec}">
-                        </td>
-                        <td class="padding-0" width="10%">
-                            <input class="layui-input text-center layui-bg-gray border-0 padding-left-0" disabled value="¥{$goods.sell_price}">
-                        </td>
-                        <td class="padding-0" width="10%">
-                            <input class="layui-input text-center layui-bg-gray border-0 padding-left-0" disabled value="{$goods.base_stock}">
-                        </td>
-                        <td class="padding-0" width="10%">
-                            <input class="layui-input text-center layui-bg-gray border-0 padding-left-0" disabled value="{$goods.sale_num}">
-                        </td>
-                        <td class="padding-0" width="10%">
-                            <input class="layui-input text-center layui-bg-gray border-0 padding-left-0" disabled value="{$goods.stock}">
-                        </td>
-                        <td class="padding-0" width="10%">
-                            <input type="hidden" name="goods_id[]" value="{$goods.goods_id|default=''}">
-                            <input type="hidden" name="goods_spec[]" value="{$goods.goods_spec|default=''}">
-                            <input class="layui-input text-center border-0 padding-left-0" onblur="this.value=parseInt(this.value)||0" name="goods_number[]" value="0">
-                        </td>
-                    </tr>
-                    <!--{/foreach}-->
-                </table>
-            </div>
-        </div>
-
-    </div>
-
-    <div class="hr-line-dashed"></div>
-
-    <div class="layui-form-item text-center">
-        <button class="layui-btn" type='submit'>确定入库</button>
-        <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定要取消入库吗?" data-close>取消入库</button>
-        <!--{notempty name='vo.id'}--><input type='hidden' value='{$vo.id}' name='id'><!--{/notempty}-->
-    </div>
-
-</form>

+ 0 - 136
application/synth/controller/ContractType.php

@@ -1,136 +0,0 @@
-<?php
-namespace app\synth\controller;
-use library\Controller;
-use think\Db;
-/**
- * 合同类型
- * Class OfferType
- * @package app\synth\controller
- */
-class ContractType extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'ContractType';
-
-    /**
-     * 类型列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '类型管理';
-        $query = $this->_query($this->table)->where('is_deleted',0)->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-    /**
-     * 禁用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function forbidden()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-    /**
-     * 启用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function enable()
-    {
-        $this->_save($this->table, ['status' => '1']);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-
-    }
-
-}

+ 0 - 144
application/synth/controller/Document.php

@@ -1,144 +0,0 @@
-<?php
-namespace app\synth\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 学校文件
- * Class Document
- * @package app\synth\controller
- */
-class Document extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'DocumentInfo';
-
-    /**
-     * 列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-
-        $this->title = '列表管理';
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        if($type = input('type')) $sel_where[] = ['a.type','=',$type];
-        if($status = input('status')) $sel_where[] = ['a.status','=',$status];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-        }
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('MaintainApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.info_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 148
application/synth/controller/Evection.php

@@ -1,148 +0,0 @@
-<?php
-namespace app\synth\controller;
-use app\common\model\LeaveApprove;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 请假列表
- * Class Evection
- * @package app\synth\controller
- */
-class Evection extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'EvectionInfo';
-
-    /**
-     * 列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-
-        $this->title = '列表管理';
-        $this->all_type =[1=>'市内出差',2=>'市外出差'];
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        if($type = input('type')) $sel_where[] = ['a.type','=',$type];
-        if($status = input('status')) $sel_where[] = ['a.status','=',$status];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-            $peer_list = $data['peer_user'] ? User::getUserList($data['peer_user'],'id,name,phone'):[];
-            $this->peer_list = $peer_list;
-        }
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('EvectionApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.info_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 126
application/synth/controller/Flow.php

@@ -1,126 +0,0 @@
-<?php
-namespace app\synth\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 流程设置
- * Class Flow
- * @package app\synth\controller
- */
-class Flow extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'ApproveFlow';
-
-    /**
-     * 流程列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '管理';
-        $sel_type = input('sel_type');
-        $module = input('module',1);
-        $this->module = input('module',1);
-        $query = $this->_query($this->table)
-            ->alias('f')
-            ->field('f.*,u.name,u.headimg')
-            ->leftJoin('store_member u','u.id = f.user_id')
-            ->order('sort asc,id desc')
-            ->where('is_deleted',0)
-            ->where('module',$module)
-            ->when($sel_type,function ($query)use ($sel_type){
-                if($sel_type) $query->where('type',$sel_type);
-            })->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_delete($this->table);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet()) {
-            $this->all_user = User::where('is_deleted',0)->column('name','id');
-        }
-        if($this->request->isPost() && $this->request->action() == 'edit')unset($data['module']);
-    }
-
-}

+ 0 - 144
application/synth/controller/Maintain.php

@@ -1,144 +0,0 @@
-<?php
-namespace app\synth\controller;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 请假列表
- * Class Maintain
- * @package app\synth\controller
- */
-class Maintain extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'MaintainInfo';
-
-    /**
-     * 列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-
-        $this->title = '列表管理';
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        if($type = input('type')) $sel_where[] = ['a.type','=',$type];
-        if($status = input('status')) $sel_where[] = ['a.status','=',$status];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-        }
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('MaintainApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.info_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 149
application/synth/controller/Offer.php

@@ -1,149 +0,0 @@
-<?php
-namespace app\synth\controller;
-use app\common\model\LeaveApprove;
-use app\common\model\User;
-use library\Controller;
-use think\Db;
-/**
- * 请假列表
- * Class Evection
- * @package app\synth\controller
- */
-class Offer extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'OfferInfo';
-
-    /**
-     * 列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-
-        $this->title = '列表管理';
-        $all_type = \app\common\model\OfferType::getAllType();
-        $all_type = array_merge([['id'=>0,'title'=>'全部']],$all_type);
-        $this->all_type = array_column($all_type,null,'id');
-        $this->status_arr = [0=>'全部','1'=>'审批中',2=>'审批通过',3=>'审批拒绝',9=>'已取消'];
-        $sel_where = [];
-        $time = explode(' - ',input('create_at'));
-        if(input('create_at')){
-            $sel_where[] = ['a.create_at','between time',$time];
-        }
-        if($type = input('type')) $sel_where[] = ['a.type','=',$type];
-        if($status = input('status')) $sel_where[] = ['a.status','=',$status];
-        if($name = input('name')) $sel_where[] = ['u.name','like','%'.$name.'%'];
-        $query = $this->_query($this->table)
-            ->field('a.*,u.name,u.headimg')
-            ->where($sel_where)
-            ->alias('a')
-            ->leftJoin('store_member u','u.id = a.user_id')
-            ->where('a.is_deleted',0)
-            ->order('a.id desc')
-            ->page();
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-
-
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-        $this->all_type  = \app\common\model\OfferType::getAllType();
-        if($this->request->isGet() && $this->request->action() == 'edit')
-        {
-            $data['user_name'] = User::where('id',$data['user_id'])->value('name');
-        }
-    }
-
-
-    /**
-     *
-     * 审批记录
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function approve()
-    {
-        $id = input('id');
-        $list = $this->_query('OfferApprove')
-            ->alias('r')
-            ->field('r.*,u.name,u.phone,u.headimg')
-            ->leftJoin('store_member u','u.id = r.approve_user')
-            ->where('r.info_id',$id)
-            ->order('r.id asc')->page(false);
-        $this->assign('list',$list);
-        $this->fetch();
-    }
-
-
-
-}

+ 0 - 136
application/synth/controller/OfferType.php

@@ -1,136 +0,0 @@
-<?php
-namespace app\synth\controller;
-use library\Controller;
-use think\Db;
-/**
- * 呈批类型
- * Class OfferType
- * @package app\synth\controller
- */
-class OfferType extends Controller
-{
-    /**
-     * 绑定数据表
-     * @var string
-     */
-    protected $table = 'OfferType';
-
-    /**
-     * 类型列表
-     * @auth true
-     * @menu true
-     * @throws \think\Exception
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     * @throws \think\exception\PDOException
-     */
-    public function index()
-    {
-        $this->title = '分类管理';
-        $query = $this->_query($this->table)->where('is_deleted',0)->page(false);
-    }
-
-    /**
-     * 数据列表处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _index_page_filter(&$data)
-    {
-        foreach ($data as $k=>&$v){
-
-        }
-    }
-
-    /**
-     * 删除
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function remove()
-    {
-        $this->_save($this->table, ['is_deleted' => '1']);
-    }
-    /**
-     * 禁用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function forbidden()
-    {
-        $this->_save($this->table, ['status' => '0']);
-    }
-    /**
-     * 启用
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function enable()
-    {
-        $this->_save($this->table, ['status' => '1']);
-    }
-
-
-    /**
-     * 添加
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function add(){
-        $this->title = '添加';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 编辑
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    public function edit()
-    {
-        $this->title = '编辑';
-        $this->_form($this->table, 'form');
-    }
-
-    /**
-     *
-     * 数据处理
-     * @auth true
-     * @menu true
-     * @param array $data
-     * @throws \think\db\exception\DataNotFoundException
-     * @throws \think\db\exception\ModelNotFoundException
-     * @throws \think\exception\DbException
-     */
-    protected function _form_filter(&$data)
-    {
-
-    }
-
-}

+ 0 - 31
application/synth/view/contract_type/form.html

@@ -1,31 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">类型名称</label>
-                <div class="layui-input-block">
-                    <input name="title" maxlength="20"  value='{$vo.title|default=""}' placeholder="请输入类型名称" class="layui-input">
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">排序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入排序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 63
application/synth/view/contract_type/index.html

@@ -1,63 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 75%">类型名称</th>
-            <th class='text-left nowrap' >状态</th>
-            <th class="text-left nowrap" >操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.title|default=''}</td>
-            <td class='text-left nowrap'>{$vo.status == 1 ?'已启用' :'已禁用'}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                {if $vo.status == 1}
-                <span class="layui-btn layui-btn-sm layui-btn-warm"  onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
-                {else}
-                <span class="layui-btn layui-btn-sm layui-btn-sm"  onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
-                {/if}
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/contract_type/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 39
application/synth/view/document/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-            <tr>
-                <th class='text-left nowrap'>审批人</th>
-                <th class='text-left nowrap'>类型</th>
-                <th class='text-left nowrap'>审批状态</th>
-                <th class='text-left nowrap'>审批时间</th>
-                <th class='text-left nowrap'>审批备注</th>
-                <th class='text-left nowrap'>审批时长</th>
-            </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 66
application/synth/view/document/form.html

@@ -1,66 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">标题</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="title" value="{$vo.title|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.create_at|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">维修地址</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="address" value="{$vo.address|default=''}"/>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">图片</label>
-                <div class="layui-input-block">
-                    <table class="layui-table" style="width:auto">
-                        <thead>
-                        <tr>
-                            <td width="auto" class="text-left"><input name="images" type="hidden" value="{$vo.images|default=''}"></td>
-                        </tr>
-                        </thead>
-                    </table>
-                </div>
-            </div>
-
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">详情</label>
-                <div class="layui-input-block">
-                    <textarea  name="content" rows="10" cols="100">{$vo.content}</textarea>
-                </div>
-            </div>
-
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-        $('[name="images"]').uploadMultipleImage();
-    </script>
-</div>

+ 0 - 83
application/synth/view/document/index.html

@@ -1,83 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='document/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>申请员工</th>
-            <th class='text-left nowrap'>文件标题</th>
-            <th class='text-left nowrap'>文件号</th>
-            <th class='text-left nowrap'>申请时间</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    记录ID:{$vo.id|default='--'}<br>
-                    员工ID:{$vo.user_id|default='--'}<br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>{$vo.title|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.file_number|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.create_at}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/maintain/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 44
application/synth/view/document/index_search.html

@@ -1,44 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                    {if $Think.get.status && $Think.get.status eq $k}
-                    <option selected value="{$k}">{$v}</option>
-                    {else}
-                    <option  value="{$k}">{$v}</option>
-                    {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-            <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 0 - 39
application/synth/view/evection/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-            <tr>
-                <th class='text-left nowrap'>审批人</th>
-                <th class='text-left nowrap'>类型</th>
-                <th class='text-left nowrap'>审批状态</th>
-                <th class='text-left nowrap'>审批时间</th>
-                <th class='text-left nowrap'>审批备注</th>
-                <th class='text-left nowrap'>审批时长</th>
-            </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 100
application/synth/view/evection/form.html

@@ -1,100 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">出差员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-
-            {if $vo.peer_user}
-            <div class="layui-form-item">
-                <label class="layui-form-label">同行员工</label>
-                <div class="layui-input-block">
-                    <table class="layui-table param">
-                        <thead>
-                        <tr>
-                            <th class="text-left">员工名称</th>
-                            <th class="text-left">电话</th>
-                            <th class="text-left">部门</th>
-                        </tr>
-                        </thead>
-                        <!--{foreach $peer_list as $pv}-->
-                        <tr class="param_index">
-                            <td class="padding-0" >
-                                <input class="layui-input  border-0" value="{$pv.name|default=''}">
-                            </td>
-                            <td class="padding-0">
-                                <input class="layui-input  border-0"  value="{$pv.phone|default=''}">
-                            </td>
-                            <td class="padding-0">
-                                <input class="layui-input  border-0"  value="--">
-                            </td>
-                        </tr>
-                        <!--{/foreach}-->
-                    </table>
-                </div>
-            </div>
-            {/if}
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">开始时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="start_time" value="{$vo.start_time|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">结束时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="end_time" value="{$vo.end_time|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">出差类型</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" value="{$vo.type == 1 ?'市内出差':'市外出差'}"/>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">文件</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="document" value="{$vo.document|default=''}"/>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">图片</label>
-                <div class="layui-input-block">
-                    <table class="layui-table" style="width:auto">
-                        <thead>
-                        <tr>
-                            <td width="auto" class="text-left"><input name="images" type="hidden" value="{$vo.images|default=''}"></td>
-                        </tr>
-                        </thead>
-                    </table>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">出差事由</label>
-                <div class="layui-input-block">
-                    <textarea  name="content" rows="10" cols="100">{$vo.reason}</textarea>
-                </div>
-            </div>
-
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-        $('[name="images"]').uploadMultipleImage();
-    </script>
-</div>

+ 0 - 85
application/synth/view/evection/index.html

@@ -1,85 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='evection/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>出差员工</th>
-            <th class='text-left nowrap'>出差类型</th>
-            <th class='text-left nowrap'>出差时间</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    员工ID:{$vo.user_id|default='--'}<br><br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>{$vo.type == 1 ? '市内出差':'市外出差'}</td>
-            <td class='text-left nowrap'>
-                <div class="inline-block">
-                    开始时间:{$vo.start_time|default='--'}<br><br>
-                    结束时间:{$vo.end_time|default='--'}<br>
-                </div>
-            </td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/evection/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 59
application/synth/view/evection/index_search.html

@@ -1,59 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">出差类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="type">
-                    <option value="0">全部</option>
-                    {foreach $all_type as $k=>$v}
-                        {if $Think.get.type > -1 && $Think.get.type eq $k}
-                        <option selected value="{$k}">{$v}</option>
-                        {else}
-                        <option  value="{$k}">{$v}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                    {if $Think.get.status && $Think.get.status eq $k}
-                    <option selected value="{$k}">{$v}</option>
-                    {else}
-                    <option  value="{$k}">{$v}</option>
-                    {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-            <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 0 - 48
application/synth/view/flow/form.html

@@ -1,48 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批类型</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="type" >
-                        {foreach [1=>'审批人',2=>'抄送人'] as $tk=>$tv}
-                         <option value="{$tk}" {if isset($vo.type) && $vo.type == $tk}selected{/if}>{$tv}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批人/抄送人</label>
-                <div class="layui-input-block">
-                    <select class="layui-select" name="user_id" >
-                        {foreach $all_user as $user_id=>$user_name}
-                            <option value="{$user_id}" {if isset($vo.user_id) && $vo.user_id == $user_id}selected{/if}>{$user_name}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">审批顺序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入审批序号" class="layui-input">
-                    <input type="hidden" name="module"  value='{$Think.get.module|default="0"}'  class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 64
application/synth/view/flow/index.html

@@ -1,64 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}&module={$module}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='flow/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 60%">类型</th>
-            <th class='text-left nowrap' >审批人/抄送人</th>
-            <th class='text-left nowrap'>审批顺序</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>
-                {eq name ='vo.type' value = '1'}审批人{/eq}
-                {eq name ='vo.type' value = '2'}抄送人{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.name|default=''}</td>
-            <td class='text-left nowrap'>{$vo.sort|default=''}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/flow/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 30
application/synth/view/flow/index_search.html

@@ -1,30 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="sel_type">
-                    <option  value="0">全部</option>
-                    {foreach [1=>'审批人',2=>'抄送人'] as $k=>$v}
-                        {if $Think.get.sel_type eq $k}
-                            <option selected value="{$k}">{$v}</option>
-                        {else}
-                            <option  value="{$k}">{$v}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-        </div>
-
-    </form>
-    <script>
-        form.render();
-    </script>
-</fieldset>

+ 0 - 39
application/synth/view/maintain/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-            <tr>
-                <th class='text-left nowrap'>审批人</th>
-                <th class='text-left nowrap'>类型</th>
-                <th class='text-left nowrap'>审批状态</th>
-                <th class='text-left nowrap'>审批时间</th>
-                <th class='text-left nowrap'>审批备注</th>
-                <th class='text-left nowrap'>审批时长</th>
-            </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 66
application/synth/view/maintain/form.html

@@ -1,66 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">标题</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="title" value="{$vo.title|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.create_at|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">维修地址</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="address" value="{$vo.address|default=''}"/>
-                </div>
-            </div>
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">图片</label>
-                <div class="layui-input-block">
-                    <table class="layui-table" style="width:auto">
-                        <thead>
-                        <tr>
-                            <td width="auto" class="text-left"><input name="images" type="hidden" value="{$vo.images|default=''}"></td>
-                        </tr>
-                        </thead>
-                    </table>
-                </div>
-            </div>
-
-
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">详情</label>
-                <div class="layui-input-block">
-                    <textarea  name="content" rows="10" cols="100">{$vo.content}</textarea>
-                </div>
-            </div>
-
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-        $('[name="images"]').uploadMultipleImage();
-    </script>
-</div>

+ 0 - 81
application/synth/view/maintain/index.html

@@ -1,81 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='maintain/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>报修员工</th>
-            <th class='text-left nowrap'>维修地址</th>
-            <th class='text-left nowrap'>申请时间</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    记录ID:{$vo.id|default='--'}<br>
-                    员工ID:{$vo.user_id|default='--'}<br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>{$vo.address|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.create_at}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/maintain/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 44
application/synth/view/maintain/index_search.html

@@ -1,44 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                    {if $Think.get.status && $Think.get.status eq $k}
-                    <option selected value="{$k}">{$v}</option>
-                    {else}
-                    <option  value="{$k}">{$v}</option>
-                    {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-            <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 0 - 39
application/synth/view/offer/approve.html

@@ -1,39 +0,0 @@
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-            <tr>
-                <th class='text-left nowrap'>审批人</th>
-                <th class='text-left nowrap'>类型</th>
-                <th class='text-left nowrap'>审批状态</th>
-                <th class='text-left nowrap'>审批时间</th>
-                <th class='text-left nowrap'>审批备注</th>
-                <th class='text-left nowrap'>审批时长</th>
-            </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.approve_type == 1 ?'审批':'抄送'}</td>
-            <td class='text-left nowrap'>{$vo.name}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='0'}待审批{/eq}
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-            </td>
-            <td class='text-left nowrap'>{$vo.approve_time|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.remark|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.time_desc|default='--'}</td>
-
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-
-{/block}
-
-
-

+ 0 - 78
application/synth/view/offer/form.html

@@ -1,78 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请员工</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.user_name|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">标题</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="title" value="{$vo.title|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请时间</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" readonly value="{$vo.create_at|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">发文字号</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="word_size" value="{$vo.word_size|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">申请数量</label>
-                <div class="layui-input-block">
-                    <input class="layui-input" name="num" value="{$vo.num|default=''}"/>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">缓急程度</label>
-                <div class="layui-input-block">
-                    <select name="level" class="layui-select">
-                            <option value="1" {if isset($vo.level) && $vo.level == 1}selected{/if}>缓</option>
-                            <option value="2" {if isset($vo.level) && $vo.level == 2}selected{/if}>稍急</option>
-                            <option value="3" {if isset($vo.level) && $vo.level == 3}selected{/if}>很急</option>
-                    </select>
-                </div>
-            </div>
-            <div class="layui-form-item">
-                <label class="layui-form-label">呈批类型</label>
-                <div class="layui-input-block">
-                    <select name="type" class="layui-select">
-                        {foreach $all_type as $v}
-                            <option value="{$v.id}" {if isset($vo.type) && $vo.type == $v.id}selected{/if}>{$v.title}</option>
-                        {/foreach}
-                    </select>
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label">详情</label>
-                <div class="layui-input-block">
-                    <textarea  name="content" rows="10" cols="100">{$vo.content}</textarea>
-                </div>
-            </div>
-
-        </div>
-
-    </form>
-    <script>
-        window.form.render();
-        $('[name="images"]').uploadMultipleImage();
-    </script>
-</div>

+ 0 - 81
application/synth/view/offer/index.html

@@ -1,81 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    {include file='offer/index_search'}
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='list-table-sort-td'>
-                <button type="button" data-reload class="layui-btn layui-btn-xs">刷 新</button>
-            </th>
-            <th class='text-left nowrap'>呈批员工</th>
-            <th class='text-left nowrap'>呈批类型</th>
-            <th class='text-left nowrap'>申请时间</th>
-            <th class='text-left nowrap'>审批状态</th>
-            <th class="text-left nowrap">操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='list-table-sort-td'><input data-action-blur="{:request()->url()}" data-value="id#{$vo.id};action#sort;sort#{value}" data-loading="false" value="{$vo.sort}" class="list-sort-input"></td>
-            <td class='text-left nowrap'>
-                <img data-tips-image style="width:60px;height:60px" src="{$vo.headimg|default=''}" class="margin-right-5 text-top">
-                <div class="inline-block">
-                    记录ID:{$vo.user_id|default='--'}<br>
-                    员工ID:{$vo.user_id|default='--'}<br>
-                    员工名称:{$vo.name|default='--'}<br>
-                </div>
-            </td>
-
-            <td class='text-left nowrap'>{$all_type[$vo.type]['title']|default='--'}</td>
-            <td class='text-left nowrap'>{$vo.create_at}</td>
-            <td class='text-left nowrap'>
-                {eq name ='vo.status' value='1'}审批中{/eq}
-                {eq name ='vo.status' value='2'}审批通过{/eq}
-                {eq name ='vo.status' value='3'}审批拒绝{/eq}
-                {eq name ='vo.status' value='9'}已取消{/eq}
-            </td>
-            <td class='text-left' >
-                <a data-title="查看详情" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>查看详情</a>
-                <a data-title="查看审批" class="layui-btn layui-btn-sm" data-modal='{:url("approve")}?id={$vo.id}'>审批记录</a>
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/offer/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 0 - 59
application/synth/view/offer/index_search.html

@@ -1,59 +0,0 @@
-<fieldset>
-    <legend>条件搜索</legend>
-    <form class="layui-form layui-form-pane form-search" action="{:request()->url()}" onsubmit="return false" method="get" autocomplete="off">
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">员工名称</label>
-            <div class="layui-input-inline">
-                <input name="name" value="{$Think.get.name|default=''}" placeholder="请输入员工昵称" class="layui-input">
-            </div>
-        </div>
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">呈批类型</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="type">
-                    <option value="0">全部</option>
-                    {foreach $all_type as $k=>$v}
-                        {if $Think.get.type > -1 && $Think.get.type eq $v.id}
-                        <option selected value="{$v.id}">{$v.title}</option>
-                        {else}
-                        <option  value="{$v.id}">{$v.title}</option>
-                        {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">审批状态</label>
-            <div class="layui-input-inline">
-                <select class="layui-select" name="status">
-                    {foreach $status_arr as $k=>$v}
-                    {if $Think.get.status && $Think.get.status eq $k}
-                    <option selected value="{$k}">{$v}</option>
-                    {else}
-                    <option  value="{$k}">{$v}</option>
-                    {/if}
-                    {/foreach}
-                </select>
-            </div>
-        </div>
-
-        <div class="layui-form-item layui-inline">
-            <label class="layui-form-label">申请时间</label>
-            <div class="layui-input-inline">
-                <input name="create_at" value="{$Think.get.create_at|default=''}" placeholder="请选择申请时间" class="layui-input">
-            </div>
-        </div>
-
-
-
-        <div class="layui-form-item layui-inline">
-            <button class="layui-btn layui-btn-primary"><i class="layui-icon">&#xe615;</i> 搜 索</button>
-            <!--     <button type="button" data-export-list class="layui-btn layui-btn-primary" id="download"><i class="layui-icon layui-icon-export"></i> 导 出</button>-->
-        </div>
-    </form>
-    <script>
-        form.render();
-        laydate.render({range: true, elem: '[name="create_at"]'})
-    </script>
-</fieldset>

+ 0 - 31
application/synth/view/offer_type/form.html

@@ -1,31 +0,0 @@
-<style>
-
-</style>
-<div class="think-box-shadow">
-    <form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
-        <div class="layui-card-body">
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">类型名称</label>
-                <div class="layui-input-block">
-                    <input name="title" maxlength="20"  value='{$vo.title|default=""}' placeholder="请输入类型名称" class="layui-input">
-                </div>
-            </div>
-
-            <div class="layui-form-item">
-                <label class="layui-form-label label-required">排序</label>
-                <div class="layui-input-block">
-                    <input type="number" name="sort"  value='{$vo.sort|default=""}' placeholder="请输入排序号" class="layui-input">
-                </div>
-            </div>
-            {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}
-            <div class="layui-form-item text-center">
-                <button class="layui-btn" type='submit'>保 存</button>
-                <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定取消编辑吗?" data-close>取消编辑</button>
-            </div>
-        </div>
-    </form>
-    <script>
-        window.form.render();
-    </script>
-</div>

+ 0 - 63
application/synth/view/offer_type/index.html

@@ -1,63 +0,0 @@
-{extend name='admin@main'}
-
-{block name="button"}
-<button data-modal='{:url("add")}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
-{/block}
-
-{block name="content"}
-<div class="think-box-shadow">
-    <table class="layui-table margin-top-20" lay-skin="line">
-        <thead>
-        <tr>
-            <th class='text-left nowrap' style="width: 75%">类型名称</th>
-            <th class='text-left nowrap' >状态</th>
-            <th class="text-left nowrap" >操作</th>
-        </tr>
-        </thead>
-        <tbody>
-        {foreach $list as $key=>$vo}
-        <tr>
-            <td class='text-left nowrap'>{$vo.title|default=''}</td>
-            <td class='text-left nowrap'>{$vo.status == 1 ?'已启用' :'已禁用'}</td>
-            <td class='text-left' >
-                <a data-title="编辑" class="layui-btn layui-btn-sm" data-modal='{:url("edit")}?id={$vo.id}'>编 辑</a>
-                {if $vo.status == 1}
-                <span class="layui-btn layui-btn-sm layui-btn-warm"  onclick="btn_confirm('禁用','forbidden','{$vo.id}');" >禁 用</span>
-                {else}
-                <span class="layui-btn layui-btn-sm layui-btn-sm"  onclick="btn_confirm('启用','enable','{$vo.id}');">启 用</span>
-                {/if}
-                <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','remove','{$vo.id}');">删 除</span>
-            </td>
-        </tr>
-        {/foreach}
-        </tbody>
-    </table>
-
-    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
-</div>
-<script>
-    function btn_confirm(msg,fun,id) {
-        layer.confirm('请确定是否'+msg, {btn: ['确定', '取消'], title: "提示"}, function () {
-            var url = "/synth/offer_type/"+fun;
-            layer.closeAll();
-            $.ajax({
-                type: "post",
-                url: url,
-                data: {id:id},
-                dataType: "json",
-                async: false,
-                success: function (data) {
-                    layer.msg(data.info);
-                    setTimeout(function () {
-                        window.location.reload();
-                    },1000)
-                }
-            });
-        });
-    }
-
-</script>
-{/block}
-
-
-

+ 5 - 8
public/1.html

@@ -35,18 +35,15 @@
 <table cellpadding="8">
     <tr>
         <td class="content with-30">审批编号</td>
-        <td class="content with-70" colspan="2">202210111716000137453</td>
-        <td>123456</td>
+        <td class="content with-70">202210111716000137453</td>
     </tr>
     <tr>
         <td class="content">创建人</td>
-        <td class="content" colspan="2">余珊珊</td>
-        <td>123456</td>
+        <td class="content">余珊珊</td>
     </tr>
     <tr>
         <td class="content">创建人部门</td>
         <td class="content">教导处-体育与康复训练组</td>
-        <td>123456</td>
     </tr>
     <tr>
         <td class="content">来文单位名称</td>
@@ -58,7 +55,7 @@
     </tr>
     <tr>
         <td class="content">文件名称</td>
-        <td class="content1">深圳市食药安办 深圳市教育局 深圳市市场监督管理局关于开展2022年“护苗促食安”校园食品安全专项行动的通知(深食药安办〔2022〕23号)</td>
+        <td class="content">深圳市食药安办 深圳市教育局 深圳市市场监督管理局关于开展2022年“护苗促食安”校园食品安全专项行动的通知(深食药安办〔2022〕23号)</td>
     </tr>
     <tr>
         <td class="content">收文日期</td>
@@ -66,7 +63,7 @@
     </tr>
     <tr valign="middle">
         <td valign="middle" class="content">内容摘要</td>
-        <td class="content1">为贯彻落实习近平总书记“四个最严”的重要要求和孟凡利书记、覃伟中市长关于校 园食品安全的指示批示精神,聚焦我市校园食品安全的突出问题、薄弱环节,进一步 压实学校、校外供餐单位、市场监管部门、教育部门食品安全责任,严严管严控校 园食品安全风险,全力保障校园食品安全,以实际行动迎接党的二十大胜利召开,市 食药安办、市市场监管局、市教育局决定自即日起至年底,开展校园食品安全“护苗 促食安”行动。10月15日前,各学校应建立家长付费陪餐制度,定期邀请学生家长参与学生餐的监督,做好陪餐记录并存档备查。</td>
+        <td class="content">为贯彻落实习近平总书记“四个最严”的重要要求和孟凡利书记、覃伟中市长关于校 园食品安全的指示批示精神,聚焦我市校园食品安全的突出问题、薄弱环节,进一步 压实学校、校外供餐单位、市场监管部门、教育部门食品安全责任,严严管严控校 园食品安全风险,全力保障校园食品安全,以实际行动迎接党的二十大胜利召开,市 食药安办、市市场监管局、市教育局决定自即日起至年底,开展校园食品安全“护苗 促食安”行动。10月15日前,各学校应建立家长付费陪餐制度,定期邀请学生家长参与学生餐的监督,做好陪餐记录并存档备查。</td>
     </tr>
     <tr>
         <td class="content">缓急程度</td>
@@ -74,7 +71,7 @@
     </tr>
     <tr>
         <td class="content">附件</td>
-        <td class="content1">深圳市食药安办 深圳市教育局 深圳市市场监督管理局关于开展2022年“护苗促食安”校园食品安全专项行动的通知(深食药安办〔2022〕23号).pdf</td>
+        <td class="content">深圳市食药安办 深圳市教育局 深圳市市场监督管理局关于开展2022年“护苗促食安”校园食品安全专项行动的通知(深食药安办〔2022〕23号).pdf</td>
     </tr>
 </table>
 <table cellpadding="8">