|
|
@@ -142,8 +142,8 @@ class pushNotice
|
|
|
$ups = new GTUps();
|
|
|
// $ups->setTransmission("ups Transmission");
|
|
|
$thirdNotification = new GTThirdNotification();
|
|
|
- $thirdNotification->setTitle("title".micro_time());
|
|
|
- $thirdNotification->setBody("body".micro_time());
|
|
|
+ $thirdNotification->setTitle("title".self::micro_time());
|
|
|
+ $thirdNotification->setBody("body".self::micro_time());
|
|
|
$thirdNotification->setClickType(GTThirdNotification::CLICK_TYPE_URL);
|
|
|
$thirdNotification->setIntent("intent:#Intent;component=你的包名/你要打开的 activity 全路径;S.parm1=value1;S.parm2=value2;end");
|
|
|
$thirdNotification->setUrl("http://docs.getui.com/getui/server/rest_v2/push/");
|
|
|
@@ -167,6 +167,13 @@ class pushNotice
|
|
|
Yii::info('push/single/cid: ' . json_encode($result));
|
|
|
}
|
|
|
|
|
|
+ public static function micro_time()
|
|
|
+ {
|
|
|
+ list($usec, $sec) = explode(" ", microtime());
|
|
|
+ $time = ($sec . substr($usec, 2, 3));
|
|
|
+ return $time;
|
|
|
+ }
|
|
|
+
|
|
|
// 执行cid单推
|
|
|
public static function newPush($cId, $title, $body)
|
|
|
{
|