Selaa lähdekoodia

fix:
- 放号设置

zzb 2 vuotta sitten
vanhempi
commit
47514fab00

+ 2 - 2
app/admin/controller/Address.php

@@ -48,8 +48,8 @@ class Address extends Permissions
 
 
             //验证
             //验证
             $validate = new \think\Validate([
             $validate = new \think\Validate([
-                ['title|标题', 'max:50'],
-                ['address|地址', 'max:500'],
+                ['title|地名', 'max:50'],
+                ['address|详细地址', 'max:500'],
             ]);
             ]);
             if (!$validate->check($post)) {
             if (!$validate->check($post)) {
                 $this->error('提交失败:' . $validate->getError());
                 $this->error('提交失败:' . $validate->getError());

+ 160 - 0
app/admin/controller/Appointment.php

@@ -0,0 +1,160 @@
+<?php
+
+namespace app\admin\controller;
+
+use app\admin\controller\base\Permissions;
+use think\Db;
+
+class Appointment extends Permissions
+{
+    private function getModel()
+    {
+        return new \app\common\model\Appointment();
+    }
+
+    public function index()
+    {
+        $pid = $this->request->param('pid', 0, 'intval');
+        if ($this->request->isAjax()) {
+            $post = $this->request->param();
+            $where = [
+                'provider_id' => $pid
+            ];
+            if (!empty($post["title"])) {
+                $where["title"] = ['like', '%' . $post["title"] . '%'];
+            }
+            if (isset($post["start_time"]) and !empty($post["start_time"])) {
+                $timerang = explode(' - ', $post["start_time"]);
+                $min_time = strtotime($timerang[0]);
+                $max_time = $timerang[0] == $timerang[1] ? $min_time + 24 * 3600 - 1 : strtotime($timerang[1]??'');
+                $where["start_time"] = [['>=', $min_time], ['<=', $max_time]];
+            }
+            if (isset($post["create_time"]) and !empty($post["create_time"])) {
+                $timerang = explode(' - ', $post["create_time"]);
+                $min_time = strtotime($timerang[0]);
+                $max_time = $timerang[0] == $timerang[1] ? $min_time + 24 * 3600 - 1 : strtotime($timerang[1]??'');
+                $where["create_time"] = [['>=', $min_time], ['<=', $max_time]];
+            }
+
+            $model = $this->getModel();
+            $count = $model->where($where)->count();
+            $data = $model->where($where)->page($post['page']??0, $post['limit']??15)->order('id desc')->select();
+
+            return array('code' => 0, 'count' => $count, 'data' => $data);
+        } else {
+            return $this->fetch();
+        }
+    }
+
+
+    public function publish()
+    {
+        $id = $this->request->param('id', 0, 'intval');
+        $pid = $this->request->param('pid', 0, 'intval');
+        $this->assign('pid', $pid);
+
+        $model = $this->getModel();
+        $post = $this->request->post();
+        $post['provider_id'] = $pid;
+
+        if ($this->request->isPost()) {
+
+            if (isset($post['start_time']) && !empty($post['start_time'])) {
+                $timerang = explode(' - ', $post["start_time"]);
+                $min_time = strtotime(str_replace(['年', '月'], '-', $timerang[0]));
+                $max_time = $timerang[0] == $timerang[1] ? $min_time + 24 * 3600 - 1 : strtotime(str_replace(['年', '月'], '-', $timerang[1]??''));
+                $post['start_time'] = $min_time;
+                $post['end_time'] = $max_time;
+            }
+            if (isset($post['morning_start_time']) && !empty($post['morning_start_time'])) {
+                $timerang = explode(' - ', $post["morning_start_time"]);
+                $post['morning_start_time'] = $timerang[0];
+                $post['morning_end_time'] = $timerang[1];
+            }
+            if (isset($post['afternoon_start_time']) && !empty($post['afternoon_start_time'])) {
+                $timerang = explode(' - ', $post["afternoon_start_time"]);
+                $post['afternoon_start_time'] = $timerang[0];
+                $post['afternoon_end_time'] = $timerang[1];
+            }
+            if (isset($post['night_start_time']) && !empty($post['night_start_time'])) {
+                $timerang = explode(' - ', $post["night_start_time"]);
+                $post['night_start_time'] = $timerang[0];
+                $post['night_end_time'] = $timerang[1];
+            }
+
+            //验证
+            $validate = new \think\Validate([
+                ['title|服务名称', 'max:50'],
+                ['provider_id', 'require|number'],
+                ['phone|咨询电话', 'require|max:50'],
+                ['start_time', 'number', '排号日期格式不对'],
+                ['end_time', 'number', '排号日期格式不对'],
+                ['morning_num|上午放号个数', 'number'],
+                ['morning_start_time', 'length:8', '上午时间格式不对'],
+                ['morning_end_time', 'length:8', '上午时间格式不对'],
+                ['afternoon_num|下午放号个数', 'number'],
+                ['afternoon_start_time', 'length:8', '下午时间格式不对'],
+                ['afternoon_end_time', 'length:8', '下午时间格式不对'],
+                ['night_num|晚上放号个数', 'number'],
+                ['night_start_time', 'length:8', '晚上时间格式不对'],
+                ['night_end_time', 'length:8', '晚上时间格式不对'],
+            ]);
+            if (!$validate->check($post)) {
+                $this->error('提交失败:' . $validate->getError());
+            }
+        }
+
+        if ($id > 0) {
+            //修改
+            $data = $model->where('id', $id)->find();
+            if (empty($data)) {
+                $this->error('id不正确');
+            }
+            if ($this->request->isPost()) {
+                if (false == $model->allowField(true)->save($post, ['id' => $id])) {
+                    $this->error('修改失败');
+                } else {
+                    $this->success('修改成功', 'index', ['pid' => $pid]);
+                }
+            } else {
+                $this->assign('data', $data);
+                return $this->fetch();
+            }
+        } else {
+            //新增
+            if ($this->request->isPost()) {
+                if (false == $model->allowField(true)->save($post)) {
+                    $this->error('添加失败');
+                } else {
+                    $this->success('添加成功', 'index', ['pid' => $pid]);
+                }
+            } else {
+                return $this->fetch();
+            }
+        }
+    }
+
+    public function delete()
+    {
+        if ($this->request->isAjax()) {
+            $id = $this->request->param('id', 0, 'intval');
+            if (false == $this->getModel()->where('id', $id)->delete()) {
+                $this->error('删除失败');
+            } else {
+                $this->success('删除成功', 'index');
+            }
+        }
+    }
+
+    public function deletes()
+    {
+        if ($this->request->isAjax()) {
+            $post = $this->request->param();
+            $ids = $post['ids'];
+            if ($this->getModel()->where('id', 'in', $ids)->delete()) {
+                $this->success('删除成功');
+            }
+        }
+    }
+
+}

+ 3 - 0
app/admin/controller/Menu.php

@@ -173,6 +173,9 @@ class Menu extends Permissions
         if (isset($post['name']) && is_array($post['name'])) {
         if (isset($post['name']) && is_array($post['name'])) {
             $data = [];
             $data = [];
             foreach ($post['name'] as $key => $name) {
             foreach ($post['name'] as $key => $name) {
+                if (!isset($post['pid'][$key])) {
+                    continue;//没有选择上级节点
+                }
                 $data[] = [
                 $data[] = [
                     'name' => $name,
                     'name' => $name,
                     'module' => $post['module'][$key],
                     'module' => $post['module'][$key],

+ 9 - 6
app/admin/controller/Specialist.php

@@ -48,10 +48,13 @@ class Specialist extends Permissions
 
 
             foreach ($data as $key => $value) {
             foreach ($data as $key => $value) {
                 $value['head_pic_url'] = geturl($value['head_pic']);
                 $value['head_pic_url'] = geturl($value['head_pic']);
+                $value['sex_text'] = $value->sex_text;
+                $value['address_name'] = $value->address ? $value->address->title : '';
                 $data[$key] = $value;
                 $data[$key] = $value;
             }
             }
             return array('code' => 0, 'count' => $count, 'data' => $data);
             return array('code' => 0, 'count' => $count, 'data' => $data);
         } else {
         } else {
+            $this->assign('addresslist', \app\common\model\Address::all());
             return $this->fetch();
             return $this->fetch();
         }
         }
     }
     }
@@ -63,21 +66,21 @@ class Specialist extends Permissions
         $model = $this->getModel();
         $model = $this->getModel();
         $post = $this->request->post();
         $post = $this->request->post();
         if ($this->request->isPost()) {
         if ($this->request->isPost()) {
-
-
             //验证
             //验证
             $validate = new \think\Validate([
             $validate = new \think\Validate([
-                ['name|名字', 'max:50'],
-                ['title|职称', 'max:50'],
+                ['name|名字', 'require|max:50'],
+                ['title|职称', 'require|max:50'],
                 ['head_pic|头像', 'max:255'],
                 ['head_pic|头像', 'max:255'],
-                ['sex|sex', 'number'],
+                ['sex|性别', 'number'],
                 ['desc|简介', 'max:500'],
                 ['desc|简介', 'max:500'],
                 ['consultation_direction|咨询方向', 'max:500'],
                 ['consultation_direction|咨询方向', 'max:500'],
-                ['address_id|地址id', 'require|number'],
+                ['address_id|地址', 'require|number'],
             ]);
             ]);
             if (!$validate->check($post)) {
             if (!$validate->check($post)) {
                 $this->error('提交失败:' . $validate->getError());
                 $this->error('提交失败:' . $validate->getError());
             }
             }
+        } else {
+            $this->assign('addresslist', \app\common\model\Address::all());
         }
         }
 
 
         if ($id > 0) {
         if ($id > 0) {

+ 41 - 33
app/admin/view/address/index.html

@@ -19,7 +19,8 @@
             display: none;
             display: none;
             color: #fff;
             color: #fff;
         }
         }
-        .tooltip > img{
+
+        .tooltip > img {
             width: 20px;
             width: 20px;
             height: 20px;
             height: 20px;
         }
         }
@@ -28,45 +29,52 @@
 <body style="padding:10px;">
 <body style="padding:10px;">
 <div class="tplay-body-div">
 <div class="tplay-body-div">
 
 
-        <div class="layui-tab">
+    <div class="layui-tab">
         <ul class="layui-tab-title">
         <ul class="layui-tab-title">
             <li class="layui-this">列表</li>
             <li class="layui-this">列表</li>
             <li><a href="{:url('publish')}" class="a_menu">新增</a></li>
             <li><a href="{:url('publish')}" class="a_menu">新增</a></li>
         </ul>
         </ul>
     </div>
     </div>
-    
+
     <script type="text/html" id="toolbarDemo">
     <script type="text/html" id="toolbarDemo">
         <div class="layui-btn-container">
         <div class="layui-btn-container">
-                        <button class="layui-btn layui-btn-danger layui-btn-sm" lay-event="deletes">批量删除</button>
-                    </div>
+            <button class="layui-btn layui-btn-danger layui-btn-sm" lay-event="deletes">批量删除</button>
+        </div>
     </script>
     </script>
 
 
     <form class="layui-form serch" action="index" method="post">
     <form class="layui-form serch" action="index" method="post">
         <div class="layui-form-item" style="float: left;">
         <div class="layui-form-item" style="float: left;">
 
 
             <div class="layui-input-inline">
             <div class="layui-input-inline">
-                                <input type="text" name="ids" autocomplete="off" placeholder="请输入ID,多个id逗号分隔" class="layui-input layui-btn-sm">
-                            </div><div class="layui-input-inline">
-                            <input type="text" name="title" autocomplete="off" placeholder="标题(模糊搜索)" class="layui-input layui-btn-sm">
-                        </div><div class="layui-input-inline">
-                            <input type="text" name="address" autocomplete="off" placeholder="地址(模糊搜索)" class="layui-input layui-btn-sm">
-                        </div>
+                <input type="text" name="ids" autocomplete="off" placeholder="请输入ID,多个id逗号分隔"
+                       class="layui-input layui-btn-sm">
+            </div>
+            <div class="layui-input-inline">
+                <input type="text" name="title" autocomplete="off" placeholder="地名(模糊搜索)"
+                       class="layui-input layui-btn-sm">
+            </div>
+            <div class="layui-input-inline">
+                <input type="text" name="address" autocomplete="off" placeholder="详细地址(模糊搜索)"
+                       class="layui-input layui-btn-sm">
+            </div>
             <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="serch">立即提交</button>
             <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="serch">立即提交</button>
         </div>
         </div>
     </form>
     </form>
 
 
-        <script type="text/html" id="barDemo">
+    <script type="text/html" id="barDemo">
         <div class="layui-btn-group">
         <div class="layui-btn-group">
-                        <button class="layui-btn layui-btn-xs a_menu" lay-event="edit"><i class="layui-icon" style="margin-right: 0;"></i></button>
-                        <button class="layui-btn layui-btn-xs delete" lay-event="del"><i class="layui-icon" style="margin-right: 0;"></i></button>
-                    </div>
+            <button class="layui-btn layui-btn-xs a_menu" lay-event="edit"><i class="layui-icon"
+                                                                              style="margin-right: 0;"></i></button>
+            <button class="layui-btn layui-btn-xs delete" lay-event="del"><i class="layui-icon"
+                                                                             style="margin-right: 0;"></i></button>
+        </div>
     </script>
     </script>
-    
+
     <table class="layui-table" id="table" lay-filter="table"></table>
     <table class="layui-table" id="table" lay-filter="table"></table>
     {include file="public/foot"}
     {include file="public/foot"}
 
 
     <script type="text/javascript">
     <script type="text/javascript">
-        layui.use(['table', 'layer', 'form','laydate'], function () {
+        layui.use(['table', 'layer', 'form', 'laydate'], function () {
             var table = layui.table,
             var table = layui.table,
                 form = layui.form,
                 form = layui.form,
                 layer = layui.layer;
                 layer = layui.layer;
@@ -76,27 +84,27 @@
                 id: 'table'
                 id: 'table'
                 , elem: '#table'
                 , elem: '#table'
                 , size: 'sm' //小尺寸的表格
                 , size: 'sm' //小尺寸的表格
-                                , toolbar: '#toolbarDemo'
-                                , limit: 15
+                , toolbar: '#toolbarDemo'
+                , limit: 15
                 , limits: [15, 20, 30, 40, 50, 100]
                 , limits: [15, 20, 30, 40, 50, 100]
                 , url: "{:url('index')}" //数据接口
                 , url: "{:url('index')}" //数据接口
                 , page: true //开启分页
                 , page: true //开启分页
                 , cols: [[ //表头
                 , cols: [[ //表头
                     {type: 'checkbox'},
                     {type: 'checkbox'},
 
 
-                                                {field: 'id', title: 'ID', width: 60},
-                                                        {field: "title", title: '标题'},
-                                                        {field: "address", title: '地址'},
-                                                    {field: 'action', title: '操作', toolbar: '#barDemo', fixed: 'right'}
-                                    ]],
+                    {field: 'id', title: 'ID', width: 60},
+                    {field: "title", title: '地名'},
+                    {field: "address", title: '详细地址'},
+                    {field: 'action', title: '操作', toolbar: '#barDemo', fixed: 'right'}
+                ]],
                 done: function () {
                 done: function () {
                     if (isExitsFunction('showThumb')) {
                     if (isExitsFunction('showThumb')) {
                         showThumb()
                         showThumb()
                     }
                     }
-                                    }
+                }
             });
             });
 
 
-            
+
             form.on('submit(serch)', function (data) {
             form.on('submit(serch)', function (data) {
                 table.reload('table', {
                 table.reload('table', {
                     where: data.field
                     where: data.field
@@ -107,8 +115,8 @@
                 return false;
                 return false;
             });
             });
 
 
-                        table.on('tool(table)', function (obj) {
-                                if (obj.event == 'edit') {
+            table.on('tool(table)', function (obj) {
+                if (obj.event == 'edit') {
                     window.parent.tab.tabAdd({
                     window.parent.tab.tabAdd({
                         icon: "fa-bookmark",
                         icon: "fa-bookmark",
                         id: "tplay_address" + obj.data.id,
                         id: "tplay_address" + obj.data.id,
@@ -116,7 +124,7 @@
                         url: "/admin/address/publish?id=" + obj.data.id
                         url: "/admin/address/publish?id=" + obj.data.id
                     });
                     });
                 }
                 }
-                                else if (obj.event == 'del') {
+                else if (obj.event == 'del') {
                     layer.confirm('确定要删除?', function (index) {
                     layer.confirm('确定要删除?', function (index) {
                         $.ajax({
                         $.ajax({
                             url: "{:url('delete')}",
                             url: "{:url('delete')}",
@@ -131,8 +139,8 @@
                         })
                         })
                     })
                     })
                 }
                 }
-                            });
-                        //监听事件
+            });
+            //监听事件
             table.on('toolbar(table)', function (obj) {
             table.on('toolbar(table)', function (obj) {
                 if (obj.event == 'deletes') {
                 if (obj.event == 'deletes') {
                     var checkStatus = table.checkStatus(obj.config.id);//获取选中的数据
                     var checkStatus = table.checkStatus(obj.config.id);//获取选中的数据
@@ -162,10 +170,10 @@
                     }
                     }
                 }
                 }
             });
             });
-                    });
+        });
     </script>
     </script>
 
 
-    
+
 </div>
 </div>
 </body>
 </body>
 </html>
 </html>

+ 47 - 46
app/admin/view/address/publish.html

@@ -6,71 +6,72 @@
     <meta name="renderer" content="webkit">
     <meta name="renderer" content="webkit">
     <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
     <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
-    <link rel="stylesheet" href="/static/public/layui/css/layui.css"  media="all">
-    <link rel="stylesheet" href="/static/public/font-awesome/css/font-awesome.min.css" media="all" />
-    <link rel="stylesheet" href="/static/admin/css/admin.css"  media="all">
+    <link rel="stylesheet" href="/static/public/layui/css/layui.css" media="all">
+    <link rel="stylesheet" href="/static/public/font-awesome/css/font-awesome.min.css" media="all"/>
+    <link rel="stylesheet" href="/static/admin/css/admin.css" media="all">
     <script src="/static/public/layui/layui.js"></script>
     <script src="/static/public/layui/layui.js"></script>
     <script src="/static/public/jquery/jquery.min.js"></script>
     <script src="/static/public/jquery/jquery.min.js"></script>
 </head>
 </head>
 <style>
 <style>
-  .layui-upload-img{
-    cursor: pointer;
-    width:150px;
-    height:150px;
-    background: url('/static/public/images/uploadimg.jpg');
-    background-size:contain;
-    border-radius: 2px;
-    border-width: 1px;
-    border-style: solid;
-    border-color: #e6e6e6;
-  }
+    .layui-upload-img {
+        cursor: pointer;
+        width: 150px;
+        height: 150px;
+        background: url('/static/public/images/uploadimg.jpg');
+        background-size: contain;
+        border-radius: 2px;
+        border-width: 1px;
+        border-style: solid;
+        border-color: #e6e6e6;
+    }
 </style>
 </style>
 <body style="padding:10px;">
 <body style="padding:10px;">
-  <div class="tplay-body-div">
+<div class="tplay-body-div">
 
 
     {empty name="$data"}
     {empty name="$data"}
     <div class="layui-tab">
     <div class="layui-tab">
-      <ul class="layui-tab-title">
-        <li><a href="index" class="a_menu">列表</a></li>
-        <li class="layui-this">新增</li>
-      </ul>
+        <ul class="layui-tab-title">
+            <li><a href="index" class="a_menu">列表</a></li>
+            <li class="layui-this">新增</li>
+        </ul>
     </div>
     </div>
     {/empty}
     {/empty}
 
 
     <div style="margin-top: 20px;"></div>
     <div style="margin-top: 20px;"></div>
     <form class="layui-form" id="publish" method="post">
     <form class="layui-form" id="publish" method="post">
 
 
-                      <!-- 输入框 -->
-              <div class="layui-form-item">
-                <label class="layui-form-label">标题</label>
-                <div class="layui-input-inline" style="max-width:300px;">
-                  <input name="title"  autocomplete="off" placeholder="请输入" class="layui-input" type="text" {notempty name="$data"}value="{$data.title}"{/notempty}>
-                </div>
-                                </div>
-                          <!-- 输入框 -->
-              <div class="layui-form-item">
-                <label class="layui-form-label">地址</label>
-                <div class="layui-input-inline" style="max-width:300px;">
-                  <input name="address"  autocomplete="off" placeholder="请输入" class="layui-input" type="text" {notempty name="$data"}value="{$data.address}"{/notempty}>
-                </div>
-                                </div>
-            
+        <!-- 输入框 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">地名</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="title" autocomplete="off" placeholder="请输入" class="layui-input" type="text" {notempty
+                       name="$data" }value="{$data.title}" {/notempty}>
+            </div>
+        </div>
+        <!-- 纯文本段落 -->
+        <div class="layui-form-item layui-form-text">
+            <label class="layui-form-label">详细地址</label>
+            <div class="layui-input-inline" style="width:80%;">
+                <textarea name="address"
+                          class="layui-textarea">{notempty name="$data"}{$data.address}{/notempty}</textarea>
+            </div>
+        </div>
+
 
 
-        
         {notempty name="$data"}
         {notempty name="$data"}
-          <input type="hidden" name="id" value="{$data.id}">
+        <input type="hidden" name="id" value="{$data.id}">
         {/notempty}
         {/notempty}
-       
-      <div class="layui-form-item">
-        <div class="layui-input-block">
-          <button class="layui-btn" lay-submit lay-filter="admin">立即提交</button>
-          <button type="reset" class="layui-btn layui-btn-primary">重置</button>
+
+        <div class="layui-form-item">
+            <div class="layui-input-block">
+                <button class="layui-btn" lay-submit lay-filter="admin">立即提交</button>
+                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
+            </div>
         </div>
         </div>
-      </div>
     </form>
     </form>
 
 
     <script>
     <script>
-        layui.use(['layer', 'form' ,'laydate'], function () {
+        layui.use(['layer', 'form', 'laydate'], function () {
             var layer = layui.layer,
             var layer = layui.layer,
                 $ = layui.jquery,
                 $ = layui.jquery,
                 form = layui.form;
                 form = layui.form;
@@ -90,7 +91,7 @@
                                     layer.alert(res.msg, function (index) {
                                     layer.alert(res.msg, function (index) {
                                         location.href = res.url;
                                         location.href = res.url;
                                     })
                                     })
-                                }else{
+                                } else {
                                     layer.confirm(res.msg, {
                                     layer.confirm(res.msg, {
                                         btn: ['关闭', '继续编辑']
                                         btn: ['关闭', '继续编辑']
                                     }, function (index) {
                                     }, function (index) {
@@ -107,10 +108,10 @@
                     return false;
                     return false;
                 });
                 });
 
 
-                
+
             });
             });
         });
         });
     </script>
     </script>
-  </div>
+</div>
 </body>
 </body>
 </html>
 </html>

+ 324 - 0
app/admin/view/appointment/index.html

@@ -0,0 +1,324 @@
+<!DOCTYPE html>
+<html>
+<head>
+    <meta charset="utf-8">
+    <title>layui</title>
+    <meta name="renderer" content="webkit">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+    <link rel="stylesheet" href="/static/public/layui/css/layui.css" media="all">
+    <link rel="stylesheet" href="/static/public/font-awesome/css/font-awesome.min.css" media="all"/>
+    <link rel="stylesheet" href="/static/admin/css/admin.css" media="all">
+    <style type="text/css">
+        /* tooltip */
+        #tooltip {
+            position: absolute;
+            border: 1px solid #ccc;
+            background: #333;
+            padding: 2px;
+            display: none;
+            color: #fff;
+        }
+
+        .tooltip > img {
+            width: 20px;
+            height: 20px;
+        }
+    </style>
+</head>
+<body style="padding:10px;">
+<div class="tplay-body-div">
+
+    <div class="layui-tab">
+        <ul class="layui-tab-title">
+            <li class="layui-this">列表</li>
+            <li><a href="{:url('publish',['pid'=>$Request.param.pid])}" class="a_menu">新增</a></li>
+        </ul>
+    </div>
+
+    <script type="text/html" id="toolbarDemo">
+        <div class="layui-btn-container">
+            <button class="layui-btn layui-btn-danger layui-btn-sm" lay-event="deletes">批量删除</button>
+        </div>
+    </script>
+
+    <form class="layui-form serch" action="index" method="post">
+        <div class="layui-form-item" style="float: left;">
+
+            <div class="layui-input-inline">
+                <input type="text" class="layui-input time_range" id="time_range_start_time" autocomplete="off"
+                       placeholder="排号日期" name="start_time">
+            </div>
+
+            <div class="layui-input-inline">
+                <input type="text" name="title" autocomplete="off" placeholder="服务名称(模糊搜索)"
+                       class="layui-input layui-btn-sm">
+            </div>
+
+            <div class="layui-input-inline">
+                <input type="text" class="layui-input time_range" id="time_range_create_time" autocomplete="off"
+                       placeholder="创建时间" name="create_time">
+            </div>
+            <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="serch">立即提交</button>
+        </div>
+    </form>
+
+    <script type="text/html" id="barDemo">
+        <div class="layui-btn-group">
+            <button class="layui-btn layui-btn-xs a_menu" lay-event="edit"><i class="layui-icon"
+                                                                              style="margin-right: 0;"></i></button>
+            <button class="layui-btn layui-btn-xs delete" lay-event="del"><i class="layui-icon"
+                                                                             style="margin-right: 0;"></i></button>
+        </div>
+    </script>
+
+    <table class="layui-table" id="table" lay-filter="table"></table>
+    {include file="public/foot"}
+
+    <script type="text/javascript">
+        layui.use(['table', 'layer', 'form', 'laydate'], function () {
+            var table = layui.table,
+                form = layui.form,
+                layer = layui.layer;
+            var laydate = layui.laydate;
+            //第一个实例
+            table.render({
+                id: 'table'
+                , elem: '#table'
+                , size: 'sm' //小尺寸的表格
+                , toolbar: '#toolbarDemo'
+                , limit: 15
+                , limits: [15, 20, 30, 40, 50, 100]
+                , url: "{:url('index',['pid'=>$Request.param.pid])}" //数据接口
+                , page: true //开启分页
+                , cols: [[ //表头
+                    {type: 'checkbox'},
+
+                    {field: 'id', title: 'ID', width: 60},
+                    {field: "start_time", title: '排号日期',templet:function (row) {
+                        return row.start_time + ' ~ ' + row.end_time;
+                    }},
+                    {field: "title", title: '服务名称'},
+                    {field: "provider_id", title: '服务人'},
+                    {field: "morning_num", title: '上午放号个数'},
+                    {field: "morning_start_time", title: 'morning_start_time'},
+                    {field: "morning_end_time", title: 'morning_end_time'},
+                    {field: "afternoon_num", title: '下午放号个数'},
+                    {field: "afternoon_start_time", title: 'afternoon_start_time'},
+                    {field: "afternoon_end_time", title: 'afternoon_end_time'},
+                    {field: "night_num", title: '晚上放号个数'},
+                    {field: "night_start_time", title: 'night_start_time'},
+                    {field: "night_end_time", title: 'night_end_time'},
+                    {field: "create_time", title: '创建时间'},
+                    {field: 'action', title: '操作', toolbar: '#barDemo', fixed: 'right'}
+                ]],
+                done: function () {
+                    if (isExitsFunction('showThumb')) {
+                        showThumb()
+                    }
+                }
+            });
+
+            laydate.render({
+                elem: '#time_range_start_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_start_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_end_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_end_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_morning_start_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_morning_start_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_morning_end_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_morning_end_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_afternoon_start_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_afternoon_start_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_afternoon_end_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_afternoon_end_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_night_start_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_night_start_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_night_end_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_night_end_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#time_range_create_time'
+                , type: 'datetime'
+                , range: true
+                , max: 0 //最大值0天后
+                , theme: 'molv'
+                , calendar: true
+                , done: function (value, date, endDate) {
+                    if (endDate.hours == 0 && endDate.minutes == 0 && endDate.seconds == 0) {
+                        setTimeout(function () {
+                            $('#time_range_create_time').val(value.replace(/00:00:00$/, '23:59:59'))
+                        }, 100)
+                    }
+                }
+            });
+
+            form.on('submit(serch)', function (data) {
+                table.reload('table', {
+                    where: data.field
+                    , page: {
+                        curr: 1 //重新从第 1 页开始
+                    }
+                });
+                return false;
+            });
+
+            table.on('tool(table)', function (obj) {
+                if (obj.event == 'edit') {
+                    location.href = "{:url('publish',['pid'=>$Request.param.pid])}?id=" + obj.data.id;
+                }
+                else if (obj.event == 'del') {
+                    layer.confirm('确定要删除?', function (index) {
+                        $.ajax({
+                            url: "{:url('delete')}",
+                            dataType: 'json',
+                            data: {id: obj.data.id},
+                            success: function (res) {
+                                layer.msg(res.msg);
+                                if (res.code == 1) {
+                                    table.reload('table');
+                                }
+                            }
+                        })
+                    })
+                }
+            });
+            //监听事件
+            table.on('toolbar(table)', function (obj) {
+                if (obj.event == 'deletes') {
+                    var checkStatus = table.checkStatus(obj.config.id);//获取选中的数据
+                    var data = checkStatus.data;
+                    if (data.length > 0) {
+                        var ids = [];//数组
+                        data.forEach(function (item, key) {
+                            ids[key] = item.id;
+                        })
+                        layer.confirm('是否删除?', function (index, layero) {
+                            $.ajax({
+                                url: "{:url('deletes')}",
+                                dataType: 'json',
+                                data: {"ids": ids},
+                                type: 'post',
+                                success: function (res) {
+                                    layer.msg(res.msg);
+                                    if (res.code == 1) {
+                                        table.reload('table');
+                                    }
+                                }
+                            })
+                            layer.close(index)
+                        });
+                    } else {
+                        layer.msg('请先勾选需要操作的记录');
+                    }
+                }
+            });
+        });
+    </script>
+
+
+</div>
+</body>
+</html>

+ 200 - 0
app/admin/view/appointment/publish.html

@@ -0,0 +1,200 @@
+<!DOCTYPE html>
+<html>
+<head>
+    <meta charset="utf-8">
+    <title>放号设置编辑</title>
+    <meta name="renderer" content="webkit">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+    <link rel="stylesheet" href="/static/public/layui/css/layui.css" media="all">
+    <link rel="stylesheet" href="/static/public/font-awesome/css/font-awesome.min.css" media="all"/>
+    <link rel="stylesheet" href="/static/admin/css/admin.css" media="all">
+    <script src="/static/public/layui/layui.js"></script>
+    <script src="/static/public/jquery/jquery.min.js"></script>
+</head>
+<style>
+    .layui-upload-img {
+        cursor: pointer;
+        width: 150px;
+        height: 150px;
+        background: url('/static/public/images/uploadimg.jpg');
+        background-size: contain;
+        border-radius: 2px;
+        border-width: 1px;
+        border-style: solid;
+        border-color: #e6e6e6;
+    }
+    .layui-form-label{
+        width: 90px;
+    }
+</style>
+<body style="padding:10px;">
+<div class="tplay-body-div">
+
+    {empty name="$data"}
+    <div class="layui-tab">
+        <ul class="layui-tab-title">
+            <li><a href="{:url('index',['pid'=>$Request.param.pid])}" class="a_menu">列表</a></li>
+            <li class="layui-this">新增</li>
+        </ul>
+    </div>
+    {/empty}
+
+    <div style="margin-top: 20px;"></div>
+    <form class="layui-form" id="publish" method="post">
+
+        <!-- 时间 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">排号日期跨度</label>
+            <div class="layui-input-inline" style="width:600px;">
+                <input name="start_time" id="start_time" autocomplete="off" placeholder="开始日期 - 结束日期" class="layui-input"
+                       type="text" {notempty name="$data" }value="{$data.start_time}" {/notempty}>
+            </div>
+        </div>
+
+
+        <!-- 数字 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">上午放号个数</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="morning_num" autocomplete="off" placeholder="请输入" class="layui-input" type="number"
+                       value="{notempty name="$data"}{$data.morning_num}{else/}20{/notempty}">
+            </div>
+            <div class="layui-form-mid">时段</div>
+            <div class="layui-input-inline" style="width:350px;">
+                <input name="morning_start_time" id="morning_start_time" autocomplete="off" placeholder="开始时间 - 结束时间"
+                       class="layui-input" type="text" {notempty name="$data" }value="{$data.morning_start_time}" {/notempty}>
+            </div>
+        </div>
+
+        <!-- 数字 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">下午放号个数</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="afternoon_num" autocomplete="off" placeholder="请输入" class="layui-input" type="number"
+                       value="{notempty name="$data"}{$data.afternoon_num}{else/}20{/notempty}">
+            </div>
+            <div class="layui-form-mid">时段</div>
+            <div class="layui-input-inline" style="width:350px;">
+                <input name="afternoon_start_time" id="afternoon_start_time" autocomplete="off" placeholder="开始时间 - 结束时间"
+                       class="layui-input" type="text" {notempty name="$data" }value="{$data.afternoon_start_time}" {/notempty}>
+            </div>
+        </div>
+        <!-- 数字 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">晚上放号个数</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="night_num" autocomplete="off" placeholder="请输入" class="layui-input" type="number"
+                       value="{notempty name="$data"}{$data.night_num}{else/}10{/notempty}">
+            </div>
+            <div class="layui-form-mid">时段</div>
+            <div class="layui-input-inline" style="width:350px;">
+                <input name="night_start_time" id="night_start_time" autocomplete="off" placeholder="开始时间 - 结束时间"
+                       class="layui-input" type="text" {notempty name="$data" }value="{$data.night_start_time}" {/notempty}>
+            </div>
+        </div>
+
+        <!-- 输入框 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">服务名称</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="title" autocomplete="off" placeholder="请输入" class="layui-input" type="text"
+                       value="{notempty name="$data"}{$data.title}{else/}咨询服务{/notempty}">
+            </div>
+        </div>
+        <!-- 输入框 -->
+        <div class="layui-form-item">
+            <label class="layui-form-label">咨询电话</label>
+            <div class="layui-input-inline" style="max-width:300px;">
+                <input name="phone" lay-verify="required" autocomplete="off" placeholder="请输入" class="layui-input"
+                       type="text" {notempty name="$data" }value="{$data.phone}" {/notempty}>
+            </div>
+            <div class="layui-form-mid layui-word-aux">必填</div>
+        </div>
+
+
+
+        <input type="hidden" name="pid" value="{$Request.param.pid}">
+
+        {notempty name="$data"}
+        <input type="hidden" name="id" value="{$data.id}">
+        {/notempty}
+
+        <div class="layui-form-item">
+            <div class="layui-input-block">
+                <button class="layui-btn" lay-submit lay-filter="admin">立即提交</button>
+                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
+            </div>
+        </div>
+    </form>
+
+    <script>
+        layui.use(['layer', 'form', 'laydate'], function () {
+            var layer = layui.layer,
+                $ = layui.jquery,
+                form = layui.form;
+            var laydate = layui.laydate;
+
+            $(window).on('load', function () {
+                form.on('submit(admin)', function (data) {
+                    $.ajax({
+                        url: "{:url('publish')}",
+                        data: $('#publish').serialize(),
+                        type: 'post',
+                        dataType: 'json',
+                        async: false,
+                        success: function (res) {
+                            if (res.code == 1) {
+                                layer.alert(res.msg, function (index) {
+                                    location.href = res.url + "?pid=" + res.data.pid;
+                                })
+                            } else {
+                                layer.msg(res.msg);
+                            }
+                        }
+                    })
+                    return false;
+                });
+
+
+                //日期范围
+                laydate.render({
+                    elem: '#start_time',
+                    range: true,
+                    type: 'datetime',
+                    theme: 'molv',
+                    mark: {
+                        '{:date("Y-m-d",time())}': '今天'
+                    },
+                    calendar: true,
+                    format:'yyyy年MM月dd',
+                    value:'{:date("Y年m月d",time())} - {:date("Y年m月d",strtotime("+ 8 days",time()))}'
+                });
+                laydate.render({
+                    elem: '#morning_start_time', //指定元素
+                    range: true,
+                    type: 'time',
+                    theme: 'molv',
+                    value:'08:00:00 - 12:00:00'
+                });
+                laydate.render({
+                    elem: '#afternoon_start_time', //指定元素
+                    range: true,
+                    type: 'time',
+                    theme: 'molv',
+                    value:'14:00:00 - 18:00:00'
+                });
+                laydate.render({
+                    elem: '#night_start_time', //指定元素
+                    range: true,
+                    type: 'time',
+                    theme: 'molv',
+                    value:'20:00:00 - 23:59:59'
+                });
+
+            });
+        });
+    </script>
+</div>
+</body>
+</html>

+ 2 - 1
app/admin/view/menu/index.html

@@ -146,11 +146,12 @@
             //弹出框
             //弹出框
             layer.open({
             layer.open({
                 type: 1,
                 type: 1,
-                title: '未添加的路由 (只有填上节点名称的才会添加路由)',
+                title: '未添加的路由 (只有填写了数据的,保存后才会添加上路由)',
                 area: ['1100px', '500px'],
                 area: ['1100px', '500px'],
                 id: 'layerDemo', //防止重复弹出
                 id: 'layerDemo', //防止重复弹出
                 content: fromobj,
                 content: fromobj,
                 btn: ['批量添加', '关闭'],
                 btn: ['批量添加', '关闭'],
+                maxmin: true,
                 btnAlign: 'c', //按钮居中
                 btnAlign: 'c', //按钮居中
                 yes: function (index, layero) {
                 yes: function (index, layero) {
                     var post_data = fromobj.serializeJson();
                     var post_data = fromobj.serializeJson();

+ 24 - 7
app/admin/view/specialist/index.html

@@ -63,8 +63,10 @@
             </div>
             </div>
             <div class="layui-input-inline" style="width: 100px">
             <div class="layui-input-inline" style="width: 100px">
                 <select name="sex" lay-search="">
                 <select name="sex" lay-search="">
-                    <option value="">sex</option>
-                    <option value="0">性别</option>
+                    <option value="">性别</option>
+                    <option value="0">未知</option>
+                    <option value="1">男</option>
+                    <option value="2">女</option>
                 </select>
                 </select>
             </div>
             </div>
             <div class="layui-input-inline">
             <div class="layui-input-inline">
@@ -75,9 +77,13 @@
                 <input type="text" name="consultation_direction" autocomplete="off" placeholder="咨询方向(模糊搜索)"
                 <input type="text" name="consultation_direction" autocomplete="off" placeholder="咨询方向(模糊搜索)"
                        class="layui-input layui-btn-sm">
                        class="layui-input layui-btn-sm">
             </div>
             </div>
-            <div class="layui-input-inline" style="width:100px">
-                <input type="number" name="address_id" autocomplete="off" placeholder="地址id"
-                       class="layui-input layui-btn-sm">
+            <div class="layui-input-inline" style="width: 100px">
+                <select name="address_id" lay-search="">
+                    <option value="">地址</option>
+                    {volist name="$addresslist" id="vo"}
+                    <option value="{$vo.id}">{$vo.title}</option>
+                    {/volist}
+                </select>
             </div>
             </div>
             <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="serch">立即提交</button>
             <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="serch">立即提交</button>
         </div>
         </div>
@@ -87,6 +93,7 @@
         <div class="layui-btn-group">
         <div class="layui-btn-group">
             <button class="layui-btn layui-btn-xs a_menu" lay-event="edit"><i class="layui-icon"
             <button class="layui-btn layui-btn-xs a_menu" lay-event="edit"><i class="layui-icon"
                                                                               style="margin-right: 0;"></i></button>
                                                                               style="margin-right: 0;"></i></button>
+            <button class="layui-btn layui-btn-xs a_menu" lay-event="edit_appointment">放号设置</button>
             <button class="layui-btn layui-btn-xs delete" lay-event="del"><i class="layui-icon"
             <button class="layui-btn layui-btn-xs delete" lay-event="del"><i class="layui-icon"
                                                                              style="margin-right: 0;"></i></button>
                                                                              style="margin-right: 0;"></i></button>
         </div>
         </div>
@@ -122,10 +129,10 @@
                         return (row.head_pic_url == '') ? '' : '<a href="' + row.head_pic_url + '" class="tooltip" target="_blank"><img src="' + row.head_pic_url + '"></a>';
                         return (row.head_pic_url == '') ? '' : '<a href="' + row.head_pic_url + '" class="tooltip" target="_blank"><img src="' + row.head_pic_url + '"></a>';
                     }
                     }
                     },
                     },
-                    {field: "sex", title: 'sex'},
+                    {field: "sex_text", title: '性别'},
                     {field: "desc", title: '简介'},
                     {field: "desc", title: '简介'},
                     {field: "consultation_direction", title: '咨询方向'},
                     {field: "consultation_direction", title: '咨询方向'},
-                    {field: "address_id", title: '地址id'},
+                    {field: "address_name", title: '地址'},
                     {field: 'action', title: '操作', toolbar: '#barDemo', fixed: 'right'}
                     {field: 'action', title: '操作', toolbar: '#barDemo', fixed: 'right'}
                 ]],
                 ]],
                 done: function () {
                 done: function () {
@@ -170,6 +177,16 @@
                         })
                         })
                     })
                     })
                 }
                 }
+                else if (obj.event == 'edit_appointment') {
+                    layer.open({
+                        type: 2,
+                        title: '放号设置 | ' + obj.data.name ,
+                        area: ['90%', '90%'],
+                        maxmin: true,
+                        id: 'layerDemo', //防止重复弹出
+                        content: "{:url('admin/appointment/index')}?pid=" + obj.data.id
+                    });
+                }
             });
             });
             //监听事件
             //监听事件
             table.on('toolbar(table)', function (obj) {
             table.on('toolbar(table)', function (obj) {

+ 19 - 12
app/admin/view/specialist/publish.html

@@ -44,17 +44,19 @@
         <div class="layui-form-item">
         <div class="layui-form-item">
             <label class="layui-form-label">名字</label>
             <label class="layui-form-label">名字</label>
             <div class="layui-input-inline" style="max-width:300px;">
             <div class="layui-input-inline" style="max-width:300px;">
-                <input name="name" autocomplete="off" placeholder="请输入" class="layui-input" type="text" {notempty
-                       name="$data" }value="{$data.name}" {/notempty}>
+                <input name="name" lay-verify="required" autocomplete="off" placeholder="请输入" class="layui-input"
+                       type="text" {notempty name="$data" }value="{$data.name}" {/notempty}>
             </div>
             </div>
+            <div class="layui-form-mid layui-word-aux">必填</div>
         </div>
         </div>
         <!-- 输入框 -->
         <!-- 输入框 -->
         <div class="layui-form-item">
         <div class="layui-form-item">
             <label class="layui-form-label">职称</label>
             <label class="layui-form-label">职称</label>
             <div class="layui-input-inline" style="max-width:300px;">
             <div class="layui-input-inline" style="max-width:300px;">
-                <input name="title" autocomplete="off" placeholder="请输入" class="layui-input" type="text" {notempty
-                       name="$data" }value="{$data.title}" {/notempty}>
+                <input name="title" lay-verify="required" autocomplete="off" placeholder="请输入" class="layui-input"
+                       type="text" {notempty name="$data" }value="{$data.title}" {/notempty}>
             </div>
             </div>
+            <div class="layui-form-mid layui-word-aux">必填</div>
         </div>
         </div>
         <!-- 图片 -->
         <!-- 图片 -->
         <div class="layui-upload">
         <div class="layui-upload">
@@ -66,15 +68,14 @@
                        value='{notempty name="$data.head_pic"}{$data.head_pic}{/notempty}'>
                        value='{notempty name="$data.head_pic"}{$data.head_pic}{/notempty}'>
             </div>
             </div>
         </div>
         </div>
-
         <!-- 单选框 -->
         <!-- 单选框 -->
         <div class="layui-form-item">
         <div class="layui-form-item">
-            <label class="layui-form-label">sex</label>
+            <label class="layui-form-label">性别</label>
             <div class="layui-input-block">
             <div class="layui-input-block">
-                <input type="radio" name="sex" value="0" title="女" {notempty name="$data" }{eq name="$data.sex"
-                       value="0" } checked {/eq}{/notempty}>
                 <input type="radio" name="sex" value="1" title="男" {notempty name="$data" }{eq name="$data.sex"
                 <input type="radio" name="sex" value="1" title="男" {notempty name="$data" }{eq name="$data.sex"
                        value="1" } checked {/eq}{/notempty}>
                        value="1" } checked {/eq}{/notempty}>
+                <input type="radio" name="sex" value="2" title="女" {notempty name="$data" }{eq name="$data.sex"
+                       value="2" } checked {/eq}{/notempty}>
             </div>
             </div>
         </div>
         </div>
         <!-- 纯文本段落 -->
         <!-- 纯文本段落 -->
@@ -91,12 +92,18 @@
                 <textarea name="consultation_direction" class="layui-textarea">{notempty name="$data"}{$data.consultation_direction}{/notempty}</textarea>
                 <textarea name="consultation_direction" class="layui-textarea">{notempty name="$data"}{$data.consultation_direction}{/notempty}</textarea>
             </div>
             </div>
         </div>
         </div>
-        <!-- 数字 -->
+        <!-- 下拉框 -->
         <div class="layui-form-item">
         <div class="layui-form-item">
-            <label class="layui-form-label">地址id</label>
+            <label class="layui-form-label">地址</label>
             <div class="layui-input-inline" style="max-width:300px;">
             <div class="layui-input-inline" style="max-width:300px;">
-                <input name="address_id" lay-verify="required" autocomplete="off" placeholder="请输入" class="layui-input"
-                       type="number" {notempty name="$data" }value="{$data.address_id}" {/notempty}>
+                <select name="address_id" lay-filter="" lay-search="" lay-verify="required">
+                    <option value="">请选择</option>
+                    {volist name="$addresslist" id="vo"}
+                    <option value="{$vo.id}"
+                            {notempty name="$data.address_id" }
+                            {eq name="$data.address_id" value="$vo.id" } selected="" {/eq}{/notempty}>{$vo.title}</option>
+                    {/volist}
+                </select>
             </div>
             </div>
             <div class="layui-form-mid layui-word-aux">必填</div>
             <div class="layui-form-mid layui-word-aux">必填</div>
         </div>
         </div>

+ 1 - 3
app/admin/view/webconfig/tab.html

@@ -1,12 +1,10 @@
 <div class="layui-tab">
 <div class="layui-tab">
     <ul class="layui-tab-title">
     <ul class="layui-tab-title">
+        <li {eq name="$Request.baseUrl" value=":url('admin/webconfig/index')"}class="layui-this"{/eq}><a href="{:url('admin/webconfig/index')}" class="a_menu">系统设置</a></li>
         <li {eq name="$Request.baseUrl" value=":url('admin/webconfig/appointmentConfig')"}class="layui-this"{/eq}><a href="{:url('admin/webconfig/appointmentConfig')}" class="a_menu">预约签到设置</a></li>
         <li {eq name="$Request.baseUrl" value=":url('admin/webconfig/appointmentConfig')"}class="layui-this"{/eq}><a href="{:url('admin/webconfig/appointmentConfig')}" class="a_menu">预约签到设置</a></li>
         <!--扩展配置-->
         <!--扩展配置-->
         {foreach $tabs as $tab}
         {foreach $tabs as $tab}
         <li {if condition="$Request.baseUrl==url('admin/config/indexWebconfig') && $Request.param.tab_id==$tab->id"}class="layui-this"{/if}><a href="{:url('admin/config/indexWebconfig')}?tab_id={$tab.id}" class="a_menu">{$tab.name}</a></li>
         <li {if condition="$Request.baseUrl==url('admin/config/indexWebconfig') && $Request.param.tab_id==$tab->id"}class="layui-this"{/if}><a href="{:url('admin/config/indexWebconfig')}?tab_id={$tab.id}" class="a_menu">{$tab.name}</a></li>
         {/foreach}
         {/foreach}
-        <li {eq name="$Request.baseUrl" value=":url('admin/webconfig/index')"}class="layui-this"{/eq}><a href="{:url('admin/webconfig/index')}" class="a_menu">系统设置</a></li>
-        <li {eq name="$Request.baseUrl" value=":url('admin/emailconfig/index')"}class="layui-this"{/eq}><a href="{:url('admin/emailconfig/index')}" class="a_menu">邮件配置</a></li>
-        <li {eq name="$Request.baseUrl" value=":url('admin/smsconfig/index')"}class="layui-this"{/eq}><a href="{:url('admin/smsconfig/index')}" class="a_menu">短信配置</a></li>
     </ul>
     </ul>
 </div>
 </div>

+ 5 - 5
app/api/controller/接口文档.md

@@ -106,17 +106,17 @@
     "msg": "查询成功",
     "msg": "查询成功",
     "time": "1682090806",
     "time": "1682090806",
     "data": {
     "data": {
-        "per_page": 20,
-        "current_page": 1,
-        "has_more": false,
-        "next_item": null,
+        "per_page": 20, //分页数
+        "current_page": 1,//当前页码
+        "has_more": false,//是否还有下一页
+        "next_item": null, //下一条数据
         "data": [
         "data": [
             {
             {
                 "id": 1,
                 "id": 1,
                 "name": "张站长", //姓名
                 "name": "张站长", //姓名
                 "title": "心里医生", //职称
                 "title": "心里医生", //职称
                 "head_pic": "6", //头像
                 "head_pic": "6", //头像
-                "sex": 1, //性别
+                "sex": 1, //性别:0未知 1男 2女
                 "desc": "心里医生",
                 "desc": "心里医生",
                 "consultation_direction": "心里医生",
                 "consultation_direction": "心里医生",
                 "address_id": 1
                 "address_id": 1

+ 21 - 0
app/common/model/Appointment.php

@@ -0,0 +1,21 @@
+<?php
+
+namespace app\common\model;
+
+use think\Model;
+
+class Appointment extends Model
+{
+    protected $updateTime = false;
+
+    public function getStartTimeAttr($value, $data)
+    {
+        return $value ? date('Y-m-d', $value) : '';
+    }
+
+    public function getEndTimeAttr($value, $data)
+    {
+        return $value ? date('Y-m-d', $value) : '';
+    }
+
+}

+ 22 - 0
app/common/model/Specialist.php

@@ -7,4 +7,26 @@ use think\Model;
 class Specialist extends Model
 class Specialist extends Model
 {
 {
     protected $autoWriteTimestamp = false;
     protected $autoWriteTimestamp = false;
+
+    const SEX_UNKNOW = 0;
+    const SEX_MAN = 1;
+    const SEX_WOMAN = 2;
+
+    const SEXS = [
+        self::SEX_UNKNOW => '未知',
+        self::SEX_MAN => '男',
+        self::SEX_WOMAN => '女'
+    ];
+
+    //sex_text
+    public function getSexTextAttr($value, $data)
+    {
+        return self::SEXS[$data['sex']]??'';
+    }
+
+    //关联地址
+    public function address()
+    {
+        return $this->belongsTo('Address');
+    }
 }
 }

+ 73 - 33
app/install/data/db.sql

@@ -16,13 +16,16 @@
 DROP TABLE IF EXISTS `tplay_address`;
 DROP TABLE IF EXISTS `tplay_address`;
 CREATE TABLE IF NOT EXISTS `tplay_address` (
 CREATE TABLE IF NOT EXISTS `tplay_address` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `id` int(11) NOT NULL AUTO_INCREMENT,
-  `title` varchar(50) NOT NULL DEFAULT '' COMMENT '标题',
-  `address` varchar(500) NOT NULL DEFAULT '' COMMENT '地址',
+  `title` varchar(50) NOT NULL DEFAULT '' COMMENT '地名',
+  `address` varchar(500) NOT NULL DEFAULT '' COMMENT '详细地址',
   PRIMARY KEY (`id`)
   PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='地址';
+) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='地址';
 
 
--- 正在导出表  appointment.tplay_address 的数据:~0 rows (大约)
+-- 正在导出表  appointment.tplay_address 的数据:~2 rows (大约)
 /*!40000 ALTER TABLE `tplay_address` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_address` DISABLE KEYS */;
+INSERT INTO `tplay_address` (`id`, `title`, `address`) VALUES
+	(1, '厦门曙光医院', '福建省厦门市湖里区金尚路127号'),
+	(2, '厦门前埔医院', '地址 : 福建省厦门市湖里区仙岳路3777号\r\n电话 : 0592-5262666');
 /*!40000 ALTER TABLE `tplay_address` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_address` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_admin 结构
 -- 导出  表 appointment.tplay_admin 结构
@@ -44,7 +47,7 @@ CREATE TABLE IF NOT EXISTS `tplay_admin` (
 -- 正在导出表  appointment.tplay_admin 的数据:~2 rows (大约)
 -- 正在导出表  appointment.tplay_admin 的数据:~2 rows (大约)
 /*!40000 ALTER TABLE `tplay_admin` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin` DISABLE KEYS */;
 INSERT INTO `tplay_admin` (`id`, `nickname`, `name`, `password`, `thumb`, `login_time`, `login_ip`, `admin_cate_id`, `create_time`, `update_time`) VALUES
 INSERT INTO `tplay_admin` (`id`, `nickname`, `name`, `password`, `thumb`, `login_time`, `login_ip`, `admin_cate_id`, `create_time`, `update_time`) VALUES
-	(1, 'Tplay', 'admin', 'ecb2702e5545cd163a63b128a2cc010c', 0, 1682058086, '127.0.0.1', 1, 1649328230, 1651808242),
+	(1, 'Tplay', 'admin', '535ddb89a52491f46128048e648bd418', 0, 1682139145, '127.0.0.1', 1, 1649328230, 1651808242),
 	(2, 'test', 'test', '582833c7a791bae18e77c4151efafc57', 6, 0, '', 2, 1682075579, 1682075579);
 	(2, 'test', 'test', '582833c7a791bae18e77c4151efafc57', 6, 0, '', 2, 1682075579, 1682075579);
 /*!40000 ALTER TABLE `tplay_admin` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin` ENABLE KEYS */;
 
 
@@ -63,7 +66,7 @@ CREATE TABLE IF NOT EXISTS `tplay_admin_cate` (
 -- 正在导出表  appointment.tplay_admin_cate 的数据:~2 rows (大约)
 -- 正在导出表  appointment.tplay_admin_cate 的数据:~2 rows (大约)
 /*!40000 ALTER TABLE `tplay_admin_cate` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_cate` DISABLE KEYS */;
 INSERT INTO `tplay_admin_cate` (`id`, `name`, `permissions`, `desc`, `create_time`, `update_time`) VALUES
 INSERT INTO `tplay_admin_cate` (`id`, `name`, `permissions`, `desc`, `create_time`, `update_time`) VALUES
-	(1, '超级管理员', '52,87,88,120,121,132,139,141,89,138,46,48,84,85,86,119,144,152,153,154,155,156,111,112,113,114,115,116,127,142,64,66,67,71,118,65,68,69,75,102,103,146,147,33,34,35,76,100,101,143,36,37,38,39,40,98,99,128,22,7,8,24,25,26,91,27,28,29,96,30,97,1,10,12,13,14,15,16,17,148,11,41,42,44,45,106,145,43,105,108,2,3,4,5,51,117,18,19,20,21,57,58,59,130,131,129,133,134,135,136,53,54,55,56,61,122,140,92,94,137,149,150,151,77,78,79,80,81,82,83,110', '', 1649328138, 1682006828),
+	(1, '超级管理员', '52,87,88,120,121,132,139,141,152,157,158,159,153,180,181,154,160,161,162,155,167,168,169,156,163,164,165,166,184,185,186,111,112,113,114,115,116,142,182,22,7,8,24,25,26,91,27,28,29,96,30,97,1,10,12,13,14,15,16,17,148,170,179,187,11,41,42,44,45,106,145,43,105,108,2,3,4,5,51,117,18,19,20,21,57,58,59,130,131,129,133,134,135,136,53,54,55,56,61,122,140,92,94,137,149,150,151,77,78,79,80,81,82,83,110', '', 1649328138, 1682147816),
 	(2, '测试', '52,87,88,120,121,132,139,141,152,153,154,155,156,111,112,113,114,115,116,142', '', 1682075047, 1682075310);
 	(2, '测试', '52,87,88,120,121,132,139,141,152,153,154,155,156,111,112,113,114,115,116,142', '', 1682075047, 1682075310);
 /*!40000 ALTER TABLE `tplay_admin_cate` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_cate` ENABLE KEYS */;
 
 
@@ -80,7 +83,7 @@ CREATE TABLE IF NOT EXISTS `tplay_admin_log` (
   PRIMARY KEY (`id`)
   PRIMARY KEY (`id`)
 ) ENGINE=InnoDB AUTO_INCREMENT=203 DEFAULT CHARSET=utf8 COMMENT='后台日志';
 ) ENGINE=InnoDB AUTO_INCREMENT=203 DEFAULT CHARSET=utf8 COMMENT='后台日志';
 
 
--- 正在导出表  appointment.tplay_admin_log 的数据:~163 rows (大约)
+-- 正在导出表  appointment.tplay_admin_log 的数据:~283 rows (大约)
 /*!40000 ALTER TABLE `tplay_admin_log` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_log` DISABLE KEYS */;
 INSERT INTO `tplay_admin_log` (`id`, `admin_menu_id`, `admin_id`, `ip`, `url`, `params`, `create_time`) VALUES
 INSERT INTO `tplay_admin_log` (`id`, `admin_menu_id`, `admin_id`, `ip`, `url`, `params`, `create_time`) VALUES
 	(1, 77, 1, '127.0.0.1', '/admin/databackup/index.html', '', 1682040980),
 	(1, 77, 1, '127.0.0.1', '/admin/databackup/index.html', '', 1682040980),
@@ -284,7 +287,7 @@ INSERT INTO `tplay_admin_log` (`id`, `admin_menu_id`, `admin_id`, `ip`, `url`, `
 	(199, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074382),
 	(199, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074382),
 	(200, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074389),
 	(200, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074389),
 	(201, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074499),
 	(201, 0, 1, '127.0.0.1', '/admin/webconfig/appointmentconfig.html', '', 1682074499),
-	(202, 11, 1, '127.0.0.1', '/admin/webconfig/publish.html', '上传附件:\\uploads\\admin\\article_content\\20230421\\ee2a2b125a3c174e11683530a931a69e.jpg', 1682074584);
+	(202, 11, 1, '127.0.0.1', '/admin/webconfig/publish.html', '上传附件:\\uploads\\admin\\article_content\\20230421\\ee2a2b125a3c174e11683530a931a69e.jpg 登录成功 登录成功', 1682074584);
 /*!40000 ALTER TABLE `tplay_admin_log` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_log` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_admin_menu 结构
 -- 导出  表 appointment.tplay_admin_menu 结构
@@ -309,9 +312,9 @@ CREATE TABLE IF NOT EXISTS `tplay_admin_menu` (
   KEY `module` (`module`) USING BTREE,
   KEY `module` (`module`) USING BTREE,
   KEY `controller` (`controller`) USING BTREE,
   KEY `controller` (`controller`) USING BTREE,
   KEY `function` (`function`) USING BTREE
   KEY `function` (`function`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=157 DEFAULT CHARSET=utf8 COMMENT='系统菜单表';
+) ENGINE=InnoDB AUTO_INCREMENT=188 DEFAULT CHARSET=utf8 COMMENT='系统菜单表';
 
 
--- 正在导出表  appointment.tplay_admin_menu 的数据:~128 rows (大约)
+-- 正在导出表  appointment.tplay_admin_menu 的数据:~165 rows (大约)
 /*!40000 ALTER TABLE `tplay_admin_menu` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_menu` DISABLE KEYS */;
 INSERT INTO `tplay_admin_menu` (`id`, `name`, `module`, `controller`, `function`, `parameter`, `description`, `is_display`, `type`, `pid`, `icon`, `is_open`, `orders`, `create_time`, `update_time`) VALUES
 INSERT INTO `tplay_admin_menu` (`id`, `name`, `module`, `controller`, `function`, `parameter`, `description`, `is_display`, `type`, `pid`, `icon`, `is_open`, `orders`, `create_time`, `update_time`) VALUES
 	(1, '系统', '', '', '', '', '系统设置。', 1, 1, 0, 'fa-cog', 0, 10, 0, 1581073013),
 	(1, '系统', '', '', '', '', '系统设置。', 1, 1, 0, 'fa-cog', 0, 10, 0, 1581073013),
@@ -341,7 +344,7 @@ INSERT INTO `tplay_admin_menu` (`id`, `name`, `module`, `controller`, `function`
 	(28, '新增/修改', 'admin', 'AdminCate', 'publish', '', '新增/修改权限组。', 2, 1, 27, '', 0, 0, 1516951483, 1516951483),
 	(28, '新增/修改', 'admin', 'AdminCate', 'publish', '', '新增/修改权限组。', 2, 1, 27, '', 0, 0, 1516951483, 1516951483),
 	(29, '删除', 'admin', 'AdminCate', 'delete', '', '删除权限组。', 2, 1, 27, '', 0, 0, 1516951515, 1516951515),
 	(29, '删除', 'admin', 'AdminCate', 'delete', '', '删除权限组。', 2, 1, 27, '', 0, 0, 1516951515, 1516951515),
 	(30, '操作日志', 'admin', 'AdminLog', 'index', '', '系统管理员操作日志。', 1, 1, 22, 'fa-pencil', 0, 0, 1516951754, 1681713740),
 	(30, '操作日志', 'admin', 'AdminLog', 'index', '', '系统管理员操作日志。', 1, 1, 22, 'fa-pencil', 0, 0, 1516951754, 1681713740),
-	(31, '内容', '', '', '', '', 'CMS 内容管理。', 1, 1, 0, 'fa-th-large', 1, 2, 1516952262, 1649318280),
+	(31, '内容', 'admin', '', '', '', 'CMS 内容管理。', 2, 2, 0, 'fa-th-large', 1, 2, 1516952262, 1682146898),
 	(33, '分类', 'admin', 'Articlecate', 'index', '', '文章分类管理。', 1, 1, 31, 'fa-tag', 0, 3, 1516952856, 1681701848),
 	(33, '分类', 'admin', 'Articlecate', 'index', '', '文章分类管理。', 1, 1, 31, 'fa-tag', 0, 3, 1516952856, 1681701848),
 	(34, '新增/修改', 'admin', 'Articlecate', 'publish', '', '新增/修改文章分类。', 2, 1, 33, 'fa-tag', 0, 0, 1516952896, 1681701873),
 	(34, '新增/修改', 'admin', 'Articlecate', 'publish', '', '新增/修改文章分类。', 2, 1, 33, 'fa-tag', 0, 0, 1516952896, 1681701873),
 	(35, '删除', 'admin', 'Articlecate', 'delete', '', '删除文章分类。', 2, 1, 33, 'fa-tag', 0, 0, 1516952942, 1681701879),
 	(35, '删除', 'admin', 'Articlecate', 'delete', '', '删除文章分类。', 2, 1, 33, 'fa-tag', 0, 0, 1516952942, 1681701879),
@@ -441,7 +444,38 @@ INSERT INTO `tplay_admin_menu` (`id`, `name`, `module`, `controller`, `function`
 	(153, '反馈管理', 'admin', 'Feedback', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1681986760, 1681986769),
 	(153, '反馈管理', 'admin', 'Feedback', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1681986760, 1681986769),
 	(154, '公告管理', 'admin', 'Announcement', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682005382, 1682005382),
 	(154, '公告管理', 'admin', 'Announcement', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682005382, 1682005382),
 	(155, '预约记录', 'admin', 'AppointmentApplication', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682006813, 1682006813),
 	(155, '预约记录', 'admin', 'AppointmentApplication', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682006813, 1682006813),
-	(156, '专家列表', 'admin', 'Specialist', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682006813, 1682006813);
+	(156, '专家列表', 'admin', 'Specialist', 'index', '', '', 1, 1, 52, 'fa-tag', 0, 0, 1682006813, 1682006813),
+	(157, '新增/修改', 'admin', 'Address', 'publish', '', '', 2, 1, 152, 'fa-tag', 0, 0, 1682145191, 1682145191),
+	(158, '删除', 'admin', 'Address', 'delete', '', '', 2, 1, 152, 'fa-tag', 0, 0, 1682145191, 1682145191),
+	(159, '批量删除', 'admin', 'Address', 'deletes', '', '', 2, 1, 152, 'fa-tag', 0, 0, 1682145191, 1682145191),
+	(160, '新增/修改', 'admin', 'Announcement', 'publish', '', '', 2, 1, 154, 'fa-tag', 0, 0, 1682145274, 1682145274),
+	(161, '删除', 'admin', 'Announcement', 'delete', '', '', 2, 1, 154, 'fa-tag', 0, 0, 1682145274, 1682145274),
+	(162, '批量删除', 'admin', 'Announcement', 'deletes', '', '', 2, 1, 154, 'fa-tag', 0, 0, 1682145274, 1682145274),
+	(163, '放号设置', 'admin', 'Appointment', 'index', '', '', 2, 1, 156, 'fa-tag', 0, 0, 1682145274, 1682145274),
+	(164, '新增/修改', 'admin', 'Appointment', 'publish', '', '', 2, 1, 163, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(165, '删除', 'admin', 'Appointment', 'delete', '', '', 2, 1, 163, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(166, '批量删除', 'admin', 'Appointment', 'deletes', '', '', 2, 1, 163, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(167, '新增/修改', 'admin', 'AppointmentApplication', 'publish', '', '', 2, 1, 155, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(168, '删除', 'admin', 'AppointmentApplication', 'delete', '', '', 2, 1, 155, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(169, '批量删', 'admin', 'AppointmentApplication', 'deletes', '', '', 2, 1, 155, 'fa-tag', 0, 0, 1682145347, 1682145347),
+	(170, '预约签到设置', 'admin', 'Webconfig', 'appointmentConfig', '', '', 2, 1, 10, 'fa-tag', 0, 0, 1682145426, 1682145426),
+	(171, '消息管理', 'admin', 'Tomessages', 'index', '', '', 2, 2, 87, 'fa-tag', 0, 0, 1682146722, 1682146722),
+	(172, '新增/修改', 'admin', 'Tomessages', 'publish', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146985),
+	(173, '系统消息', 'admin', 'Tomessages', 'sysmessage', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146852),
+	(174, '阅读状态', 'admin', 'Tomessages', 'look', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146852),
+	(175, '审核状态', 'admin', 'Tomessages', 'status', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146852),
+	(176, '删除', 'admin', 'Tomessages', 'delete', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146852),
+	(177, '批量删除', 'admin', 'Tomessages', 'deletes', '', '', 2, 1, 171, 'fa-tag', 0, 0, 1682146852, 1682146852),
+	(178, '积分记录', 'admin', 'PointLog', 'index', '', '', 2, 2, 87, 'fa-tag', 0, 0, 1682147077, 1682147782),
+	(179, '显示扩展配置', 'admin', 'Config', 'indexWebconfig', '', '', 2, 1, 10, 'fa-tag', 0, 0, 1682147237, 1682147858),
+	(180, '删除', 'admin', 'Feedback', 'delete', '', '', 2, 1, 153, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(181, '批量删除', 'admin', 'Feedback', 'deletes', '', '', 2, 1, 153, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(182, '发布远程', 'admin', 'FileManage', 'ftpCover', '', '', 2, 1, 111, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(183, '批量删除', 'admin', 'PointLog', 'deletes', '', '', 2, 1, 178, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(184, '新增/修改', 'admin', 'Specialist', 'publish', '', '', 2, 1, 156, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(185, '删除', 'admin', 'Specialist', 'delete', '', '', 2, 1, 156, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(186, '批量删除', 'admin', 'Specialist', 'deletes', '', '', 2, 1, 156, 'fa-tag', 0, 0, 1682147237, 1682147237),
+	(187, '编辑', 'admin', 'Config', 'publishWebconfig', '', '', 2, 1, 179, 'fa-tag', 0, 0, 1682147737, 1682147737);
 /*!40000 ALTER TABLE `tplay_admin_menu` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_admin_menu` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_announcement 结构
 -- 导出  表 appointment.tplay_announcement 结构
@@ -466,26 +500,30 @@ INSERT INTO `tplay_announcement` (`id`, `title`, `content`, `admin_id`, `create_
 DROP TABLE IF EXISTS `tplay_appointment`;
 DROP TABLE IF EXISTS `tplay_appointment`;
 CREATE TABLE IF NOT EXISTS `tplay_appointment` (
 CREATE TABLE IF NOT EXISTS `tplay_appointment` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `id` int(11) NOT NULL AUTO_INCREMENT,
-  `title` varchar(50) NOT NULL COMMENT '服务名称',
+  `title` varchar(50) NOT NULL DEFAULT '咨询服务' COMMENT '服务名称',
   `provider_id` int(11) NOT NULL COMMENT '服务人',
   `provider_id` int(11) NOT NULL COMMENT '服务人',
-  `phone` varchar(50) NOT NULL COMMENT '服务人电话',
-  `start_time` int(11) NOT NULL DEFAULT '0' COMMENT '预约时间',
-  `end_time` int(11) NOT NULL DEFAULT '0' COMMENT '预约时间',
+  `phone` varchar(50) NOT NULL COMMENT '咨询电话',
+  `start_time` int(11) NOT NULL DEFAULT '0' COMMENT '排号日期起始',
+  `end_time` int(11) NOT NULL DEFAULT '0' COMMENT '排号日期结束',
   `morning_num` int(11) NOT NULL DEFAULT '20' COMMENT '上午放号个数',
   `morning_num` int(11) NOT NULL DEFAULT '20' COMMENT '上午放号个数',
-  `morning_start_time` int(11) NOT NULL DEFAULT '20',
-  `morning_end_time` int(11) NOT NULL DEFAULT '20',
+  `morning_start_time` char(8) NOT NULL DEFAULT '08:00:00',
+  `morning_end_time` char(8) NOT NULL DEFAULT '12:00:00',
   `afternoon_num` int(11) NOT NULL DEFAULT '20' COMMENT '下午放号个数',
   `afternoon_num` int(11) NOT NULL DEFAULT '20' COMMENT '下午放号个数',
-  `afternoon_start_time` int(11) NOT NULL DEFAULT '20',
-  `afternoon_end_time` int(11) NOT NULL DEFAULT '20',
+  `afternoon_start_time` char(8) NOT NULL DEFAULT '14:00:00',
+  `afternoon_end_time` char(8) NOT NULL DEFAULT '18:00:00',
   `night_num` int(11) NOT NULL DEFAULT '10' COMMENT '晚上放号个数',
   `night_num` int(11) NOT NULL DEFAULT '10' COMMENT '晚上放号个数',
-  `night_start_time` int(11) NOT NULL DEFAULT '10',
-  `night_end_time` int(11) NOT NULL DEFAULT '10',
+  `night_start_time` char(8) NOT NULL DEFAULT '20:00:00',
+  `night_end_time` char(8) NOT NULL DEFAULT '23:59:59',
   `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
   `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
   PRIMARY KEY (`id`)
   PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='预约放号管理';
+) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8 COMMENT='放号设置';
 
 
--- 正在导出表  appointment.tplay_appointment 的数据:~0 rows (大约)
+-- 正在导出表  appointment.tplay_appointment 的数据:~1 rows (大约)
 /*!40000 ALTER TABLE `tplay_appointment` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_appointment` DISABLE KEYS */;
+INSERT INTO `tplay_appointment` (`id`, `title`, `provider_id`, `phone`, `start_time`, `end_time`, `morning_num`, `morning_start_time`, `morning_end_time`, `afternoon_num`, `afternoon_start_time`, `afternoon_end_time`, `night_num`, `night_start_time`, `night_end_time`, `create_time`) VALUES
+	(1, '咨询服务', 3, '12121', 1682092800, 1682784000, 11, '08:00:00', '12:00:00', 20, '14:00:00', '18:00:00', 10, '20:00:00', '23:59:59', 1682151842),
+	(2, '咨询服务', 3, '1111', 1682092800, 1682784000, 20, '08:00:00', '12:00:00', 20, '14:00:00', '18:00:00', 10, '20:00:00', '23:59:59', 1682154903),
+	(4, '心里咨询', 1, '11', 1682092800, 1682784000, 20, '08:00:00', '12:00:00', 20, '14:00:00', '18:00:00', 10, '20:00:00', '23:59:59', 1682155202);
 /*!40000 ALTER TABLE `tplay_appointment` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_appointment` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_appointment_application 结构
 -- 导出  表 appointment.tplay_appointment_application 结构
@@ -802,20 +840,22 @@ INSERT INTO `tplay_smsconfig` (`id`, `sms`, `appkey`, `secretkey`, `type`, `name
 DROP TABLE IF EXISTS `tplay_specialist`;
 DROP TABLE IF EXISTS `tplay_specialist`;
 CREATE TABLE IF NOT EXISTS `tplay_specialist` (
 CREATE TABLE IF NOT EXISTS `tplay_specialist` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `id` int(11) NOT NULL AUTO_INCREMENT,
-  `name` varchar(50) NOT NULL DEFAULT '' COMMENT '名字',
-  `title` varchar(50) NOT NULL DEFAULT '' COMMENT '职称',
+  `name` varchar(50) NOT NULL COMMENT '名字',
+  `title` varchar(50) NOT NULL COMMENT '职称',
   `head_pic` varchar(255) NOT NULL DEFAULT '' COMMENT '头像',
   `head_pic` varchar(255) NOT NULL DEFAULT '' COMMENT '头像',
-  `sex` tinyint(4) NOT NULL DEFAULT '0' COMMENT '性别',
+  `sex` tinyint(4) NOT NULL DEFAULT '0' COMMENT '性别:0未知,1男,2女',
   `desc` varchar(500) NOT NULL DEFAULT '' COMMENT '简介',
   `desc` varchar(500) NOT NULL DEFAULT '' COMMENT '简介',
   `consultation_direction` varchar(500) NOT NULL DEFAULT '' COMMENT '咨询方向',
   `consultation_direction` varchar(500) NOT NULL DEFAULT '' COMMENT '咨询方向',
-  `address_id` int(11) NOT NULL COMMENT '地址id',
+  `address_id` int(11) NOT NULL COMMENT '地址',
   PRIMARY KEY (`id`)
   PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT='专家';
+) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COMMENT='专家';
 
 
--- 正在导出表  appointment.tplay_specialist 的数据:~1 rows (大约)
+-- 正在导出表  appointment.tplay_specialist 的数据:~3 rows (大约)
 /*!40000 ALTER TABLE `tplay_specialist` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_specialist` DISABLE KEYS */;
 INSERT INTO `tplay_specialist` (`id`, `name`, `title`, `head_pic`, `sex`, `desc`, `consultation_direction`, `address_id`) VALUES
 INSERT INTO `tplay_specialist` (`id`, `name`, `title`, `head_pic`, `sex`, `desc`, `consultation_direction`, `address_id`) VALUES
-	(1, '张站长', '心里医生', '6', 1, '心里医生', '心里医生', 1);
+	(1, '张站长', '心里医生', '6', 2, '心里医生', '心里医生', 0),
+	(2, '李医生', '男科专家', '8', 1, '男科主任', '妇科病', 1),
+	(3, '王医生', '妇科大夫', '0', 0, '妇科大夫', '妇科大夫', 1);
 /*!40000 ALTER TABLE `tplay_specialist` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_specialist` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_urlconfig 结构
 -- 导出  表 appointment.tplay_urlconfig 结构
@@ -834,7 +874,7 @@ CREATE TABLE IF NOT EXISTS `tplay_urlconfig` (
 -- 正在导出表  appointment.tplay_urlconfig 的数据:~1 rows (大约)
 -- 正在导出表  appointment.tplay_urlconfig 的数据:~1 rows (大约)
 /*!40000 ALTER TABLE `tplay_urlconfig` DISABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_urlconfig` DISABLE KEYS */;
 INSERT INTO `tplay_urlconfig` (`id`, `aliases`, `url`, `desc`, `status`, `create_time`, `update_time`) VALUES
 INSERT INTO `tplay_urlconfig` (`id`, `aliases`, `url`, `desc`, `status`, `create_time`, `update_time`) VALUES
-	(1, 'admin_login', 'admin/common/login', '后台登录地址', 1, 1517621629, 1681894088);
+	(1, 'admin_login', 'admin/common/login', '后台登录地址', 1, 1517621629, 1682134751);
 /*!40000 ALTER TABLE `tplay_urlconfig` ENABLE KEYS */;
 /*!40000 ALTER TABLE `tplay_urlconfig` ENABLE KEYS */;
 
 
 -- 导出  表 appointment.tplay_user 结构
 -- 导出  表 appointment.tplay_user 结构
@@ -859,7 +899,7 @@ CREATE TABLE IF NOT EXISTS `tplay_user` (
   `login_time` int(11) NOT NULL COMMENT '最后登录时间',
   `login_time` int(11) NOT NULL COMMENT '最后登录时间',
   `openid` varchar(50) NOT NULL DEFAULT '',
   `openid` varchar(50) NOT NULL DEFAULT '',
   `unionid` varchar(50) NOT NULL DEFAULT '',
   `unionid` varchar(50) NOT NULL DEFAULT '',
-  `sex` tinyint(4) NOT NULL DEFAULT '0' COMMENT '0未知1男2女',
+  `sex` tinyint(4) NOT NULL DEFAULT '0' COMMENT '性别:0未知,1男,2女',
   `country` varchar(50) NOT NULL DEFAULT '' COMMENT '国家',
   `country` varchar(50) NOT NULL DEFAULT '' COMMENT '国家',
   `province` varchar(50) NOT NULL DEFAULT '' COMMENT '省份',
   `province` varchar(50) NOT NULL DEFAULT '' COMMENT '省份',
   `city` varchar(50) NOT NULL DEFAULT '' COMMENT '城市',
   `city` varchar(50) NOT NULL DEFAULT '' COMMENT '城市',