|
|
@@ -6,6 +6,7 @@ import android.content.DialogInterface;
|
|
|
import android.content.Intent;
|
|
|
import android.content.pm.PackageManager;
|
|
|
import android.graphics.drawable.BitmapDrawable;
|
|
|
+import android.os.Handler;
|
|
|
import android.support.annotation.NonNull;
|
|
|
import android.text.TextUtils;
|
|
|
import android.view.Gravity;
|
|
|
@@ -132,9 +133,16 @@ public class IndexActivity extends BaseActivity implements AdapterView.OnItemCli
|
|
|
mFragment = new WorkOrderSearchFragment();
|
|
|
sc_code=SharedPreUtil.getString(this,Constants.FLAG.GANG_WEI_SOURCE_CODE,"");
|
|
|
sc_name=SharedPreUtil.getString(this,Constants.FLAG.GANG_WEI_SOURCE_NAME,"");
|
|
|
- if (!StringUtil.isEmpty(sc_code)) {
|
|
|
- handleCode(sc_code, true);
|
|
|
- }
|
|
|
+ new Handler().postDelayed(new Runnable() {
|
|
|
+ @Override
|
|
|
+ public void run() {
|
|
|
+ if (!StringUtil.isEmpty(sc_code)) {
|
|
|
+ handleCode(sc_code, true);
|
|
|
+ }else{
|
|
|
+ initEditPopupWindow();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },500);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
@@ -187,7 +195,7 @@ public class IndexActivity extends BaseActivity implements AdapterView.OnItemCli
|
|
|
moveTaskToBack(isFinishing());
|
|
|
break;
|
|
|
case R.id.index_edit:
|
|
|
- initEditPopupWindow(v);
|
|
|
+ initEditPopupWindow();
|
|
|
break;
|
|
|
case R.id.btn_actionbar_scan_iv:
|
|
|
if (CameraUtil.hasCamera()) {
|
|
|
@@ -233,7 +241,7 @@ public class IndexActivity extends BaseActivity implements AdapterView.OnItemCli
|
|
|
|
|
|
}
|
|
|
|
|
|
- private void initEditPopupWindow(View view) {
|
|
|
+ private void initEditPopupWindow() {
|
|
|
View contView = LayoutInflater.from(this).inflate(R.layout.index_edit_pup, null);
|
|
|
edit_et = (ClearableEditText) contView.findViewById(R.id.edit_et);
|
|
|
TextView sure_tv = (TextView) contView.findViewById(R.id.sure_tv);
|