Merge branch 'main' into dev-wangyiming
This commit is contained in:
commit
37b1bca405
|
|
@ -10,7 +10,9 @@ declare module 'vue' {
|
||||||
ElButton: typeof import('element-plus/es')['ElButton']
|
ElButton: typeof import('element-plus/es')['ElButton']
|
||||||
ElCarousel: typeof import('element-plus/es')['ElCarousel']
|
ElCarousel: typeof import('element-plus/es')['ElCarousel']
|
||||||
ElCarouselItem: typeof import('element-plus/es')['ElCarouselItem']
|
ElCarouselItem: typeof import('element-plus/es')['ElCarouselItem']
|
||||||
ElDivider: typeof import('element-plus/es')['ElDivider']
|
ElCheckbox: typeof import('element-plus/es')['ElCheckbox']
|
||||||
|
ElCol: typeof import('element-plus/es')['ElCol']
|
||||||
|
ElDialog: typeof import('element-plus/es')['ElDialog']
|
||||||
ElForm: typeof import('element-plus/es')['ElForm']
|
ElForm: typeof import('element-plus/es')['ElForm']
|
||||||
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
||||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||||
|
|
@ -19,14 +21,13 @@ declare module 'vue' {
|
||||||
ElMenu: typeof import('element-plus/es')['ElMenu']
|
ElMenu: typeof import('element-plus/es')['ElMenu']
|
||||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
||||||
ElOption: typeof import('element-plus/es')['ElOption']
|
ElOption: typeof import('element-plus/es')['ElOption']
|
||||||
ElPageHeader: typeof import('element-plus/es')['ElPageHeader']
|
|
||||||
ElPagination: typeof import('element-plus/es')['ElPagination']
|
ElPagination: typeof import('element-plus/es')['ElPagination']
|
||||||
ElProgress: typeof import('element-plus/es')['ElProgress']
|
ElProgress: typeof import('element-plus/es')['ElProgress']
|
||||||
|
ElRow: typeof import('element-plus/es')['ElRow']
|
||||||
ElSelect: typeof import('element-plus/es')['ElSelect']
|
ElSelect: typeof import('element-plus/es')['ElSelect']
|
||||||
ElTable: typeof import('element-plus/es')['ElTable']
|
ElTable: typeof import('element-plus/es')['ElTable']
|
||||||
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
|
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
|
||||||
ElTimeline: typeof import('element-plus/es')['ElTimeline']
|
ElTag: typeof import('element-plus/es')['ElTag']
|
||||||
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
|
|
||||||
ElUpload: typeof import('element-plus/es')['ElUpload']
|
ElUpload: typeof import('element-plus/es')['ElUpload']
|
||||||
EquipCard: typeof import('./src/components/equipCard.vue')['default']
|
EquipCard: typeof import('./src/components/equipCard.vue')['default']
|
||||||
EquipDetailTable: typeof import('./src/components/equipDetailTable.vue')['default']
|
EquipDetailTable: typeof import('./src/components/equipDetailTable.vue')['default']
|
||||||
|
|
|
||||||
|
|
@ -5,11 +5,11 @@ VITE_BUILD_MODE = 'dev'
|
||||||
VITE_API_URL = '/proxyApi'
|
VITE_API_URL = '/proxyApi'
|
||||||
|
|
||||||
# 开发环境接口地址
|
# 开发环境接口地址
|
||||||
# VITE_proxyTarget = 'http://10.40.92.66:9205' #盛旭
|
VITE_proxyTarget = 'http://10.40.92.66:9205' #盛旭
|
||||||
|
|
||||||
# VITE_proxyTarget = 'http://10.40.92.185:9200' # 赵福海 (登录)
|
# VITE_proxyTarget = 'http://10.40.92.185:9200' # 赵福海 (登录)
|
||||||
|
|
||||||
VITE_proxyTarget = 'http://10.40.92.185:9206' # 赵福海 ( 设备类型)
|
# VITE_proxyTarget = 'http://10.40.92.185:9206' # 赵福海 ( 设备类型)
|
||||||
# VITE_proxyTarget = 'http://10.40.92.253:8080' # 牛 (个人中心 基础信息企业申请认证)
|
# VITE_proxyTarget = 'http://10.40.92.253:8080' # 牛 (个人中心 基础信息企业申请认证)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
const handleSelectionChange = (val: any) => {
|
const handleSelectionChange = (val: any) => {
|
||||||
const codeList = val.map((ele: any) => {
|
const codeList = val.map((ele: any) => {
|
||||||
return ele.v_code
|
return ele
|
||||||
})
|
})
|
||||||
// console.log("code", codeList)
|
// console.log("code", codeList)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,4 +10,10 @@ export const equipmentDeploymentApi = (data: any) => {
|
||||||
// 获取商品入驻列表
|
// 获取商品入驻列表
|
||||||
export const getEquipmentListApi = (data: any) => {
|
export const getEquipmentListApi = (data: any) => {
|
||||||
return post('/dev/list', data)
|
return post('/dev/list', data)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 商品删除接口
|
||||||
|
export const deleteGoodstApi = (data: any) => {
|
||||||
|
return post('/dev/remove', data)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
// 个人中心 承租下的上下架页面
|
||||||
|
|
||||||
|
import { get, post } from '../../index'
|
||||||
|
|
||||||
|
// 装备上架接口
|
||||||
|
export const goodsUpApi = (data: any) => {
|
||||||
|
return post('/off', data)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 装备下架接口
|
||||||
|
export const goodsDownApi = (data: any) => {
|
||||||
|
return post('/off/upOffList ', data)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 装备删除接口
|
||||||
|
export const goodsDeleteApi = (data: any) => {
|
||||||
|
return post('/off/remove', data)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import NProgress from 'nprogress'
|
import NProgress from 'nprogress'
|
||||||
import { useStore } from 'store/main'
|
import { useStore } from 'store/main'
|
||||||
import {ElMessage} from "element-plus";
|
import { ElMessage } from "element-plus";
|
||||||
import router from "@/router"
|
import router from "@/router"
|
||||||
const store = useStore()
|
const store = useStore()
|
||||||
// const CancelToken = axios.CancelToken
|
// const CancelToken = axios.CancelToken
|
||||||
|
|
@ -21,7 +21,7 @@ const service = axios.create({
|
||||||
|
|
||||||
service.interceptors.request.use(
|
service.interceptors.request.use(
|
||||||
(config) => {
|
(config) => {
|
||||||
config.headers['Authorization'] =VITE_ENV=='development'&&VITE_LocalFlag?VITE_token: store.token
|
config.headers['Authorization'] = VITE_ENV == 'development' && VITE_LocalFlag ? VITE_token : store.token
|
||||||
return config
|
return config
|
||||||
},
|
},
|
||||||
(error) => {
|
(error) => {
|
||||||
|
|
@ -32,12 +32,12 @@ service.interceptors.request.use(
|
||||||
service.interceptors.response.use(
|
service.interceptors.response.use(
|
||||||
(res) => {
|
(res) => {
|
||||||
const { data } = res
|
const { data } = res
|
||||||
if(data.code == '200'){
|
if (data.code == '200') {
|
||||||
return data
|
return data
|
||||||
}else if(data.code == '403'){
|
} else if (data.code == '403') {
|
||||||
ElMessage.error('请重新登录')
|
ElMessage.error('请重新登录')
|
||||||
router.push('/login')
|
router.push('/login')
|
||||||
}else{
|
} else {
|
||||||
return data
|
return data
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -154,7 +154,18 @@ const routes: Array<RouteRecordRaw> = [
|
||||||
name: 'orderManagementCz',
|
name: 'orderManagementCz',
|
||||||
component: () => import('views/user/orderManagementCz/index.vue'),
|
component: () => import('views/user/orderManagementCz/index.vue'),
|
||||||
meta: {
|
meta: {
|
||||||
title: '基础信息',
|
title: '订单管理(承租)',
|
||||||
|
keepAlive: true,
|
||||||
|
AuthFlag: false
|
||||||
|
},
|
||||||
|
},
|
||||||
|
/* 订单管理(结算) */
|
||||||
|
{
|
||||||
|
path: 'settlement',
|
||||||
|
name: 'settlement',
|
||||||
|
component: () => import('views/user/orderManagementCz/settlement/index.vue'),
|
||||||
|
meta: {
|
||||||
|
title: '订单管理(结算)',
|
||||||
keepAlive: true,
|
keepAlive: true,
|
||||||
AuthFlag: false
|
AuthFlag: false
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -255,6 +255,7 @@
|
||||||
|
|
||||||
.goods-count {
|
.goods-count {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
background-clip: #f5f5f5;
|
||||||
padding-top: 30px;
|
padding-top: 30px;
|
||||||
|
|
||||||
li {
|
li {
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,18 @@
|
||||||
import FormComponent from 'components/FormComponent/index.vue'
|
import FormComponent from 'components/FormComponent/index.vue'
|
||||||
import PagingComponent from 'components/PagingComponent/index.vue'
|
import PagingComponent from 'components/PagingComponent/index.vue'
|
||||||
import uploadComponent from 'components/uploadComponent/index.vue'
|
import uploadComponent from 'components/uploadComponent/index.vue'
|
||||||
|
import { ElMessage } from 'element-plus'
|
||||||
|
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
|
||||||
import { useStore } from 'store/user'
|
import { useStore } from 'store/user'
|
||||||
const store = useStore()
|
const store = useStore()
|
||||||
|
|
||||||
import { equipmentDeploymentApi, getEquipmentListApi } from 'http/api/usercenter/goodsmang'
|
import {
|
||||||
|
equipmentDeploymentApi,
|
||||||
|
getEquipmentListApi,
|
||||||
|
deleteGoodstApi
|
||||||
|
} from 'http/api/usercenter/goodsmang'
|
||||||
|
|
||||||
// 注册地址拼装
|
// 注册地址拼装
|
||||||
const AssemblyRegisterAddress: any = reactive([])
|
const AssemblyRegisterAddress: any = reactive([])
|
||||||
|
|
@ -87,9 +93,9 @@
|
||||||
/*
|
/*
|
||||||
* 商品入驻弹框参数
|
* 商品入驻弹框参数
|
||||||
*/
|
*/
|
||||||
const equipmentDeploymentParams = reactive({
|
const equipmentDeploymentParams: any = ref({
|
||||||
/* 租赁范围 */
|
/* 租赁范围 */
|
||||||
easeScope: '',
|
leaseScope: '',
|
||||||
/* 设备所在地 */
|
/* 设备所在地 */
|
||||||
location: '',
|
location: '',
|
||||||
/* 设备所在地 省 */
|
/* 设备所在地 省 */
|
||||||
|
|
@ -147,16 +153,24 @@
|
||||||
id: '20',
|
id: '20',
|
||||||
utr: 'https://zlpt-1259760603.cos.ap-nanjing.myqcloud.com/488bab245180ebf9f1f3d7db5301be4.png'
|
utr: 'https://zlpt-1259760603.cos.ap-nanjing.myqcloud.com/488bab245180ebf9f1f3d7db5301be4.png'
|
||||||
}
|
}
|
||||||
]
|
],
|
||||||
|
/* 设备状态 */
|
||||||
|
maStatus: 15
|
||||||
})
|
})
|
||||||
|
|
||||||
const pageSize = 20
|
const pageSize = 20
|
||||||
const pageNumber = 1
|
const pageNumber = 1
|
||||||
const total: any = 20
|
const total: any = ref(0)
|
||||||
|
|
||||||
|
const tableData: any = reactive({
|
||||||
|
list: []
|
||||||
|
})
|
||||||
|
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
const getList = async () => {
|
const getList = async () => {
|
||||||
const res = await getEquipmentListApi({})
|
const res: any = await getEquipmentListApi({})
|
||||||
console.log('获取数据列表***', res)
|
total.value = res.total
|
||||||
|
tableData.list = res.rows
|
||||||
}
|
}
|
||||||
|
|
||||||
getList()
|
getList()
|
||||||
|
|
@ -168,14 +182,88 @@
|
||||||
// 编辑按钮
|
// 编辑按钮
|
||||||
const editRowInfo = (row: any) => {
|
const editRowInfo = (row: any) => {
|
||||||
console.log(row, '编辑当前数据')
|
console.log(row, '编辑当前数据')
|
||||||
|
|
||||||
|
equipmentDeploymentParams.value = row
|
||||||
|
dialogFormVisibleSettlein.value = true
|
||||||
}
|
}
|
||||||
// 删除按钮
|
// 删除按钮
|
||||||
const deleteRowInfo = (row: any) => {
|
const deleteRowInfo = async (row: any) => {
|
||||||
console.log(row, '删除当前数据')
|
const res: any = await deleteGoodstApi([row.maId])
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '删除成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 装备入驻按钮
|
// 装备入驻按钮
|
||||||
const equipmentDeployment = () => {
|
const equipmentDeployment = () => {
|
||||||
|
equipmentDeploymentParams.value = {
|
||||||
|
/* 租赁范围 */
|
||||||
|
leaseScope: '',
|
||||||
|
/* 设备所在地 */
|
||||||
|
location: '',
|
||||||
|
/* 设备所在地 省 */
|
||||||
|
addressEconomize: '',
|
||||||
|
/* 设备所在地 市 */
|
||||||
|
addressProvince: '',
|
||||||
|
/* 设备所在地 区 */
|
||||||
|
addressArea: '',
|
||||||
|
/* 设备类型 */
|
||||||
|
typeId: '',
|
||||||
|
/* 设备类型大类 */
|
||||||
|
deviceType: '',
|
||||||
|
/* 设备类型子类 */
|
||||||
|
deviceTypeSon: '',
|
||||||
|
/* 设备类型小类*/
|
||||||
|
deviceTypeSun: '',
|
||||||
|
/* 设备品牌 */
|
||||||
|
brand: '',
|
||||||
|
/* 设备型号 */
|
||||||
|
modelName: '',
|
||||||
|
/* 出场日期 */
|
||||||
|
productionDate: '',
|
||||||
|
/* 工作小时数 */
|
||||||
|
workingHours: '',
|
||||||
|
/* 整机序列号 */
|
||||||
|
serialNumber: '',
|
||||||
|
/* 月租金 */
|
||||||
|
monthLeasePrice: '',
|
||||||
|
/* 日租金 */
|
||||||
|
dayLeasePrice: '',
|
||||||
|
/* 是否提供机手 */
|
||||||
|
isOperator: '',
|
||||||
|
/* 机手月费用 */
|
||||||
|
jsMonthPrice: '',
|
||||||
|
/* 机手日费用 */
|
||||||
|
jsDayPrice: '',
|
||||||
|
/* 详细说明 */
|
||||||
|
description: '',
|
||||||
|
/* 设备图片 */
|
||||||
|
picUrl: '',
|
||||||
|
/* 检测信息 ,保险信息*/
|
||||||
|
fileList: [
|
||||||
|
/* 检测信息 */
|
||||||
|
{
|
||||||
|
id: '28',
|
||||||
|
url: 'https://zlpt-1259760603.cos.ap-nanjing.myqcloud.com/488bab245180ebf9f1f3d7db5301be4.png'
|
||||||
|
},
|
||||||
|
/* 保险信息 */
|
||||||
|
{
|
||||||
|
id: '29',
|
||||||
|
utr: 'https://zlpt-1259760603.cos.ap-nanjing.myqcloud.com/488bab245180ebf9f1f3d7db5301be4.png'
|
||||||
|
},
|
||||||
|
/* 设备图片 */
|
||||||
|
{
|
||||||
|
id: '20',
|
||||||
|
utr: 'https://zlpt-1259760603.cos.ap-nanjing.myqcloud.com/488bab245180ebf9f1f3d7db5301be4.png'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
/* 设备状态 */
|
||||||
|
maStatus: 15
|
||||||
|
}
|
||||||
// 打开入驻弹框
|
// 打开入驻弹框
|
||||||
dialogFormVisibleSettlein.value = true
|
dialogFormVisibleSettlein.value = true
|
||||||
}
|
}
|
||||||
|
|
@ -185,10 +273,18 @@
|
||||||
// 入驻框保存提交
|
// 入驻框保存提交
|
||||||
const submitBtn = async () => {
|
const submitBtn = async () => {
|
||||||
console.log(AssemblyRegisterAddress, '地址***---***')
|
console.log(AssemblyRegisterAddress, '地址***---***')
|
||||||
equipmentDeploymentParams.location = AssemblyRegisterAddress.join(',')
|
// equipmentDeploymentParams.value.location = AssemblyRegisterAddress.join(',')
|
||||||
// equipmentDeploymentParams.typeId = deviceType.join(',')
|
// equipmentDeploymentParams.typeId = deviceType.join(',')
|
||||||
const res = await equipmentDeploymentApi(equipmentDeploymentParams)
|
const res: any = await equipmentDeploymentApi(equipmentDeploymentParams.value)
|
||||||
console.log(res, '商品入驻结果999')
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '入驻成功'
|
||||||
|
})
|
||||||
|
|
||||||
|
dialogFormVisibleSettlein.value = false
|
||||||
|
getList()
|
||||||
|
}
|
||||||
|
|
||||||
/* ruleFormRef.value.validate((valid: any) => {
|
/* ruleFormRef.value.validate((valid: any) => {
|
||||||
console.log(valid)
|
console.log(valid)
|
||||||
|
|
@ -196,62 +292,62 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
const tableProps: any = ref([
|
const tableProps: any = ref([
|
||||||
{ v_label: '编码', v_props: 'v_code', v_slot: '', width: '' },
|
{ v_label: '编码', v_props: 'code', v_slot: '', width: '' },
|
||||||
{ v_label: '租赁范围', v_props: 'v_lease_scope', v_slot: '', width: '' },
|
{ v_label: '租赁范围', v_props: 'leaseScope', v_slot: '', width: '' },
|
||||||
{ v_label: '装备类型', v_props: 'v_equipment_type', v_slot: '', width: '' },
|
{ v_label: '装备类型', v_props: 'modelName', v_slot: '', width: '' },
|
||||||
{ v_label: '装备名称', v_props: 'v_equipment_name', v_slot: '', width: '' },
|
{ v_label: '装备名称', v_props: 'v_equipment_name', v_slot: '', width: '' },
|
||||||
{ v_label: '租金', v_props: 'v_rent', v_slot: '', width: '' },
|
{ v_label: '租金', v_props: 'monthLeasePrice', v_slot: '', width: '' },
|
||||||
{ v_label: '状态', v_props: 'v_type', v_slot: 'v_type', width: '' },
|
{ v_label: '状态', v_props: 'maStatus', v_slot: 'v_type', width: '' },
|
||||||
{ v_label: '操作', v_props: 'v_operate', v_slot: 'operate', width: '140px' }
|
{ v_label: '操作', v_props: 'v_operate', v_slot: 'operate', width: '140px' }
|
||||||
])
|
])
|
||||||
|
|
||||||
const tableData: any = [
|
// const tableData: any = [
|
||||||
{
|
// {
|
||||||
v_code: '123456',
|
// v_code: '123456',
|
||||||
v_lease_scope: '2023/12/12',
|
// v_lease_scope: '2023/12/12',
|
||||||
v_equipment_type: '挖掘机',
|
// v_equipment_type: '挖掘机',
|
||||||
v_equipment_name: '2023新版挖掘机',
|
// v_equipment_name: '2023新版挖掘机',
|
||||||
v_rent: '123/月',
|
// v_rent: '123/月',
|
||||||
v_type: 1,
|
// v_type: 1,
|
||||||
v_operate: ''
|
// v_operate: ''
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
v_code: '123456',
|
// v_code: '123456',
|
||||||
v_lease_scope: '2023/12/12',
|
// v_lease_scope: '2023/12/12',
|
||||||
v_equipment_type: '挖掘机',
|
// v_equipment_type: '挖掘机',
|
||||||
v_equipment_name: '2023新版挖掘机',
|
// v_equipment_name: '2023新版挖掘机',
|
||||||
v_rent: '123/月',
|
// v_rent: '123/月',
|
||||||
v_type: 2,
|
// v_type: 2,
|
||||||
v_operate: ''
|
// v_operate: ''
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
v_code: '123456',
|
// v_code: '123456',
|
||||||
v_lease_scope: '2023/12/12',
|
// v_lease_scope: '2023/12/12',
|
||||||
v_equipment_type: '挖掘机',
|
// v_equipment_type: '挖掘机',
|
||||||
v_equipment_name: '2023新版挖掘机',
|
// v_equipment_name: '2023新版挖掘机',
|
||||||
v_rent: '123/月',
|
// v_rent: '123/月',
|
||||||
v_type: 3,
|
// v_type: 3,
|
||||||
v_operate: ''
|
// v_operate: ''
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
v_code: '123456',
|
// v_code: '123456',
|
||||||
v_lease_scope: '2023/12/12',
|
// v_lease_scope: '2023/12/12',
|
||||||
v_equipment_type: '挖掘机',
|
// v_equipment_type: '挖掘机',
|
||||||
v_equipment_name: '2023新版挖掘机',
|
// v_equipment_name: '2023新版挖掘机',
|
||||||
v_rent: '123/月',
|
// v_rent: '123/月',
|
||||||
v_type: 3,
|
// v_type: 3,
|
||||||
v_operate: ''
|
// v_operate: ''
|
||||||
},
|
// },
|
||||||
{
|
// {
|
||||||
v_code: '123456',
|
// v_code: '123456',
|
||||||
v_lease_scope: '2023/12/12',
|
// v_lease_scope: '2023/12/12',
|
||||||
v_equipment_type: '挖掘机',
|
// v_equipment_type: '挖掘机',
|
||||||
v_equipment_name: '2023新版挖掘机',
|
// v_equipment_name: '2023新版挖掘机',
|
||||||
v_rent: '123/月',
|
// v_rent: '123/月',
|
||||||
v_type: 3,
|
// v_type: 3,
|
||||||
v_operate: ''
|
// v_operate: ''
|
||||||
}
|
// }
|
||||||
]
|
// ]
|
||||||
|
|
||||||
// 表单 lable 数据
|
// 表单 lable 数据
|
||||||
const formItemList: any = ref([
|
const formItemList: any = ref([
|
||||||
|
|
@ -263,7 +359,7 @@
|
||||||
])
|
])
|
||||||
|
|
||||||
// 装备入驻弹框显示隐藏
|
// 装备入驻弹框显示隐藏
|
||||||
const dialogFormVisibleSettlein = ref(false)
|
const dialogFormVisibleSettlein: any = ref(false)
|
||||||
|
|
||||||
const rules = ref({
|
const rules = ref({
|
||||||
v_name: [
|
v_name: [
|
||||||
|
|
@ -293,11 +389,12 @@
|
||||||
</FormComponent>
|
</FormComponent>
|
||||||
|
|
||||||
<!-- 表格 -->
|
<!-- 表格 -->
|
||||||
<TableComponent :tableProps="tableProps" :tableData="tableData" @getRowId="getRowId">
|
<TableComponent :tableProps="tableProps" :tableData="tableData.list" @getRowId="getRowId">
|
||||||
<template v-slot:v_type="{ row }">
|
<template v-slot:v_type="{ row }">
|
||||||
<el-tag v-if="row.v_type === 1" size="small" type="success">租赁中</el-tag>
|
<el-tag v-if="row.maStatus === '15'" size="small" type="info">待上架审批</el-tag>
|
||||||
<el-tag v-if="row.v_type === 2" size="small" type="warning">已上架</el-tag>
|
<el-tag v-if="row.maStatus === '16'" size="small" type="warning">待租</el-tag>
|
||||||
<el-tag v-if="row.v_type === 3" size="small" type="info">待上架</el-tag>
|
<el-tag v-if="row.maStatus === '17'" size="small" type="success">在租</el-tag>
|
||||||
|
<el-tag v-if="row.maStatus === '18'" size="small" type="danger">下架</el-tag>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:operate="{ row }">
|
<template v-slot:operate="{ row }">
|
||||||
<el-button size="small" type="primary" @click="editRowInfo(row)">编辑</el-button>
|
<el-button size="small" type="primary" @click="editRowInfo(row)">编辑</el-button>
|
||||||
|
|
@ -323,7 +420,7 @@
|
||||||
<el-input
|
<el-input
|
||||||
autocomplete="off"
|
autocomplete="off"
|
||||||
style="width: 360px"
|
style="width: 360px"
|
||||||
v-model="equipmentDeploymentParams.easeScope"
|
v-model="equipmentDeploymentParams.leaseScope"
|
||||||
clearable />
|
clearable />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="设备所在地">
|
<el-form-item label="设备所在地">
|
||||||
|
|
@ -484,8 +581,8 @@
|
||||||
style="width: 220px; margin: 0 5px"
|
style="width: 220px; margin: 0 5px"
|
||||||
clearable
|
clearable
|
||||||
v-model="equipmentDeploymentParams.isOperator">
|
v-model="equipmentDeploymentParams.isOperator">
|
||||||
<el-option label="是" value="1"></el-option>
|
<el-option label="是" value="0"></el-option>
|
||||||
<el-option label="是" value="2"></el-option>
|
<el-option label="否" value="1"></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,94 +5,148 @@
|
||||||
import TableComponent from 'components/TableComponent/index.vue'
|
import TableComponent from 'components/TableComponent/index.vue'
|
||||||
import FormComponent from 'components/FormComponent/index.vue'
|
import FormComponent from 'components/FormComponent/index.vue'
|
||||||
import PagingComponent from 'components/PagingComponent/index.vue'
|
import PagingComponent from 'components/PagingComponent/index.vue'
|
||||||
|
import { getEquipmentListApi } from 'http/api/usercenter/goodsmang'
|
||||||
|
import { goodsUpApi, goodsDownApi, goodsDeleteApi } from 'http/api/usercenter/goodsupdown'
|
||||||
|
import { ElMessage } from 'element-plus'
|
||||||
const pageSize = 20
|
const pageSize = 20
|
||||||
const pageNumber = 1
|
const pageNumber = 1
|
||||||
const total: any = 20
|
const total: any = ref(0)
|
||||||
|
|
||||||
|
// 上架参数
|
||||||
|
const groundingParams: any = ref([])
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
const getList = () => {
|
const getList = async () => {
|
||||||
console.log('获取数据列表***')
|
const res: any = await getEquipmentListApi({})
|
||||||
|
console.log('获取数据列表***', res)
|
||||||
|
total.value = res.total
|
||||||
|
tableData.value = res.rows
|
||||||
}
|
}
|
||||||
|
|
||||||
// 选择复选框时获取需要删除的数据源
|
getList()
|
||||||
|
|
||||||
|
// 选择复选框时获取的数据源
|
||||||
const getRowId = (val: any) => {
|
const getRowId = (val: any) => {
|
||||||
console.log(val, '需要删除的数据源**')
|
val.forEach((item: any, index: any) => {
|
||||||
|
groundingParams.value[index] = {
|
||||||
|
/* 设备id */
|
||||||
|
maId: item.maId,
|
||||||
|
/* 申请时间 */
|
||||||
|
applyTime: '',
|
||||||
|
/* 申请人 */
|
||||||
|
applyUser: '',
|
||||||
|
/* 申请企业*/
|
||||||
|
applyCompany: '',
|
||||||
|
/* 1为上架 2为下架 */
|
||||||
|
type: 1
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 上架按钮
|
// 批量上架按钮
|
||||||
const handleGrounding = () => {
|
const handleGrounding = async () => {
|
||||||
console.log('上架设备')
|
const res: any = await goodsUpApi(groundingParams.value)
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '批量上架申请成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
groundingParams.value = []
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 下架按钮
|
// 批量下架按钮
|
||||||
const handleOffshelf = () => {
|
const handleOffshelf = async () => {
|
||||||
console.log('下架设备')
|
groundingParams.value.forEach((item: any) => {
|
||||||
|
item.type = 2
|
||||||
|
})
|
||||||
|
const res: any = await goodsDownApi(groundingParams.value)
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '批量下架申请成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
groundingParams.value = []
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// 编辑按钮
|
// 编辑按钮
|
||||||
const editRowInfo = (row: any) => {
|
const editRowInfo = (row: any) => {
|
||||||
console.log(row, '编辑当前数据')
|
console.log(row, '编辑当前数据')
|
||||||
}
|
}
|
||||||
// 删除按钮
|
// 删除按钮
|
||||||
const deleteRowInfo = (row: any) => {
|
const deleteRowInfo = async (row: any) => {
|
||||||
console.log(row, '删除当前数据')
|
const res: any = await goodsDeleteApi([row.upId])
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '删除成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 上架按钮
|
||||||
|
const groundingBtn = async (row: any) => {
|
||||||
|
groundingParams.value[0] = {
|
||||||
|
/* 设备id */
|
||||||
|
maId: row.maId,
|
||||||
|
/* 申请时间 */
|
||||||
|
applyTime: '',
|
||||||
|
/* 申请人 */
|
||||||
|
applyUser: '',
|
||||||
|
/* 申请企业*/
|
||||||
|
applyCompany: '',
|
||||||
|
/* 1为上架 2为下架 */
|
||||||
|
type: 1
|
||||||
|
}
|
||||||
|
const res: any = await goodsUpApi(groundingParams.value)
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '上架申请成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
groundingParams.value = []
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 下架按钮
|
||||||
|
const offShelfBtn = async (row: any) => {
|
||||||
|
groundingParams.value[0] = {
|
||||||
|
/* 设备id */
|
||||||
|
maId: row.maId,
|
||||||
|
/* 申请时间 */
|
||||||
|
applyTime: '',
|
||||||
|
/* 申请人 */
|
||||||
|
applyUser: '',
|
||||||
|
/* 申请企业*/
|
||||||
|
applyCompany: '',
|
||||||
|
/* 1为上架 2为下架 */
|
||||||
|
type: 2
|
||||||
|
}
|
||||||
|
console.log('下架设备')
|
||||||
|
const res: any = await goodsDownApi(groundingParams.value)
|
||||||
|
if (res.code === 200) {
|
||||||
|
ElMessage({
|
||||||
|
type: 'success',
|
||||||
|
message: '下架申请成功'
|
||||||
|
})
|
||||||
|
getList()
|
||||||
|
groundingParams.value = []
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const tableProps: any = ref([
|
const tableProps: any = ref([
|
||||||
{ v_label: '编码', v_props: 'v_code', v_slot: '', width: '' },
|
{ v_label: '编码', v_props: 'code', v_slot: '', width: '' },
|
||||||
{ v_label: '租赁范围', v_props: 'v_lease_scope', v_slot: '', width: '' },
|
{ v_label: '租赁范围', v_props: 'leaseScope', v_slot: '', width: '' },
|
||||||
{ v_label: '装备类型', v_props: 'v_equipment_type', v_slot: '', width: '' },
|
{ v_label: '装备类型', v_props: 'modelName', v_slot: '', width: '' },
|
||||||
{ v_label: '装备名称', v_props: 'v_equipment_name', v_slot: '', width: '' },
|
{ v_label: '装备名称', v_props: 'v_equipment_name', v_slot: '', width: '' },
|
||||||
{ v_label: '租金', v_props: 'v_rent', v_slot: '', width: '' },
|
{ v_label: '租金', v_props: 'monthLeasePrice', v_slot: '', width: '' },
|
||||||
{ v_label: '状态', v_props: 'v_type', v_slot: 'v_type', width: '' },
|
{ v_label: '状态', v_props: 'maStatus', v_slot: 'v_type', width: '' },
|
||||||
{ v_label: '操作', v_props: 'v_operate', v_slot: 'operate', width: '140px' }
|
{ v_label: '操作', v_props: 'v_operate', v_slot: 'operate', width: '260px' }
|
||||||
])
|
])
|
||||||
|
|
||||||
const tableData: any = [
|
const tableData: any = ref([])
|
||||||
{
|
|
||||||
v_code: '123456',
|
|
||||||
v_lease_scope: '2023/12/12',
|
|
||||||
v_equipment_type: '挖掘机',
|
|
||||||
v_equipment_name: '2023新版挖掘机',
|
|
||||||
v_rent: '123/月',
|
|
||||||
v_type: 1,
|
|
||||||
v_operate: ''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
v_code: '123456',
|
|
||||||
v_lease_scope: '2023/12/12',
|
|
||||||
v_equipment_type: '挖掘机',
|
|
||||||
v_equipment_name: '2023新版挖掘机',
|
|
||||||
v_rent: '123/月',
|
|
||||||
v_type: 2,
|
|
||||||
v_operate: ''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
v_code: '123456',
|
|
||||||
v_lease_scope: '2023/12/12',
|
|
||||||
v_equipment_type: '挖掘机',
|
|
||||||
v_equipment_name: '2023新版挖掘机',
|
|
||||||
v_rent: '123/月',
|
|
||||||
v_type: 3,
|
|
||||||
v_operate: ''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
v_code: '123456',
|
|
||||||
v_lease_scope: '2023/12/12',
|
|
||||||
v_equipment_type: '挖掘机',
|
|
||||||
v_equipment_name: '2023新版挖掘机',
|
|
||||||
v_rent: '123/月',
|
|
||||||
v_type: 3,
|
|
||||||
v_operate: ''
|
|
||||||
},
|
|
||||||
{
|
|
||||||
v_code: '123456',
|
|
||||||
v_lease_scope: '2023/12/12',
|
|
||||||
v_equipment_type: '挖掘机',
|
|
||||||
v_equipment_name: '2023新版挖掘机',
|
|
||||||
v_rent: '123/月',
|
|
||||||
v_type: 3,
|
|
||||||
v_operate: ''
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
|
||||||
// 表单 lable 数据
|
// 表单 lable 数据
|
||||||
const formItemList: any = ref([
|
const formItemList: any = ref([
|
||||||
|
|
@ -110,7 +164,7 @@
|
||||||
<FormComponent :formItemList="formItemList">
|
<FormComponent :formItemList="formItemList">
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="handleGrounding">批量上架</el-button>
|
<el-button type="primary" @click="handleGrounding">批量上架</el-button>
|
||||||
<el-button type="wanring" @click="handleOffshelf">批量下架</el-button>
|
<el-button type="warning" @click="handleOffshelf">批量下架</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</FormComponent>
|
</FormComponent>
|
||||||
|
|
||||||
|
|
@ -118,11 +172,14 @@
|
||||||
|
|
||||||
<TableComponent :tableProps="tableProps" :tableData="tableData" @getRowId="getRowId">
|
<TableComponent :tableProps="tableProps" :tableData="tableData" @getRowId="getRowId">
|
||||||
<template v-slot:v_type="{ row }">
|
<template v-slot:v_type="{ row }">
|
||||||
<el-tag v-if="row.v_type === 1" size="small" type="success">租赁中</el-tag>
|
<el-tag v-if="row.maStatus === '15'" size="small" type="info">待上架审批</el-tag>
|
||||||
<el-tag v-if="row.v_type === 2" size="small" type="warning">已上架</el-tag>
|
<el-tag v-if="row.maStatus === '16'" size="small" type="warning">待租</el-tag>
|
||||||
<el-tag v-if="row.v_type === 3" size="small" type="info">待上架</el-tag>
|
<el-tag v-if="row.maStatus === '17'" size="small" type="success">在租</el-tag>
|
||||||
|
<el-tag v-if="row.maStatus === '18'" size="small" type="danger">下架</el-tag>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:operate="{ row }">
|
<template v-slot:operate="{ row }">
|
||||||
|
<el-button size="small" type="success" @click="groundingBtn(row)">上架</el-button>
|
||||||
|
<el-button size="small" type="warning" @click="offShelfBtn(row)">下架</el-button>
|
||||||
<el-button size="small" type="primary" @click="editRowInfo(row)">编辑</el-button>
|
<el-button size="small" type="primary" @click="editRowInfo(row)">编辑</el-button>
|
||||||
<el-button size="small" type="danger" @click="deleteRowInfo(row)">删除</el-button>
|
<el-button size="small" type="danger" @click="deleteRowInfo(row)">删除</el-button>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -63,10 +63,10 @@
|
||||||
color: '#fff'
|
color: '#fff'
|
||||||
}">
|
}">
|
||||||
<el-table-column align="center" prop="code" label="订单编号" />
|
<el-table-column align="center" prop="code" label="订单编号" />
|
||||||
<el-table-column align="center" prop="name" label="供应商" />
|
<el-table-column align="center" prop="supplierCompany" label="供应商" />
|
||||||
<el-table-column align="center" prop="createTime" label="订单创建日期" />
|
<el-table-column align="center" prop="createTime" label="订单创建日期" />
|
||||||
<el-table-column align="center" prop="payType" label="装备类型" />
|
<el-table-column align="center" prop="payType" label="装备类型" />
|
||||||
<el-table-column align="center" prop="orderUser" label="装备名称" />
|
<el-table-column align="center" prop="deviceName" label="装备名称" />
|
||||||
<el-table-column align="center" prop="orderStatus" label="订单状态" />
|
<el-table-column align="center" prop="orderStatus" label="订单状态" />
|
||||||
<el-table-column align="center" prop="name" label="操作" width="260px">
|
<el-table-column align="center" prop="name" label="操作" width="260px">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
const queryParams = ref({})
|
const queryParams = ref({})
|
||||||
import PagingComponent from 'components/PagingComponent/index.vue'
|
import PagingComponent from 'components/PagingComponent/index.vue'
|
||||||
|
|
||||||
const pageSize = 20
|
const pageSize = 20
|
||||||
const pageNumber = 1
|
const pageNumber = 1
|
||||||
const total: any = 20
|
const total: any = 20
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,102 @@
|
||||||
|
<script setup lang="ts"></script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<el-form :inline="true" label-width="120px">
|
||||||
|
<el-row>
|
||||||
|
<el-form-item>订单编号: xxxxx12134566</el-form-item>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>单位: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>联系电话: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>租赁时长: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备进场地址: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>详细地址: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>项目说明: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备编号: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备类型: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备组别: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备名称: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>设备规格: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>机手需求: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>租金: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>发票类型: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item>订单起止时间: xxxxx12134566</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<h3>费用明细</h3>
|
||||||
|
|
||||||
|
<el-table border>
|
||||||
|
<el-table-column label="订单起止时间"></el-table-column>
|
||||||
|
<el-table-column label="租赁时常"></el-table-column>
|
||||||
|
<el-table-column label="租金"></el-table-column>
|
||||||
|
<el-table-column label="合计"></el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button>添加增项</el-button>
|
||||||
|
<el-button>添加减项</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-table border>
|
||||||
|
<el-table-column label="类别"></el-table-column>
|
||||||
|
<el-table-column label="描述"></el-table-column>
|
||||||
|
<el-table-column label="金额"></el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<br />
|
||||||
|
<el-form-item>订单金额: xxxx</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item>
|
||||||
|
<el-button>确认结算</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.el-form {
|
||||||
|
padding: 15px;
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
margin: 10px 0;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #333;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Loading…
Reference in New Issue