| | |
| | | |
| | | import com.huawei.hms.support.api.push.PushReceiver; |
| | | import com.tejia.lijin.app.ShoppingApi; |
| | | import com.tejia.lijin.app.ShoppingApplication; |
| | | import com.tejia.lijin.app.util.user.UserUtil; |
| | | |
| | | import org.json.JSONObject; |
| | | |
| | |
| | | public void onToken(Context context, String s, Bundle bundle) { |
| | | super.onToken(context, s, bundle); |
| | | Log.e("eee", "onToken: " + s); |
| | | SharedPreferences sp = context.getSharedPreferences("user", Context.MODE_PRIVATE); |
| | | String uid = sp.getString("uid", ""); |
| | | |
| | | // String off_no = sp.getString("push_off_no", "false_01"); |
| | | // if (off_no.equals("true_01")) { |
| | | ShoppingApi.bindHMPush(context, s, uid, null); |
| | | ShoppingApi.bindHMPush(context, s, UserUtil.getUid(ShoppingApplication.application), null); |
| | | // } |
| | | mToken = s; |
| | | Intent intent = new Intent(); |