Browse Source

add timepa

wenweiwei 3 năm trước cách đây
mục cha
commit
58ad71f17e

+ 3 - 2
BFAnalyzeKit/Classes/BFBaseEventTrack.swift

@@ -189,12 +189,13 @@ public class BFBaseEventTrack: NSObject {
     //   - businessType: <#businessType description#>
     //   - targetUid: <#targetUid description#>
     //   - shareId: <#shareId description#>
-    public class func bf_shareReportUpload(url: String, isShareVideo: Bool = true, screenType _: Int = 1, videoId: String?, recommendId: String?, recommendLogVO: String?, flowPool: String?, abInfoData: String?, measureType: Int?, measureId: Int?, targetUid: Int?, shareId: String = "", playId: String?, wxOpenId: String?, businessType: String?, pageSource: String?, extParams: [String: Any]? = nil, commonParams: [String: Any]? = nil) {
+    public class func bf_shareReportUpload(url: String, isShareVideo: Bool = true, screenType _: Int = 1, videoId: String?, recommendId: String?, recommendLogVO: String?, flowPool: String?, abInfoData: String?, measureType: Int?, measureId: Int?, targetUid: Int?, shareId: String = "", playId: String?, wxOpenId: String?,rootPageTimestamp:Int64, businessType: String?, pageSource: String?, extParams: [String: Any]? = nil, commonParams: [String: Any]? = nil) {
         DispatchQueue.global().async {
-            var params: [String: Any] = ["type": isShareVideo ? "1" : "2", "videoId": videoId ?? "", "pageSource": pageSource ?? "", "playId": playId ?? "", "targetUid": targetUid ?? 0, "shareDepth": "0"]
+            var params: [String: Any] = ["type": isShareVideo ? "1" : "2", "videoId": videoId ?? "", "pageSource": pageSource ?? "", "playId": playId ?? "", "targetUid": targetUid ?? 0, "shareDepth": "0","rootPageTimestamp":rootPageTimestamp]
             if extParams != nil {
                 params["extParams"] = bf_dictionaryToJsonString(extParams!)
             }
+            params["eventData"] = bf_dictionaryToJsonString(["rootPageTimestamp":rootPageTimestamp])
             if measureType != nil {
                 params["measureType"] = measureType
             }

+ 2 - 2
BFAnalyzeKit/Classes/BFEventTrackAdaptor.swift

@@ -124,7 +124,7 @@ public class BFEventTrackAdaptor: NSObject {
     //   - businessType: <#businessType description#>
     //   - targetUid: <#targetUid description#>
     //   - shareId: <#shareId description#>
-    public class func shareReportUpload(isShareVideo: Bool = true, screenType: Int = 1, videoId: String, pageSource: PAGESOURCE, recommendId: String?, recommendLogVO: String?, flowPool: String?, abInfoData: String?, measureType: Int?, measureId: Int?, businessType: businessType?, targetUid: Int?, shareId: String = "", playId: String?, wxOpenId: String?, extParams: [String: Any]? = nil, commonParams: [String: Any]?) {
+    public class func shareReportUpload(isShareVideo: Bool = true, screenType: Int = 1, videoId: String, pageSource: PAGESOURCE, recommendId: String?, recommendLogVO: String?, flowPool: String?, abInfoData: String?, measureType: Int?, measureId: Int?, businessType: businessType?, targetUid: Int?, shareId: String = "", playId: String?, wxOpenId: String?,rootPageTimestamp:Int64, extParams: [String: Any]? = nil, commonParams: [String: Any]?) {
         DispatchQueue.global().async {
             var url: String = PQENVUtil.shared.longvideoapi
             switch screenType {
@@ -137,7 +137,7 @@ public class BFEventTrackAdaptor: NSObject {
             default:
                 break
             }
-            BFBaseEventTrack.bf_shareReportUpload(url: url, isShareVideo: isShareVideo, screenType: screenType, videoId: videoId, recommendId: recommendId, recommendLogVO: recommendLogVO, flowPool: flowPool, abInfoData: abInfoData, measureType: measureType, measureId: measureId, targetUid: targetUid, shareId: shareId, playId: playId, wxOpenId: wxOpenId, businessType: businessType?.rawValue, pageSource: pageSource.rawValue, extParams: extParams, commonParams: commonParams)
+            BFBaseEventTrack.bf_shareReportUpload(url: url, isShareVideo: isShareVideo, screenType: screenType, videoId: videoId, recommendId: recommendId, recommendLogVO: recommendLogVO, flowPool: flowPool, abInfoData: abInfoData, measureType: measureType, measureId: measureId, targetUid: targetUid, shareId: shareId, playId: playId, wxOpenId: wxOpenId,rootPageTimestamp:rootPageTimestamp, businessType: businessType?.rawValue, pageSource: pageSource.rawValue, extParams: extParams, commonParams: commonParams)
         }
     }