| | |
| | | import cn.sinata.xldutils.utils.ViewClickDelay.hash |
| | | import cn.sinata.xldutils.utils.ViewClickDelay.lastClickTime |
| | | import cn.sinata.xldutils.xldUtils |
| | | import com.google.gson.Gson |
| | | import com.okgoincar.base.MyApplication |
| | | import com.okgoincar.bean.OrderBean |
| | | import com.okgoincar.netUtls.Api |
| | | import com.okgoincar.netUtls.callNet |
| | | import com.okgoincar.netUtls.getMapByAny |
| | | import com.okgoincar.utils.Cache.CacheKey |
| | | import org.jetbrains.anko.internals.AnkoInternals |
| | | import java.lang.NumberFormatException |
| | |
| | | } |
| | | } |
| | | |
| | | interface Isyy{ |
| | | fun isYy(b:Boolean) |
| | | } |
| | | |
| | | fun calldetailOrderIsYy(context: Context,orderId:String,orderType:String,isyy: Isyy){ |
| | | var map = getMapByAny() |
| | | map["orderId"] = orderId |
| | | map["orderType"] = orderType |
| | | map["lat"] = MyApplication.getLocation().latitude |
| | | map["lon"] = MyApplication.getLocation().longitude |
| | | callNet(context, Api.queryPushOrder, map) { |
| | | val data = Gson().fromJson<OrderBean>(it, OrderBean::class.java).data |
| | | data?.let { |
| | | if(it.reservation != 2){ |
| | | isyy.isYy(true) |
| | | }else{ |
| | | isyy.isYy(false) |
| | | } |
| | | |
| | | } |
| | | } |
| | | } |
| | | |
| | | fun toast(s: String) { |
| | | Toast.makeText(MyApplication.appContext, s, Toast.LENGTH_SHORT).show() |
| | | } |