bug修复

This commit is contained in:
BianLzhaoMin 2024-12-31 17:09:21 +08:00
parent ed6707d126
commit ddeb9d11d6
4 changed files with 25 additions and 9 deletions

2
components.d.ts vendored
View File

@ -29,6 +29,7 @@ declare module 'vue' {
ElEmpty: typeof import('element-plus/es')['ElEmpty'] ElEmpty: typeof import('element-plus/es')['ElEmpty']
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']
ElHeader: typeof import('element-plus/es')['ElHeader']
ElIcon: typeof import('element-plus/es')['ElIcon'] ElIcon: typeof import('element-plus/es')['ElIcon']
ElImage: typeof import('element-plus/es')['ElImage'] ElImage: typeof import('element-plus/es')['ElImage']
ElInput: typeof import('element-plus/es')['ElInput'] ElInput: typeof import('element-plus/es')['ElInput']
@ -36,6 +37,7 @@ 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']
ElPopconfirm: typeof import('element-plus/es')['ElPopconfirm'] ElPopconfirm: typeof import('element-plus/es')['ElPopconfirm']
ElProgress: typeof import('element-plus/es')['ElProgress'] ElProgress: typeof import('element-plus/es')['ElProgress']

4
env/.env.dev vendored
View File

@ -9,8 +9,8 @@ VITE_API_URL = '/proxyApi'
# VITE_proxyTarget = 'http://192.168.2.246:28080' # 马帅 # VITE_proxyTarget = 'http://192.168.2.246:28080' # 马帅
# VITE_proxyTarget = 'http://192.168.2.122:28080' # 梁超 # VITE_proxyTarget = 'http://192.168.2.122:28080' # 梁超
VITE_proxyTarget = 'http://36.33.26.201:17788/proxyApi' # 测试服务 # VITE_proxyTarget = 'http://36.33.26.201:17788/proxyApi' # 测试服务
# VITE_proxyTarget = 'http://192.168.0.244:28580' # 测试服务 VITE_proxyTarget = 'http://192.168.0.244:28580' # 测试服务
# VITE_proxyTarget = 'http://192.168.2.75:28080' # 盛旭 # VITE_proxyTarget = 'http://192.168.2.75:28080' # 盛旭
# VITE_proxyTarget = 'http://10.40.92.185:9206' # 赵福海 ( 设备类型) # VITE_proxyTarget = 'http://10.40.92.185:9206' # 赵福海 ( 设备类型)

View File

@ -60,10 +60,7 @@
<el-button class="primary-lease" type="primary" @click="addContract" <el-button class="primary-lease" type="primary" @click="addContract"
>合同新建</el-button >合同新建</el-button
> >
<a <a :href="uploadUrlTemp" download="安徽省机械化装备共享平台-协议模板">
href="/contract-template.docx"
download="安徽省机械化装备共享平台-协议模板"
>
<el-button <el-button
class="primary-lease" class="primary-lease"
type="primary" type="primary"
@ -120,7 +117,12 @@
<el-button size="small" type="primary" @click="onContract(row, false)"> <el-button size="small" type="primary" @click="onContract(row, false)">
编辑 编辑
</el-button> </el-button>
<el-button size="small" type="danger" @click="onDelete(row.id, true)" v-if="row.status==0"> <el-button
size="small"
type="danger"
@click="onDelete(row.id, true)"
v-if="row.status == 0"
>
删除 删除
</el-button> </el-button>
</template> </template>
@ -350,6 +352,7 @@ import { QuillEditor } from '@vueup/vue-quill'
import 'quill/dist/quill.core.css' import 'quill/dist/quill.core.css'
import 'quill/dist/quill.snow.css' import 'quill/dist/quill.snow.css'
import 'quill/dist/quill.bubble.css' import 'quill/dist/quill.bubble.css'
const uploadUrlTemp = ref('')
const store2 = mainStore() const store2 = mainStore()
const isViewForm = ref(false) const isViewForm = ref(false)
@ -685,6 +688,8 @@ const onEditorReady = (editor) => {
} }
onMounted(() => { onMounted(() => {
getContractListData() getContractListData()
uploadUrlTemp.value = window.location.origin + '/mall-view/contract-template.docx'
// getEquipmentTypeApi().then((res: any) => { // getEquipmentTypeApi().then((res: any) => {
// deviceTypeTree.value = res.data // deviceTypeTree.value = res.data
}) })

View File

@ -103,6 +103,8 @@ const queryParams: any = ref({
typeId: '', typeId: '',
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1,
startTime: '',
endTime: '',
}) })
const queryFormRef = ref<FormInstance>() const queryFormRef = ref<FormInstance>()
const total: any = ref(0) const total: any = ref(0)
@ -117,6 +119,8 @@ const resetTableList = (formEl: FormInstance | undefined) => {
if (!formEl) return if (!formEl) return
formEl.resetFields() formEl.resetFields()
dateRange.value = [] dateRange.value = []
queryParams.value.startTime = ''
queryParams.value.endTime = ''
deviceTypeList.value = [] deviceTypeList.value = []
queryParams.value.typeId = null queryParams.value.typeId = null
queryTableList() queryTableList()
@ -124,6 +128,11 @@ const resetTableList = (formEl: FormInstance | undefined) => {
// //
const getList = async () => { const getList = async () => {
console.log(queryParams.value.pageNum, '***9999', queryParams.value.pageSize) console.log(queryParams.value.pageNum, '***9999', queryParams.value.pageSize)
if (dateRange.value.length > 0) {
queryParams.value.startTime = dateRange.value[0]
queryParams.value.endTime = dateRange.value[1]
}
const res: any = await getEquipmentListApi(queryParams.value) const res: any = await getEquipmentListApi(queryParams.value)
console.log(res, '列表数据**--**') console.log(res, '列表数据**--**')
total.value = res.total total.value = res.total
@ -1323,7 +1332,7 @@ const changeDate = (row: any, index: number) => {
style="width: 100%" style="width: 100%"
v-model="dateRange" v-model="dateRange"
type="datetimerange" type="datetimerange"
value-format="yyyy-MM-dd HH:mm:ss" value-format="YYYY-MM-DD"
range-separator="至" range-separator="至"
start-placeholder="更新开始日期" start-placeholder="更新开始日期"
end-placeholder="更新结束日期" end-placeholder="更新结束日期"
@ -1404,7 +1413,7 @@ const changeDate = (row: any, index: number) => {
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" prop="typeName" label="装备型号" /> <el-table-column align="center" prop="typeName" label="装备型号" />
<el-table-column align="center" prop="updateTime" label="更新时间" />
<el-table-column align="center" label="装备状态"> <el-table-column align="center" label="装备状态">
<template #default="{ row }"> <template #default="{ row }">
<el-tag v-if="row.maStatus == 0" size="small" type="info">草稿状态</el-tag> <el-tag v-if="row.maStatus == 0" size="small" type="info">草稿状态</el-tag>