diff --git a/src/components/a-dialog/ADialog.vue b/src/components/a-dialog/ADialog.vue index 4897882..41c6252 100644 --- a/src/components/a-dialog/ADialog.vue +++ b/src/components/a-dialog/ADialog.vue @@ -49,7 +49,6 @@ const enableRender = ref(false) let moveHandle = useMove(id) function openedHandler() { - console.log('ADialog opened', id) const modal = document.querySelector('.' + modalClass) let container = modal?.querySelector('.el-overlay-dialog') as HTMLElement let dialog = container?.querySelector('.draggable-dialog') as HTMLElement @@ -63,7 +62,6 @@ function openedHandler() { } function closedHandler() { - console.log('ADialog closed', id) moveHandle .disable() .setContainer() @@ -72,15 +70,12 @@ function closedHandler() { } onMounted(() => { - console.log('ADialog mounted', id) enableRender.value = true }) onActivated(() => { - console.log('ADialog activated', id) moveHandle.enable() }) onUnmounted(() => { - console.log('ADialog unmounted', id) moveHandle.destroy() }) diff --git a/src/components/a-icon/iconfont.css b/src/components/a-icon/iconfont.css index c9fdde8..1386cd7 100644 --- a/src/components/a-icon/iconfont.css +++ b/src/components/a-icon/iconfont.css @@ -1,8 +1,8 @@ @font-face { font-family: "iconfont"; /* 项目名称 再昇云 */ - src: url('@/components/a-icon/iconfont.woff2?t=1768642091253') format('woff2'), - url('@/components/a-icon/iconfont.woff?t=1768642091253') format('woff'), - url('@/components/a-icon/iconfont.ttf?t=1768642091253') format('truetype'); + src: url('@/components/a-icon/iconfont.woff2?t=1769142012944') format('woff2'), + url('@/components/a-icon/iconfont.woff?t=1769142012944') format('woff'), + url('@/components/a-icon/iconfont.ttf?t=1769142012944') format('truetype'); } .iconfont { @@ -13,6 +13,42 @@ -moz-osx-font-smoothing: grayscale; } +.icon-dianhua-1:before { + content: "\e65d"; +} + +.icon-weixin:before { + content: "\e65a"; +} + +.icon-yue:before { + content: "\e65b"; +} + +.icon-yuejie:before { + content: "\e65c"; +} + +.icon-siji:before { + content: "\e659"; +} + +.icon-icon-cart:before { + content: "\e656"; +} + +.icon-yunshu:before { + content: "\e657"; +} + +.icon-kehu:before { + content: "\e658"; +} + +.icon-xiaonachang:before { + content: "\e7aa"; +} + .icon-home-3-line:before { content: "\e6b3"; } diff --git a/src/components/a-icon/iconfont.json b/src/components/a-icon/iconfont.json index f6472f0..8372ba2 100644 --- a/src/components/a-icon/iconfont.json +++ b/src/components/a-icon/iconfont.json @@ -5,6 +5,69 @@ "css_prefix_text": "icon-", "description": "", "glyphs": [ + { + "icon_id": "1272171", + "name": "电话", + "font_class": "dianhua-1", + "unicode": "e65d", + "unicode_decimal": 58973 + }, + { + "icon_id": "933713", + "name": "微信", + "font_class": "weixin", + "unicode": "e65a", + "unicode_decimal": 58970 + }, + { + "icon_id": "2681721", + "name": "余额", + "font_class": "yue", + "unicode": "e65b", + "unicode_decimal": 58971 + }, + { + "icon_id": "5351377", + "name": "月结", + "font_class": "yuejie", + "unicode": "e65c", + "unicode_decimal": 58972 + }, + { + "icon_id": "19586478", + "name": "司机", + "font_class": "siji", + "unicode": "e659", + "unicode_decimal": 58969 + }, + { + "icon_id": "712236", + "name": "采购", + "font_class": "icon-cart", + "unicode": "e656", + "unicode_decimal": 58966 + }, + { + "icon_id": "12975022", + "name": "运输", + "font_class": "yunshu", + "unicode": "e657", + "unicode_decimal": 58967 + }, + { + "icon_id": "31312998", + "name": "客户", + "font_class": "kehu", + "unicode": "e658", + "unicode_decimal": 58968 + }, + { + "icon_id": "45748068", + "name": "消纳场", + "font_class": "xiaonachang", + "unicode": "e7aa", + "unicode_decimal": 59306 + }, { "icon_id": "17102563", "name": "home-3-line", diff --git a/src/components/a-icon/iconfont.ts b/src/components/a-icon/iconfont.ts index 7d58035..bfd28c6 100644 --- a/src/components/a-icon/iconfont.ts +++ b/src/components/a-icon/iconfont.ts @@ -5,6 +5,69 @@ export const icons = { 'css_prefix_text': 'icon-', 'description': '', 'glyphs': [ + { + 'icon_id': '1272171', + 'name': '电话', + 'font_class': 'dianhua-1', + 'unicode': 'e65d', + 'unicode_decimal': 58973, + }, + { + 'icon_id': '933713', + 'name': '微信', + 'font_class': 'weixin', + 'unicode': 'e65a', + 'unicode_decimal': 58970, + }, + { + 'icon_id': '2681721', + 'name': '余额', + 'font_class': 'yue', + 'unicode': 'e65b', + 'unicode_decimal': 58971, + }, + { + 'icon_id': '5351377', + 'name': '月结', + 'font_class': 'yuejie', + 'unicode': 'e65c', + 'unicode_decimal': 58972, + }, + { + 'icon_id': '19586478', + 'name': '司机', + 'font_class': 'siji', + 'unicode': 'e659', + 'unicode_decimal': 58969, + }, + { + 'icon_id': '712236', + 'name': '采购', + 'font_class': 'icon-cart', + 'unicode': 'e656', + 'unicode_decimal': 58966, + }, + { + 'icon_id': '12975022', + 'name': '运输', + 'font_class': 'yunshu', + 'unicode': 'e657', + 'unicode_decimal': 58967, + }, + { + 'icon_id': '31312998', + 'name': '客户', + 'font_class': 'kehu', + 'unicode': 'e658', + 'unicode_decimal': 58968, + }, + { + 'icon_id': '45748068', + 'name': '消纳场', + 'font_class': 'xiaonachang', + 'unicode': 'e7aa', + 'unicode_decimal': 59306, + }, { 'icon_id': '17102563', 'name': 'home-3-line', diff --git a/src/components/a-icon/iconfont.ttf b/src/components/a-icon/iconfont.ttf index 7e9b710..4003999 100644 Binary files a/src/components/a-icon/iconfont.ttf and b/src/components/a-icon/iconfont.ttf differ diff --git a/src/components/a-icon/iconfont.woff b/src/components/a-icon/iconfont.woff index 5e24df3..4ccddad 100644 Binary files a/src/components/a-icon/iconfont.woff and b/src/components/a-icon/iconfont.woff differ diff --git a/src/components/a-icon/iconfont.woff2 b/src/components/a-icon/iconfont.woff2 index 992c7fe..a0cdda5 100644 Binary files a/src/components/a-icon/iconfont.woff2 and b/src/components/a-icon/iconfont.woff2 differ diff --git a/src/components/page/FormPage.vue b/src/components/page/FormPage.vue index 73d87e4..d84b05e 100644 --- a/src/components/page/FormPage.vue +++ b/src/components/page/FormPage.vue @@ -4,6 +4,7 @@ import Page from '@/components/page/Page.vue' import Utils, { type ResetAble } from '@/common/utils' import Colls from '@/common/utils/colls.ts' import Strings from '@/common/utils/strings.ts' +import { saveFile } from '@/common/app' import type { R } from '@/common/utils/http-util.ts' import type { TableColumnCtx, @@ -13,6 +14,7 @@ import type { DefaultRow } from 'element-plus/es/components/table/src/table/defa import type { ActionColumnType, FormPropsType, + TableActionType, TablePropsType, ToolType, } from '@/components/page/a-page-type.ts' @@ -27,6 +29,7 @@ const props = withDefaults( rightTools?: Required>[] tableProps?: TablePropsType searchFormProps?: FormPropsType + exportHandler?: (param: F) => Promise> simpleSearchFormProps?: FormPropsType formStyle?: { border: boolean @@ -106,6 +109,23 @@ function doSearch() { } } +function doExport() { + if (props.exportHandler == null) { + return + } + loading.value = true + props.exportHandler(searchForm.$clone() as F) + .then((res) => { + const {content, filename} = res.data ?? {} + if (content != null && filename != null) { + saveFile(content, filename) + } + }) + .finally(() => { + loading.value = false + }) +} + function showSearchFormHandle() { showSearchForm.value = !showSearchForm.value searchForm.$reset() @@ -174,10 +194,10 @@ onMounted(doSearch) doReset() } }"> - + @@ -187,6 +207,9 @@ onMounted(doSearch) :icon="elIcons[tool.icon]" @click="tool.action"/> + + + @@ -210,7 +233,7 @@ onMounted(doSearch)