Commit cf92ac2b authored by tanghao's avatar tanghao

版本

parent f38d7de0
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
"dependencies": { "dependencies": {
"@originjs/vite-plugin-commonjs": "^1.0.3", "@originjs/vite-plugin-commonjs": "^1.0.3",
"axios": "^1.6.1", "axios": "^1.6.1",
"element-plus": "^2.4.2", "element-plus": "^2.10.1",
"exceljs": "^4.4.0", "exceljs": "^4.4.0",
"file-saver": "^2.0.5", "file-saver": "^2.0.5",
"highlight.js": "^11.10.0", "highlight.js": "^11.10.0",
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
"devDependencies": { "devDependencies": {
"@rushstack/eslint-patch": "^1.3.3", "@rushstack/eslint-patch": "^1.3.3",
"@tsconfig/node18": "^18.2.2", "@tsconfig/node18": "^18.2.2",
"@types/file-saver": "^2.0.7",
"@types/node": "^18.18.5", "@types/node": "^18.18.5",
"@vitejs/plugin-vue": "^4.4.0", "@vitejs/plugin-vue": "^4.4.0",
"@vitejs/plugin-vue-jsx": "^3.0.2", "@vitejs/plugin-vue-jsx": "^3.0.2",
...@@ -1250,6 +1251,13 @@ ...@@ -1250,6 +1251,13 @@
"integrity": "sha512-d6McJeGsuoRlwWZmVIeE8CUA27lu6jLjvv1JzqmpsytOYYbVi1tHZEnwCNVOXnj4pyLvneZlFlpXUK+X9wBWyw==", "integrity": "sha512-d6McJeGsuoRlwWZmVIeE8CUA27lu6jLjvv1JzqmpsytOYYbVi1tHZEnwCNVOXnj4pyLvneZlFlpXUK+X9wBWyw==",
"dev": true "dev": true
}, },
"node_modules/@types/file-saver": {
"version": "2.0.7",
"resolved": "https://registry.npmmirror.com/@types/file-saver/-/file-saver-2.0.7.tgz",
"integrity": "sha512-dNKVfHd/jk0SkR/exKGj2ggkB45MAkzvWCaqLUUgkyjITkGNzH8H+yUwr+BLJUBjZOe9w8X3wgmXhZDRg1ED6A==",
"dev": true,
"license": "MIT"
},
"node_modules/@types/json-schema": { "node_modules/@types/json-schema": {
"version": "7.0.15", "version": "7.0.15",
"resolved": "https://registry.npmmirror.com/@types/json-schema/-/json-schema-7.0.15.tgz", "resolved": "https://registry.npmmirror.com/@types/json-schema/-/json-schema-7.0.15.tgz",
...@@ -2684,9 +2692,10 @@ ...@@ -2684,9 +2692,10 @@
"integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==" "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw=="
}, },
"node_modules/dayjs": { "node_modules/dayjs": {
"version": "1.11.12", "version": "1.11.13",
"resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.12.tgz", "resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz",
"integrity": "sha512-Rt2g+nTbLlDWZTwwrIXjy9MeiZmSDI375FvZs72ngxx8PDC6YXOeR3q5LAuPzjZQxhiWdRKac7RKV+YyQYfYIg==" "integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==",
"license": "MIT"
}, },
"node_modules/de-indent": { "node_modules/de-indent": {
"version": "1.0.2", "version": "1.0.2",
...@@ -2801,19 +2810,20 @@ ...@@ -2801,19 +2810,20 @@
"dev": true "dev": true
}, },
"node_modules/element-plus": { "node_modules/element-plus": {
"version": "2.4.2", "version": "2.10.1",
"resolved": "https://registry.npmmirror.com/element-plus/-/element-plus-2.4.2.tgz", "resolved": "https://registry.npmmirror.com/element-plus/-/element-plus-2.10.1.tgz",
"integrity": "sha512-E/HwXX7JF1LPvQSjs0fZ8WblIoc0quoXsRXQZiL7QDq7xJdNGSUaXtdk7xiEv7axPmLfEFtxE5du9fFspDrmJw==", "integrity": "sha512-R+YM8b+s+3aQ3EeY33q0inn3ehRnunP42aDYoJxUtSZPgMPSXzYgmGEhIDP7Xg4NvY8raaSuO0/1fDLEfZ+nlA==",
"license": "MIT",
"dependencies": { "dependencies": {
"@ctrl/tinycolor": "^3.4.1", "@ctrl/tinycolor": "^3.4.1",
"@element-plus/icons-vue": "^2.0.6", "@element-plus/icons-vue": "^2.3.1",
"@floating-ui/dom": "^1.0.1", "@floating-ui/dom": "^1.0.1",
"@popperjs/core": "npm:@sxzz/popperjs-es@^2.11.7", "@popperjs/core": "npm:@sxzz/popperjs-es@^2.11.7",
"@types/lodash": "^4.14.182", "@types/lodash": "^4.14.182",
"@types/lodash-es": "^4.17.6", "@types/lodash-es": "^4.17.6",
"@vueuse/core": "^9.1.0", "@vueuse/core": "^9.1.0",
"async-validator": "^4.2.5", "async-validator": "^4.2.5",
"dayjs": "^1.11.3", "dayjs": "^1.11.13",
"escape-html": "^1.0.3", "escape-html": "^1.0.3",
"lodash": "^4.17.21", "lodash": "^4.17.21",
"lodash-es": "^4.17.21", "lodash-es": "^4.17.21",
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
"dependencies": { "dependencies": {
"@originjs/vite-plugin-commonjs": "^1.0.3", "@originjs/vite-plugin-commonjs": "^1.0.3",
"axios": "^1.6.1", "axios": "^1.6.1",
"element-plus": "^2.4.2", "element-plus": "^2.10.1",
"exceljs": "^4.4.0", "exceljs": "^4.4.0",
"file-saver": "^2.0.5", "file-saver": "^2.0.5",
"highlight.js": "^11.10.0", "highlight.js": "^11.10.0",
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
"devDependencies": { "devDependencies": {
"@rushstack/eslint-patch": "^1.3.3", "@rushstack/eslint-patch": "^1.3.3",
"@tsconfig/node18": "^18.2.2", "@tsconfig/node18": "^18.2.2",
"@types/file-saver": "^2.0.7",
"@types/node": "^18.18.5", "@types/node": "^18.18.5",
"@vitejs/plugin-vue": "^4.4.0", "@vitejs/plugin-vue": "^4.4.0",
"@vitejs/plugin-vue-jsx": "^3.0.2", "@vitejs/plugin-vue-jsx": "^3.0.2",
......
...@@ -141,4 +141,17 @@ export const delInformationInfoApi = (params: any) => { ...@@ -141,4 +141,17 @@ export const delInformationInfoApi = (params: any) => {
params, params,
headers: formHeader headers: formHeader
}) })
} }
\ No newline at end of file
/**
* 删除资源库
* @param params
* @returns
*/
export const deleteInformation = (params: any) => {
return axios.get('/api/information/deleteInformation', {
params,
headers: formHeader
})
}
...@@ -20,6 +20,7 @@ const { setFileInfo } = useCommentExcel() ...@@ -20,6 +20,7 @@ const { setFileInfo } = useCommentExcel()
// 获取文件信息及客户信息 // 获取文件信息及客户信息
const queryFileInfo = async () => { const queryFileInfo = async () => {
const { data } = await getOrderFileById(route.query.fileId as string) const { data } = await getOrderFileById(route.query.fileId as string)
alert(1111)
setFileInfo(data.result) setFileInfo(data.result)
loading.value = true loading.value = true
} }
......
...@@ -15,13 +15,21 @@ ...@@ -15,13 +15,21 @@
<el-button type="primary" @click="handleImport">导入</el-button> <el-button type="primary" @click="handleImport">导入</el-button>
</el-col> </el-col>
</el-row> </el-row>
<el-space wrap> <el-space wrap :size="15">
<el-card v-for="informationType in informationTypes" :key="informationType" class="box-card" <el-badge v-for="informationType in informationTypes" :key="informationType" class="item1">
<el-button class="box-card"
@click="handleInfoTypeClick(informationType)"> @click="handleInfoTypeClick(informationType)">
<div class="text item"> {{ informationType }}
{{ informationType }} </el-button>
</div> <template #content="{ value }">
</el-card> <div class="custom-content">
<el-icon @click="deleteInfo(informationType)" >
<Close />
</el-icon>
</div>
</template>
</el-badge>
</el-space> </el-space>
<UploadInformationInfoDialog :visible="importVisible" @onImportChange="onImportChange" /> <UploadInformationInfoDialog :visible="importVisible" @onImportChange="onImportChange" />
</div> </div>
...@@ -31,8 +39,11 @@ ...@@ -31,8 +39,11 @@
import { ref, onMounted, reactive, unref } from 'vue' import { ref, onMounted, reactive, unref } from 'vue'
import { getInformationTypeListApi } from '@/api/customer' import { getInformationTypeListApi } from '@/api/customer'
import { useRouter } from 'vue-router' import { useRouter } from 'vue-router'
import { ElMessage, type FormInstance } from 'element-plus' import { ElMessage,ElMessageBox, type FormInstance } from 'element-plus'
import UploadInformationInfoDialog from './components/upload-information-info-dialog.vue'; import UploadInformationInfoDialog from './components/upload-information-info-dialog.vue';
import { Back ,Close} from '@element-plus/icons-vue'
import { deleteInformation } from '@/api/customer'
const loading = ref(false) const loading = ref(false)
const router = useRouter() const router = useRouter()
...@@ -89,6 +100,20 @@ const handleInfoTypeClick = (informationType: any) => { ...@@ -89,6 +100,20 @@ const handleInfoTypeClick = (informationType: any) => {
}) })
} }
const deleteInfo = async (informationType: any) => {
await ElMessageBox.confirm('资源库一旦删除无法恢复,是否确认删除', '提示', {
confirmButtonText: '删除',
cancelButtonText: '取消',
type: 'warning'
})
const params = {
nodeLabel: informationType,
}
const { data } = await deleteInformation(params)
queryCustomer()
}
onMounted(() => { onMounted(() => {
queryCustomer() queryCustomer()
}) })
...@@ -98,4 +123,16 @@ onMounted(() => { ...@@ -98,4 +123,16 @@ onMounted(() => {
:deep(.el-card) { :deep(.el-card) {
cursor: pointer; cursor: pointer;
} }
.item1 {
margin-top: 0px;
margin-right: 5px;
}
.custom-content {
display: flex;
align-items: center;
justify-content: center;
gap: 4px;
}
</style> </style>
\ No newline at end of file
...@@ -176,7 +176,7 @@ const onChange = (type: any) => { ...@@ -176,7 +176,7 @@ const onChange = (type: any) => {
if (type != 'close') { if (type != 'close') {
onReset() onReset()
} }
onReset() // onReset()
} }
const handleAdd = () => { const handleAdd = () => {
...@@ -193,6 +193,14 @@ const handleUpdate = (row: any) => { ...@@ -193,6 +193,14 @@ const handleUpdate = (row: any) => {
} }
const handleDel = async (row: any) => { const handleDel = async (row: any) => {
await ElMessageBox.confirm('资源一旦删除无法恢复,是否确认删除', '提示', {
confirmButtonText: '删除',
cancelButtonText: '取消',
type: 'warning'
})
const params = { const params = {
informationType: route.query.informationType, informationType: route.query.informationType,
id: row.id id: row.id
......
...@@ -558,9 +558,7 @@ const confirmChange = async (row) => { ...@@ -558,9 +558,7 @@ const confirmChange = async (row) => {
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}) })
loading.value = true
const { data } = await convertExcelFileOrder(row.excelOrderId) const { data } = await convertExcelFileOrder(row.excelOrderId)
loading.value = false
if (data.code == 200) { if (data.code == 200) {
ElMessage.success(data.message || '转换成功!') ElMessage.success(data.message || '转换成功!')
detailVisible.value = false detailVisible.value = false
......
...@@ -266,7 +266,7 @@ ...@@ -266,7 +266,7 @@
resolved "https://registry.npmmirror.com/@ctrl/tinycolor/-/tinycolor-3.6.1.tgz" resolved "https://registry.npmmirror.com/@ctrl/tinycolor/-/tinycolor-3.6.1.tgz"
integrity sha512-SITSV6aIXsuVNV3f3O0f2n/cgyEDWoSqtZMYiAmcsYHydcKrOz3gUxB/iXd/Qf08+IZX4KpgNbvUdMBmWz+kcA== integrity sha512-SITSV6aIXsuVNV3f3O0f2n/cgyEDWoSqtZMYiAmcsYHydcKrOz3gUxB/iXd/Qf08+IZX4KpgNbvUdMBmWz+kcA==
"@element-plus/icons-vue@^2.0.6": "@element-plus/icons-vue@^2.3.1":
version "2.3.1" version "2.3.1"
resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.3.1.tgz" resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.3.1.tgz"
integrity sha512-XxVUZv48RZAd87ucGS48jPf6pKu0yV5UCg9f4FFwtrYxXOwWuVJo6wOvSLKEoMQKjv8GsX/mhP6UsC1lRwbUWg== integrity sha512-XxVUZv48RZAd87ucGS48jPf6pKu0yV5UCg9f4FFwtrYxXOwWuVJo6wOvSLKEoMQKjv8GsX/mhP6UsC1lRwbUWg==
...@@ -584,6 +584,11 @@ ...@@ -584,6 +584,11 @@
resolved "https://registry.npmmirror.com/@tsconfig/node18/-/node18-18.2.2.tgz" resolved "https://registry.npmmirror.com/@tsconfig/node18/-/node18-18.2.2.tgz"
integrity sha512-d6McJeGsuoRlwWZmVIeE8CUA27lu6jLjvv1JzqmpsytOYYbVi1tHZEnwCNVOXnj4pyLvneZlFlpXUK+X9wBWyw== integrity sha512-d6McJeGsuoRlwWZmVIeE8CUA27lu6jLjvv1JzqmpsytOYYbVi1tHZEnwCNVOXnj4pyLvneZlFlpXUK+X9wBWyw==
"@types/file-saver@^2.0.7":
version "2.0.7"
resolved "https://registry.npmmirror.com/@types/file-saver/-/file-saver-2.0.7.tgz"
integrity sha512-dNKVfHd/jk0SkR/exKGj2ggkB45MAkzvWCaqLUUgkyjITkGNzH8H+yUwr+BLJUBjZOe9w8X3wgmXhZDRg1ED6A==
"@types/json-schema@^7.0.12": "@types/json-schema@^7.0.12":
version "7.0.15" version "7.0.15"
resolved "https://registry.npmmirror.com/@types/json-schema/-/json-schema-7.0.15.tgz" resolved "https://registry.npmmirror.com/@types/json-schema/-/json-schema-7.0.15.tgz"
...@@ -1435,10 +1440,10 @@ csstype@^3.1.2: ...@@ -1435,10 +1440,10 @@ csstype@^3.1.2:
resolved "https://registry.npmmirror.com/csstype/-/csstype-3.1.3.tgz" resolved "https://registry.npmmirror.com/csstype/-/csstype-3.1.3.tgz"
integrity sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw== integrity sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==
dayjs@^1.11.3, dayjs@^1.8.34: dayjs@^1.11.13, dayjs@^1.8.34:
version "1.11.12" version "1.11.13"
resolved "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.12.tgz" resolved "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.13.tgz"
integrity sha512-Rt2g+nTbLlDWZTwwrIXjy9MeiZmSDI375FvZs72ngxx8PDC6YXOeR3q5LAuPzjZQxhiWdRKac7RKV+YyQYfYIg== integrity sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg==
de-indent@^1.0.2: de-indent@^1.0.2:
version "1.0.2" version "1.0.2"
...@@ -1508,20 +1513,20 @@ electron-to-chromium@^1.5.4: ...@@ -1508,20 +1513,20 @@ electron-to-chromium@^1.5.4:
resolved "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.5.7.tgz" resolved "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.5.7.tgz"
integrity sha512-6FTNWIWMxMy/ZY6799nBlPtF1DFDQ6VQJ7yyDP27SJNt5lwtQ5ufqVvHylb3fdQefvRcgA3fKcFMJi9OLwBRNw== integrity sha512-6FTNWIWMxMy/ZY6799nBlPtF1DFDQ6VQJ7yyDP27SJNt5lwtQ5ufqVvHylb3fdQefvRcgA3fKcFMJi9OLwBRNw==
element-plus@^2.4.2: element-plus@^2.10.1:
version "2.4.2" version "2.10.1"
resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.4.2.tgz" resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.10.1.tgz"
integrity sha512-E/HwXX7JF1LPvQSjs0fZ8WblIoc0quoXsRXQZiL7QDq7xJdNGSUaXtdk7xiEv7axPmLfEFtxE5du9fFspDrmJw== integrity sha512-R+YM8b+s+3aQ3EeY33q0inn3ehRnunP42aDYoJxUtSZPgMPSXzYgmGEhIDP7Xg4NvY8raaSuO0/1fDLEfZ+nlA==
dependencies: dependencies:
"@ctrl/tinycolor" "^3.4.1" "@ctrl/tinycolor" "^3.4.1"
"@element-plus/icons-vue" "^2.0.6" "@element-plus/icons-vue" "^2.3.1"
"@floating-ui/dom" "^1.0.1" "@floating-ui/dom" "^1.0.1"
"@popperjs/core" "npm:@sxzz/popperjs-es@^2.11.7" "@popperjs/core" "npm:@sxzz/popperjs-es@^2.11.7"
"@types/lodash" "^4.14.182" "@types/lodash" "^4.14.182"
"@types/lodash-es" "^4.17.6" "@types/lodash-es" "^4.17.6"
"@vueuse/core" "^9.1.0" "@vueuse/core" "^9.1.0"
async-validator "^4.2.5" async-validator "^4.2.5"
dayjs "^1.11.3" dayjs "^1.11.13"
escape-html "^1.0.3" escape-html "^1.0.3"
lodash "^4.17.21" lodash "^4.17.21"
lodash-es "^4.17.21" lodash-es "^4.17.21"
......
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