public void onClick(View view) {
   switch (view.getId()) {
     case R.id.kp_button_cancel:
       this.f10989t = true;
       m14514h();
     case R.id.button_retry_cancel:
       if (this.f10993x) {
         Localytics.tagEvent("Cancelled booking_Cancel clicked");
         m14500a("cancel");
         return;
       }
       this.f10989t = true;
       this.f10979j.onBackPressed();
     case R.id.button_retry:
       if (Utils.m14909a(this.f10979j.getApplicationContext())) {
         Sherlock.m13334a("Ins KP ride booked");
         if (this.f10993x) {
           Localytics.tagEvent("Cancelled Booking_Retry clicked");
           m14500a("retry");
           return;
         }
         m14513g();
         return;
       }
       m14501a(Constants.CONNECTION_TIME_OUT_HEADER, Constants.NO_NETWORK_TEXT);
     default:
   }
 }
 private void m14519j() {
   if (m14538c()) {
     Localytics.tagEvent("AUTO request cancelled");
   } else {
     Localytics.tagEvent("KP request cancelled");
   }
 }
 private void m14530p() {
   Object hashMap = new HashMap();
   if (m14538c()) {
     hashMap.put("Cab category", "Auto");
     Localytics.tagEvent("AUTO confirmed");
     Apsalar.event("AUTO confirmed");
   } else {
     hashMap.put("Cab category", "KP");
     Localytics.tagEvent("KP confirmed");
     Apsalar.event("KP confirmed");
   }
   hashMap.put("Discount State", "No coupon");
   this.f10990u.m12859a("fb_mobile_purchase", hashMap);
 }
Esempio n. 4
0
 private void m13522b(String str) {
   if (this.f9624h.m13209c() != null && this.f9624h.m13209c().getCity() != null) {
     Map hashMap = new HashMap();
     hashMap.put("City name", this.f9624h.m13209c().getCity());
     hashMap.put("Action Taken", str);
     Localytics.tagEvent("Partial stock out popup", hashMap);
   }
 }
Esempio n. 5
0
 private void m13517a(String str) {
   if (this.f9624h.m13209c() != null && this.f9624h.m13209c().getCity() != null) {
     Map hashMap = new HashMap();
     hashMap.put("City name", this.f9624h.m13209c().getCity());
     hashMap.put("Action Taken", str);
     Localytics.tagEvent("Order Review Screen Viewed", hashMap);
   }
 }
Esempio n. 6
0
 private void m13512a(int i, String str) {
   if (this.f9624h.m13209c() != null && this.f9624h.m13209c().getCity() != null) {
     Map hashMap = new HashMap();
     hashMap.put("City name", this.f9624h.m13209c().getCity());
     hashMap.put("Units of Menu Item", String.valueOf(i));
     hashMap.put("Category", str);
     Localytics.tagEvent("Place Order clicked", hashMap);
   }
 }
Esempio n. 7
0
 private void m13531j() {
   this.f9638v.setText(
       String.format(
           getResources().getString(R.string.title_food_category),
           new Object[] {this.f9632p.getFoodCategory().getName()}));
   if (!(this.f9624h.m13209c() == null || this.f9624h.m13209c().getCity() == null)) {
     Object obj;
     Map hashMap = new HashMap();
     hashMap.put("City name", this.f9624h.m13209c().getCity());
     hashMap.put("Category", this.f9632p.getFoodCategory().getName());
     hashMap.put("Is Service Available", String.valueOf(m13554e()));
     String str = "Partial Stock Out";
     Iterator it = this.f9627k.iterator();
     int i = 0;
     while (it.hasNext()) {
       int i2;
       if (((bd) it.next()).getQuantity() > 0) {
         i2 = 1;
       } else {
         i2 = i;
       }
       i = i2;
     }
     if (i == 0) {
       obj = "Full Stock";
     } else if (i == this.f9627k.size()) {
       obj = "No Stock Out";
     } else {
       String str2 = str;
     }
     hashMap.put("Stockout", obj);
     Localytics.tagEvent("User Viewed Menu Screen", hashMap);
   }
   if (m13554e()) {
     m13551c(4);
     return;
   }
   try {
     Date parse = new SimpleDateFormat("HH:mm:ss").parse(this.f9632p.getStart_time());
     Date parse2 = new SimpleDateFormat("HH:mm:ss").parse(this.f9632p.getEnd_time());
     DateFormat simpleDateFormat = new SimpleDateFormat("hh:mm a");
     this.f9637u.setText(
         String.format(
             getResources().getString(R.string.no_service_text),
             new Object[] {
               this.f9632p.getFoodCategory().getName(),
               simpleDateFormat.format(parse),
               simpleDateFormat.format(parse2)
             }));
     m13551c(0);
   } catch (ParseException e) {
     e.printStackTrace();
   }
 }
Esempio n. 8
0
 public void onFailure(Throwable th) {
   OLog.m13310a("Failed to place food order", th);
   VolleyError volleyError = (VolleyError) th;
   this.f9590a.m13555f();
   Object obj = "Network Error";
   if (!(volleyError == null || volleyError.f464a == null)) {
     byte[] bArr = volleyError.f464a.f498b;
     if (bArr != null) {
       String str = "Other";
       String str2 = new String(bArr);
       try {
         bt btVar = (bt) new Gson().m12343a(str2, bt.class);
         bz bzVar = (bz) new Gson().m12343a(str2, bz.class);
         if (volleyError.f464a.f497a != HttpStatus.SC_UNPROCESSABLE_ENTITY
             || bzVar.getPartialItems() == null
             || bzVar.getPartialItems().isEmpty()) {
           HashMap hashMap = new HashMap();
           if (Utils.m14924g(this.f9590a.f9624h.m13209c().getCity())) {
             hashMap.put("Booking city", this.f9590a.f9624h.m13209c().getCity());
           } else {
             hashMap.put("Booking city", "NA");
           }
           Sherlock.m13338a(
               "Ins OFD order placed", "Failure", volleyError, btVar.getText(), true, hashMap);
           this.f9590a.m13518a(btVar.getHeader(), btVar.getText());
         } else {
           this.f9590a.m13521b(bzVar);
         }
         obj = str;
       } catch (Exception e) {
         String str3 = str;
       }
     }
   }
   if (this.f9590a.f9624h.m13209c() != null && this.f9590a.f9624h.m13209c().getCity() != null) {
     Map hashMap2 = new HashMap();
     hashMap2.put("City name", this.f9590a.f9624h.m13209c().getCity());
     hashMap2.put(Constants.BUNDLE_TYPE, obj);
     Localytics.tagEvent("OlaFood error message", hashMap2);
   }
 }
 private void m14517i() {
   Map hashMap = new HashMap();
   hashMap.put("Cancelled Reason", Ola.f11493j != null ? Ola.f11493j : Trace.NULL);
   Localytics.tagEvent("Driver Cancelled Booking", hashMap);
 }
 private void m14510f() {
   HashMap hashMap = new HashMap();
   hashMap.put("Local taxi category", this.f10980k);
   if (Utils.m14924g(this.f10991v)) {
     hashMap.put("Booking city", this.f10991v);
   } else {
     hashMap.put("Booking city", "NA");
   }
   Sherlock.m13342a("Ins KP ride booked", hashMap, null);
   if (getView() != null) {
     if (m14538c()) {
       Localytics.tagEvent("AUTO stock out");
     } else {
       Localytics.tagEvent("KP stock out");
     }
     getView().findViewById(R.id.layout_progress).setVisibility(8);
     View findViewById = getView().findViewById(R.id.layout_retry);
     findViewById.setVisibility(0);
     if (Ola.f11494k) {
       ((Button) getView().findViewById(R.id.button_retry_cancel)).setText("CANCEL");
       if (!this.f10994y) {
         ((Button) getView().findViewById(R.id.button_retry)).setClickable(false);
       }
     } else {
       ((Button) getView().findViewById(R.id.button_retry_cancel)).setText("OK");
       ((Button) getView().findViewById(R.id.button_retry)).setClickable(true);
     }
     if (Utils.m14909a(this.f10979j.getApplicationContext())) {
       TextView textView = (TextView) findViewById.findViewById(R.id.no_kp_text);
       TextView textView2 = (TextView) findViewById.findViewById(R.id.no_kp_sub_text);
       if (Ola.f11494k) {
         textView.setText("Booking Cancelled!");
         if (m14538c()) {
           textView2.setText(
               Ola.f11492i != null
                   ? Ola.f11492i
                   : "Regret to inform that driver cancelled the booking");
           return;
         } else {
           textView2.setText(
               Ola.f11492i != null
                   ? Ola.f11492i
                   : "Regret to inform that driver cancelled the booking");
           return;
         }
       } else if (m14538c()) {
         textView.setText("No Autos available\nnear you!");
         textView2.setText("How about choosing\nanother category?");
         return;
       } else {
         textView.setText("No Kaali Peelis\nnear you!");
         textView2.setText("How about choosing\nanother category?");
         return;
       }
     }
     ((TextView) findViewById.findViewById(R.id.no_kp_text))
         .setText("No internet connection available!");
     ((TextView) findViewById.findViewById(R.id.no_kp_sub_text))
         .setText("Please check your settings or try again later.");
   }
 }