|
@@ -0,0 +1,41 @@
|
|
|
+<?php
|
|
|
+
|
|
|
+namespace General\Services\Report;
|
|
|
+
|
|
|
+use General\Models\Report\ReportUserBindRecord;
|
|
|
+
|
|
|
+/**
|
|
|
+ * uc数据上报
|
|
|
+ */
|
|
|
+class QappUchcReport extends BaseReport
|
|
|
+{
|
|
|
+ public function __construct()
|
|
|
+ {
|
|
|
+ $this->charge_event_type = 69;
|
|
|
+ $this->register_event_type = 67;
|
|
|
+ $this->report_url = '';// 同callback参数
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ public function getRegisterQueryParams(ReportUserBindRecord $user): array
|
|
|
+ {
|
|
|
+ return [
|
|
|
+ 'callback' => $user->callback,
|
|
|
+ 'type' => $this->register_event_type,
|
|
|
+ 'event_time' => time() * 100,
|
|
|
+ 'source' => $user->source,
|
|
|
+ 'money' => 0,
|
|
|
+ ];
|
|
|
+ }
|
|
|
+
|
|
|
+ public function getChargeQueryParams(ReportUserBindRecord $user, float $amount): array
|
|
|
+ {
|
|
|
+ return [
|
|
|
+ 'callback' => $user->callback,
|
|
|
+ 'type' => $this->charge_event_type,
|
|
|
+ 'event_time' => time() * 100,
|
|
|
+ 'source' => $user->source,
|
|
|
+ 'money' => $amount,
|
|
|
+ ];
|
|
|
+ }
|
|
|
+}
|