| | |
| | | import PageHeader from "@/components/PageHeader/index.vue"; |
| | | |
| | | import { getToken } from "@/utils/auth"; |
| | | import { toDateOnly } from "@/utils/dateDisplay"; |
| | | import { |
| | | calculateTaxExclusiveTotalPrice, |
| | | summarizeTable, |
| | |
| | | app.config.globalProperties.addDateRange = addDateRange; |
| | | app.config.globalProperties.selectDictLabel = selectDictLabel; |
| | | app.config.globalProperties.selectDictLabels = selectDictLabels; |
| | | app.config.globalProperties.formatDateOnly = toDateOnly; |
| | | app.config.globalProperties.javaApi = __BASE_API__; |
| | | app.config.globalProperties.HaveJson = (val) => { |
| | | return JSON.parse(JSON.stringify(val)); |
| | |
| | | }); |
| | | app._context.components.ElDialog.props.closeOnClickModal.default = false; |
| | | |
| | | // 列表时间统一只展示年月日:未单独配置 formatter 的表格列走这里 |
| | | const tableColumnFormatter = |
| | | app._context.components.ElTableColumn?.props?.formatter; |
| | | if (tableColumnFormatter) { |
| | | const formatCell = (row, column, cellValue) => toDateOnly(cellValue); |
| | | if (typeof tableColumnFormatter === "function") { |
| | | app._context.components.ElTableColumn.props.formatter = { |
| | | type: Function, |
| | | default: formatCell, |
| | | }; |
| | | } else { |
| | | tableColumnFormatter.default = formatCell; |
| | | } |
| | | } |
| | | |
| | | app.mount("#app"); |