Skip to content

Commit

Permalink
解决wechat, message测试问题 #2923
Browse files Browse the repository at this point in the history
  • Loading branch information
twinh committed Feb 28, 2017
1 parent cde3afa commit 5facff6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions docs/AutoComplete.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?php

namespace plugins\message\docs {

/**
* @property \Miaoxing\Message\Service\Message $message
* @method \Miaoxing\Message\Service\Message|\Miaoxing\Message\Service\Message[] message()
Expand All @@ -11,6 +12,7 @@ class AutoComplete
}

namespace {

/**
* @return \plugins\message\docs\AutoComplete
*/
Expand Down
6 changes: 3 additions & 3 deletions src/Controller/Admin/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ public function indexAction($req)
));
}

default:
default:
return get_defined_vars();
}
}
Expand Down Expand Up @@ -167,11 +167,11 @@ public function sendAction($req, $res)
// 2. 获取当前用户,平台对象的微信账号,及API服务对象
$user = wei()->user()->findOneById($req['userId']);
switch (true) {
case $user['wechatOpenId'] :
case $user['wechatOpenId']:
$account = wei()->wechatAccount->getCurrentAccount();
break;

case $user['qqOpenId'] :
case $user['qqOpenId']:
$account = wei()->qqAccount->getCurrentAccount();
break;

Expand Down
2 changes: 1 addition & 1 deletion src/Service/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function beforeSave()
public function afterFind()
{
switch ($this['msgType']) {
case 'text' :
case 'text':
$this['content'] = nl2br($this['content']);
break;

Expand Down

0 comments on commit 5facff6

Please sign in to comment.