新增卡片策略播报埋点、去掉小智形象逻辑
This commit is contained in:
@@ -6,7 +6,7 @@ public enum LauncherCardRefreshType {
|
||||
Weather( "News", "weather", "天气" ),
|
||||
News( "NearRoads", "news", "新闻" ),
|
||||
NearRoads( "ExplorerWay", "nearRoads", "近路" ),
|
||||
// TrafficRestriction( "NearRoads", "trafficRestriction" ),
|
||||
TrafficRestriction( "NearRoads", "trafficRestriction", "限行" ),
|
||||
ExplorerWay( "OnlineCar", "friendAndPois", "道路事件" ),
|
||||
OnlineCar( "Weather", "friendAndPois", "车友" );
|
||||
|
||||
|
||||
@@ -33,6 +33,7 @@ import com.mogo.utils.storage.SharedPrefsMgr;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -455,6 +456,9 @@ class LauncherCardRefresher {
|
||||
if ( trafficRestriction == null || TextUtils.isEmpty( trafficRestriction.tts ) ) {
|
||||
continue;
|
||||
}
|
||||
final Map< String, Object > properties = new HashMap<>();
|
||||
properties.put( "type", LauncherCardRefreshType.TrafficRestriction.name() );
|
||||
MogoApisHandler.getInstance().getApis().getAnalyticsApi().track( "v2x_play", properties );
|
||||
speakTTS( trafficRestriction.tts, false );
|
||||
return;
|
||||
}
|
||||
@@ -618,6 +622,10 @@ class LauncherCardRefresher {
|
||||
*/
|
||||
private void writeNextLoadType( LauncherCardRefreshType type ) {
|
||||
SharedPrefsMgr.getInstance( mContext ).putString( KEY_LAST_LOAD_TTS_TYPE, type.getNext() );
|
||||
|
||||
final Map< String, Object > properties = new HashMap<>();
|
||||
properties.put( "type", type.name() );
|
||||
MogoApisHandler.getInstance().getApis().getAnalyticsApi().track( "v2x_play", properties );
|
||||
Logger.d( TAG, "本次播报:%s,下次播报:%s", type.name(), LauncherCardRefreshType.valueOf( type.getNext() ).name() );
|
||||
SharedPrefsMgr.getInstance( mContext ).putLong( KEY_LAST_LOAD_TTS_DATE, System.currentTimeMillis() );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user