From 73c394ebe6e8704e78951532dbfde632f5847e8c Mon Sep 17 00:00:00 2001 From: vilson <545522390@qq.com> Date: Sun, 22 May 2022 10:49:25 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=86=E8=8A=82=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/common/Model/TaskMember.php | 2 +- data/2.8.0/pearproject.sql | 2 +- data/pearproject.sql | 2 +- thinkphp/library/think/db/Query.php | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) 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;