Commit 6c1dc94d authored by zhengke's avatar zhengke

行程导航

parent 86ec99f4
...@@ -5,6 +5,13 @@ import Api,{ HttpResponse, Result } from './../utils/request'; ...@@ -5,6 +5,13 @@ import Api,{ HttpResponse, Result } from './../utils/request';
*/ */
class ConfigService{ class ConfigService{
/**
* 删除文件夹
*/
static async RemoveTripFolder(params : any):Promise<HttpResponse>{
return Api.Post("triptemplate_RemoveTripFolder",params)
}
/** /**
* 我的云文档列表(行程、广告) * 我的云文档列表(行程、广告)
*/ */
......
...@@ -2,9 +2,19 @@ ...@@ -2,9 +2,19 @@
<div class="q-px-md q-pt-lg"> <div class="q-px-md q-pt-lg">
<div class="q-pl-lg row q-mb-lg"> <div class="q-pl-lg row q-mb-lg">
<div class="col row items-center q-pl-md"> <div class="col row items-center q-pl-md">
<h5> <h5 class="row items-center">
<template v-if="currentMenu==3">行程文档</template> <span class="pointer" @click="()=>{queryObj.FileId=0;refreshHandler()}"><el-icon class="q-pt-md" v-if="queryObj.FileId>0" size="20"><ArrowLeft /></el-icon></span>
<template v-else-if="currentMenu==4">广告图</template> <span v-if="queryObj.FileId==0" class="q-pl-md">
<template v-if="currentMenu==3">行程文档</template>
<template v-else-if="currentMenu==4">广告图</template>
</span>
<span v-else class="q-pl-md row items-center">
<span>
<template v-if="currentMenu==3">行程文档</template>
<template v-else-if="currentMenu==4">广告图</template>
</span>
<span>/{{Navigation.FileName}}</span>
</span>
</h5> </h5>
<div class="select-btn q-pl-lg pointer q-mt-sm"> <div class="select-btn q-pl-lg pointer q-mt-sm">
<el-icon> <el-icon>
...@@ -37,7 +47,7 @@ ...@@ -37,7 +47,7 @@
@click="clickSelectAll" @click="clickSelectAll"
:indeterminate="isIndeterminate"/></th> :indeterminate="isIndeterminate"/></th>
<th colspan="2" class="text-light"><div class="text-left q-pl-md">文档名称</div></th> <th colspan="2" class="text-light"><div class="text-left q-pl-md">文档名称</div></th>
<th class="text-light" style="min-width: 100px;width: 110px;">最近修改</th> <th class="text-light" style="min-width: 150px;width: 150px;">最近修改</th>
<th class="text-light" style="min-width: 100px;width: 100px;">创建者</th> <th class="text-light" style="min-width: 100px;width: 100px;">创建者</th>
<th class="text-light" style="min-width: 120px;width: 120px;">操作</th> <th class="text-light" style="min-width: 120px;width: 120px;">操作</th>
</tr> </tr>
...@@ -50,12 +60,12 @@ ...@@ -50,12 +60,12 @@
<td style="width: 30px;" @click.stop="OffEdit"> <td style="width: 30px;" @click.stop="OffEdit">
<img v-if="item.FileType" class="q-px-md" :src="item.FileType==1?datas.pdfImg:datas.adsImg" <img v-if="item.FileType" class="q-px-md" :src="item.FileType==1?datas.pdfImg:datas.adsImg"
style="height: 25px;" /> style="height: 25px;" />
<!-- <img v-else class="q-px-md" :src="item.FileType==1?datas.pdfImg:datas.adsImg" <img v-else @click.stop="editDelete(item,2)" class="q-px-md" :src="datas.adsImg"
style="height: 25px;" /> --> style="height: 25px;" />
</td> </td>
<td class="journeyAds-title wrap row"> <td class="journeyAds-title wrap row" @click.stop="editDelete(item,2)">
<div v-if="!item.editTitle" class="col"> <div v-if="!item.editTitle" class="col">
<el-tooltip @click.stop="OffEdit" <el-tooltip @click.stop="OffEdit()"
placement="top-start"> placement="top-start">
<template #content><div style="max-width: 600px;">{{item.FileName}}</div></template> <template #content><div style="max-width: 600px;">{{item.FileName}}</div></template>
<div class="journeyAds-TitleCenter">{{item.FileName}} <div class="journeyAds-TitleCenter">{{item.FileName}}
...@@ -118,7 +128,7 @@ ...@@ -118,7 +128,7 @@
<script setup lang="ts"> <script setup lang="ts">
import { ref, reactive, provide, watch, inject, onMounted } from 'vue' import { ref, reactive, provide, watch, inject, onMounted } from 'vue'
import { ElLoading, ElMessage, ElMessageBox } from "element-plus"; import { ElLoading, ElMessage, ElMessageBox } from "element-plus";
import { MoreFilled,Edit } from '@element-plus/icons-vue' import { MoreFilled,Edit,ArrowLeft } from '@element-plus/icons-vue'
import ConfigService from '@/services/ConfigService' import ConfigService from '@/services/ConfigService'
import { injectKeyTemplate } from '@/types/injectKey' import { injectKeyTemplate } from '@/types/injectKey'
import { getDaysBetween } from '@/utils/common' import { getDaysBetween } from '@/utils/common'
...@@ -140,11 +150,13 @@ ...@@ -140,11 +150,13 @@
const PopoverVisibleControls = ref(false) const PopoverVisibleControls = ref(false)
const shareId = ref(0) const shareId = ref(0)
const journeyAdsDetails = ref({}) const journeyAdsDetails = ref({})
const Navigation = ref({})
const showHistory = ref(true) const showHistory = ref(true)
const isIndeterminate = ref(false) const isIndeterminate = ref(false)
const dataList = ref([] as Array < any > ) const dataList = ref([] as Array < any > )
const searchData = ref({} as any) const searchData = ref({} as any)
searchData.value = inject(injectKeyTemplate) searchData.value = inject(injectKeyTemplate)
const deleteLoading = ref<any>(null)
const datas = reactive({ const datas = reactive({
selectedDatas: [] as Array, selectedDatas: [] as Array,
selectAll: false as any, selectAll: false as any,
...@@ -317,17 +329,16 @@ ...@@ -317,17 +329,16 @@
}) })
let pageRes = await ConfigService.RemoveTripFolder(queryMsg); let pageRes = await ConfigService.RemoveTripFolder(queryMsg);
if (pageRes.data.resultCode == 1) { if (pageRes.data.resultCode == 1) {
queryObj.pageIndex = 1
ElMessage({ ElMessage({
showClose: true, showClose: true,
message: `删除${item.TemplateType==2?'广告':'行程'}成功`, message: `删除${queryObj.FileType==2?'广告':'行程'}文件夹成功`,
type: 'success', type: 'success',
}) })
querySearchHandler() refreshHandler()
}else { }else {
ElMessage({ ElMessage({
showClose: true, showClose: true,
message: `删除${item.TemplateType==2?'广告':'行程'}失败`, message: `删除${queryObj.FileType==2?'广告':'行程'}文件夹失败`,
type: 'warning', type: 'warning',
}) })
} }
...@@ -358,17 +369,16 @@ ...@@ -358,17 +369,16 @@
}) })
let pageRes = await ConfigService.sellSetRemoveTemplate(queryMsg); let pageRes = await ConfigService.sellSetRemoveTemplate(queryMsg);
if (pageRes.data.resultCode == 1) { if (pageRes.data.resultCode == 1) {
queryObj.pageIndex = 1
ElMessage({ ElMessage({
showClose: true, showClose: true,
message: `删除${item.TemplateType==2?'广告':'行程'}成功`, message: `删除${queryObj.FileType==2?'广告':'行程'}成功`,
type: 'success', type: 'success',
}) })
querySearchHandler() refreshHandler()
}else { }else {
ElMessage({ ElMessage({
showClose: true, showClose: true,
message: `删除${item.TemplateType==2?'广告':'行程'}失败`, message: `删除${queryObj.FileType==2?'广告':'行程'}失败`,
type: 'warning', type: 'warning',
}) })
} }
...@@ -402,9 +412,17 @@ ...@@ -402,9 +412,17 @@
SalesEditorStore.setSalesEditor(2) SalesEditorStore.setSalesEditor(2)
marketStore.setMarket(false) marketStore.setMarket(false)
}else { }else {
folderObj.value.id=row.FileId // 2文件夹详情
folderObj.value.name=row.FileName if(type==2){
folderObj.value.type=row.FileType queryObj.FileId = row.FileId
Navigation.value = row
refreshHandler()
}else{
folderObj.value.id=row.FileId
folderObj.value.name=row.FileName
folderObj.value.type=row.FileType
}
} }
} }
} }
...@@ -466,6 +484,7 @@ ...@@ -466,6 +484,7 @@
datas.selectAll = false datas.selectAll = false
datas.selectedDatas = [] datas.selectedDatas = []
queryObj.FileType = n queryObj.FileType = n
queryObj.FileId = 0
refreshHandler() refreshHandler()
}) })
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment