Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigDataSystem
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张伯涛
bigDataSystem
Commits
c0a33ab7
Commit
c0a33ab7
authored
Nov 06, 2024
by
liwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
物理模型页面
parent
b785bd3a
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
227 additions
and
97 deletions
+227
-97
detailModel.data.ts
src/views/metaModel/physicsModel/detailModel.data.ts
+0
-89
detailSetModal.vue
src/views/metaModel/physicsModel/detailSetModal.vue
+114
-0
model.data.ts
src/views/metaModel/physicsModel/model.data.ts
+75
-0
modelData.ts
src/views/metaModel/physicsModel/modelData.ts
+26
-0
modelDetailModal.vue
src/views/metaModel/physicsModel/modelDetailModal.vue
+12
-8
No files found.
src/views/metaModel/physicsModel/detailModel.data.ts
deleted
100644 → 0
View file @
b785bd3a
import
{
getAllRoleList
}
from
'@/api/system/role/role'
;
import
{
BasicColumn
,
FormSchema
}
from
'@/components/Table'
;
import
{
h
}
from
"vue"
;
import
{
Tag
}
from
"ant-design-vue"
;
import
{
Switch
}
from
'ant-design-vue'
;
import
{
useMessage
}
from
"@/hooks/web/useMessage"
;
import
{
changeFlagApi
}
from
"@/api/system/user/user"
;
// 引入开关组件
type
CheckedType
=
boolean
|
string
|
number
;
export
const
columns
:
BasicColumn
[]
=
[
{
title
:
'属性名称'
,
dataIndex
:
'name'
,
width
:
150
,
},
{
title
:
'描述'
,
dataIndex
:
'description'
,
width
:
150
,
},
{
title
:
'属性英文名'
,
dataIndex
:
'englishName'
,
width
:
150
,
},
{
title
:
'是否必填'
,
dataIndex
:
'isWrite'
,
editComponent
:
'RadioGroup'
,
editComponentProps
:
{
options
:
[
{
label
:
'是'
,
value
:
'1'
,
},
{
label
:
'否'
,
value
:
'0'
,
},
],
},
width
:
150
,
},
{
title
:
'是否必填'
,
dataIndex
:
'isShow'
,
editComponent
:
'RadioGroup'
,
editComponentProps
:
{
options
:
[
{
label
:
'是'
,
value
:
'1'
,
},
{
label
:
'否'
,
value
:
'0'
,
},
],
},
width
:
150
,
},
{
title
:
'类型'
,
dataIndex
:
'type'
,
editComponent
:
'Select'
,
editComponentProps
:
{
options
:
[
{
label
:
'字符串'
,
value
:
'1'
,
},
{
label
:
'布尔'
,
value
:
'2'
,
},
{
label
:
'整型'
,
value
:
'3'
,
},
{
label
:
'浮点型'
,
value
:
'4'
,
},
],
},
width
:
200
,
},
];
src/views/metaModel/physicsModel/detailSetModal.vue
0 → 100644
View file @
c0a33ab7
<
template
>
<BasicModal
width=
"50%"
v-bind=
"$attrs"
@
register=
"registerModal"
:title=
"getTitle"
@
ok=
"handleSubmit"
>
<BasicTable
@
register=
"registerTable1"
class=
"height"
style=
"height: 200px;"
>
<template
#
toolbar
>
<a-input
style=
"width: 200px;margin-right: auto"
default-value=
"表信息"
allowClear
></a-input>
</
template
>
</BasicTable>
<BasicTable
@
register=
"registerTable2"
class=
"height"
>
<
template
#
toolbar
>
<a-input
style=
"width: 200px;margin-right: auto"
default-value=
"列信息"
allowClear
></a-input>
</
template
>
</BasicTable>
</BasicModal>
</template>
<
script
lang=
"ts"
setup
>
import
{
PageWrapper
}
from
'@/components/Page'
;
import
{
ref
,
computed
,
unref
,
reactive
,
onMounted
}
from
'vue'
;
import
{
BasicModal
,
useModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
modelFormSchema
}
from
'./model.data'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
TreeData
}
from
"@/views/metaModel/physicsModel/modelData"
;
import
{
router
}
from
"@/router"
;
import
ColumnTable
from
'./ColumnTable.vue'
;
import
AreaTable
from
'./AreaTable.vue'
;
import
Table
from
'./Table.vue'
;
import
BucketTable
from
'./BucketTable.vue'
;
import
DetailSetModal
from
'./detailSetModal.vue'
;
import
{
useTable
,
BasicTable
}
from
"@/components/Table"
;
import
{
dataSetColumns
}
from
"@/views/metaModel/physicsModel/model.data"
;
import
{
setColumnData
,
setTableData
}
from
'@/views/metaModel/physicsModel/modelData.ts'
import
Icon
from
'@/components/Icon/Icon.vue'
;
import
{
useGo
}
from
'@/hooks/web/usePage'
;
defineOptions
({
name
:
'ModelModal'
});
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
{
createMessage
}
=
useMessage
();
const
isUpdate
=
ref
(
true
);
const
isMove
=
ref
(
false
);
const
rowId
=
ref
(
''
);
const
tableData
=
ref
([])
const
columnTableData
=
ref
([])
const
go
=
useGo
();
const
getTitle
=
computed
(()
=>
(
'映射配置'
));
const
[
registerTable1
,
{
reload1
,
getForm1
}]
=
useTable
({
title
:
''
,
api
:
async
(
params
)
=>
{
const
response
=
{
pageNu
:
"1"
,
pageSize
:
"10"
,
pages
:
"1"
,
total
:
tableData
.
value
.
length
,
code
:
''
,
message
:
''
,
data
:
[],
};
return
{
...
response
,
data
:
tableData
.
value
};
},
columns
:
dataSetColumns
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
bordered
:
true
,
});
const
[
registerTable2
,
{
reload2
,
getForm2
}]
=
useTable
({
title
:
''
,
api
:
async
(
params
)
=>
{
const
response
=
{
pageNu
:
"1"
,
pageSize
:
"10"
,
pages
:
"1"
,
total
:
columnTableData
.
value
.
length
,
code
:
''
,
message
:
''
,
data
:
columnTableData
.
value
,
};
return
{
...
response
,
data
:
columnTableData
.
value
};
},
columns
:
dataSetColumns
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
bordered
:
true
,
});
//初始化弹框
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
});
/**确定按钮*/
async
function
handleSubmit
()
{
createMessage
.
success
(
'保存成功!'
)
closeModal
()
}
/** 删除按钮*/
function
handleDelete
(
record
:
Recordable
)
{
createMessage
.
success
(
'删除成功!'
);
}
/** 修改按钮*/
function
handleUpdateButton
()
{
go
(
'/metaModel/physicsModel/editRowTable'
);
}
onMounted
(()
=>
{
tableData
.
value
=
setTableData
columnTableData
.
value
=
setColumnData
});
</
script
>
<
style
>
</
style
>
src/views/metaModel/physicsModel/model.data.ts
View file @
c0a33ab7
...
@@ -31,6 +31,81 @@ export const columns: BasicColumn[] = [
...
@@ -31,6 +31,81 @@ export const columns: BasicColumn[] = [
width
:
150
,
width
:
150
,
},
},
];
];
export
const
dataSetColumns
:
BasicColumn
[]
=
[
{
title
:
'元数据'
,
dataIndex
:
'orginalData'
,
width
:
150
,
},
{
title
:
'物理模型'
,
dataIndex
:
'physicsModel'
,
width
:
150
,
editable
:
true
,
edit
:
true
,
editComponent
:
'Select'
,
editComponentProps
:
{
options
:
[
{
label
:
'表名'
,
value
:
'1'
,
},
{
label
:
'中文名'
,
value
:
'2'
,
},
{
label
:
'列名'
,
value
:
'3'
,
},
{
label
:
'列中文名'
,
value
:
'4'
,
},
{
label
:
'英文名'
,
value
:
'5'
,
},
{
label
:
'列英文名'
,
value
:
'6'
,
},
],
},
},
];
export
const
detailColumns
:
BasicColumn
[]
=
[
{
title
:
'属性名称'
,
dataIndex
:
'name'
,
width
:
150
,
},
{
title
:
'描述'
,
dataIndex
:
'description'
,
width
:
150
,
},
{
title
:
'属性英文名'
,
dataIndex
:
'englishName'
,
width
:
150
,
},
{
title
:
'是否必填'
,
dataIndex
:
'isWrite'
,
width
:
150
,
},
{
title
:
'是否必填'
,
dataIndex
:
'isShow'
,
width
:
150
,
},
{
title
:
'类型'
,
dataIndex
:
'type'
,
width
:
200
,
},
];
export
const
searchFormSchema
:
FormSchema
[]
=
[
export
const
searchFormSchema
:
FormSchema
[]
=
[
{
{
field
:
'name'
,
field
:
'name'
,
...
...
src/views/metaModel/physicsModel/modelData.ts
View file @
c0a33ab7
...
@@ -503,4 +503,30 @@ export const editAreaData: any[] = [
...
@@ -503,4 +503,30 @@ export const editAreaData: any[] = [
},
},
];
];
export
const
setTableData
:
any
[]
=
[
{
"businessId"
:
1
,
"orginalData"
:
"表名"
,
"physicsModel"
:
"表名"
,
},
{
"businessId"
:
1
,
"orginalData"
:
"表注释"
,
"physicsModel"
:
"2"
,
},
];
export
const
setColumnData
:
any
[]
=
[
{
"businessId"
:
1
,
"orginalData"
:
"列名"
,
"physicsModel"
:
"列名"
,
},
{
"businessId"
:
1
,
"orginalData"
:
"列注释"
,
"physicsModel"
:
"4"
,
},
];
src/views/metaModel/physicsModel/modelDetailModal.vue
View file @
c0a33ab7
...
@@ -107,6 +107,7 @@
...
@@ -107,6 +107,7 @@
</template>
</template>
</BasicTable>
</BasicTable>
</PageWrapper>
</PageWrapper>
<DetailSetModal
@
register=
"registerSetModal"
@
success=
"handleSuccess"
/>
</BasicModal>
</BasicModal>
</template>
</template>
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
...
@@ -114,7 +115,7 @@ import { PageWrapper } from '@/components/Page';
...
@@ -114,7 +115,7 @@ import { PageWrapper } from '@/components/Page';
import
{
ref
,
computed
,
unref
,
reactive
,
onMounted
}
from
'vue'
;
import
{
ref
,
computed
,
unref
,
reactive
,
onMounted
}
from
'vue'
;
import
{
BasicModal
,
useModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicModal
,
useModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
modelFormSchema
}
from
'./model.data'
;
import
{
detailColumns
,
modelFormSchema
}
from
'./model.data'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
TreeData
}
from
"@/views/metaModel/physicsModel/modelData"
;
import
{
TreeData
}
from
"@/views/metaModel/physicsModel/modelData"
;
import
{
router
}
from
"@/router"
;
import
{
router
}
from
"@/router"
;
...
@@ -122,8 +123,8 @@ import ColumnTable from './ColumnTable.vue';
...
@@ -122,8 +123,8 @@ import ColumnTable from './ColumnTable.vue';
import
AreaTable
from
'./AreaTable.vue'
;
import
AreaTable
from
'./AreaTable.vue'
;
import
Table
from
'./Table.vue'
;
import
Table
from
'./Table.vue'
;
import
BucketTable
from
'./BucketTable.vue'
;
import
BucketTable
from
'./BucketTable.vue'
;
import
DetailSetModal
from
'./detailSetModal.vue'
;
import
{
useTable
,
BasicTable
}
from
"@/components/Table"
;
import
{
useTable
,
BasicTable
}
from
"@/components/Table"
;
import
{
columns
}
from
"@/views/metaModel/physicsModel/detailModel.data"
;
import
{
editAreaData
,
editColumnData
,
editBucketData
,
editTableData
}
from
'@/views/metaModel/physicsModel/modelData.ts'
import
{
editAreaData
,
editColumnData
,
editBucketData
,
editTableData
}
from
'@/views/metaModel/physicsModel/modelData.ts'
import
Icon
from
'@/components/Icon/Icon.vue'
;
import
Icon
from
'@/components/Icon/Icon.vue'
;
import
{
useGo
}
from
'@/hooks/web/usePage'
;
import
{
useGo
}
from
'@/hooks/web/usePage'
;
...
@@ -152,10 +153,9 @@ const [registerTable1, { reload1,getForm1 }] = useTable({
...
@@ -152,10 +153,9 @@ const [registerTable1, { reload1,getForm1 }] = useTable({
message
:
''
,
message
:
''
,
data
:
[],
data
:
[],
};
};
console
.
log
(
'tableData.value:'
,
tableData
.
value
)
return
{
...
response
,
data
:
tableData
.
value
};
return
{
...
response
,
data
:
tableData
.
value
};
},
},
columns
,
columns
:
detailColumns
,
showTableSetting
:
false
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
pagination
:
false
,
...
@@ -180,7 +180,7 @@ const [registerTable2, { reload2,getForm2 }] = useTable({
...
@@ -180,7 +180,7 @@ const [registerTable2, { reload2,getForm2 }] = useTable({
};
};
return
{
...
response
,
data
:
bucketTableData
.
value
};
return
{
...
response
,
data
:
bucketTableData
.
value
};
},
},
columns
,
columns
:
detailColumns
,
showTableSetting
:
false
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
pagination
:
false
,
...
@@ -205,7 +205,7 @@ const [registerTable3, { reload3,getForm3 }] = useTable({
...
@@ -205,7 +205,7 @@ const [registerTable3, { reload3,getForm3 }] = useTable({
};
};
return
{
...
response
,
data
:
areaTableData
.
value
};
return
{
...
response
,
data
:
areaTableData
.
value
};
},
},
columns
,
columns
:
detailColumns
,
showTableSetting
:
false
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
pagination
:
false
,
...
@@ -230,7 +230,7 @@ const [registerTable4, { reload4,getForm4 }] = useTable({
...
@@ -230,7 +230,7 @@ const [registerTable4, { reload4,getForm4 }] = useTable({
};
};
return
{
...
response
,
data
:
columnTableData
.
value
};
return
{
...
response
,
data
:
columnTableData
.
value
};
},
},
columns
,
columns
:
detailColumns
,
showTableSetting
:
false
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
showIndexColumn
:
false
,
pagination
:
false
,
pagination
:
false
,
...
@@ -247,6 +247,8 @@ const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data
...
@@ -247,6 +247,8 @@ const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data
setModalProps
({
confirmLoading
:
false
,
showCancelBtn
:
false
,
showOkBtn
:
false
});
setModalProps
({
confirmLoading
:
false
,
showCancelBtn
:
false
,
showOkBtn
:
false
});
});
});
const
[
registerSetModal
,
{
openModal
:
setModal
}]
=
useModal
();
/**确定按钮*/
/**确定按钮*/
async
function
handleSubmit
()
{
async
function
handleSubmit
()
{
router
.
push
({
router
.
push
({
...
@@ -263,7 +265,9 @@ function handleDelete(record: Recordable) {
...
@@ -263,7 +265,9 @@ function handleDelete(record: Recordable) {
/** 配置按钮*/
/** 配置按钮*/
function
handleSetButton
()
{
function
handleSetButton
()
{
console
.
log
(
'1111'
)
setModal
(
true
,
{
isUpdate
:
false
,
});
}
}
/** 修改按钮*/
/** 修改按钮*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment