| | |
| | | import android.view.LayoutInflater; |
| | | import android.view.View; |
| | | import android.view.ViewGroup; |
| | | import android.widget.Button; |
| | | import android.widget.EditText; |
| | | import android.widget.TextView; |
| | | |
| | | import androidx.annotation.NonNull; |
| | | import androidx.appcompat.widget.AppCompatImageButton; |
| | |
| | | |
| | | public class EditeAdapter extends RecyclerView.Adapter<EditeAdapter.ViewHolder> { |
| | | |
| | | private static List<Item> itemList; |
| | | private static List<AGVCar> itemList; |
| | | |
| | | public EditeAdapter(List<Item> itemList) { |
| | | public EditeAdapter(List<AGVCar> itemList) { |
| | | this.itemList = itemList; |
| | | } |
| | | |
| | |
| | | // 文本变化之后 |
| | | int position = getAdapterPosition(); |
| | | if (position != RecyclerView.NO_POSITION) { |
| | | Item item = itemList.get(position); |
| | | AGVCar item = itemList.get(position); |
| | | item.setAgvNo(s.toString()); // 更新数据源 |
| | | } |
| | | } |
| | |
| | | // 文本变化之后 |
| | | int position = getAdapterPosition(); |
| | | if (position != RecyclerView.NO_POSITION) { |
| | | Item item = itemList.get(position); |
| | | AGVCar item = itemList.get(position); |
| | | item.setIp(s.toString()); // 更新数据源 |
| | | } |
| | | } |
| | |
| | | // 默认显示页面 |
| | | //return 1; |
| | | } else { |
| | | Item item = itemList.get(position); |
| | | AGVCar item = itemList.get(position); |
| | | int status = item.getStatus(); |
| | | switch (status) { |
| | | case 0: |