代码优化
This commit is contained in:
parent
9d4fc72589
commit
d1067fb61a
|
|
@ -24,6 +24,7 @@ declare module 'vue' {
|
|||
ElEmpty: typeof import('element-plus/es')['ElEmpty']
|
||||
ElForm: typeof import('element-plus/es')['ElForm']
|
||||
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
||||
ElHeader: typeof import('element-plus/es')['ElHeader']
|
||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||
ElImage: typeof import('element-plus/es')['ElImage']
|
||||
ElInput: typeof import('element-plus/es')['ElInput']
|
||||
|
|
@ -31,6 +32,7 @@ declare module 'vue' {
|
|||
ElMenu: typeof import('element-plus/es')['ElMenu']
|
||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
||||
ElOption: typeof import('element-plus/es')['ElOption']
|
||||
ElPageHeader: typeof import('element-plus/es')['ElPageHeader']
|
||||
ElPagination: typeof import('element-plus/es')['ElPagination']
|
||||
ElPopconfirm: typeof import('element-plus/es')['ElPopconfirm']
|
||||
ElProgress: typeof import('element-plus/es')['ElProgress']
|
||||
|
|
@ -38,6 +40,8 @@ declare module 'vue' {
|
|||
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
||||
ElRow: typeof import('element-plus/es')['ElRow']
|
||||
ElSelect: typeof import('element-plus/es')['ElSelect']
|
||||
ElStep: typeof import('element-plus/es')['ElStep']
|
||||
ElSteps: typeof import('element-plus/es')['ElSteps']
|
||||
ElTable: typeof import('element-plus/es')['ElTable']
|
||||
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
|
||||
ElTag: typeof import('element-plus/es')['ElTag']
|
||||
|
|
|
|||
|
|
@ -308,29 +308,29 @@ const routes: Array<RouteRecordRaw> = [
|
|||
// },
|
||||
// },
|
||||
// /* 订单管理(订单详情承租) */
|
||||
// {
|
||||
// path: 'orderManagementInfo',
|
||||
// name: 'orderManagementInfo',
|
||||
// component: () => import('@/views/user/orderManagement/detail.vue'),
|
||||
// meta: {
|
||||
// title: '订单详情',
|
||||
// keepAlive: true,
|
||||
// AuthFlag: false,
|
||||
// isLogin: false
|
||||
// },
|
||||
// },
|
||||
{
|
||||
path: 'orderManagementInfo',
|
||||
name: 'orderManagementInfo',
|
||||
component: () => import('@/views/user/orderManagement/detail.vue'),
|
||||
meta: {
|
||||
title: '订单详情',
|
||||
keepAlive: true,
|
||||
AuthFlag: false,
|
||||
isLogin: false
|
||||
},
|
||||
},
|
||||
// /* 订单管理(退租) */
|
||||
// {
|
||||
// path: 'rentinTermination',
|
||||
// name: 'rentinTermination',
|
||||
// component: () => import('views/user/orderManagement/orderCom/rentinTermination.vue'),
|
||||
// meta: {
|
||||
// title: '订单管理(退租)',
|
||||
// keepAlive: true,
|
||||
// AuthFlag: false,
|
||||
// isLogin: true
|
||||
// },
|
||||
// },
|
||||
{
|
||||
path: 'rentinTermination',
|
||||
name: 'rentinTermination',
|
||||
component: () => import('views/user/orderManagement/orderCom/rentinTermination.vue'),
|
||||
meta: {
|
||||
title: '订单管理(退租)',
|
||||
keepAlive: true,
|
||||
AuthFlag: false,
|
||||
isLogin: true
|
||||
},
|
||||
},
|
||||
// /* 订单管理(续租) */
|
||||
// {
|
||||
// path: 'renewalOfLease',
|
||||
|
|
|
|||
|
|
@ -47,6 +47,8 @@ import imgSrc from '@/assets/img/logo.png'
|
|||
|
||||
const handleSelect = (name: any, path: any) => {
|
||||
// store.editcurrentMenuItem(name)
|
||||
|
||||
store.editcurrentMenuItem(name)
|
||||
router.push({
|
||||
name,
|
||||
})
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@
|
|||
import { ref } from 'vue'
|
||||
import PagingComponent from 'components/PagingComponent/index.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { getOrderListApi,passApi,failApi } from 'http/api/usercenter/seekorder'
|
||||
import { getOrderListApi, passApi, failApi } from 'http/api/usercenter/seekorder'
|
||||
import uploadComponent from 'components/uploadComponent/index.vue'
|
||||
import previewImg from './previewImg/index.vue'
|
||||
import { ElMessage,ElMessageBox } from 'element-plus'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import type { FormInstance } from 'element-plus'
|
||||
import { useStore } from 'store/user'
|
||||
const store = useStore()
|
||||
|
|
@ -45,8 +45,8 @@ const statusList = [
|
|||
/** 查询列表 */
|
||||
const getList = async () => {
|
||||
if (time.value.length > 0) {
|
||||
const dateStart = new Date(time.value[0]);
|
||||
const dateEnd = new Date(time.value[1]);
|
||||
const dateStart = new Date(time.value[0])
|
||||
const dateEnd = new Date(time.value[1])
|
||||
queryParams.value.startTime = dateStart.toLocaleDateString('en-CA')
|
||||
queryParams.value.endTime = dateEnd.toLocaleDateString('en-CA')
|
||||
} else {
|
||||
|
|
@ -72,7 +72,7 @@ onMounted(() => {
|
|||
|
||||
// 查询按钮
|
||||
const queryTableList = () => {
|
||||
queryParams.value.pageNum=1
|
||||
queryParams.value.pageNum = 1
|
||||
getList()
|
||||
}
|
||||
|
||||
|
|
@ -86,111 +86,117 @@ const resetTableList = (formEl: FormInstance | undefined) => {
|
|||
|
||||
// 全选事件
|
||||
const onChangeCompany = (e: boolean, index: number, item: any) => {
|
||||
cardList.value[index].detailsList.forEach((item:any)=>{
|
||||
if(item.orderStatus=="2"){
|
||||
item.isChecked = e;
|
||||
cardList.value[index].detailsList.forEach((item: any) => {
|
||||
if (item.orderStatus == '2') {
|
||||
item.isChecked = e
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 单选事件
|
||||
const onChangeGoods = (index: number) => {
|
||||
let flag = true;
|
||||
let flag = true
|
||||
for (let item of cardList.value[index].detailsList) {
|
||||
if (item.orderStatus == "2" && item.isChecked != true) {
|
||||
flag = false;
|
||||
break;
|
||||
if (item.orderStatus == '2' && item.isChecked != true) {
|
||||
flag = false
|
||||
break
|
||||
}
|
||||
}
|
||||
cardList.value[index].isChecked = flag;
|
||||
cardList.value[index].isChecked = flag
|
||||
}
|
||||
|
||||
// 出库按钮
|
||||
const confirmPass = async (index: number) => {
|
||||
let ids: number[] = [];
|
||||
cardList.value[index].detailsList.forEach((item:any)=>{
|
||||
if(item.orderStatus=="2" && item.isChecked==true){
|
||||
console.log(2222222222)
|
||||
ids.push(item.id)
|
||||
}
|
||||
})
|
||||
console.log('ids',ids)
|
||||
if(ids.length==0){
|
||||
const confirmPass = async (index: number) => {
|
||||
let ids: number[] = []
|
||||
cardList.value[index].detailsList.forEach((item: any) => {
|
||||
if (item.orderStatus == '2' && item.isChecked == true) {
|
||||
console.log(2222222222)
|
||||
ids.push(item.id)
|
||||
}
|
||||
})
|
||||
console.log('ids', ids)
|
||||
if (ids.length == 0) {
|
||||
ElMessage({
|
||||
showClose: false,
|
||||
message: '请选择装备',
|
||||
type: 'error',
|
||||
})
|
||||
return
|
||||
}else{
|
||||
} else {
|
||||
ElMessageBox.confirm('是否确定出库?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(() => {
|
||||
return passApi({'ids':ids,'orderStatus':3})
|
||||
// return removeDeviceApi([row.maId])
|
||||
}).then((res) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
message: '出库成功'
|
||||
})
|
||||
.then(() => {
|
||||
return passApi({ ids: ids, orderStatus: 3 })
|
||||
// return removeDeviceApi([row.maId])
|
||||
})
|
||||
numberTemp.value = numberTemp.value+1;
|
||||
getList()
|
||||
}
|
||||
}).catch(() => {})
|
||||
}
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
message: '出库成功',
|
||||
})
|
||||
numberTemp.value = numberTemp.value + 1
|
||||
getList()
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
}
|
||||
}
|
||||
|
||||
// 驳回按钮
|
||||
const confirmFail = async (index: number) => {
|
||||
let ids: number[] = [];
|
||||
cardList.value[index].detailsList.forEach((item:any)=>{
|
||||
if(item.orderStatus=="2" && item.isChecked==true){
|
||||
ids.push(item.id)
|
||||
}
|
||||
})
|
||||
console.log('ids',ids)
|
||||
if(ids.length==0){
|
||||
const confirmFail = async (index: number) => {
|
||||
let ids: number[] = []
|
||||
cardList.value[index].detailsList.forEach((item: any) => {
|
||||
if (item.orderStatus == '2' && item.isChecked == true) {
|
||||
ids.push(item.id)
|
||||
}
|
||||
})
|
||||
console.log('ids', ids)
|
||||
if (ids.length == 0) {
|
||||
ElMessage({
|
||||
showClose: false,
|
||||
message: '请选择装备',
|
||||
type: 'error',
|
||||
})
|
||||
return
|
||||
}else{
|
||||
} else {
|
||||
ElMessageBox.confirm('是否确定驳回?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(() => {
|
||||
return failApi({'ids':ids,'orderStatus':7})
|
||||
// return removeDeviceApi([row.maId])
|
||||
}).then((res) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
message: '驳回成功'
|
||||
})
|
||||
.then(() => {
|
||||
return failApi({ ids: ids, orderStatus: 7 })
|
||||
// return removeDeviceApi([row.maId])
|
||||
})
|
||||
numberTemp.value = numberTemp.value+1;
|
||||
getList()
|
||||
}
|
||||
}).catch(() => {})
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
message: '驳回成功',
|
||||
})
|
||||
numberTemp.value = numberTemp.value + 1
|
||||
getList()
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
}
|
||||
}
|
||||
|
||||
// 计算是否过期
|
||||
const isExpired=(goods:any)=> {
|
||||
// 获取当前日期并去掉时间部分
|
||||
const today = new Date();
|
||||
today.setHours(0, 0, 0, 0);
|
||||
const isExpired = (goods: any) => {
|
||||
// 获取当前日期并去掉时间部分
|
||||
const today = new Date()
|
||||
today.setHours(0, 0, 0, 0)
|
||||
|
||||
// 将endtime转为Date对象
|
||||
const endTime = new Date(goods.rentEndTime.replace(/-/g, "/"));
|
||||
// 将endtime转为Date对象
|
||||
const endTime = new Date(goods.rentEndTime.replace(/-/g, '/'))
|
||||
|
||||
// 判断endtime是否早于今天
|
||||
return endTime < today;
|
||||
// 判断endtime是否早于今天
|
||||
return endTime < today
|
||||
}
|
||||
|
||||
/* 退租按钮 */
|
||||
|
|
@ -300,71 +306,71 @@ const handleFileSuccess2 = (response: any) => {
|
|||
}
|
||||
}
|
||||
//退租检修
|
||||
const handleViewBack = () => {
|
||||
settleinTitle.value = '退租检修'
|
||||
isEditDisabled.value = true
|
||||
equipmentDeploymentParams.value = {
|
||||
/* 企业Id */
|
||||
// ownCo: mainStore().userInfo.companyId,
|
||||
/* 租赁范围 */
|
||||
leaseScope: '',
|
||||
/* 设备所在地 */
|
||||
location: '',
|
||||
/* 省 */
|
||||
provinceId: '',
|
||||
/* 市 */
|
||||
cityId: '',
|
||||
/* 区 */
|
||||
areaId: '',
|
||||
/* 设备所在地 省 */
|
||||
addressEconomize: '',
|
||||
/* 设备所在地 市 */
|
||||
addressProvince: '',
|
||||
/* 设备所在地 区 */
|
||||
addressArea: '',
|
||||
/* 设备类型 */
|
||||
typeId: '',
|
||||
/* 设备类型大类 */
|
||||
deviceType: '',
|
||||
/* 设备类型子类 */
|
||||
deviceTypeSon: '',
|
||||
/* 设备类型小类*/
|
||||
deviceTypeSun: '',
|
||||
/* 设备品牌 */
|
||||
brand: '',
|
||||
/* 设备型号 */
|
||||
modelName: '',
|
||||
/* 出场日期 */
|
||||
productionDate: '',
|
||||
/* 工作小时数 */
|
||||
workingHours: '',
|
||||
/* 整机序列号 */
|
||||
serialNumber: '',
|
||||
/* 月租金 */
|
||||
monthLeasePrice: '',
|
||||
/* 日租金 */
|
||||
dayLeasePrice: '',
|
||||
/* 是否提供机手 */
|
||||
isOperator: '',
|
||||
/* 机手月费用 */
|
||||
jsMonthPrice: '',
|
||||
/* 机手日费用 */
|
||||
jsDayPrice: '',
|
||||
/* 详细说明 */
|
||||
description: '',
|
||||
/* 设备主图片 */
|
||||
picUrl: '',
|
||||
/* 检测信息 ,保险信息*/
|
||||
fileList: [],
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
// 打开退组检修弹框
|
||||
dialogFormVisibleSettlein.value = true
|
||||
const handleViewBack = () => {
|
||||
settleinTitle.value = '退租检修'
|
||||
isEditDisabled.value = true
|
||||
equipmentDeploymentParams.value = {
|
||||
/* 企业Id */
|
||||
// ownCo: mainStore().userInfo.companyId,
|
||||
/* 租赁范围 */
|
||||
leaseScope: '',
|
||||
/* 设备所在地 */
|
||||
location: '',
|
||||
/* 省 */
|
||||
provinceId: '',
|
||||
/* 市 */
|
||||
cityId: '',
|
||||
/* 区 */
|
||||
areaId: '',
|
||||
/* 设备所在地 省 */
|
||||
addressEconomize: '',
|
||||
/* 设备所在地 市 */
|
||||
addressProvince: '',
|
||||
/* 设备所在地 区 */
|
||||
addressArea: '',
|
||||
/* 设备类型 */
|
||||
typeId: '',
|
||||
/* 设备类型大类 */
|
||||
deviceType: '',
|
||||
/* 设备类型子类 */
|
||||
deviceTypeSon: '',
|
||||
/* 设备类型小类*/
|
||||
deviceTypeSun: '',
|
||||
/* 设备品牌 */
|
||||
brand: '',
|
||||
/* 设备型号 */
|
||||
modelName: '',
|
||||
/* 出场日期 */
|
||||
productionDate: '',
|
||||
/* 工作小时数 */
|
||||
workingHours: '',
|
||||
/* 整机序列号 */
|
||||
serialNumber: '',
|
||||
/* 月租金 */
|
||||
monthLeasePrice: '',
|
||||
/* 日租金 */
|
||||
dayLeasePrice: '',
|
||||
/* 是否提供机手 */
|
||||
isOperator: '',
|
||||
/* 机手月费用 */
|
||||
jsMonthPrice: '',
|
||||
/* 机手日费用 */
|
||||
jsDayPrice: '',
|
||||
/* 详细说明 */
|
||||
description: '',
|
||||
/* 设备主图片 */
|
||||
picUrl: '',
|
||||
/* 检测信息 ,保险信息*/
|
||||
fileList: [],
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
// 打开退组检修弹框
|
||||
dialogFormVisibleSettlein.value = true
|
||||
}
|
||||
|
||||
const settlemoneyTitle = ref('')
|
||||
const moneyParams1: any = ref({
|
||||
|
|
@ -389,34 +395,34 @@ const moneyParams3: any = ref({
|
|||
unitName: '',
|
||||
})
|
||||
const tableData: any = ref([
|
||||
{
|
||||
name1:'测试1',
|
||||
name2:'测试1-1',
|
||||
name3:'测试1-2',
|
||||
jy1:'外观1-1',
|
||||
jy2:'故障1-2',
|
||||
jy3:'外观1-2',
|
||||
jy4:'故障1-2',
|
||||
jy5:'外观1-3',
|
||||
jy6:'故障1-3',
|
||||
jy7:'',
|
||||
jy8:'',
|
||||
remark:'备注1',
|
||||
},
|
||||
{
|
||||
name1:'测试2',
|
||||
name2:'测试2-1',
|
||||
name3:'测试2-2',
|
||||
jy1:'外观2-1',
|
||||
jy2:'故障2-2',
|
||||
jy3:'外观2-2',
|
||||
jy4:'故障2-2',
|
||||
jy5:'外观2-3',
|
||||
jy6:'故障2-3',
|
||||
jy7:'',
|
||||
jy8:'',
|
||||
remark:'备注2',
|
||||
}
|
||||
name1: '测试1',
|
||||
name2: '测试1-1',
|
||||
name3: '测试1-2',
|
||||
jy1: '外观1-1',
|
||||
jy2: '故障1-2',
|
||||
jy3: '外观1-2',
|
||||
jy4: '故障1-2',
|
||||
jy5: '外观1-3',
|
||||
jy6: '故障1-3',
|
||||
jy7: '',
|
||||
jy8: '',
|
||||
remark: '备注1',
|
||||
},
|
||||
{
|
||||
name1: '测试2',
|
||||
name2: '测试2-1',
|
||||
name3: '测试2-2',
|
||||
jy1: '外观2-1',
|
||||
jy2: '故障2-2',
|
||||
jy3: '外观2-2',
|
||||
jy4: '故障2-2',
|
||||
jy5: '外观2-3',
|
||||
jy6: '故障2-3',
|
||||
jy7: '',
|
||||
jy8: '',
|
||||
remark: '备注2',
|
||||
},
|
||||
])
|
||||
|
||||
const partItems1: any = ref([{}])
|
||||
|
|
@ -425,200 +431,206 @@ const partItems3: any = ref([{}])
|
|||
// 费用结算弹框显示隐藏
|
||||
const dialogFormVisibleSettlemoney: any = ref(false)
|
||||
//费用结算
|
||||
const handleViewMoney = () => {
|
||||
settlemoneyTitle.value = '费用结算'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
moneyParams2.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
moneyParams3.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
// 打开退组检修弹框
|
||||
dialogFormVisibleSettlemoney.value = true
|
||||
const handleViewMoney = () => {
|
||||
settlemoneyTitle.value = '费用结算'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
moneyParams2.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
moneyParams3.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
// 打开退组检修弹框
|
||||
dialogFormVisibleSettlemoney.value = true
|
||||
}
|
||||
|
||||
//维修费用
|
||||
const addPartItem1=()=> {
|
||||
partItems1.value.push({ partType: "", num: "", isCharge: "" });
|
||||
}
|
||||
const removePartItem1 =(index:number)=> {
|
||||
if (partItems1.value.length > 1) {
|
||||
partItems1.value.splice(index, 1);
|
||||
}
|
||||
//维修费用
|
||||
const addPartItem1 = () => {
|
||||
partItems1.value.push({ partType: '', num: '', isCharge: '' })
|
||||
}
|
||||
const removePartItem1 = (index: number) => {
|
||||
if (partItems1.value.length > 1) {
|
||||
partItems1.value.splice(index, 1)
|
||||
}
|
||||
}
|
||||
|
||||
//报废费用
|
||||
const addPartItem2=()=> {
|
||||
partItems2.value.push({ partType: "", num: "", isCharge: "" });
|
||||
}
|
||||
const removePartItem2 =(index:number)=> {
|
||||
if (partItems2.value.length > 1) {
|
||||
partItems2.value.splice(index, 1);
|
||||
}
|
||||
//报废费用
|
||||
const addPartItem2 = () => {
|
||||
partItems2.value.push({ partType: '', num: '', isCharge: '' })
|
||||
}
|
||||
const removePartItem2 = (index: number) => {
|
||||
if (partItems2.value.length > 1) {
|
||||
partItems2.value.splice(index, 1)
|
||||
}
|
||||
}
|
||||
|
||||
//报废费用 修改
|
||||
const addPartItem3=()=> {
|
||||
partItems3.value.push({ partType: "", num: "", isCharge: "" });
|
||||
}
|
||||
const removePartItem3 =(index:number)=> {
|
||||
if (partItems3.value.length > 1) {
|
||||
partItems3.value.splice(index, 1);
|
||||
}
|
||||
//报废费用 修改
|
||||
const addPartItem3 = () => {
|
||||
partItems3.value.push({ partType: '', num: '', isCharge: '' })
|
||||
}
|
||||
const removePartItem3 = (index: number) => {
|
||||
if (partItems3.value.length > 1) {
|
||||
partItems3.value.splice(index, 1)
|
||||
}
|
||||
}
|
||||
|
||||
const settleListTitle = ref('')
|
||||
// 费用清单弹框显示隐藏
|
||||
const dialogFormVisibleSettleList: any = ref(false)
|
||||
const tableData1: any = ref([
|
||||
{
|
||||
name1:'测试1',
|
||||
name2:'测试1-1',
|
||||
name3:'3台',
|
||||
jy1:'100',
|
||||
jy2:'31',
|
||||
jy3:'2024-11-25 至2024-12-25',
|
||||
jy4:'1600',
|
||||
},
|
||||
{
|
||||
name1:'测试2',
|
||||
name2:'测试2-1',
|
||||
name3:'3台',
|
||||
jy1:'100',
|
||||
jy2:'31',
|
||||
jy3:'2024-11-25 至2024-12-25',
|
||||
jy4:'1600',
|
||||
}
|
||||
name1: '测试1',
|
||||
name2: '测试1-1',
|
||||
name3: '3台',
|
||||
jy1: '100',
|
||||
jy2: '31',
|
||||
jy3: '2024-11-25 至2024-12-25',
|
||||
jy4: '1600',
|
||||
},
|
||||
{
|
||||
name1: '测试2',
|
||||
name2: '测试2-1',
|
||||
name3: '3台',
|
||||
jy1: '100',
|
||||
jy2: '31',
|
||||
jy3: '2024-11-25 至2024-12-25',
|
||||
jy4: '1600',
|
||||
},
|
||||
])
|
||||
const tableData2: any = ref([
|
||||
{
|
||||
name1:'测试2',
|
||||
name2:'测试2-1',
|
||||
name3:'3台',
|
||||
jy1:'类型1',
|
||||
jy2:'维修中',
|
||||
jy3:'1500',
|
||||
},
|
||||
{
|
||||
name1:'测试2',
|
||||
name2:'测试2-2',
|
||||
name3:'3台',
|
||||
jy1:'类型2',
|
||||
jy2:'维修中',
|
||||
jy3:'1500',
|
||||
}
|
||||
name1: '测试2',
|
||||
name2: '测试2-1',
|
||||
name3: '3台',
|
||||
jy1: '类型1',
|
||||
jy2: '维修中',
|
||||
jy3: '1500',
|
||||
},
|
||||
{
|
||||
name1: '测试2',
|
||||
name2: '测试2-2',
|
||||
name3: '3台',
|
||||
jy1: '类型2',
|
||||
jy2: '维修中',
|
||||
jy3: '1500',
|
||||
},
|
||||
])
|
||||
const tableData3: any = ref([
|
||||
{
|
||||
name1:'测试3',
|
||||
name2:'测试3-1',
|
||||
name3:'3台',
|
||||
jy1:'轻度维修',
|
||||
jy2:'1400',
|
||||
},
|
||||
{
|
||||
name1:'测试3',
|
||||
name2:'测试3-2',
|
||||
name3:'3台',
|
||||
jy1:'轻度维修',
|
||||
jy2:'1400',
|
||||
}
|
||||
name1: '测试3',
|
||||
name2: '测试3-1',
|
||||
name3: '3台',
|
||||
jy1: '轻度维修',
|
||||
jy2: '1400',
|
||||
},
|
||||
{
|
||||
name1: '测试3',
|
||||
name2: '测试3-2',
|
||||
name3: '3台',
|
||||
jy1: '轻度维修',
|
||||
jy2: '1400',
|
||||
},
|
||||
])
|
||||
const tableData4: any = ref([
|
||||
{
|
||||
name1:'测试4',
|
||||
name2:'测试4-1',
|
||||
name3:'3台',
|
||||
jy1:'1400',
|
||||
},
|
||||
{
|
||||
name1:'测试4',
|
||||
name2:'测试4-2',
|
||||
name3:'3台',
|
||||
jy1:'1400',
|
||||
}
|
||||
name1: '测试4',
|
||||
name2: '测试4-1',
|
||||
name3: '3台',
|
||||
jy1: '1400',
|
||||
},
|
||||
{
|
||||
name1: '测试4',
|
||||
name2: '测试4-2',
|
||||
name3: '3台',
|
||||
jy1: '1400',
|
||||
},
|
||||
])
|
||||
//费用清单
|
||||
const handleViewList = () => {
|
||||
settleListTitle.value = '费用清单'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
// 打开费用清单弹框
|
||||
dialogFormVisibleSettleList.value = true
|
||||
const handleViewList = () => {
|
||||
settleListTitle.value = '费用清单'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
// 打开费用清单弹框
|
||||
dialogFormVisibleSettleList.value = true
|
||||
}
|
||||
|
||||
const tableData5: any = ref([
|
||||
{
|
||||
name1:'测试1',
|
||||
name2:'测试1-1',
|
||||
name3:'测试1-2',
|
||||
jy1:'外观1-1',
|
||||
jy2:'故障1-2',
|
||||
jy3:'外观1-2',
|
||||
jy4:'故障1-2',
|
||||
jy5:'外观1-3',
|
||||
jy6:'故障1-3',
|
||||
jy7:'',
|
||||
jy8:'',
|
||||
remark:'备注1',
|
||||
},
|
||||
{
|
||||
name1:'测试2',
|
||||
name2:'测试2-1',
|
||||
name3:'测试2-2',
|
||||
jy1:'外观2-1',
|
||||
jy2:'故障2-2',
|
||||
jy3:'外观2-2',
|
||||
jy4:'故障2-2',
|
||||
jy5:'外观2-3',
|
||||
jy6:'故障2-3',
|
||||
jy7:'',
|
||||
jy8:'',
|
||||
remark:'备注2',
|
||||
}
|
||||
name1: '测试1',
|
||||
name2: '测试1-1',
|
||||
name3: '测试1-2',
|
||||
jy1: '外观1-1',
|
||||
jy2: '故障1-2',
|
||||
jy3: '外观1-2',
|
||||
jy4: '故障1-2',
|
||||
jy5: '外观1-3',
|
||||
jy6: '故障1-3',
|
||||
jy7: '',
|
||||
jy8: '',
|
||||
remark: '备注1',
|
||||
},
|
||||
{
|
||||
name1: '测试2',
|
||||
name2: '测试2-1',
|
||||
name3: '测试2-2',
|
||||
jy1: '外观2-1',
|
||||
jy2: '故障2-2',
|
||||
jy3: '外观2-2',
|
||||
jy4: '故障2-2',
|
||||
jy5: '外观2-3',
|
||||
jy6: '故障2-3',
|
||||
jy7: '',
|
||||
jy8: '',
|
||||
remark: '备注2',
|
||||
},
|
||||
])
|
||||
const settleRepairTitle = ref('')
|
||||
const settleRepairTitle = ref('')
|
||||
// 检修详情弹框显示隐藏
|
||||
const dialogFormVisibleSettleRepair: any = ref(false)
|
||||
//检修详情
|
||||
const handleViewRepair = () => {
|
||||
settleListTitle.value = '检修详情'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: []
|
||||
}
|
||||
// 打开检修详情弹框
|
||||
dialogFormVisibleSettleRepair.value = true
|
||||
//检修详情
|
||||
const handleViewRepair = () => {
|
||||
settleListTitle.value = '检修详情'
|
||||
moneyParams1.value = {
|
||||
/* 设备状态 */
|
||||
maStatus: 15,
|
||||
detectionList: [],
|
||||
insureList: [],
|
||||
picList: [],
|
||||
}
|
||||
// 打开检修详情弹框
|
||||
dialogFormVisibleSettleRepair.value = true
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<!-- 订单管理 -->
|
||||
<div class="container">
|
||||
<el-form :model="queryParams" ref="queryFormRef" :inline="true" size="default" label-width="0">
|
||||
<el-form
|
||||
:model="queryParams"
|
||||
ref="queryFormRef"
|
||||
:inline="true"
|
||||
size="default"
|
||||
label-width="0"
|
||||
>
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item prop="deviceName">
|
||||
|
|
@ -809,7 +821,12 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
<el-row class="cart-list" v-for="(goods, j) in item.detailsList" :key="j">
|
||||
<el-col :span="1">
|
||||
<div style="text-align: center">
|
||||
<el-checkbox :key="numberTemp" v-model="goods.isChecked" @change="onChangeGoods(index)" :disabled="goods.orderStatus!='2'">
|
||||
<el-checkbox
|
||||
:key="numberTemp"
|
||||
v-model="goods.isChecked"
|
||||
@change="onChangeGoods(index)"
|
||||
:disabled="goods.orderStatus != '2'"
|
||||
>
|
||||
</el-checkbox>
|
||||
</div>
|
||||
</el-col>
|
||||
|
|
@ -847,38 +864,68 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '3'"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #C76F60"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #c76f60;
|
||||
"
|
||||
>
|
||||
{{ '待收货' }}
|
||||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '4' && isExpired(goods)"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #008D06"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #008d06;
|
||||
"
|
||||
>
|
||||
{{ '租赁中' }}
|
||||
<span style="color: red">(已过期)</span>
|
||||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '4' && !isExpired(goods)"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #008D06"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #008d06;
|
||||
"
|
||||
>
|
||||
{{ '租赁中' }}
|
||||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '5'"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #5B33CC"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #5b33cc;
|
||||
"
|
||||
>
|
||||
{{ '已退租' }}
|
||||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '6'"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #C00017"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #c00017;
|
||||
"
|
||||
>
|
||||
{{ '已完成' }}
|
||||
</div>
|
||||
<div
|
||||
v-if="goods.orderStatus == '7'"
|
||||
style="font-size: 14px; font-weight: bold; margin-bottom: 10px; color: #797979"
|
||||
style="
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
color: #797979;
|
||||
"
|
||||
>
|
||||
{{ '已驳回' }}
|
||||
</div>
|
||||
|
|
@ -902,7 +949,7 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
租赁协议
|
||||
</el-button>
|
||||
<el-button
|
||||
v-if="goods.orderStatus=='5'"
|
||||
v-if="goods.orderStatus == '5'"
|
||||
@click="handleViewBack(j)"
|
||||
type="text"
|
||||
size="mini"
|
||||
|
|
@ -911,7 +958,7 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
退租检修
|
||||
</el-button>
|
||||
<el-button
|
||||
v-if="goods.orderStatus=='5'"
|
||||
v-if="goods.orderStatus == '5'"
|
||||
@click="handleViewMoney(j)"
|
||||
type="text"
|
||||
size="mini"
|
||||
|
|
@ -919,8 +966,8 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
>
|
||||
费用结算
|
||||
</el-button>
|
||||
<el-button
|
||||
v-if="goods.orderStatus=='6'"
|
||||
<el-button
|
||||
v-if="goods.orderStatus == '6'"
|
||||
@click="handleViewRepair(j)"
|
||||
type="text"
|
||||
size="mini"
|
||||
|
|
@ -928,8 +975,8 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
>
|
||||
检修详情
|
||||
</el-button>
|
||||
<el-button
|
||||
v-if="goods.orderStatus=='6'"
|
||||
<el-button
|
||||
v-if="goods.orderStatus == '6'"
|
||||
@click="handleViewList(j)"
|
||||
type="text"
|
||||
size="mini"
|
||||
|
|
@ -947,7 +994,6 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
:pageNumber="pageNumber"
|
||||
:total="total"
|
||||
/>
|
||||
|
||||
</div>
|
||||
<!-- 退租检修弹框 -->
|
||||
<el-dialog
|
||||
|
|
@ -1105,10 +1151,7 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
<span class="imgItem__icon hide" @click="picturePreview(item)">
|
||||
<i class="el-icon-zoom-in" />
|
||||
</span>
|
||||
<span
|
||||
class="imgItem__icon hide"
|
||||
@click="handleRemove(mainFileList, index)"
|
||||
>
|
||||
<span class="imgItem__icon hide" @click="handleRemove(mainFileList, index)">
|
||||
<i class="el-icon-delete" />
|
||||
</span>
|
||||
</div>
|
||||
|
|
@ -1533,13 +1576,14 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
</el-dialog>
|
||||
|
||||
<!-- 费用清单弹框 -->
|
||||
<el-dialog
|
||||
<el-dialog
|
||||
v-model="dialogFormVisibleSettleList"
|
||||
:title="settleListTitle"
|
||||
width="60%"
|
||||
align-center
|
||||
:close-on-click-modal="false">
|
||||
<div style="height: 80px">
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div style="height: 80px">
|
||||
<div
|
||||
class="info"
|
||||
style="margin-top: 5px; margin-bottom: 8px; display: flex; flex-wrap: wrap"
|
||||
|
|
@ -1603,7 +1647,7 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
<span class="title-text">租赁费用明细</span>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 表格 -->
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
:data="tableData1"
|
||||
class="table"
|
||||
|
|
@ -1686,11 +1730,12 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
</el-dialog>
|
||||
|
||||
<!-- 检修详情弹框 -->
|
||||
<el-dialog
|
||||
<el-dialog
|
||||
v-model="dialogFormVisibleSettleRepair"
|
||||
:title="settleRepairTitle"
|
||||
width="60%"
|
||||
:close-on-click-modal="false">
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div style="height: 80px">
|
||||
<div
|
||||
class="info"
|
||||
|
|
@ -1709,7 +1754,6 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
<span>订单编号:10000212135656</span>
|
||||
</div>
|
||||
|
||||
|
||||
<div
|
||||
class="item"
|
||||
style="width: 48%; flex-shrink: 0; margin-bottom: 1px; font-size: 16px"
|
||||
|
|
@ -1896,7 +1940,7 @@ const dialogFormVisibleSettleRepair: any = ref(false)
|
|||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 13px;
|
||||
|
||||
|
||||
div {
|
||||
text-align: center;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue