|
@@ -19,17 +19,15 @@ class processor extends queue\ILooper
|
|
|
foreach ($msg as $key => $params)
|
|
|
{
|
|
|
Log::record("start one", Log::DEBUG);
|
|
|
- $method = strtolower($key);
|
|
|
+ if(empty($params)) continue;
|
|
|
|
|
|
- $proxy = new proxy();
|
|
|
- if($method == 'add')
|
|
|
- {
|
|
|
- try {
|
|
|
+ try {
|
|
|
+ $method = strtolower($key);
|
|
|
+ $proxy = new proxy();
|
|
|
+ if($method == 'add')
|
|
|
+ {
|
|
|
$proxy->add($params);
|
|
|
- }
|
|
|
- catch (Exception $x) {
|
|
|
- Log::record($x->getMessage(),Log::ERR);
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
// go(function () use ($proxy,$params)
|
|
|
// {
|
|
@@ -40,16 +38,21 @@ class processor extends queue\ILooper
|
|
|
// Log::record($x->getMessage(),Log::ERR);
|
|
|
// }
|
|
|
// });
|
|
|
- }
|
|
|
- elseif($method == 'notify') {
|
|
|
+ }
|
|
|
+ elseif($method == 'notify') {
|
|
|
|
|
|
- }
|
|
|
- elseif($method == 'notify_mechant') {
|
|
|
+ }
|
|
|
+ elseif($method == 'notify_mechant') {
|
|
|
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ Log::record("Error msg",Log::DEBUG);
|
|
|
+ }
|
|
|
}
|
|
|
- else {
|
|
|
- Log::record("Error msg",Log::DEBUG);
|
|
|
+ catch (Exception $x) {
|
|
|
+ Log::record($x->getMessage(),Log::ERR);
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
}
|