diff --git a/application/common/Model/TaskMember.php b/application/common/Model/TaskMember.php index cd56595..5be1d01 100644 --- a/application/common/Model/TaskMember.php +++ b/application/common/Model/TaskMember.php @@ -35,7 +35,7 @@ class TaskMember extends CommonModel } $currentMember = getCurrentMember(); $taskExecutor = self::where(['is_executor' => 1, 'task_code' => $taskCode])->find(); //原执行者 - if ($taskExecutor['member_code'] == $memberCode) { + if ($taskExecutor && $taskExecutor['member_code'] == $memberCode) { //已经是本人 return true; } diff --git a/data/2.8.0/pearproject.sql b/data/2.8.0/pearproject.sql index c4c1b8d..16ebdec 100644 --- a/data/2.8.0/pearproject.sql +++ b/data/2.8.0/pearproject.sql @@ -5,7 +5,7 @@ Source Server Type : MySQL Source Server Version : 50726 Source Host : localhost:3306 - Source Schema : pearprojectpro + Source Schema : pearproject Target Server Type : MySQL Target Server Version : 50726 diff --git a/data/pearproject.sql b/data/pearproject.sql index c4c1b8d..16ebdec 100644 --- a/data/pearproject.sql +++ b/data/pearproject.sql @@ -5,7 +5,7 @@ Source Server Type : MySQL Source Server Version : 50726 Source Host : localhost:3306 - Source Schema : pearprojectpro + Source Schema : pearproject Target Server Type : MySQL Target Server Version : 50726 diff --git a/thinkphp/library/think/db/Query.php b/thinkphp/library/think/db/Query.php index 5b1785e..954c00c 100644 --- a/thinkphp/library/think/db/Query.php +++ b/thinkphp/library/think/db/Query.php @@ -565,7 +565,7 @@ class Query $seq = (ord(substr($type($value), 0, 1)) % $rule['num']) + 1; } else { // 按照字段的首字母的值分表 - $seq = (ord($value{0}) % $rule['num']) + 1; + $seq = (ord($value[0]) % $rule['num']) + 1; } } return $this->getTable() . '_' . $seq;