@@ -204,19 +211,20 @@ export default {
{field: 'truck_code', sortable: true, title: '车辆编码', width: 120}, // 车辆编码
{field: 'truck_name', sortable: true, title: '车辆名称', width: 120}, // 车辆名称
{field: 'truck_number', sortable: true, title: '车牌号', width: 120}, // 车牌号
- {field: 'tire_type', sortable: true, title: '类型', width: 70 ,slots:{ default:"tire_type"}}, // 轮胎更换类型: 1.更换,2.补胎
- {field: 'tire_brand', sortable: true, title: '品牌', width: 100}, // 轮胎品牌
- {field: 'tire_model', sortable: true, title: '型号', width: 100}, // 轮胎型号
+ // {field: 'tire_type', sortable: true, title: '类型', width: 70 ,slots:{ default:"tire_type"}}, // 轮胎更换类型: 1.更换,2.补胎
+ // {field: 'tire_brand', sortable: true, title: '品牌', width: 100}, // 轮胎品牌
+ // {field: 'tire_model', sortable: true, title: '型号', width: 100}, // 轮胎型号
+ {field: 'tire_date', sortable: true, title: '更换日期', formatter: 'formatDate',width: 120}, // 轮胎更换日期
+ {field: 'last_mileage', sortable: true, title: '更换时公里数', width: 130}, // 更换公里数
+ {field: 'mileage', sortable: true, title: '使用公里数', width: 120}, // 轮胎使用公里数
+ {field: 'tire_change_date', sortable: true, title: '更换日期间隔',width: 150,slots:{ default:"tire_change_date"}}, // 轮胎更换日期间隔
+ {field: 'tire_change_mileage', sortable: true, title: '更换间隔(公里数)', width: 150}, // 轮胎更换公里数间隔
+ {field: 'tire_abolish_date', sortable: true, title: '作废日期',formatter: 'formatDate', width: 120}, // 轮胎作废日期
+ {field: 'tire_abolish_mileage', sortable: true, title: '作废公里数', width: 120}, // 轮胎作废公里数
{field: 'tire_count', sortable: true, title: '更换数量', width: 100}, // 轮胎更换数量
{field: 'tire_price', sortable: true, title: '价格(元)', width: 120}, // 轮胎更换价格
{field: 'tire_number', sortable: true, title: '胎号', width: 150}, // 轮胎胎号
{field: 'old_tire_number', sortable: true, title: '旧胎号', width: 150}, // 轮胎更换旧胎号
- {field: 'last_mileage', sortable: true, title: '更换时公里数', width: 130}, // 更换公里数
- {field: 'mileage', sortable: true, title: '使用公里数', width: 120}, // 轮胎使用公里数
- {field: 'tire_change_date', sortable: true, title: '更换日期间隔',formatter: 'formatDate', width: 150}, // 轮胎更换日期间隔
- {field: 'tire_change_mileage', sortable: true, title: '更换公里数间隔', width: 150}, // 轮胎更换公里数间隔
- {field: 'tire_abolish_date', sortable: true, title: '作废日期',formatter: 'formatDate', width: 120}, // 轮胎作废日期
- {field: 'tire_abolish_mileage', sortable: true, title: '作废公里数', width: 120}, // 轮胎作废公里数
{field: 'tire_remark', sortable: true, title: '备注', width: 250}, // 轮胎更换备注
{
@@ -232,7 +240,8 @@ export default {
// =============================== 表格列 自动生成 Start ===============================
- {title: '操作', slots: {default: 'op'}, width: 120,fixed: 'right'}
+ {title: '轮胎作废', slots: {default: 'op1'}, width: 110,fixed: 'right'},
+ {title: '操作', slots: {default: 'op'}, width: 80,fixed: 'right'}
]
}
@@ -250,6 +259,10 @@ export default {
// desc() {
// return this.$t('pageDesc')
// }
+ currentTime() {
+ // 当前时间的时间戵
+ return Math.floor(Date.now() / 1000);
+ }
},
// 创建完成
@@ -334,11 +347,34 @@ export default {
// 编辑
pageEdit(row) {
- if (!row) { // 如果没有选中行
- this.$mk.msg("请选择行"); // 提示
- return; // 返回
- }
- this.$openPage("/Tire/TireUpdate/" + row[this.keyName]); // 打开页面
+ // let rows = row ? [row] : this.$refs.xGrid.getCheckboxRecords(); // 获取选中行
+ // let ids = []; // 定义id数组
+ // rows.forEach((row) => { // 遍历选中行
+ // ids.push(row[this.keyName]); // 将选择行的id添加到id数组
+ // });
+
+ // if (!ids.length) { // 如果没有选中行
+ // this.$mk.error("请选择行"); // 提示
+ // return;
+ // }
+
+ this.$mk.confirm('您确定要将轮胎作废吗?').then(type => { // 确认删除
+ if (type == 'confirm') { // 如果确认删除
+ this.$mk.post({
+ url: this.actions.TireAbolish, // 请求删除数据地址
+ loading: "处理中...", // 加载提示
+ data: {
+ id: row.id // 传递id数组
+ },
+ useBigInt: true
+ }).then(() => { // 成功
+ this.$mk.success("轮胎作废成功"); // 提示成功
+ this.onSearch(); // 重新加载数据
+ }).catch((a) => { // 失败
+ this.$mk.error(a.data.msg); // 提示错误信息
+ });
+ }
+ });
},
// 删除
@@ -357,7 +393,7 @@ export default {
this.$mk.confirm('您确定要删除吗?').then(type => { // 确认删除
if (type == 'confirm') { // 如果确认删除
this.$mk.post({
- url: this.actions.delete, // 请求删除数据地址
+ url: this.actions.TireBatchDelete, // 请求删除数据地址
loading: "删除中...", // 加载提示
data: {
ids: ids // 传递id数组
diff --git a/src/pages/Middle/transport/TrainNumber/TrainNumber/Edit.vue b/src/pages/Middle/transport/TrainNumber/TrainNumber/Edit.vue
index 64da8d3..a36892f 100644
--- a/src/pages/Middle/transport/TrainNumber/TrainNumber/Edit.vue
+++ b/src/pages/Middle/transport/TrainNumber/TrainNumber/Edit.vue
@@ -733,6 +733,8 @@ export default {
let save = () => {
+ // this.formOptions.data.outsourcing_driver_phone转换为字符串
+ this.formOptions.data.outsourcing_driver_phone = String(this.formOptions.data.outsourcing_driver_phone)
// 如果是新增模式,提交新增接口 如果是编辑模式,提交编辑接口
let action = !this.isEdit ? this.actions.create : this.actions.update;
diff --git a/src/pages/Middle/transport/Truck/Truck/Detail.vue b/src/pages/Middle/transport/Truck/Truck/Detail.vue
index 6ce03f0..35b5474 100644
--- a/src/pages/Middle/transport/Truck/Truck/Detail.vue
+++ b/src/pages/Middle/transport/Truck/Truck/Detail.vue
@@ -4,11 +4,7 @@
-
+
{{ data.code }}
@@ -54,14 +50,28 @@
+
+
+ 出车记录
+
+
+
+
+
+
+
+
+
+