feat:执行工单
parent
6377a5db0c
commit
604b1800eb
@ -1,16 +1,45 @@
|
||||
package com.example.tyre.maintenance;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.ProgressDialog;
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.view.Window;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import java.text.Format;
|
||||
import com.google.gson.Gson;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
|
||||
public class BaseActivity extends AppCompatActivity {
|
||||
public SimpleDateFormat dateFormat=new SimpleDateFormat("yyyy-MM-dd");
|
||||
public SimpleDateFormat dateFormat ;
|
||||
public ProgressDialog dialog;
|
||||
public Context context;
|
||||
public Gson gson;
|
||||
@SuppressLint("SimpleDateFormat")
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
context = this;
|
||||
dateFormat = new SimpleDateFormat("yyyy-MM-dd");
|
||||
gson=new Gson();
|
||||
initDialog();
|
||||
|
||||
}
|
||||
|
||||
public void onBackClick(View view) {
|
||||
finish();
|
||||
}
|
||||
|
||||
private void initDialog() {
|
||||
dialog = new ProgressDialog(context);
|
||||
dialog.requestWindowFeature(Window.FEATURE_NO_TITLE);
|
||||
dialog.setCanceledOnTouchOutside(false);
|
||||
dialog.setProgressStyle(ProgressDialog.STYLE_SPINNER);
|
||||
dialog.setMessage("loading...");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -1,33 +1,98 @@
|
||||
package com.example.tyre.maintenance;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import android.os.Bundle;
|
||||
import android.text.Editable;
|
||||
import android.text.TextWatcher;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.ArrayAdapter;
|
||||
import android.widget.ListPopupWindow;
|
||||
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
|
||||
import com.example.tyre.R;
|
||||
import com.example.tyre.databinding.ActivityCreateWorkOrderBinding;
|
||||
import com.example.tyre.entity.BaseCar;
|
||||
import com.example.tyre.maintenance.dialog.TipResultDialog;
|
||||
import com.example.tyre.util.MyUrl;
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
import com.lzy.okgo.OkGo;
|
||||
import com.lzy.okgo.callback.StringCallback;
|
||||
import com.lzy.okgo.model.Response;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class CreateWorkOrderActivity extends BaseActivity {
|
||||
TipResultDialog dialog;
|
||||
|
||||
|
||||
private TipResultDialog tipDialog;
|
||||
private ActivityCreateWorkOrderBinding binding;
|
||||
private ListPopupWindow lpw;
|
||||
private boolean isSearch = false;
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
DataBindingUtil.setContentView(this,R.layout.activity_create_work_order);
|
||||
dialog = new TipResultDialog(this, this);
|
||||
ActivityCreateWorkOrderBinding binding;
|
||||
binding = DataBindingUtil.setContentView(this, R.layout.activity_create_work_order);
|
||||
tipDialog = new TipResultDialog(this, this);
|
||||
binding.createWorkCarNo.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) {
|
||||
Log.e("TAG", "onTextChanged:" + count);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterTextChanged(Editable s) {
|
||||
Log.e("TAG", "afterTextChanged:" + s);
|
||||
if (isSearch && s.length() >= 4) {
|
||||
// 搜索
|
||||
selectCarNo(s.toString());
|
||||
}
|
||||
isSearch=true;
|
||||
}
|
||||
});
|
||||
lpw = new ListPopupWindow(this);
|
||||
lpw.setAnchorView(binding.createWorkCarNo);
|
||||
lpw.setOnItemClickListener((parent, view, position, id) -> {
|
||||
isSearch=false;
|
||||
binding.createWorkCarNo.setText(parent.getItemAtPosition(position).toString());
|
||||
lpw.dismiss();
|
||||
});
|
||||
}
|
||||
|
||||
private void selectCarNo(String carNo) {
|
||||
OkGo.<String>post(MyUrl.url + "/tyre/car/PdaQueryCarList")
|
||||
.tag(this)
|
||||
.params("carNo", carNo)
|
||||
.execute(new StringCallback() {
|
||||
@Override
|
||||
public void onSuccess(Response<String> response) {
|
||||
String body = response.body();
|
||||
List<BaseCar> baseCarList = gson.fromJson(body, new TypeToken<List<BaseCar>>() {
|
||||
}.getType());
|
||||
|
||||
if (baseCarList == null || baseCarList.isEmpty())
|
||||
return;
|
||||
|
||||
List<String> carNoList = new ArrayList<>(baseCarList.size());
|
||||
baseCarList.forEach(car -> carNoList.add(car.getCarNo()));
|
||||
lpw.setAdapter(new ArrayAdapter<>(context, android.R.layout.simple_list_item_1, carNoList));
|
||||
lpw.show();
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
public void openSelectCarDialog(View view) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
public void generateWorkOrder(View view) {
|
||||
dialog.show(true, "工单生成成功", true);
|
||||
// dialog.show(true, "工单生成成功", true);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,16 @@
|
||||
package com.example.tyre.maintenance;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.example.tyre.R;
|
||||
|
||||
public class TireRepairActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_tire_repair);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,16 @@
|
||||
package com.example.tyre.maintenance;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.example.tyre.R;
|
||||
|
||||
public class TireScrapActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_tire_scrap);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,17 @@
|
||||
package com.example.tyre.maintenance;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.databinding.DataBindingUtil;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.example.tyre.R;
|
||||
|
||||
public class WorkExecuteActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
DataBindingUtil. setContentView(this,R.layout.activity_work_execute);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,187 @@
|
||||
package com.example.tyre.maintenance.been;
|
||||
|
||||
import androidx.databinding.BaseObservable;
|
||||
|
||||
/**
|
||||
* 轮胎基础信息对象 base_tyre
|
||||
*
|
||||
* @author highway
|
||||
* @date 2025-12-16
|
||||
*/
|
||||
public class BaseTyre extends BaseObservable {
|
||||
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
private Long tyreId;
|
||||
|
||||
/**
|
||||
* 胎号
|
||||
*/
|
||||
private String tyreNo;
|
||||
/**
|
||||
* 自编号
|
||||
*/
|
||||
private String selfNo;
|
||||
/**
|
||||
* RFID标签
|
||||
*/
|
||||
private String tyreEpc;
|
||||
|
||||
/**
|
||||
* 轮胎品牌
|
||||
*/
|
||||
private String tyreBrand;
|
||||
|
||||
/**
|
||||
* 轮胎型号
|
||||
*/
|
||||
private String tyreModel;
|
||||
|
||||
/**
|
||||
* 轮胎层级
|
||||
*/
|
||||
private String tyreLevel;
|
||||
|
||||
/**
|
||||
* 轮胎花纹
|
||||
*/
|
||||
private String tyrePattern;
|
||||
private String patternDepth;
|
||||
private String grooves;
|
||||
/**
|
||||
* 轮胎类别
|
||||
*/
|
||||
private String tyreType;
|
||||
|
||||
/**
|
||||
* 所属车队
|
||||
*/
|
||||
private String team;
|
||||
|
||||
private String carNo;
|
||||
private String wheelPostion;
|
||||
private Long deptId;
|
||||
|
||||
public String getPatternDepth() {
|
||||
return patternDepth;
|
||||
}
|
||||
|
||||
public void setPatternDepth(String patternDepth) {
|
||||
this.patternDepth = patternDepth;
|
||||
}
|
||||
|
||||
public String getGrooves() {
|
||||
return grooves;
|
||||
}
|
||||
|
||||
public void setGrooves(String grooves) {
|
||||
this.grooves = grooves;
|
||||
}
|
||||
|
||||
public String getSelfNo() {
|
||||
return selfNo;
|
||||
}
|
||||
|
||||
public void setSelfNo(String selfNo) {
|
||||
this.selfNo = selfNo;
|
||||
}
|
||||
|
||||
public Long getDeptId() {
|
||||
return deptId;
|
||||
}
|
||||
|
||||
public void setDeptId(Long deptId) {
|
||||
this.deptId = deptId;
|
||||
}
|
||||
|
||||
public String getCarNo() {
|
||||
return carNo;
|
||||
}
|
||||
|
||||
public void setCarNo(String carNo) {
|
||||
this.carNo = carNo;
|
||||
}
|
||||
|
||||
public String getWheelPostion() {
|
||||
return wheelPostion;
|
||||
}
|
||||
|
||||
public void setWheelPostion(String wheelPostion) {
|
||||
this.wheelPostion = wheelPostion;
|
||||
}
|
||||
|
||||
public Long getTyreId() {
|
||||
return tyreId;
|
||||
}
|
||||
|
||||
public void setTyreId(Long tyreId) {
|
||||
this.tyreId = tyreId;
|
||||
}
|
||||
|
||||
public String getTyreNo() {
|
||||
return tyreNo;
|
||||
}
|
||||
|
||||
public void setTyreNo(String tyreNo) {
|
||||
this.tyreNo = tyreNo;
|
||||
}
|
||||
|
||||
public String getTyreEpc() {
|
||||
return tyreEpc;
|
||||
}
|
||||
|
||||
public void setTyreEpc(String tyreEpc) {
|
||||
this.tyreEpc = tyreEpc;
|
||||
}
|
||||
|
||||
public String getTyreBrand() {
|
||||
return tyreBrand;
|
||||
}
|
||||
|
||||
public void setTyreBrand(String tyreBrand) {
|
||||
this.tyreBrand = tyreBrand;
|
||||
}
|
||||
|
||||
public String getTyreModel() {
|
||||
return tyreModel;
|
||||
}
|
||||
|
||||
public void setTyreModel(String tyreModel) {
|
||||
this.tyreModel = tyreModel;
|
||||
}
|
||||
|
||||
public String getTyreLevel() {
|
||||
return tyreLevel;
|
||||
}
|
||||
|
||||
public void setTyreLevel(String tyreLevel) {
|
||||
this.tyreLevel = tyreLevel;
|
||||
}
|
||||
|
||||
public String getTyrePattern() {
|
||||
return tyrePattern;
|
||||
}
|
||||
|
||||
public void setTyrePattern(String tyrePattern) {
|
||||
this.tyrePattern = tyrePattern;
|
||||
}
|
||||
|
||||
public String getTyreType() {
|
||||
return tyreType;
|
||||
}
|
||||
|
||||
public void setTyreType(String tyreType) {
|
||||
this.tyreType = tyreType;
|
||||
}
|
||||
|
||||
public String getTeam() {
|
||||
return team;
|
||||
}
|
||||
|
||||
public void setTeam(String team) {
|
||||
this.team = team;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,19 @@
|
||||
package com.example.tyre.maintenance.dialog;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
|
||||
public class SelectCarDialog extends Dialog {
|
||||
|
||||
private Gson gson;
|
||||
|
||||
public SelectCarDialog(@NonNull Context context) {
|
||||
super(context);
|
||||
gson = new Gson();
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="#E3E6EC"
|
||||
/>
|
||||
|
||||
<corners android:radius="6dp"/>
|
||||
</shape>
|
||||
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="#4B84FE" />
|
||||
<corners android:radius="8dp" />
|
||||
</shape>
|
||||
@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<shape>
|
||||
<corners
|
||||
android:radius="8dp" />
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="#F29B12" />
|
||||
</shape>
|
||||
</item>
|
||||
|
||||
<item android:height="35dp"
|
||||
|
||||
>
|
||||
<shape>
|
||||
|
||||
<corners
|
||||
android:topLeftRadius="8dp"
|
||||
android:topRightRadius="8dp" />
|
||||
<solid android:color="#F29B12" />
|
||||
</shape>
|
||||
</item>
|
||||
<!-- <item-->
|
||||
<!-- android:top="35dp">-->
|
||||
<!-- <shape>-->
|
||||
<!-- <corners android:bottomLeftRadius="8dp" android:bottomRightRadius="8dp" />-->
|
||||
<!-- <solid android:color="#4B84FE" />-->
|
||||
<!-- </shape>-->
|
||||
<!-- </item>-->
|
||||
</layer-list>
|
||||
@ -1,92 +1,100 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
tools:context=".maintenance.CreateWorkOrderActivity">
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<include
|
||||
layout="@layout/layout_activity_title"
|
||||
app:title='@{"发起新工单"}' />
|
||||
<data>
|
||||
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:background="@drawable/card_bg"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:padding="12dp">
|
||||
tools:context=".maintenance.CreateWorkOrderActivity">
|
||||
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
<include
|
||||
layout="@layout/layout_activity_title"
|
||||
app:title='@{"发起新工单"}' />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 车牌" />
|
||||
android:layout_margin="12dp"
|
||||
android:background="@drawable/card_bg"
|
||||
android:orientation="vertical"
|
||||
android:padding="12dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:text="点击选择"
|
||||
android:gravity="center|left"
|
||||
android:letterSpacing="0.1"
|
||||
android:paddingStart="12dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="@drawable/bg_select_blue"
|
||||
android:onClick="openSelectCarDialog"
|
||||
/>
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 车牌" />
|
||||
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 工单类型" />
|
||||
<EditText
|
||||
android:id="@+id/create_work_car_no"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:gravity="center|start"
|
||||
android:paddingStart="16dp"
|
||||
android:textSize="16sp"
|
||||
android:hint="输入最少四位开始检索"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="@drawable/bg_stroke_blue_1"
|
||||
/>
|
||||
|
||||
<Spinner
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:entries="@array/work_type"
|
||||
android:background="@drawable/bg_select_grey"
|
||||
android:paddingStart="12dp"/>
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 工单类型" />
|
||||
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 执行站点" />
|
||||
<Spinner
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:paddingStart="12dp"
|
||||
android:entries="@array/zxzd"
|
||||
android:background="@drawable/bg_select_grey"/>
|
||||
<Spinner
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:entries="@array/work_type"
|
||||
android:background="@drawable/bg_select_grey"
|
||||
android:paddingStart="12dp" />
|
||||
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="* 执行站点" />
|
||||
|
||||
<Spinner
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:paddingStart="12dp"
|
||||
android:entries="@array/zxzd"
|
||||
android:background="@drawable/bg_select_grey" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<Button
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="55dp"
|
||||
android:layout_margin="16dp"
|
||||
android:background="@drawable/bg_button_blue"
|
||||
android:letterSpacing="0.3"
|
||||
android:text="生成工单"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="18sp"
|
||||
android:onClick="generateWorkOrder"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<Button
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="55dp"
|
||||
android:layout_margin="16dp"
|
||||
android:background="@drawable/bg_button_blue"
|
||||
android:letterSpacing="0.3"
|
||||
android:text="生成工单"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="18sp"
|
||||
android:onClick="generateWorkOrder"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".maintenance.TireRepairActivity">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".maintenance.TireScrapActivity">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -0,0 +1,268 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center|top"
|
||||
android:orientation="vertical"
|
||||
tools:context=".maintenance.WorkExecuteActivity">
|
||||
|
||||
<include
|
||||
layout="@layout/layout_activity_title"
|
||||
app:title='@{"执行工单"}' />
|
||||
|
||||
<TextView
|
||||
style="@style/text_title_2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text='"车牌"+"粤B01260D"' />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:letterSpacing="0.1"
|
||||
android:text='"◎"+"观湖修理厂"'
|
||||
android:textColor="@color/textColor1" />
|
||||
|
||||
<androidx.gridlayout.widget.GridLayout
|
||||
style="@style/layout_card_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
app:columnCount="2"
|
||||
app:rowCount="5">
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="start|center"
|
||||
android:letterSpacing="0.1"
|
||||
android:text="*仪表盘里程(km)"
|
||||
android:textColor="@color/textColor1"
|
||||
android:textStyle="bold"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
<EditText
|
||||
android:layout_height="40dp"
|
||||
android:gravity="right|center"
|
||||
android:hint="必填"
|
||||
android:inputType="numberDecimal"
|
||||
android:onClick="selectDate"
|
||||
android:paddingEnd="10dp"
|
||||
android:textColor="@color/textColor2"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_columnWeight="1"
|
||||
tools:ignore="RtlHardcoded,RtlSymmetry" />
|
||||
|
||||
|
||||
<View
|
||||
android:layout_height="1dp"
|
||||
android:background="#F1F1F1"
|
||||
app:layout_columnSpan="2" />
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="start|center"
|
||||
android:text="上次里程"
|
||||
android:textColor="@color/textColor2"
|
||||
app:layout_columnSpan="2" />
|
||||
|
||||
|
||||
</androidx.gridlayout.widget.GridLayout>
|
||||
|
||||
<androidx.gridlayout.widget.GridLayout
|
||||
style="@style/layout_card_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="12dp"
|
||||
android:layout_marginEnd="12dp"
|
||||
app:columnCount="2"
|
||||
app:rowCount="5">
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="left|center"
|
||||
android:text="线路"
|
||||
android:textColor="@color/textColor1"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="right|center"
|
||||
android:onClick="selectDate"
|
||||
android:paddingEnd="10dp"
|
||||
android:text="保养日期"
|
||||
android:textColor="@color/textColor1"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
|
||||
<View
|
||||
android:layout_height="1dp"
|
||||
android:background="#F1F1F1"
|
||||
app:layout_columnSpan="2" />
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="left|center"
|
||||
android:text="补充说明"
|
||||
android:textColor="@color/textColor1"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
<EditText
|
||||
android:layout_height="40dp"
|
||||
android:background="@color/white"
|
||||
android:gravity="end|center"
|
||||
android:hint="选填"
|
||||
android:paddingEnd="10dp"
|
||||
android:textColor="@color/textColor1"
|
||||
android:textSize="14sp"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
|
||||
<View
|
||||
android:layout_height="1dp"
|
||||
android:background="#F1F1F1"
|
||||
app:layout_columnSpan="2" />
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="left|center"
|
||||
android:text="保养日期"
|
||||
|
||||
android:textColor="@color/textColor1"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
<TextView
|
||||
android:layout_height="40dp"
|
||||
android:gravity="end|center"
|
||||
android:onClick="switchStatus"
|
||||
android:paddingEnd="10dp"
|
||||
android:text="2026-04-09"
|
||||
android:textColor="@color/textColor1"
|
||||
app:layout_columnWeight="1" />
|
||||
|
||||
</androidx.gridlayout.widget.GridLayout>
|
||||
|
||||
<LinearLayout
|
||||
style="@style/layout_card_style"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="12dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center">
|
||||
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_weight="1"
|
||||
android:background="#E3E6EC" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:background="@drawable/bg_grey"
|
||||
android:gravity="center"
|
||||
android:text="1"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_weight="1"
|
||||
android:background="#E3E6EC" />
|
||||
|
||||
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="center">
|
||||
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp" />
|
||||
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_marginStart="4dp" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_weight="1"
|
||||
android:background="#E3E6EC" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:background="@drawable/bg_grey"
|
||||
android:gravity="center"
|
||||
android:text="2"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_weight="1"
|
||||
android:background="#E3E6EC" />
|
||||
|
||||
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp" />
|
||||
<include
|
||||
layout="@layout/layout_trae_info"
|
||||
android:layout_width="80dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_marginStart="4dp" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<Button
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="55dp"
|
||||
android:layout_margin="16dp"
|
||||
android:background="@drawable/bg_button_blue"
|
||||
android:letterSpacing="0.3"
|
||||
android:onClick="generateWorkOrder"
|
||||
android:text="完成处理"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout></layout>
|
||||
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="150dp"
|
||||
android:background="@drawable/layout_trae"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="35dp"
|
||||
android:gravity="center"
|
||||
android:text="左前"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/white" />
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
Loading…
Reference in New Issue