From 85d745fcee964b44fe14e9cdb53d08fe400e63cf Mon Sep 17 00:00:00 2001
From: "meilin.huang" <954537473@qq.com>
Date: Thu, 21 Dec 2023 13:07:02 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E6=95=B0=E6=8D=AE=E5=BA=93=E8=A1=A8?=
=?UTF-8?q?=E5=8D=95=E5=85=83=E6=A0=BC=E7=BC=96=E8=BE=91=E5=B0=81=E8=A3=85?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../ops/db/component/table/ColumnFormItem.vue | 152 ++++++++++++++++++
.../ops/db/component/table/DbTableData.vue | 112 +------------
.../ops/db/component/table/DbTableDataOp.vue | 39 +----
3 files changed, 161 insertions(+), 142 deletions(-)
create mode 100644 mayfly_go_web/src/views/ops/db/component/table/ColumnFormItem.vue
diff --git a/mayfly_go_web/src/views/ops/db/component/table/ColumnFormItem.vue b/mayfly_go_web/src/views/ops/db/component/table/ColumnFormItem.vue
new file mode 100644
index 00000000..7d0d5dfa
--- /dev/null
+++ b/mayfly_go_web/src/views/ops/db/component/table/ColumnFormItem.vue
@@ -0,0 +1,152 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/mayfly_go_web/src/views/ops/db/component/table/DbTableData.vue b/mayfly_go_web/src/views/ops/db/component/table/DbTableData.vue
index a7e370ea..115d4135 100644
--- a/mayfly_go_web/src/views/ops/db/component/table/DbTableData.vue
+++ b/mayfly_go_web/src/views/ops/db/component/table/DbTableData.vue
@@ -94,57 +94,11 @@
-
-
-
-
@@ -206,6 +160,7 @@ import { exportCsv, exportFile } from '@/common/utils/export';
import { dateStrFormat } from '@/common/utils/date';
import { useIntervalFn } from '@vueuse/core';
import { ColumnTypeSubscript, DataType, DbDialect, DbType, getDbDialect } from '../../dialect/index';
+import ColumnFormItem from './ColumnFormItem.vue';
const emits = defineEmits(['dataDelete', 'sortChange', 'deleteData', 'selectionChange', 'changeUpdatedField']);
@@ -706,6 +661,7 @@ const onEnterEditMode = (rowData: any, column: any, rowIndex = 0, columnIndex =
};
const onExitEditMode = (rowData: any, column: any, rowIndex = 0) => {
+ console.trace('exit');
const oldValue = nowUpdateCell.oldValue;
const newValue = rowData[column.dataKey];
@@ -915,62 +871,4 @@ defineExpose({
right: 0px;
}
}
-
-.edit-time-picker {
- height: 26px;
- width: 100% !important;
- .el-input__prefix {
- display: none;
- }
- .el-input__inner {
- text-align: center;
- }
-}
-.edit-time-picker-popper {
- .el-date-picker {
- width: 250px !important;
- .el-date-picker__header {
- margin: 0 5px;
- }
- .el-picker-panel__content {
- width: unset;
- margin: 0 5px;
- }
- .el-date-picker__header-label {
- font-size: 13px;
- }
- .el-picker-panel__footer {
- padding: 0 5px;
- button {
- font-size: 11px;
- padding: 5px 6px;
- height: 20px;
- }
- }
- }
- .el-date-table {
- th {
- font-size: 10px;
- font-weight: 600;
- padding: 0;
- }
- td {
- padding: 0;
- }
- }
- .el-time-panel {
- width: 100px;
-
- .el-time-spinner__list {
- &::after,
- &::before {
- height: 10px;
- }
- .el-time-spinner__item {
- height: 20px;
- line-height: 20px;
- }
- }
- }
-}
diff --git a/mayfly_go_web/src/views/ops/db/component/table/DbTableDataOp.vue b/mayfly_go_web/src/views/ops/db/component/table/DbTableDataOp.vue
index c2977c78..92a6e42a 100644
--- a/mayfly_go_web/src/views/ops/db/component/table/DbTableDataOp.vue
+++ b/mayfly_go_web/src/views/ops/db/component/table/DbTableDataOp.vue
@@ -135,43 +135,11 @@
:label="column.columnName"
:required="column.nullable != 'YES' && column.columnKey != 'PRI'"
>
-
-
-
-
-
-
-
@@ -190,8 +158,9 @@ import { ElMessage } from 'element-plus';
import { DbInst } from '@/views/ops/db/db';
import DbTableData from './DbTableData.vue';
-import { DataType, DbDialect, getDbDialect } from '@/views/ops/db/dialect';
+import { DbDialect, getDbDialect } from '@/views/ops/db/dialect';
import SvgIcon from '@/components/svgIcon/index.vue';
+import ColumnFormItem from './ColumnFormItem.vue';
const props = defineProps({
dbId: {