Browse Source

添加push,跳转至我的页面

hy 3 years ago
parent
commit
9362e31269

+ 6 - 1
app/src/main/java/com/electric/chargingpile/jpush/PushMessageReceiver.java

1
package com.electric.chargingpile.jpush;
1
   package com.electric.chargingpile.jpush;
2
2
3
import android.app.Activity;
3
import android.app.Activity;
4
import android.content.Context;
4
import android.content.Context;
20
import com.electric.chargingpile.activity.MyWebViewActivity;
20
import com.electric.chargingpile.activity.MyWebViewActivity;
21
import com.electric.chargingpile.activity.RankingListActivity;
21
import com.electric.chargingpile.activity.RankingListActivity;
22
import com.electric.chargingpile.activity.UserCenterActivity;
22
import com.electric.chargingpile.activity.UserCenterActivity;
23
import com.electric.chargingpile.activity.UserInfoActivity;
23
import com.electric.chargingpile.application.MainApplication;
24
import com.electric.chargingpile.application.MainApplication;
24
import com.electric.chargingpile.data.ChargingShareBean;
25
import com.electric.chargingpile.data.ChargingShareBean;
25
import com.electric.chargingpile.util.DES3;
26
import com.electric.chargingpile.util.DES3;
197
            } catch (Exception e) {
198
            } catch (Exception e) {
198
                e.printStackTrace();
199
                e.printStackTrace();
199
            }
200
            }
201
        }else if ("PushUserInfo".equals(type) && MainApplication.isLogin()) {
202
            intent = new Intent(context, UserCenterActivity.class);
203
            intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);
204
            context.startActivity(intent);
200
        } else {
205
        } else {
201
            intent = new Intent(context, MainMapActivity.class);
206
            intent = new Intent(context, MainMapActivity.class);
202
            intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);
207
            intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);