mirror of
https://github.com/freeedcom/ai-codereviewer.git
synced 2025-06-30 21:04:16 +00:00
add project adins
This commit is contained in:
parent
ad06ac5505
commit
f8f85d679d
5299 changed files with 625430 additions and 0 deletions
|
@ -0,0 +1,30 @@
|
|||
package com.adins.mss.base.checkin;
|
||||
|
||||
import com.adins.mss.dao.LocationInfo;
|
||||
import com.adins.mss.foundation.http.MssRequestType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class JsonRequestAbsensi extends MssRequestType {
|
||||
@SerializedName("locationInfo")
|
||||
List<LocationInfo> locationInfo;
|
||||
@SerializedName("attd_address")
|
||||
String attd_address;
|
||||
|
||||
public String getAttd_address() {
|
||||
return this.attd_address;
|
||||
}
|
||||
|
||||
public void setAttd_address(String value) {
|
||||
this.attd_address = value;
|
||||
}
|
||||
|
||||
public List<LocationInfo> getLocationInfo() {
|
||||
return this.locationInfo;
|
||||
}
|
||||
|
||||
public void setLocationInfo(List<LocationInfo> value) {
|
||||
this.locationInfo = value;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,735 @@
|
|||
package com.adins.mss.base.todolist.form;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.os.AsyncTask;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
import android.os.Message;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentTransaction;
|
||||
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.AdapterView;
|
||||
import android.widget.AdapterView.OnItemClickListener;
|
||||
import android.widget.AdapterView.OnItemLongClickListener;
|
||||
import android.widget.ArrayAdapter;
|
||||
import android.widget.Filter;
|
||||
import android.widget.Filterable;
|
||||
import android.widget.GridView;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.R;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.base.dynamicform.CustomerFragment;
|
||||
import com.adins.mss.base.dynamicform.SurveyHeaderBean;
|
||||
import com.adins.mss.base.dynamicform.TaskManager;
|
||||
import com.adins.mss.base.mainmenu.MainMenuActivity;
|
||||
import com.adins.mss.base.todolist.ToDoList;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.dao.Scheme;
|
||||
import com.adins.mss.dao.TaskD;
|
||||
import com.adins.mss.dao.TaskH;
|
||||
import com.adins.mss.foundation.db.dataaccess.SchemeDataAccess;
|
||||
import com.adins.mss.foundation.db.dataaccess.TaskDDataAccess;
|
||||
import com.adins.mss.foundation.db.dataaccess.TaskHDataAccess;
|
||||
import com.adins.mss.foundation.dialog.NiftyDialogBuilder;
|
||||
import com.adins.mss.foundation.dialog.NiftyDialogBuilder_PL;
|
||||
import com.adins.mss.foundation.formatter.Tool;
|
||||
|
||||
import org.acra.ACRA;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
@SuppressLint("NewApi")
|
||||
public class StatusSectionFragment extends Fragment implements
|
||||
Filterable,
|
||||
OnItemClickListener, OnItemLongClickListener {
|
||||
|
||||
protected List<TaskH> listTaskH;
|
||||
public static ListHandler handler;
|
||||
private static boolean isStatusOpen = false;
|
||||
public ToDoList toDoList;
|
||||
public int searchType;
|
||||
public String searchContent;
|
||||
public ArrayAdapter<TaskH> statusListAdapter;
|
||||
LayoutInflater inflater;
|
||||
private GridView gridView;
|
||||
private SwipeRefreshLayout mSwipeRefreshLayout;
|
||||
|
||||
public StatusSectionFragment() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onViewCreated(View view, Bundle savedInstanceState) {
|
||||
gridView = (GridView) view
|
||||
.findViewById(R.id.gridStatus);
|
||||
List<SurveyHeaderBean> list = null;
|
||||
if (ToDoList.getListOfSurveyStatus() == null) {
|
||||
try {
|
||||
list = new ArrayList<SurveyHeaderBean>();
|
||||
for (TaskH h : listTaskH) {
|
||||
list.add(new SurveyHeaderBean(h));
|
||||
}
|
||||
ToDoList.setListOfSurveyStatus(list);
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
if (Global.IS_DEV) {
|
||||
e.printStackTrace();
|
||||
System.out.println("list failed");
|
||||
}
|
||||
ACRA.getErrorReporter().putCustomData("errorOnViewCreated", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnViewCreated", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat getList"));
|
||||
String[] msg = {getActivity().getString(R.string.msgConnectionFailed)};
|
||||
String alert = Tool.implode(msg, "\n");
|
||||
Toast.makeText(getActivity(), alert, Toast.LENGTH_LONG).show();
|
||||
getActivity().finish();
|
||||
}
|
||||
} else {
|
||||
list = ToDoList.getListOfSurveyStatus();
|
||||
}
|
||||
View view2 = view.findViewById(R.id.actionbar);
|
||||
String application = GlobalData.getSharedGlobalData().getAuditData().getApplication();
|
||||
if (Global.APPLICATION_ORDER.equalsIgnoreCase(application)) {
|
||||
view2.setVisibility(View.VISIBLE);
|
||||
RelativeLayout mainLayout = (RelativeLayout) view.findViewById(R.id.mainLayout);
|
||||
mainLayout.setBackgroundResource(R.drawable.bg_grayscale);
|
||||
} else if (Global.APPLICATION_SURVEY.equalsIgnoreCase(application)) {
|
||||
if (MainMenuActivity.mnTaskList != null)
|
||||
view2.setVisibility(View.GONE);
|
||||
else {
|
||||
view2.setVisibility(View.VISIBLE);
|
||||
RelativeLayout mainLayout = (RelativeLayout) view.findViewById(R.id.mainLayout);
|
||||
mainLayout.setBackgroundResource(R.drawable.bg_grayscale);
|
||||
}
|
||||
} else {
|
||||
view2.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity().getApplicationContext(), listTaskH);
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
|
||||
gridView.setOnItemClickListener(this);
|
||||
gridView.setOnItemLongClickListener(this);
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
ACRA.getErrorReporter().putCustomData("errorOnViewCreated", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnViewCreated", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set Drawer"));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPause() {
|
||||
super.onPause();
|
||||
isStatusOpen = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroy() {
|
||||
super.onDestroy();
|
||||
isStatusOpen = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onResume() {
|
||||
super.onResume();
|
||||
isStatusOpen = true;
|
||||
if (Global.APPLICATION_ORDER.equalsIgnoreCase(GlobalData.getSharedGlobalData().getAuditData().getApplication())) {
|
||||
getActivity().getActionBar().setTitle(getActivity().getString(R.string.title_mn_tasklist));
|
||||
} else if (Global.APPLICATION_SURVEY.equalsIgnoreCase(GlobalData.getSharedGlobalData().getAuditData().getApplication())) {
|
||||
if (MainMenuActivity.mnTaskList == null) {
|
||||
getActivity().getActionBar().setTitle("Status Task");
|
||||
}
|
||||
}
|
||||
if (toDoList == null) toDoList = new ToDoList(getActivity());
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
List<SurveyHeaderBean> list = new ArrayList<SurveyHeaderBean>();
|
||||
for (TaskH h : listTaskH) {
|
||||
list.add(new SurveyHeaderBean(h));
|
||||
}
|
||||
ToDoList.setListOfSurveyStatus(list);
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity().getApplicationContext(), listTaskH);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
try {
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set Drawer"));
|
||||
}
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set Drawer"));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
toDoList = new ToDoList(getActivity().getApplicationContext());
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
|
||||
this.inflater = inflater;
|
||||
handler = new ListHandler();
|
||||
View rootView = inflater.inflate(
|
||||
R.layout.status_layout, container, false);
|
||||
mSwipeRefreshLayout = (SwipeRefreshLayout) rootView.findViewById(R.id.swiperefresh);
|
||||
|
||||
// BEGIN_INCLUDE (change_colors)
|
||||
// Set the color scheme of the SwipeRefreshLayout by providing 4 color resource ids
|
||||
mSwipeRefreshLayout.setColorSchemeColors(
|
||||
getResources().getColor(R.color.tv_light),
|
||||
getResources().getColor(R.color.tv_normal),
|
||||
getResources().getColor(R.color.tv_gray),
|
||||
getResources().getColor(R.color.tv_darker));
|
||||
|
||||
mSwipeRefreshLayout.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() {
|
||||
@Override
|
||||
public void onRefresh() {
|
||||
|
||||
initiateRefresh();
|
||||
}
|
||||
});
|
||||
return rootView;
|
||||
}
|
||||
|
||||
private void initiateRefresh() {
|
||||
new RefreshBackgroundTask().executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
|
||||
}
|
||||
|
||||
private void onRefreshComplete(List<TaskH> result) {
|
||||
// Remove all items from the ListAdapter, and then replace them with the new items
|
||||
try {
|
||||
statusListAdapter.clear();
|
||||
for (TaskH taskH : result) {
|
||||
statusListAdapter.add(taskH);
|
||||
}
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
} catch (UnsupportedOperationException e) {
|
||||
try {
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity().getApplicationContext(), listTaskH);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
} catch (Exception e2) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefreshComplete", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefreshComplete", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat notify Data Set Changed"));
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
try {
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity().getApplicationContext(), listTaskH);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
} catch (Exception e2) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefreshComplete", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefreshComplete", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat notify Data Set Changed"));
|
||||
}
|
||||
}
|
||||
// Stop the refreshing indicator
|
||||
if (mSwipeRefreshLayout != null && mSwipeRefreshLayout.isRefreshing())
|
||||
mSwipeRefreshLayout.setRefreshing(false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Filter getFilter() {
|
||||
return new Filter() {
|
||||
@Override
|
||||
protected FilterResults performFiltering(CharSequence constraint) {
|
||||
FilterResults result = new FilterResults();
|
||||
if (constraint.length() == 0) {
|
||||
result.count = 0;
|
||||
result.values = null;
|
||||
return result;
|
||||
}
|
||||
listTaskH = toDoList.getListTaskInStatus(ToDoList.SEARCH_BY_ALL, (String) constraint);
|
||||
result.values = listTaskH;
|
||||
result.count = listTaskH.size();
|
||||
searchType = ToDoList.SEARCH_BY_ALL;
|
||||
searchContent = (String) constraint;
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void publishResults(CharSequence constraint, FilterResults results) {
|
||||
if (results.count != 0) {
|
||||
List<SurveyHeaderBean> list = new ArrayList<SurveyHeaderBean>();
|
||||
for (TaskH h : ((List<TaskH>) results.values)) {
|
||||
list.add(new SurveyHeaderBean(h));
|
||||
}
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity(), listTaskH);
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
} else {
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
}
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setUserVisibleHint(boolean isVisibleToUser) {
|
||||
super.setUserVisibleHint(isVisibleToUser);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDetach() {
|
||||
super.onDetach();
|
||||
isStatusOpen = false;
|
||||
try {
|
||||
Field childFragmentManager = Fragment.class.getDeclaredField("mChildFragmentManager");
|
||||
childFragmentManager.setAccessible(true);
|
||||
childFragmentManager.set(this, null);
|
||||
} catch (NoSuchFieldException e) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnDetach", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnDetach", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set FragmentDeclared, NoSuchFieldExcp"));
|
||||
throw new RuntimeException(e);
|
||||
} catch (IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnDetach", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnDetach", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set FragmentDeclared, IllegalAccess"));
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public void updateListItem() {
|
||||
try {
|
||||
if (statusListAdapter != null) {
|
||||
statusListAdapter.clear();
|
||||
if (ToDoList.getListOfSurveyStatus() != null &&
|
||||
ToDoList.getListOfSurveyStatus().size() > 0) {
|
||||
for (SurveyHeaderBean bean : ToDoList.getListOfSurveyStatus()) {
|
||||
statusListAdapter.add(bean);
|
||||
}
|
||||
}
|
||||
if (gridView != null) {
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
initiateRefresh();
|
||||
}
|
||||
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
try {
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
} catch (Exception e2) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorUpdateListItem", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorUpdateListItem", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat notify data set changed"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onItemClick(AdapterView<?> parent, View v, int position, long id) {
|
||||
if (position < listTaskH.size()) {
|
||||
TaskH item = listTaskH.get(position);
|
||||
|
||||
try {
|
||||
Scheme scheme = null;
|
||||
scheme = item.getScheme();
|
||||
if (scheme == null) {
|
||||
if (item.getUuid_scheme() != null) {
|
||||
scheme = SchemeDataAccess.getOne(getActivity(),
|
||||
item.getUuid_scheme());
|
||||
if (scheme != null)
|
||||
item.setScheme(scheme);
|
||||
}
|
||||
}
|
||||
|
||||
if (scheme == null) {
|
||||
Toast.makeText(getActivity(),
|
||||
getActivity().getString(R.string.task_cant_seen),
|
||||
Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
SurveyHeaderBean header = new SurveyHeaderBean(item);
|
||||
CustomerFragment fragment = CustomerFragment.create(header);
|
||||
FragmentTransaction transaction = MainMenuActivity.fragmentManager.beginTransaction();
|
||||
transaction.setCustomAnimations(R.anim.activity_open_translate, R.anim.activity_close_scale, R.anim.activity_open_scale, R.anim.activity_close_translate);
|
||||
transaction.replace(R.id.content_frame, fragment);
|
||||
transaction.addToBackStack(null);
|
||||
transaction.commit();
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
Toast.makeText(
|
||||
getActivity(),
|
||||
getActivity().getString(R.string.scheme_gone)
|
||||
+ e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat event on Click, check Scheme"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onItemLongClick(AdapterView<?> parent, View v,
|
||||
int position, long id) {
|
||||
try {
|
||||
TaskH item = ToDoList.getListOfSurveyStatus().get(position);
|
||||
} catch (IndexOutOfBoundsException e) {
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
List<SurveyHeaderBean> list = new ArrayList<SurveyHeaderBean>();
|
||||
for (TaskH h : listTaskH) {
|
||||
list.add(new SurveyHeaderBean(h));
|
||||
}
|
||||
ToDoList.setListOfSurveyStatus(null);
|
||||
ToDoList.setListOfSurveyStatus(list);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat event onLongClick"));
|
||||
}
|
||||
try {
|
||||
final TaskH item = ToDoList.getListOfSurveyStatus().get(position);
|
||||
if (item.getStatus().equals(TaskHDataAccess.STATUS_SEND_UPLOADING)) {
|
||||
try {
|
||||
final NiftyDialogBuilder dialogBuilder = NiftyDialogBuilder.getInstance(getActivity());
|
||||
dialogBuilder.withTitle(getActivity().getString(R.string.info_capital))
|
||||
.withMessage(getActivity().getString(R.string.confirm_upload) + " " + item.getCustomer_name() + " ?")
|
||||
.withButton1Text(getActivity().getString(R.string.btnYes))
|
||||
.withButton2Text(getActivity().getString(R.string.btnCancel))
|
||||
.setButton1Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View arg0) {
|
||||
dialogBuilder.dismiss();
|
||||
if (Tool.isInternetconnected(getActivity())) {
|
||||
if (Global.isIsUploading() || Global.isIsManualUploading()) {
|
||||
Toast.makeText(getActivity(), getActivity().getString(R.string.upload_on_queue), Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
try {
|
||||
List<TaskD> taskd = TaskDDataAccess.getUnsentImageByTaskH(getActivity(), item.getUuid_user(), item.getUuid_task_h());
|
||||
TaskManager.ManualUploadImage(getActivity(), taskd);
|
||||
for (int i = 1; i < getActivity().getSupportFragmentManager().getBackStackEntryCount(); i++)
|
||||
getActivity().getSupportFragmentManager().popBackStack();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
Toast.makeText(getActivity(), getActivity().getString(R.string.request_error), Toast.LENGTH_SHORT).show();
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat event onLongClick"));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(getActivity(), getActivity().getString(R.string.no_internet_connection), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
if (StatusSectionFragment.handler != null)
|
||||
StatusSectionFragment.handler.sendEmptyMessage(0);
|
||||
}
|
||||
})
|
||||
.setButton2Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
dialogBuilder.dismiss();
|
||||
}
|
||||
})
|
||||
.show();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat event onLongClick"));
|
||||
}
|
||||
} else if (item.getStatus().equals(TaskHDataAccess.STATUS_SEND_PENDING)) {
|
||||
String btnText1 = getActivity().getString(R.string.btnSend);
|
||||
if (item.getIs_prepocessed() != null && item.getIs_prepocessed().equals(Global.FORM_TYPE_VERIFICATION))
|
||||
btnText1 = "Verify";
|
||||
final NiftyDialogBuilder_PL dialogBuilder = NiftyDialogBuilder_PL.getInstance(getActivity());
|
||||
dialogBuilder.withNoTitle()
|
||||
.withNoMessage()
|
||||
.withButton1Text(btnText1)
|
||||
.withButton2Text(getActivity().getString(R.string.btnDelete))
|
||||
.setButton1Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View arg0) {
|
||||
dialogBuilder.dismiss();
|
||||
if (Tool.isInternetconnected(getActivity())) {
|
||||
if (item.getTask_id() != null) {
|
||||
new TaskManager().saveAndSendTaskOnBackground(getActivity(), item.getTask_id(), false, false);
|
||||
|
||||
for (int i = 1; i < getActivity().getSupportFragmentManager().getBackStackEntryCount(); i++)
|
||||
getActivity().getSupportFragmentManager().popBackStack();
|
||||
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set DrawerCounter"));
|
||||
}
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity(), listTaskH);
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat notifyDataSetChanged"));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(getActivity(), getActivity().getString(R.string.no_internet_connection), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
})
|
||||
.setButton2Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
TaskHDataAccess.deleteWithRelation(getActivity(), item);
|
||||
if (item.getTask_id() != null)
|
||||
ToDoList.removeSurveyFromList(item.getTask_id());
|
||||
if (StatusSectionFragment.handler != null)
|
||||
StatusSectionFragment.handler.sendEmptyMessage(0);
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity(), listTaskH);
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
Handler handler = new Handler(Looper.getMainLooper());
|
||||
handler.post(new Runnable() {
|
||||
public void run() {
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set DrawerCounter"));
|
||||
}
|
||||
}
|
||||
});
|
||||
dialogBuilder.dismiss();
|
||||
}
|
||||
}).show();
|
||||
} else {
|
||||
final NiftyDialogBuilder dialogBuilder = NiftyDialogBuilder.getInstance(getActivity());
|
||||
dialogBuilder.withTitle(getActivity().getString(R.string.info_capital))
|
||||
.withMessage(getActivity().getString(R.string.confirm_delete) + " " + item.getCustomer_name() + " ?")
|
||||
.withButton1Text(getActivity().getString(R.string.btnYes))
|
||||
.withButton2Text(getActivity().getString(R.string.btnCancel))
|
||||
.setButton1Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View arg0) {
|
||||
TaskHDataAccess.deleteWithRelation(getActivity(), item);
|
||||
ToDoList.removeSurveyFromList(item.getTask_id());
|
||||
if (StatusSectionFragment.handler != null)
|
||||
StatusSectionFragment.handler.sendEmptyMessage(0);
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
statusListAdapter = new StatusArrayAdapter(getActivity(), listTaskH);
|
||||
gridView.setAdapter(statusListAdapter);
|
||||
statusListAdapter.notifyDataSetChanged();
|
||||
dialogBuilder.dismiss();
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set DrawerCounter"));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
})
|
||||
.setButton2Click(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
dialogBuilder.dismiss();
|
||||
}
|
||||
})
|
||||
.show();
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnItemLongClick", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat get item"));
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
private class RefreshBackgroundTask extends AsyncTask<Void, Void, List<TaskH>> {
|
||||
|
||||
static final int TASK_DURATION = 2 * 1000; // 2 seconds
|
||||
|
||||
@Override
|
||||
protected List<TaskH> doInBackground(Void... params) {
|
||||
// Sleep for a small amount of time to simulate a background-task
|
||||
try {
|
||||
Thread.sleep(TASK_DURATION);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefresh", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnRefresh", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat Thread.sleep"));
|
||||
}
|
||||
listTaskH = toDoList.getListTaskInStatus(searchType, searchContent);
|
||||
List<SurveyHeaderBean> list = new ArrayList<SurveyHeaderBean>();
|
||||
for (TaskH h : listTaskH) {
|
||||
list.add(new SurveyHeaderBean(h));
|
||||
}
|
||||
ToDoList.setListOfSurveyStatus(null);
|
||||
ToDoList.setListOfSurveyStatus(list);
|
||||
|
||||
// Return a new random list of cheeses
|
||||
return listTaskH;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPostExecute(List<TaskH> result) {
|
||||
super.onPostExecute(result);
|
||||
try {
|
||||
MainMenuActivity.setDrawerCounter();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorOnResume", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat set Drawer"));
|
||||
}
|
||||
onRefreshComplete(result);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public class StatusArrayAdapter extends ArrayAdapter<TaskH> {
|
||||
|
||||
|
||||
private Context mContext;
|
||||
private List<TaskH> list;
|
||||
|
||||
// references to our images
|
||||
public StatusArrayAdapter(Context context,
|
||||
List<TaskH> list) {
|
||||
super(context, R.layout.status_item_layout, list);
|
||||
mContext = context;
|
||||
this.list = list;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCount() {
|
||||
return list.size();
|
||||
}
|
||||
|
||||
@Override
|
||||
public SurveyHeaderBean getItem(int position) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getItemId(int position) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public View getView(int position, View convertView, ViewGroup parent) {
|
||||
View v = convertView;
|
||||
if (v == null) v = inflater.inflate(R.layout.status_item_layout, null);
|
||||
try {
|
||||
ImageView imgStatus = (ImageView) v.findViewById(R.id.imgStatus);
|
||||
TextView txtId = (TextView) v.findViewById(R.id.txtTaskID);
|
||||
TextView txtName = (TextView) v.findViewById(R.id.txtName);
|
||||
TextView txtDate = (TextView) v.findViewById(R.id.txtDate);
|
||||
TextView txtStatus = (TextView) v.findViewById(R.id.txtStatusTask);
|
||||
TextView txtScheme = (TextView) v.findViewById(R.id.txtScheme);
|
||||
TaskH bean = list.get(position);
|
||||
if (TaskHDataAccess.STATUS_SEND_PENDING.equals(bean.getStatus())) {
|
||||
imgStatus.setImageResource(R.drawable.ic_pending);
|
||||
} else if (TaskHDataAccess.STATUS_SEND_SAVEDRAFT.equals(bean.getStatus())) {
|
||||
imgStatus.setImageResource(R.drawable.ic_save_status);
|
||||
} else if (TaskHDataAccess.STATUS_SEND_UPLOADING.equals(bean.getStatus())) {
|
||||
imgStatus.setImageResource(R.drawable.ic_uploading);
|
||||
}
|
||||
txtId.setText(bean.getTask_id());
|
||||
txtName.setText(bean.getCustomer_name());
|
||||
txtStatus.setText(bean.getStatus());
|
||||
if (bean.getScheme() != null)
|
||||
txtScheme.setText(bean.getScheme().getForm_id());
|
||||
// bong 6 apr 15 - add txtDate below txtname
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yy - HH:mm");
|
||||
String draftDate = sdf.format(bean.getDraft_date());
|
||||
txtDate.setText(draftDate);
|
||||
txtDate.setTextSize(10);
|
||||
txtId.setSelected(true);
|
||||
txtName.setSelected(true);
|
||||
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
ACRA.getErrorReporter().putCustomData("errorGetView", e.getMessage());
|
||||
ACRA.getErrorReporter().putCustomData("errorGetView", Tool.getSystemDateTime().toLocaleString());
|
||||
ACRA.getErrorReporter().handleSilentException(new Exception("Exception saat binding data to view"));
|
||||
}
|
||||
return v;
|
||||
}
|
||||
}
|
||||
|
||||
public class ListHandler extends Handler {
|
||||
@Override
|
||||
public void handleMessage(Message msg) {
|
||||
if (isStatusOpen) {
|
||||
updateListItem();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<string name="define_int_MobileSurvey">year;owner</string>
|
||||
<string name="library_MobileSurvey_author">AdIns</string>
|
||||
<string name="library_MobileSurvey_authorWebsite">http://ad-ins.com/</string>
|
||||
<string name="library_MobileSurvey_libraryName">CheckId v2.0</string>
|
||||
<string name="library_MobileSurvey_libraryDescription">
|
||||
Mobile Survey have never been easier. You can capture mobile market research anytime, on any device, even offline.
|
||||
Request a free demo and learn more.
|
||||
</string>
|
||||
<string name="library_MobileSurvey_libraryVersion">1.0.0</string>
|
||||
<string name="library_MobileSurvey_libraryWebsite">https://ad-ins.com/MobileSurvey</string>
|
||||
<string name="library_MobileSurvey_licenseId">apache_2_0</string>
|
||||
<string name="library_MobileSurvey_isOpenSource">true</string>
|
||||
<string name="library_MobileSurvey_repositoryLink">https://ad-ins.com/MobileSurvey</string>
|
||||
<!-- Custom variables section -->
|
||||
<string name="library_MobileSurvey_owner">PT. Adicipta Dinamika Inovasi</string>
|
||||
<string name="library_MobileSurvey_year">2015</string>
|
||||
</resources>
|
|
@ -0,0 +1,100 @@
|
|||
package com.adins.mss.odr.model;
|
||||
|
||||
import com.adins.mss.foundation.http.MssRequestType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
/**
|
||||
* @author gigin.ginanjar
|
||||
*/
|
||||
public class JsonRequestCheckOrder extends MssRequestType {
|
||||
@SerializedName("order_number")
|
||||
String order_number;
|
||||
@SerializedName("start_date")
|
||||
String start_date;
|
||||
@SerializedName("end_date")
|
||||
String end_date;
|
||||
@SerializedName("status")
|
||||
String status;
|
||||
@SerializedName("flag")
|
||||
String flag;
|
||||
@SerializedName("customer_name")
|
||||
String customer_name;
|
||||
|
||||
/**
|
||||
* Gets the flag
|
||||
*/
|
||||
public String getFlag() {
|
||||
return this.flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the flag
|
||||
*/
|
||||
public void setFlag(String value) {
|
||||
this.flag = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the orderNumber
|
||||
*/
|
||||
public String getOrderNumber() {
|
||||
return this.order_number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the orderNumber
|
||||
*/
|
||||
public void setOrderNumber(String value) {
|
||||
this.order_number = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the startDate
|
||||
*/
|
||||
public String getStartDate() {
|
||||
return this.start_date;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the startDate
|
||||
*/
|
||||
public void setStartDate(String value) {
|
||||
this.start_date = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the endDate
|
||||
*/
|
||||
public String getEndDate() {
|
||||
return this.end_date;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the endDate
|
||||
*/
|
||||
public void setEndDate(String value) {
|
||||
this.end_date = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the status
|
||||
*/
|
||||
public String getStatus() {
|
||||
return this.status;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the status
|
||||
*/
|
||||
public void setStatus(String value) {
|
||||
this.status = value;
|
||||
}
|
||||
|
||||
public String getCustomerName() {
|
||||
return customer_name;
|
||||
}
|
||||
|
||||
public void setCustomerName(String customer_name) {
|
||||
this.customer_name = customer_name;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,122 @@
|
|||
package com.adins.mss.base.dukcapil;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.ProgressDialog;
|
||||
import android.content.Context;
|
||||
import android.os.AsyncTask;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.R;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.base.dynamicform.DynamicFormActivity;
|
||||
import com.adins.mss.base.util.GsonHelper;
|
||||
import com.adins.mss.base.util.Utility;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.dao.TaskH;
|
||||
import com.adins.mss.foundation.formatter.Tool;
|
||||
import com.adins.mss.foundation.http.HttpConnectionResult;
|
||||
import com.adins.mss.foundation.http.HttpCryptedConnection;
|
||||
import com.adins.mss.foundation.questiongenerator.QuestionBean;
|
||||
import com.google.firebase.perf.FirebasePerformance;
|
||||
import com.google.firebase.perf.metrics.HttpMetric;
|
||||
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
|
||||
public class SubmitImageDkcp extends AsyncTask<String, Void, String> {
|
||||
|
||||
private ProgressDialog progressDialog;
|
||||
private WeakReference<Activity> activity;
|
||||
private Context context;
|
||||
private String errMessage;
|
||||
private QuestionBean questionBean;
|
||||
private LinkedHashMap<String, List<QuestionBean>> listOfQuestionBean;
|
||||
|
||||
public SubmitImageDkcp(Activity activity, Context context, LinkedHashMap<String, List<QuestionBean>> listOfQuestionBean,QuestionBean questionBean){
|
||||
this.activity = new WeakReference<>(activity);
|
||||
this.questionBean = questionBean;
|
||||
this.context = context;
|
||||
this.listOfQuestionBean = listOfQuestionBean;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPreExecute() {
|
||||
progressDialog = ProgressDialog.show(activity.get(), "", activity.get().getString(R.string.generate_image_data), true);
|
||||
super.onPreExecute();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String doInBackground(String... params) {
|
||||
String imgBase64 = params[0];
|
||||
if (Tool.isInternetconnected(activity.get())) {
|
||||
JsonRequestImageDkcp jsonRequestImageIdentity = new JsonRequestImageDkcp();
|
||||
jsonRequestImageIdentity.setAudit(GlobalData.getSharedGlobalData().getAuditData());
|
||||
jsonRequestImageIdentity.setImgIdentity(imgBase64);
|
||||
|
||||
String jsonRequest = GsonHelper.toJson(jsonRequestImageIdentity);
|
||||
|
||||
String url = GlobalData.getSharedGlobalData().getURL_SUBMIT_DKCP();
|
||||
boolean encrypt = GlobalData.getSharedGlobalData().isEncrypt();
|
||||
boolean decrypt = GlobalData.getSharedGlobalData().isDecrypt();
|
||||
HttpCryptedConnection httpConn = new HttpCryptedConnection(activity.get(), encrypt, decrypt);
|
||||
HttpConnectionResult serverResult = null;
|
||||
|
||||
//Firebase Performance Trace HTTP Request
|
||||
HttpMetric networkMetric =
|
||||
FirebasePerformance.getInstance().newHttpMetric(url, FirebasePerformance.HttpMethod.POST);
|
||||
Utility.metricStart(networkMetric, jsonRequest);
|
||||
|
||||
try {
|
||||
serverResult = httpConn.requestToServer(url, jsonRequest, Global.DEFAULTCONNECTIONTIMEOUT);
|
||||
Utility.metricStop(networkMetric, serverResult);
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
questionBean.setImgAnswer(null);
|
||||
questionBean.setAnswer(null);
|
||||
errMessage = activity.get().getString(R.string.msgConnectionFailed);
|
||||
return null;
|
||||
}
|
||||
if (serverResult != null && serverResult.isOK()) {
|
||||
String body = serverResult.getResult();
|
||||
return body;
|
||||
} else {
|
||||
questionBean.setImgAnswer(null);
|
||||
questionBean.setAnswer(null);
|
||||
errMessage = activity.get().getString(R.string.connection_failed);
|
||||
}
|
||||
} else {
|
||||
questionBean.setImgAnswer(null);
|
||||
questionBean.setAnswer(null);
|
||||
errMessage = activity.get().getString(R.string.no_internet_connection);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPostExecute(String response) {
|
||||
super.onPostExecute(response);
|
||||
if(errMessage==null) {
|
||||
ResponseImageDkcp responseImageDkcp = new ResponseImageDkcp();
|
||||
|
||||
responseImageDkcp = GsonHelper.fromJson(response, ResponseImageDkcp.class);
|
||||
|
||||
if (responseImageDkcp.getStatus().getCode() == 0 && responseImageDkcp.getDataDkcp()!=null) {
|
||||
if(responseImageDkcp.getDataDkcp().getGeneratedStatus().equals("Failed")){
|
||||
Toast.makeText(context,activity.get().getString(R.string.copy_value_dkcp_failed), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
questionBean.setResponseImageDkcp(responseImageDkcp);
|
||||
TaskH taskH = DynamicFormActivity.getHeader().getTaskH();
|
||||
taskH.setCustomer_name(questionBean.getResponseImageDkcp().getDataDkcp().getValueRead("nama"));
|
||||
taskH.setCustomer_address(questionBean.getResponseImageDkcp().getDataDkcp().getValueRead("alamat"));
|
||||
} else {
|
||||
Toast.makeText(context,activity.get().getString(R.string.copy_value_dkcp_failed), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else{
|
||||
Toast.makeText(context,errMessage, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
progressDialog.dismiss();
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue