| | |
| | | override fun isShowToast() = showToast |
| | | |
| | | override fun onError(code: Int, msg: String) { |
| | | if (code == 700||code == 401){//token无效 |
| | | if (code == 700||code == 401||code == 501){//token无效 |
| | | error(code,"登录已失效") |
| | | SPUtils.instance().remove(Const.User.TOKEN).remove(Const.User.USER_ID).apply() |
| | | // (activity.application as JkApplication).exit() |
| | |
| | | override fun isShowToast() = showToast |
| | | |
| | | override fun onError(code: Int, msg: String) { |
| | | if (code == 401){//token无效 |
| | | if (code == 401||code == 501){//token无效 |
| | | error(code,"登录已失效") |
| | | SPUtils.instance().remove(Const.User.TOKEN).remove(Const.User.USER_ID).apply() |
| | | // (fragment.activity!!.application as JkApplication).exit() |