Bläddra i källkod

岗位备料子界面增加全部下料功能,单个下料功能,增加备料条码汇总按钮,工位编号验证逻辑,物料批号验证逻辑,UI调整

ChengJH 2 år sedan
förälder
incheckning
cd83194059

+ 136 - 0
app/src/main/java/com/uas/yitao_productionline/bean/FilldataGridViewBean.java

@@ -0,0 +1,136 @@
+package com.uas.yitao_productionline.bean;
+
+import java.io.Serializable;
+
+/**
+ * Created by cjh-sail on 2023-03-15
+ */
+public class FilldataGridViewBean implements Serializable {
+
+    private String MSS_MAKECODE;
+    private String MSS_LINECODE;
+    private String SP_FSONCODE;
+    private String MSS_ID;
+    private String SP_SONCODE;
+    private String MSS_PRODCODE;
+    private String SP_ONEUSEQTY;
+    private String MSS_BARCODE;
+    private String MSS_QTY;
+    private String MSS_REMAIN;
+    private String PR_DETAIL;
+    private String MSS_USEQTY;
+    private String SP_REGEX ;
+    private String DELETEID ;
+
+    public String getDELETEID() {
+        return DELETEID;
+    }
+
+    public void setDELETEID(String DELETEID) {
+        this.DELETEID = DELETEID;
+    }
+
+    public String getSP_REGEX() {
+        return SP_REGEX;
+    }
+
+    public void setSP_REGEX(String SP_REGEX) {
+        this.SP_REGEX = SP_REGEX;
+    }
+
+    public String getMSS_MAKECODE() {
+        return MSS_MAKECODE;
+    }
+
+    public void setMSS_MAKECODE(String MSS_MAKECODE) {
+        this.MSS_MAKECODE = MSS_MAKECODE;
+    }
+
+    public String getMSS_LINECODE() {
+        return MSS_LINECODE;
+    }
+
+    public void setMSS_LINECODE(String MSS_LINECODE) {
+        this.MSS_LINECODE = MSS_LINECODE;
+    }
+
+    public String getSP_FSONCODE() {
+        return SP_FSONCODE;
+    }
+
+    public void setSP_FSONCODE(String SP_FSONCODE) {
+        this.SP_FSONCODE = SP_FSONCODE;
+    }
+
+    public String getMSS_ID() {
+        return MSS_ID;
+    }
+
+    public void setMSS_ID(String MSS_ID) {
+        this.MSS_ID = MSS_ID;
+    }
+
+    public String getSP_SONCODE() {
+        return SP_SONCODE;
+    }
+
+    public void setSP_SONCODE(String SP_SONCODE) {
+        this.SP_SONCODE = SP_SONCODE;
+    }
+
+    public String getMSS_PRODCODE() {
+        return MSS_PRODCODE;
+    }
+
+    public void setMSS_PRODCODE(String MSS_PRODCODE) {
+        this.MSS_PRODCODE = MSS_PRODCODE;
+    }
+
+    public String getSP_ONEUSEQTY() {
+        return SP_ONEUSEQTY;
+    }
+
+    public void setSP_ONEUSEQTY(String SP_ONEUSEQTY) {
+        this.SP_ONEUSEQTY = SP_ONEUSEQTY;
+    }
+
+    public String getMSS_BARCODE() {
+        return MSS_BARCODE;
+    }
+
+    public void setMSS_BARCODE(String MSS_BARCODE) {
+        this.MSS_BARCODE = MSS_BARCODE;
+    }
+
+    public String getMSS_QTY() {
+        return MSS_QTY;
+    }
+
+    public void setMSS_QTY(String MSS_QTY) {
+        this.MSS_QTY = MSS_QTY;
+    }
+
+    public String getMSS_REMAIN() {
+        return MSS_REMAIN;
+    }
+
+    public void setMSS_REMAIN(String MSS_REMAIN) {
+        this.MSS_REMAIN = MSS_REMAIN;
+    }
+
+    public String getPR_DETAIL() {
+        return PR_DETAIL;
+    }
+
+    public void setPR_DETAIL(String PR_DETAIL) {
+        this.PR_DETAIL = PR_DETAIL;
+    }
+
+    public String getMSS_USEQTY() {
+        return MSS_USEQTY;
+    }
+
+    public void setMSS_USEQTY(String MSS_USEQTY) {
+        this.MSS_USEQTY = MSS_USEQTY;
+    }
+}

+ 8 - 9
app/src/main/java/com/uas/yitao_productionline/fragment/ModifyBarcodeQuantityFragment.java

@@ -115,14 +115,12 @@ public class ModifyBarcodeQuantityFragment extends BaseFragment {
             }
             }
         });
         });
 
 
-        mBarcodeEditText.setOnFocusChangeListener(new View.OnFocusChangeListener() {
-            @Override
-            public void onFocusChange(View v, boolean hasFocus) {
-                if (!hasFocus && isVisible() && !mIgnoreFocusChange) {
-                    getBarcodeData();
-                }
-            }
-        });
+//        mBarcodeEditText.setOnFocusChangeListener(new View.OnFocusChangeListener() {
+//            @Override
+//            public void onFocusChange(View v, boolean hasFocus) {
+//                getBarcodeData();
+//            }
+//        });
 
 
         mConfirmButton.setOnClickListener(new View.OnClickListener() {
         mConfirmButton.setOnClickListener(new View.OnClickListener() {
             @Override
             @Override
@@ -288,7 +286,8 @@ public class ModifyBarcodeQuantityFragment extends BaseFragment {
                         new Response.ErrorListener() {
                         new Response.ErrorListener() {
                             @Override
                             @Override
                             public void onErrorResponse(VolleyError volleyError) {
                             public void onErrorResponse(VolleyError volleyError) {
-                                progressDialog.dismiss();
+                                if (progressDialog.isShowing())
+                                    progressDialog.dismiss();
                                 String errorToast = CommonUtil.showErrorToast(volleyError, true);
                                 String errorToast = CommonUtil.showErrorToast(volleyError, true);
                                 mResultTextView.setVisibility(View.VISIBLE);
                                 mResultTextView.setVisibility(View.VISIBLE);
                                 mResultTextView.setText(errorToast);
                                 mResultTextView.setText(errorToast);

+ 402 - 38
app/src/main/java/com/uas/yitao_productionline/fragment/PostStockAdvocateFragment.java

@@ -1,12 +1,20 @@
 package com.uas.yitao_productionline.fragment;
 package com.uas.yitao_productionline.fragment;
 
 
+import android.app.Activity;
+import android.app.AlertDialog;
+import android.content.DialogInterface;
+import android.content.Intent;
 import android.graphics.Color;
 import android.graphics.Color;
 import android.os.Handler;
 import android.os.Handler;
 import android.support.v4.content.ContextCompat;
 import android.support.v4.content.ContextCompat;
+import android.text.Editable;
+import android.text.TextWatcher;
 import android.util.Log;
 import android.util.Log;
 import android.view.KeyEvent;
 import android.view.KeyEvent;
 import android.view.View;
 import android.view.View;
 import android.view.WindowManager;
 import android.view.WindowManager;
+import android.view.inputmethod.EditorInfo;
+import android.widget.ImageView;
 import android.widget.TextView;
 import android.widget.TextView;
 
 
 import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSON;
@@ -20,17 +28,22 @@ import com.bin.david.form.data.column.Column;
 import com.bin.david.form.data.format.bg.BaseCellBackgroundFormat;
 import com.bin.david.form.data.format.bg.BaseCellBackgroundFormat;
 import com.bin.david.form.data.style.FontStyle;
 import com.bin.david.form.data.style.FontStyle;
 import com.bin.david.form.data.table.TableData;
 import com.bin.david.form.data.table.TableData;
+import com.bin.david.form.listener.OnColumnItemClickListener;
 import com.uas.yitao_productionline.R;
 import com.uas.yitao_productionline.R;
 import com.uas.yitao_productionline.application.PdaApplication;
 import com.uas.yitao_productionline.application.PdaApplication;
-import com.uas.yitao_productionline.bean.CollectNotBean;
+import com.uas.yitao_productionline.bean.FilldataGridViewBean;
 import com.uas.yitao_productionline.bean.SourceLocationBean;
 import com.uas.yitao_productionline.bean.SourceLocationBean;
 import com.uas.yitao_productionline.global.GloableParams;
 import com.uas.yitao_productionline.global.GloableParams;
+import com.uas.yitao_productionline.util.CameraUtil;
 import com.uas.yitao_productionline.util.CommonUtil;
 import com.uas.yitao_productionline.util.CommonUtil;
 import com.uas.yitao_productionline.util.Constants;
 import com.uas.yitao_productionline.util.Constants;
+import com.uas.yitao_productionline.util.FastjsonUtil;
 import com.uas.yitao_productionline.util.HttpCallback;
 import com.uas.yitao_productionline.util.HttpCallback;
 import com.uas.yitao_productionline.util.HttpParams;
 import com.uas.yitao_productionline.util.HttpParams;
 import com.uas.yitao_productionline.util.VolleyRequest;
 import com.uas.yitao_productionline.util.VolleyRequest;
 import com.uas.yitao_productionline.view.ClearableEditText;
 import com.uas.yitao_productionline.view.ClearableEditText;
+import com.uuzuche.lib_zxing.activity.CaptureActivity;
+import com.uuzuche.lib_zxing.activity.CodeUtils;
 
 
 import java.util.ArrayList;
 import java.util.ArrayList;
 import java.util.List;
 import java.util.List;
@@ -38,19 +51,27 @@ import java.util.List;
 /**
 /**
  * Created by cjh-sail on 2023-03-08
  * Created by cjh-sail on 2023-03-08
  */
  */
-public class PostStockAdvocateFragment extends BaseFragment{
-
+public class PostStockAdvocateFragment extends BaseFragment implements OnColumnItemClickListener<String> {
+    private int mFocusId;
+    private static final int SCAN_BARCODE_CODE = 111;
+    private static final int SCAN_BARCODE_CODE2 = 222;
     private SmartTable mSmartTable;
     private SmartTable mSmartTable;
-    private Column<String> mTypeColumn, mcontentColumn, mCnColumn, mOrispeccodeColumn, mCodeColumn, mDetailColumn,mDeleteColumn;
-    private TableData<CollectNotBean> mTableData;
-    private List<CollectNotBean> mFilterStorageInBeans;
-    private ClearableEditText modify_barcode_quantity_barcode_cet;
-    private ClearableEditText ce_ma_craftcode;
+    private Column<String> mTypeColumn, mcontentColumn, mCnColumn, mOrispeccodeColumn, mCodeColumn, mMSS_USEQTYColumn, mDetailColumn,mSp_regexColumn,mDeleteColumn;
+    private TableData<FilldataGridViewBean> mTableData;
+    private List<FilldataGridViewBean> mFilterStorageInBeans;
+    private TextView modify_barcode_quantity_barcode_cet;
+    private TextView ce_ma_craftcode;
     private TextView tv_step_code;
     private TextView tv_step_code;
     private TextView tv_sc_code;
     private TextView tv_sc_code;
     private TextView tv_pr_detail;
     private TextView tv_pr_detail;
     private SourceLocationBean dataCacheFromMap;
     private SourceLocationBean dataCacheFromMap;
     private TextView tv_refresh;
     private TextView tv_refresh;
+    private ClearableEditText ce_station;
+    private ImageView iv_station;
+    private ClearableEditText ce_material_lot_number;
+    private ImageView iv_material_lot_number;
+    private TextView tv_hint;
+    private TextView tv_all_delete;
 
 
     @Override
     @Override
     protected int getLayout() {
     protected int getLayout() {
@@ -67,17 +88,27 @@ public class PostStockAdvocateFragment extends BaseFragment{
         tv_sc_code = root.findViewById(R.id.tv_sc_code);
         tv_sc_code = root.findViewById(R.id.tv_sc_code);
         tv_pr_detail = root.findViewById(R.id.tv_pr_detail);
         tv_pr_detail = root.findViewById(R.id.tv_pr_detail);
         tv_refresh = root.findViewById(R.id.tv_refresh);
         tv_refresh = root.findViewById(R.id.tv_refresh);
+        mSmartTable = root.findViewById(R.id.jlt_storage_in_filter_list_st);
+        ce_station = root.findViewById(R.id.ce_station);
+        iv_station = root.findViewById(R.id.iv_station);
+        ce_material_lot_number = root.findViewById(R.id.ce_material_lot_number);
+        iv_material_lot_number = root.findViewById(R.id.iv_material_lot_number);
+        tv_hint = root.findViewById(R.id.tv_hint);
+        tv_all_delete = root.findViewById(R.id.tv_all_delete);
 
 
+        mSp_regexColumn = new Column<String>("工位", "SP_REGEX");
+        mTypeColumn = new Column<String>("物料编号", "SP_FSONCODE");
+        mcontentColumn = new Column<String>("单位用量", "SP_ONEUSEQTY");
+        mCnColumn = new Column<String>("条码号", "MSS_BARCODE");
+        mOrispeccodeColumn = new Column<String>("备料数", "MSS_QTY");
+        mCodeColumn = new Column<String>("剩余数", "MSS_REMAIN");
+        mMSS_USEQTYColumn = new Column<String>("已用数", "MSS_USEQTY");
+        mDetailColumn = new Column<String>("物料名称", "PR_DETAIL");
+        mDeleteColumn = new Column<String>("删除", "DELETEID");
+        mSp_regexColumn.setFixed(true);
+
+        mDeleteColumn.setOnColumnItemClickListener(this);
 
 
-        mSmartTable = root.findViewById(R.id.jlt_storage_in_filter_list_st);
-        mTypeColumn = new Column<String>("类型", "PIM_TYPE");
-        mcontentColumn = new Column<String>("内容", "CONTENT");
-        mCnColumn = new Column<String>("数量", "CN");
-        mOrispeccodeColumn = new Column<String>("型号", "PR_ORISPECCODE");
-        mCodeColumn = new Column<String>("料号", "PR_CODE");
-        mDetailColumn = new Column<String>("名称", "PR_DETAIL");
-        mDeleteColumn = new Column<String>("删除", "×");
-        mDetailColumn.setFixed(true);
         mFilterStorageInBeans = new ArrayList<>();
         mFilterStorageInBeans = new ArrayList<>();
         WindowManager wm = mActivity.getWindowManager();
         WindowManager wm = mActivity.getWindowManager();
         int screenWith = wm.getDefaultDisplay().getWidth();
         int screenWith = wm.getDefaultDisplay().getWidth();
@@ -105,18 +136,51 @@ public class PostStockAdvocateFragment extends BaseFragment{
 
 
     @Override
     @Override
     protected void initEvents() {
     protected void initEvents() {
-
+        iv_station.requestFocus();
+        iv_station.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                if (CameraUtil.hasCamera()) {
+                    if (root.findFocus() != null) {
+                        mFocusId = root.findFocus().getId();
+                        Intent intent = new Intent();
+                        intent.setClass(mActivity, CaptureActivity.class);
+                        startActivityForResult(intent, SCAN_BARCODE_CODE);
+                    } else {
+                        CommonUtil.toastNoRepeat(mActivity, "请选择您要操作的输入框");
+                    }
+                } else {
+                    CommonUtil.toastNoRepeat(mActivity, getString(R.string.no_camera_detected));
+                }
+            }
+        });
+        iv_station.requestFocus();
+        iv_material_lot_number.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                if (CameraUtil.hasCamera()) {
+                    if (root.findFocus() != null) {
+                        mFocusId = root.findFocus().getId();
+                        Intent intent = new Intent();
+                        intent.setClass(mActivity, CaptureActivity.class);
+                        startActivityForResult(intent, SCAN_BARCODE_CODE2);
+                    } else {
+                        CommonUtil.toastNoRepeat(mActivity, "请选择您要操作的输入框");
+                    }
+                } else {
+                    CommonUtil.toastNoRepeat(mActivity, getString(R.string.no_camera_detected));
+                }
+            }
+        });
     }
     }
 
 
     @Override
     @Override
     protected void initDatas() {
     protected void initDatas() {
-
         dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
         dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
-
         modify_barcode_quantity_barcode_cet.setText(dataCacheFromMap.getMa_code());
         modify_barcode_quantity_barcode_cet.setText(dataCacheFromMap.getMa_code());
         ce_ma_craftcode.setText(dataCacheFromMap.getMa_craftcode());
         ce_ma_craftcode.setText(dataCacheFromMap.getMa_craftcode());
         tv_step_code.setText(dataCacheFromMap.getStep_code());
         tv_step_code.setText(dataCacheFromMap.getStep_code());
-        tv_sc_code.setText(dataCacheFromMap.getSc_code());
+        tv_sc_code.setText(dataCacheFromMap.getMa_prodcode());
         tv_pr_detail.setText(dataCacheFromMap.getPr_detail());
         tv_pr_detail.setText(dataCacheFromMap.getPr_detail());
 
 
 
 
@@ -127,9 +191,75 @@ public class PostStockAdvocateFragment extends BaseFragment{
                 getCollectList();
                 getCollectList();
             }
             }
         });
         });
+        ce_station.requestFocus();
+        ce_material_lot_number.setEnabled(false);
+        ce_material_lot_number.setFocusable(false);
+        ce_material_lot_number.setFocusableInTouchMode(false);
+        ce_station.addTextChangedListener(new TextWatcher() {
+            @Override
+            public void beforeTextChanged(CharSequence s, int start, int count, int after) {
+
+            }
+
+            @Override
+            public void onTextChanged(CharSequence s, int start, int before, int count) {
+
+            }
+
+            @Override
+            public void afterTextChanged(Editable s) {
+                if (s == null || s.length() == 0) {
+                    ce_material_lot_number.setEnabled(false);
+                    ce_material_lot_number.setFocusable(false);
+                    ce_material_lot_number.setFocusableInTouchMode(false);
+                } else {
+                    ce_material_lot_number.setEnabled(true);
+                    ce_material_lot_number.setFocusable(true);
+                    ce_material_lot_number.setFocusableInTouchMode(true);
+                }
+            }
+        });
+        ce_station.setOnEditorActionListener(new TextView.OnEditorActionListener() {
+            @Override
+            public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
+                if (actionId == EditorInfo.IME_ACTION_DONE
+                        || actionId == EditorInfo.IME_ACTION_SEND
+                        || (event != null && event.getAction() == KeyEvent.ACTION_DOWN && event.getKeyCode() == KeyEvent.KEYCODE_ENTER)) {
 
 
+                    getPositionLocation();
+                    return true;
+                }
+                return false;
+            }
+        });
+        ce_material_lot_number.setOnEditorActionListener(new TextView.OnEditorActionListener() {
+            @Override
+            public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
+                if (actionId == EditorInfo.IME_ACTION_DONE
+                        || actionId == EditorInfo.IME_ACTION_SEND
+                        || (event != null && event.getAction() == KeyEvent.ACTION_DOWN && event.getKeyCode() == KeyEvent.KEYCODE_ENTER)) {
 
 
+                    getDataByBarcode();
+                    return true;
+                }
+                return false;
+            }
+        });
 
 
+        //全部删除
+        tv_all_delete.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                new AlertDialog.Builder(getActivity()).setTitle("提示").setMessage("确定要全部下料吗?")
+                        .setPositiveButton(getString(R.string.confirm), new DialogInterface.OnClickListener() {
+                            @Override
+                            public void onClick(DialogInterface dialog, int which) {
+                                setalldelete();
+
+                            }
+                        }).setNegativeButton(getString(R.string.cancel), null).create().show();
+            }
+        });
 
 
     }
     }
 
 
@@ -159,21 +289,32 @@ public class PostStockAdvocateFragment extends BaseFragment{
                     String result = o.toString();
                     String result = o.toString();
                     JSONObject resultObject = JSON.parseObject(result);
                     JSONObject resultObject = JSON.parseObject(result);
                     JSONArray dataArray = resultObject.getJSONArray("data");
                     JSONArray dataArray = resultObject.getJSONArray("data");
-//                    List<CollectNotBean> list=new ArrayList<>();
-//                    if (dataArray != null && dataArray.size() > 0) {
-//                        for (int i = 0; i < dataArray.size(); i++) {
-//                            JSONObject dataObject = dataArray.getJSONObject(i);
-//                            if (dataObject != null) {
-//
-//                                CollectNotBean collectListBean = new CollectNotBean();
-////                                collectListBean.setPIM_TYPE(FastjsonUtil.getText(dataObject, "PIM_TYPE"));
-//                                list.add(collectListBean);
-//                            }
-//                        }
-//                    }
-//                    mFilterStorageInBeans = list;//PI_INOUTNO
-//                    setFilterTableData(mFilterStorageInBeans);
+                    List<FilldataGridViewBean> list=new ArrayList<>();
+                    list.clear();
+                    if (dataArray != null && dataArray.size() > 0) {
+                        for (int i = 0; i < dataArray.size(); i++) {
+                            JSONObject dataObject = dataArray.getJSONObject(i);
+                            if (dataObject != null) {
+                                FilldataGridViewBean collectListBean = new FilldataGridViewBean();
+                                collectListBean.setSP_FSONCODE(FastjsonUtil.getText(dataObject, "SP_FSONCODE"));
+                                collectListBean.setSP_ONEUSEQTY(FastjsonUtil.getText(dataObject, "SP_ONEUSEQTY"));
+                                collectListBean.setMSS_BARCODE(FastjsonUtil.getText(dataObject, "MSS_BARCODE"));
+                                collectListBean.setMSS_QTY(FastjsonUtil.getText(dataObject, "MSS_QTY"));
+                                collectListBean.setMSS_REMAIN(FastjsonUtil.getText(dataObject, "MSS_REMAIN"));
+                                collectListBean.setMSS_USEQTY(FastjsonUtil.getText(dataObject, "MSS_USEQTY"));
+                                collectListBean.setPR_DETAIL(FastjsonUtil.getText(dataObject, "PR_DETAIL"));
+                                collectListBean.setSP_REGEX(FastjsonUtil.getText(dataObject, "SP_REGEX"));
+                                collectListBean.setMSS_ID(FastjsonUtil.getText(dataObject, "MSS_ID"));
+                                collectListBean.setDELETEID("x");
+
+                                list.add(collectListBean);
+                            }
+                        }
+                    }
+                    mFilterStorageInBeans = list;//PI_INOUTNO
+                    setFilterTableData(mFilterStorageInBeans);
                 } catch (Exception e) {
                 } catch (Exception e) {
+                    setFilterTableData(mFilterStorageInBeans);
                     e.printStackTrace();
                     e.printStackTrace();
                     progressDialog.dismiss();
                     progressDialog.dismiss();
                 }
                 }
@@ -187,9 +328,9 @@ public class PostStockAdvocateFragment extends BaseFragment{
             }
             }
         });
         });
     }
     }
-    private void setFilterTableData(List<CollectNotBean> filterTableData) {
-        mTableData = new TableData<CollectNotBean>("入库单列表", filterTableData,
-                mTypeColumn, mcontentColumn, mCnColumn, mOrispeccodeColumn, mCodeColumn, mDetailColumn,mDeleteColumn);
+    private void setFilterTableData(List<FilldataGridViewBean> filterTableData) {
+        mTableData = new TableData<FilldataGridViewBean>("入库单列表", filterTableData,
+                mSp_regexColumn , mTypeColumn,mcontentColumn, mCnColumn, mOrispeccodeColumn, mCodeColumn, mMSS_USEQTYColumn,mDetailColumn,mDeleteColumn);
         mSmartTable.setTableData(mTableData);
         mSmartTable.setTableData(mTableData);
 //        mSmartTable.requestLayout();
 //        mSmartTable.requestLayout();
         new Handler().postDelayed(new Runnable() {
         new Handler().postDelayed(new Runnable() {
@@ -199,6 +340,128 @@ public class PostStockAdvocateFragment extends BaseFragment{
             }
             }
         }, 100);
         }, 100);
     }
     }
+    public void getPositionLocation(){
+        dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
+        ArrayList<SourceLocationBean> list=new ArrayList<>();
+        list.add(dataCacheFromMap);
+        JSONArray jsonArray = new JSONArray();
+        jsonArray.add(list);
+        String substring = jsonArray.toString().substring(0, jsonArray.toString().length() - 1);//去除尾部
+        String substring1 = substring.substring(1, substring.length());//去除首部
+        progressDialog.show();
+        VolleyRequest.getInstance().stringRequest(new HttpParams.Builder()
+                .url(GloableParams.ADDRESS_SMT_POSITIONLOCATION)
+                .method(Request.Method.POST)
+                .tag(TAG + "getindatalist")
+                .flag(0)
+                .addParam("linemessage",substring1)
+                .addParam("location",ce_station.getText().toString().trim())
+                .build(), new HttpCallback() {
+            @Override
+            public void onSuccess(int flag, Object o) throws Exception {
+                progressDialog.dismiss();
+                ce_material_lot_number.requestFocus();
+                ce_station.setSelection(ce_material_lot_number.getText().toString().length());
+                String result = o.toString();
+                Log.e("result",result);
+                com.alibaba.fastjson.JSONObject resultObject = JSON.parseObject(result);
+                String data = FastjsonUtil.getText(resultObject, "data");
+                setColorText(getResources().getColor(R.color.green),data);
+            }
+            @Override
+            public void onFail(int flag, String failStr) throws Exception {
+                progressDialog.dismiss();
+                setColorText(getResources().getColor(R.color.red),failStr);
+                ce_station.setText("");
+                setFilterTableData(mFilterStorageInBeans);
+            }
+        });
+    }
+    public void getDataByBarcode(){
+        dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
+        ArrayList<SourceLocationBean> list=new ArrayList<>();
+        list.add(dataCacheFromMap);
+        JSONArray jsonArray = new JSONArray();
+        jsonArray.add(list);
+        String substring = jsonArray.toString().substring(0, jsonArray.toString().length() - 1);//去除尾部
+        String substring1 = substring.substring(1, substring.length());//去除首部
+        progressDialog.show();
+        VolleyRequest.getInstance().stringRequest(new HttpParams.Builder()
+                .url(GloableParams.ADDRESS_SMT_POSITIONBARCODE)
+                .method(Request.Method.POST)
+                .tag(TAG + "getindatalist")
+                .flag(0)
+                .addParam("linemessage",substring1)
+                .addParam("location",ce_station.getText().toString().trim())
+                .addParam("barcode",ce_material_lot_number.getText().toString().trim())
+                .build(), new HttpCallback() {
+            @Override
+            public void onSuccess(int flag, Object o) throws Exception {
+                    progressDialog.dismiss();
+                    String result = o.toString();
+                    Log.e("result",result);
+                    com.alibaba.fastjson.JSONObject resultObject = JSON.parseObject(result);
+                    String data = FastjsonUtil.getText(resultObject, "data");
+                    setColorText(getResources().getColor(R.color.green),data);
+                    getCollectList();
+                    ce_material_lot_number.setText("");
+            }
+
+            @Override
+            public void onFail(int flag, String failStr) throws Exception {
+                progressDialog.dismiss();
+                ce_material_lot_number.setText("");
+                setColorText(getResources().getColor(R.color.red),failStr);
+                setFilterTableData(mFilterStorageInBeans);
+            }
+        });
+    }
+
+
+    public void getdePositionBarcode(String mss_id,String barcode){
+        dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
+        ArrayList<SourceLocationBean> list=new ArrayList<>();
+        list.add(dataCacheFromMap);
+        JSONArray jsonArray = new JSONArray();
+        jsonArray.add(list);
+        String substring = jsonArray.toString().substring(0, jsonArray.toString().length() - 1);//去除尾部
+        String substring1 = substring.substring(1, substring.length());//去除首部
+        progressDialog.show();
+        VolleyRequest.getInstance().stringRequest(new HttpParams.Builder()
+                .url(GloableParams.ADDRESS_SMT_DEPOSITIONBARCODE)
+                .method(Request.Method.POST)
+                .tag(TAG + "getindatalist")
+                .flag(0)
+                .addParam("linemessage",substring1)
+                .addParam("mss_id",mss_id)
+                .addParam("barcode",barcode)
+                .build(), new HttpCallback() {
+            @Override
+            public void onSuccess(int flag, Object o) throws Exception {
+                progressDialog.dismiss();
+                String result = o.toString();
+                com.alibaba.fastjson.JSONObject resultObject = JSON.parseObject(result);
+                String data = FastjsonUtil.getText(resultObject, "data");
+                setColorText(getResources().getColor(R.color.green),data);
+                getCollectList();
+            }
+
+            @Override
+            public void onFail(int flag, String failStr) throws Exception {
+                progressDialog.dismiss();
+                setColorText(getResources().getColor(R.color.red),failStr);
+                setFilterTableData(mFilterStorageInBeans);
+            }
+        });
+    }
+
+    public void setColorText(int color,String text){
+        tv_hint.setTextColor(color);
+        tv_hint.setText(text);
+    }
+
+
+
     @Override
     @Override
     public boolean onKeyDown(int keyCode, KeyEvent event) {
     public boolean onKeyDown(int keyCode, KeyEvent event) {
         return false;
         return false;
@@ -207,5 +470,106 @@ public class PostStockAdvocateFragment extends BaseFragment{
     @Override
     @Override
     public boolean onFragmentBackPressed() {
     public boolean onFragmentBackPressed() {
         return false;
         return false;
+    }
+    @Override
+    public void onActivityResult(int requestCode, int resultCode, Intent data) {
+        super.onActivityResult(requestCode, resultCode, data);
+        if (resultCode != Activity.RESULT_OK) {
+            return;
+        }
+
+        if (requestCode == SCAN_BARCODE_CODE && data != null) {
+            if (data.getExtras() != null) {
+                String result = data.getExtras().getString(CodeUtils.RESULT_STRING);
+                if (mFocusId == R.id.ce_station) {
+                    ce_station.setText(result);
+                    ce_station.setSelection(result.length());
+                    getPositionLocation();
+                }
+            }
+        }
+        if (requestCode == SCAN_BARCODE_CODE2 && data != null) {
+            if (data.getExtras() != null) {
+                String result = data.getExtras().getString(CodeUtils.RESULT_STRING);
+                if (mFocusId == R.id.ce_material_lot_number) {
+                    ce_material_lot_number.setText(result);
+                    ce_material_lot_number.setSelection(result.length());
+                    getDataByBarcode();
+                }
+            }
+        }
+    }
+    //表格点击
+    @Override
+    public void onClick(Column<String> column, String s, String s2, int i) {
+        String mss_id = mFilterStorageInBeans.get(i).getMSS_ID();
+        String mss_barcode = mFilterStorageInBeans.get(i).getMSS_BARCODE();
+        if (!mss_id.isEmpty()){
+            if (!mss_id.equals("0")){
+                getdePositionBarcode(mss_id,mss_barcode);
+            }
+
+        }
+    }
+
+
+    public void setalldelete(){
+        ArrayList<String> jsonList=new ArrayList<>();
+        jsonList.clear();
+        for (int i=0;i<mFilterStorageInBeans.size();i++){
+            if (!mFilterStorageInBeans.get(i).getMSS_ID().equals("0")){
+                jsonList.add(mFilterStorageInBeans.get(i).getMSS_ID());
+            }
+
+        }
+        JSONArray jsonArrayall = new JSONArray();
+        jsonArrayall.add(jsonList);
+        String allsubstring = jsonArrayall.toString().substring(0, jsonArrayall.toString().length() - 1);//去除尾部
+        String allsubstring1 = allsubstring.substring(1, allsubstring.length());//去除首部
+        String substringall = allsubstring1.substring(0, allsubstring1.length() - 1);
+        String substring1all = substringall.substring(1, substringall.length());
+        String replace = substring1all.replace("\"", "");
+
+        dataCacheFromMap = (SourceLocationBean) PdaApplication.getDataCacheFromMap(Constants.FLAG.SMT_DEVICE_LINE_CACHES);
+        ArrayList<SourceLocationBean> list=new ArrayList<>();
+        list.add(dataCacheFromMap);
+        JSONArray jsonArray = new JSONArray();
+        jsonArray.add(list);
+        String substring = jsonArray.toString().substring(0, jsonArray.toString().length() - 1);//去除尾部
+        String substring1 = substring.substring(1, substring.length());//去除首部
+        progressDialog.show();
+        VolleyRequest.getInstance().stringRequest(new HttpParams.Builder()
+                .url(GloableParams.ADDRESS_SMT_DEALLPOSITIONBARCODE)
+                .method(Request.Method.POST)
+                .tag(TAG + "getindatalist")
+                .flag(0)
+                .addParam("linemessage",substring1)
+                .addParam("mss_idlist",replace)
+                .build(), new HttpCallback() {
+            @Override
+            public void onSuccess(int flag, Object o) throws Exception {
+                progressDialog.dismiss();
+                String result = o.toString();
+                com.alibaba.fastjson.JSONObject resultObject = JSON.parseObject(result);
+                String data = FastjsonUtil.getText(resultObject, "data");
+                setColorText(getResources().getColor(R.color.green),data);
+                getCollectList();
+            }
+
+            @Override
+            public void onFail(int flag, String failStr) throws Exception {
+                progressDialog.dismiss();
+                setColorText(getResources().getColor(R.color.red),failStr);
+                setFilterTableData(mFilterStorageInBeans);
+            }
+        });
+
+
+
+
+
+
+
+
     }
     }
 }
 }

+ 0 - 1
app/src/main/java/com/uas/yitao_productionline/fragment/PostStockFragment.java

@@ -242,7 +242,6 @@ public class PostStockFragment extends BaseFragment implements View.OnClickListe
                                 JSONObject dataObject = resultObject.optJSONObject("data");
                                 JSONObject dataObject = resultObject.optJSONObject("data");
                                 if (dataObject != null) {
                                 if (dataObject != null) {
                                     mLineInfo = new SourceLocationBean();
                                     mLineInfo = new SourceLocationBean();
-
                                     mLineInfo.setStep_code(JsonUtils.optStringNotNull(dataObject, "step_code"));
                                     mLineInfo.setStep_code(JsonUtils.optStringNotNull(dataObject, "step_code"));
                                     mLineInfo.setMa_prodcode(JsonUtils.optStringNotNull(dataObject, "ma_prodcode"));
                                     mLineInfo.setMa_prodcode(JsonUtils.optStringNotNull(dataObject, "ma_prodcode"));
                                     mLineInfo.setMa_bomversion(JsonUtils.optStringNotNull(dataObject, "ma_bomversion"));
                                     mLineInfo.setMa_bomversion(JsonUtils.optStringNotNull(dataObject, "ma_bomversion"));

+ 17 - 4
app/src/main/java/com/uas/yitao_productionline/global/GloableParams.java

@@ -227,7 +227,10 @@ public class GloableParams {
     public static String ADDRESS_SMT_FUZZYSEARCHSOURCE;
     public static String ADDRESS_SMT_FUZZYSEARCHSOURCE;
     public static String ADDRESS_SMT_GETSOURCELOCATION;
     public static String ADDRESS_SMT_GETSOURCELOCATION;
     public static String ADDRESS_SMT_FILLDATAGRIDVIEW;
     public static String ADDRESS_SMT_FILLDATAGRIDVIEW;
-
+    public static String ADDRESS_SMT_POSITIONLOCATION;
+    public static String ADDRESS_SMT_POSITIONBARCODE;
+    public static String ADDRESS_SMT_DEPOSITIONBARCODE;
+    public static String ADDRESS_SMT_DEALLPOSITIONBARCODE;
 
 
     //连接服务器请求地址
     //连接服务器请求地址
     private static final String ADDRESSTAIL_CONNECT_SERVER = "/api/pda/getAllMasters.action";
     private static final String ADDRESSTAIL_CONNECT_SERVER = "/api/pda/getAllMasters.action";
@@ -626,6 +629,15 @@ public class GloableParams {
     private static String ADDRESSTAIL_SMT_GETSOURCELOCATION = "/api/pda/smt/getSourceLocation.action";
     private static String ADDRESSTAIL_SMT_GETSOURCELOCATION = "/api/pda/smt/getSourceLocation.action";
     private static String ADDRESSTAIL_SMT_FILLDATAGRIDVIEW = "/api/pda/smt/FillDataGridView.action";
     private static String ADDRESSTAIL_SMT_FILLDATAGRIDVIEW = "/api/pda/smt/FillDataGridView.action";
 
 
+    private static String ADDRESSTAIL_SMT_POSITIONLOCATION = "/api/pda/smt/positionLocation.action";
+
+    private static String ADDRESSTAIL_SMT_POSITIONBARCODE = "/api/pda/smt/positionBarcode.action";
+
+    private static String ADDRESSTAIL_SMT_DEPOSITIONBARCODE = "/api/pda/smt/depositionBarcode.action";
+
+    private static String ADDRESSTAIL_SMT_DEALLPOSITIONBARCODE = "/api/pda/smt/deAllpositionBarcode.action";
+
+
     /**
     /**
      * 设置页面
      * 设置页面
      */
      */
@@ -1038,14 +1050,15 @@ public class GloableParams {
         GloableParams.ADDRESS_SPM_GETLINE = uriHead + GloableParams.ADDRESSTAIL_SPM_GETLINE;
         GloableParams.ADDRESS_SPM_GETLINE = uriHead + GloableParams.ADDRESSTAIL_SPM_GETLINE;
         GloableParams.ADDRESS_SMT_FORECASTDATACHECK = uriHead + GloableParams.ADDRESSTAIL_SMT_FORECASTDATACHECK;
         GloableParams.ADDRESS_SMT_FORECASTDATACHECK = uriHead + GloableParams.ADDRESSTAIL_SMT_FORECASTDATACHECK;
         GloableParams.ADDRESS_CHECK_LOCATIONCHECK = uriHead + GloableParams.ADDRESSTAIL_CHECK_LOCATIONCHECK;
         GloableParams.ADDRESS_CHECK_LOCATIONCHECK = uriHead + GloableParams.ADDRESSTAIL_CHECK_LOCATIONCHECK;
-
         GloableParams.ADDRESS_CHECK_LOCATIONDATAREPEATCHECK = uriHead + GloableParams.ADDRESSTAIL_SMT_START_DATAREPEATCHECK;
         GloableParams.ADDRESS_CHECK_LOCATIONDATAREPEATCHECK = uriHead + GloableParams.ADDRESSTAIL_SMT_START_DATAREPEATCHECK;
         GloableParams.ADDRESS_SMT_REPEATCHECK_DATA = uriHead + GloableParams.ADDRESSTAIL_SMT_DATAREPEATCHECK_DATA;
         GloableParams.ADDRESS_SMT_REPEATCHECK_DATA = uriHead + GloableParams.ADDRESSTAIL_SMT_DATAREPEATCHECK_DATA;
-
         GloableParams.ADDRESS_SMT_FUZZYSEARCHSOURCE = uriHead + GloableParams.ADDRESSTAIL_SMT_FUZZYSEARCHSOURCE;
         GloableParams.ADDRESS_SMT_FUZZYSEARCHSOURCE = uriHead + GloableParams.ADDRESSTAIL_SMT_FUZZYSEARCHSOURCE;
         GloableParams.ADDRESS_SMT_GETSOURCELOCATION = uriHead + GloableParams.ADDRESSTAIL_SMT_GETSOURCELOCATION;
         GloableParams.ADDRESS_SMT_GETSOURCELOCATION = uriHead + GloableParams.ADDRESSTAIL_SMT_GETSOURCELOCATION;
         GloableParams.ADDRESS_SMT_FILLDATAGRIDVIEW = uriHead + GloableParams.ADDRESSTAIL_SMT_FILLDATAGRIDVIEW;
         GloableParams.ADDRESS_SMT_FILLDATAGRIDVIEW = uriHead + GloableParams.ADDRESSTAIL_SMT_FILLDATAGRIDVIEW;
-
+        GloableParams.ADDRESS_SMT_POSITIONLOCATION = uriHead + GloableParams.ADDRESSTAIL_SMT_POSITIONLOCATION;
+        GloableParams.ADDRESS_SMT_POSITIONBARCODE = uriHead + GloableParams.ADDRESSTAIL_SMT_POSITIONBARCODE;
+        GloableParams.ADDRESS_SMT_DEPOSITIONBARCODE = uriHead + GloableParams.ADDRESSTAIL_SMT_DEPOSITIONBARCODE;
+        GloableParams.ADDRESS_SMT_DEALLPOSITIONBARCODE = uriHead + GloableParams.ADDRESSTAIL_SMT_DEALLPOSITIONBARCODE;
 
 
 
 
     }
     }

+ 124 - 87
app/src/main/res/layout/poststockadvocate_fragment.xml

@@ -10,38 +10,35 @@
         android:layout_height="wrap_content"
         android:layout_height="wrap_content"
         android:stretchColumns="1">
         android:stretchColumns="1">
         <TableRow
         <TableRow
-            android:id="@+id/material_in_collect_num_tr"
-            android:layout_marginTop="5dp">
+            android:id="@+id/material_in_collect_num_tr">
 
 
             <TextView
             <TextView
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
                 android:gravity="center"
                 android:gravity="center"
-                android:text="归属工单"
+                android:text="归属工单:"
                 android:layout_gravity="center"
                 android:layout_gravity="center"
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
                 android:textSize="16sp"/>
                 android:textSize="16sp"/>
-
-            <com.uas.yitao_productionline.view.ClearableEditText
+            <TextView
                 android:id="@+id/modify_barcode_quantity_barcode_cet"
                 android:id="@+id/modify_barcode_quantity_barcode_cet"
                 style="@style/EditTextStyle"
                 style="@style/EditTextStyle"
                 android:layout_width="0dp"
                 android:layout_width="0dp"
+                android:layout_height="@dimen/textsize_20"
                 android:layout_weight="1"
                 android:layout_weight="1"
-                android:layout_height="30dp"
                 android:focusable="true"
                 android:focusable="true"
+                android:layout_gravity="center"
                 android:focusableInTouchMode="true"
                 android:focusableInTouchMode="true"
-                android:hint="请输入归属工单"
-                android:background="@drawable/bg_line_edittext"
                 android:imeOptions="actionSend"
                 android:imeOptions="actionSend"
-                android:textColor="@color/black"/>
-            <CheckBox
+                android:textColor="@color/black" />
+            <TextView
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
-                android:layout_height="wrap_content"
+                android:layout_height="20dp"
                 android:gravity="center"
                 android:gravity="center"
                 android:padding="10dp"
                 android:padding="10dp"
-                android:text="锁定"
+                android:text=""
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
-                android:textSize="16sp"/>
+                android:textSize="16sp" />
         </TableRow>
         </TableRow>
 
 
 
 
@@ -51,39 +48,22 @@
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
                 android:gravity="center"
                 android:gravity="center"
-                android:text="涂程"
+                android:text="途程:"
                 android:layout_gravity="center"
                 android:layout_gravity="center"
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
                 android:textSize="16sp"/>
                 android:textSize="16sp"/>
 
 
-            <com.uas.yitao_productionline.view.ClearableEditText
+            <TextView
                 android:id="@+id/ce_ma_craftcode"
                 android:id="@+id/ce_ma_craftcode"
                 style="@style/EditTextStyle"
                 style="@style/EditTextStyle"
                 android:layout_width="0dp"
                 android:layout_width="0dp"
-                android:layout_height="30dp"
+                android:layout_height="@dimen/textsize_20"
                 android:layout_weight="1"
                 android:layout_weight="1"
                 android:focusable="true"
                 android:focusable="true"
                 android:layout_gravity="center"
                 android:layout_gravity="center"
                 android:focusableInTouchMode="true"
                 android:focusableInTouchMode="true"
-                android:hint="请输入归属工单"
-                android:background="@drawable/bg_line_edittext"
                 android:imeOptions="actionSend"
                 android:imeOptions="actionSend"
                 android:textColor="@color/black" />
                 android:textColor="@color/black" />
-            <TextView
-                style="@style/tl_tv_style"
-                android:layout_height="match_parent"
-                android:gravity="center"
-                android:padding="10dp"
-                android:text=""
-                android:textColor="@color/body_text_1"
-                android:textSize="16sp"/>
-        </TableRow>
-
-
-
-        <TableRow
-            android:layout_marginTop="5dp">
-
             <TextView
             <TextView
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
                 android:layout_height="match_parent"
                 android:layout_height="match_parent"
@@ -99,13 +79,15 @@
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
                 android:gravity="left"
                 android:gravity="left"
                 android:text=""
                 android:text=""
+                android:layout_marginRight="@dimen/dp_10"
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
                 android:textSize="16sp"/>
                 android:textSize="16sp"/>
         </TableRow>
         </TableRow>
 
 
 
 
-        <TableRow
-            android:layout_marginTop="5dp">
+
+
+        <TableRow>
 
 
             <TextView
             <TextView
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
@@ -124,19 +106,10 @@
                 android:text=""
                 android:text=""
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
                 android:textSize="16sp"/>
                 android:textSize="16sp"/>
-            <TextView
-                android:id="@+id/tv_refresh"
-                style="@style/tl_tv_style"
-                android:layout_height="wrap_content"
-                android:gravity="center"
-                android:text="刷新"
-                android:background="@drawable/bg_line_edittext"
-                android:textColor="@color/body_text_1"
-                android:textSize="16sp"/>
+
         </TableRow>
         </TableRow>
 
 
-        <TableRow
-            android:layout_marginTop="5dp">
+        <TableRow>
 
 
             <TextView
             <TextView
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
@@ -153,16 +126,20 @@
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
                 android:gravity="left"
                 android:gravity="left"
                 android:text=""
                 android:text=""
+                android:layout_weight="1"
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
                 android:textSize="16sp"/>
                 android:textSize="16sp"/>
             <TextView
             <TextView
+                android:id="@+id/tv_refresh"
                 style="@style/tl_tv_style"
                 style="@style/tl_tv_style"
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
                 android:gravity="center"
                 android:gravity="center"
-                android:text="全部下料"
+                android:text="刷新"
                 android:background="@drawable/bg_line_edittext"
                 android:background="@drawable/bg_line_edittext"
                 android:textColor="@color/body_text_1"
                 android:textColor="@color/body_text_1"
-                android:textSize="16sp"/>
+                android:textSize="16sp"
+                android:layout_marginRight="@dimen/dp_10"/>
+
         </TableRow>
         </TableRow>
 
 
     </TableLayout>
     </TableLayout>
@@ -170,7 +147,7 @@
 
 
     <LinearLayout
     <LinearLayout
         android:background="@color/white"
         android:background="@color/white"
-        android:layout_marginTop="@dimen/dp_10"
+        android:layout_marginTop="5dp"
         android:orientation="horizontal"
         android:orientation="horizontal"
         android:layout_width="match_parent"
         android:layout_width="match_parent"
         android:layout_height="wrap_content">
         android:layout_height="wrap_content">
@@ -185,16 +162,31 @@
             android:textStyle="bold"
             android:textStyle="bold"
             android:text="采集信息">
             android:text="采集信息">
         </TextView>
         </TextView>
-        <CheckBox
-            android:layout_width="wrap_content"
+
+        <TextView
+            style="@style/tl_tv_style"
+            android:layout_width="0dp"
             android:layout_height="wrap_content"
             android:layout_height="wrap_content"
-            android:text="显示全部上料信息"
-            android:textSize="@dimen/textsize_16"
-            android:layout_gravity="left"
-            android:layout_marginRight="@dimen/dp_10"
-            android:visibility="gone">
-        </CheckBox>
+            android:layout_weight="1"
+            android:gravity="center"
+            android:text="备料条码汇总"
+            android:background="@drawable/bg_line_edittext"
+            android:textColor="@color/body_text_1"
+            android:layout_marginRight="5dp"
+            android:textSize="16sp"/>
 
 
+        <TextView
+            android:id="@+id/tv_all_delete"
+            style="@style/tl_tv_style"
+            android:layout_width="0dp"
+            android:layout_height="wrap_content"
+            android:layout_weight="1"
+            android:gravity="center"
+            android:text="全部下料"
+            android:background="@drawable/bg_line_edittext"
+            android:textColor="@color/body_text_1"
+            android:layout_marginRight="@dimen/dp_10"
+            android:textSize="16sp"/>
     </LinearLayout>
     </LinearLayout>
 
 
     <com.bin.david.form.core.SmartTable
     <com.bin.david.form.core.SmartTable
@@ -203,17 +195,24 @@
         android:layout_width="match_parent"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         android:layout_height="match_parent"
         android:layout_weight="1" />
         android:layout_weight="1" />
+
+
+
+
+
+
+
     <LinearLayout
     <LinearLayout
+        android:layout_marginLeft="5dp"
+        android:layout_marginRight="5dp"
         android:orientation="vertical"
         android:orientation="vertical"
         android:background="@color/white"
         android:background="@color/white"
         android:layout_width="match_parent"
         android:layout_width="match_parent"
         android:layout_height="wrap_content">
         android:layout_height="wrap_content">
-
         <TextView
         <TextView
             android:id="@+id/tv_hint"
             android:id="@+id/tv_hint"
             android:layout_width="match_parent"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_height="wrap_content"
-            android:padding="5dp"
             android:background="@color/white"
             android:background="@color/white"
             android:text="">
             android:text="">
         </TextView>
         </TextView>
@@ -222,49 +221,87 @@
             android:orientation="horizontal"
             android:orientation="horizontal"
             android:layout_width="match_parent"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_height="wrap_content"
-            android:layout_marginTop="6dp"
-            android:layout_marginBottom="@dimen/dp_10">
+            android:layout_marginTop="3dp">
             <TextView
             <TextView
+                android:layout_gravity="center"
                 android:layout_width="wrap_content"
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
-                android:textColor="@color/white"
-                android:text="物料批号">
+                android:text="工位编号:">
             </TextView>
             </TextView>
-            <com.uas.yitao_productionline.view.ClearableEditText
-                style="@style/EditTextStyle"
-                android:layout_width="0dp"
-                android:layout_weight="1"
-                android:enabled="false"
-                android:focusable="true"
-                android:focusableInTouchMode="true"
-                android:background="@drawable/bg_line_edittext"
-                android:hint="请输入物料批号"
-                android:inputType="numberDecimal"
-                android:textColor="@color/black"/>
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:background="@drawable/bg_line_edittext">
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:background="@drawable/bg_line_edittext">
+                    <com.uas.yitao_productionline.view.ClearableEditText
+                        android:id="@+id/ce_station"
+                        style="@style/EditTextStyle"
+                        android:layout_weight="1"
+                        android:layout_height="30dp"
+                        android:background="@null"
+                        android:focusable="true"
+                        android:focusableInTouchMode="true"
+                        android:hint="请输入工位编号"
+                        android:imeOptions="actionSend"
+                        android:textColor="@color/black" />
+
+                    <ImageView
+                        android:id="@+id/iv_station"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_gravity="center"
+                        android:layout_marginRight="10dp"
+                        android:clickable="false"
+                        android:src="@drawable/ic_edittext_scan" />
+                </LinearLayout>
+
+
+            </LinearLayout>
+
         </LinearLayout>
         </LinearLayout>
         <LinearLayout
         <LinearLayout
             android:background="@color/white"
             android:background="@color/white"
             android:orientation="horizontal"
             android:orientation="horizontal"
             android:layout_width="match_parent"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_height="wrap_content"
-            android:layout_marginTop="6dp"
+            android:layout_marginTop="2dp"
             android:layout_marginBottom="@dimen/dp_10">
             android:layout_marginBottom="@dimen/dp_10">
             <TextView
             <TextView
+                android:layout_gravity="center"
+                android:background="@color/white"
                 android:layout_width="wrap_content"
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_height="wrap_content"
-                android:text="物料批号">
+                android:text="物料批号:">
             </TextView>
             </TextView>
-            <com.uas.yitao_productionline.view.ClearableEditText
-                style="@style/EditTextStyle"
-                android:layout_width="0dp"
-                android:layout_weight="1"
-                android:enabled="false"
-                android:focusable="true"
-                android:focusableInTouchMode="true"
-                android:background="@drawable/bg_line_edittext"
-                android:hint="请输入物料批号"
-                android:inputType="numberDecimal"
-                android:textColor="@color/black"/>
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:background="@drawable/bg_line_edittext">
+
+                <com.uas.yitao_productionline.view.ClearableEditText
+                    android:id="@+id/ce_material_lot_number"
+                    style="@style/EditTextStyle"
+                    android:layout_height="30dp"
+                    android:layout_weight="1"
+                    android:background="@null"
+                    android:focusable="true"
+                    android:focusableInTouchMode="true"
+                    android:hint="请输入物料批号"
+                    android:imeOptions="actionSend"
+                    android:textColor="@color/black" />
+
+                <ImageView
+                    android:id="@+id/iv_material_lot_number"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center"
+                    android:layout_marginRight="10dp"
+                    android:clickable="false"
+                    android:src="@drawable/ic_edittext_scan" />
+            </LinearLayout>
         </LinearLayout>
         </LinearLayout>
     </LinearLayout>
     </LinearLayout>