Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
szse
Overview
Overview
Details
Activity
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
zhaochengxiang
szse
Commits
8df595e3
Commit
8df595e3
authored
Jun 04, 2024
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
报表
parent
87d08137
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
34 additions
and
21 deletions
+34
-21
assetmanage.js
src/model/assetmanage.js
+5
-0
dataassetmanager.js
src/service/dataassetmanager.js
+5
-0
AssetAction.jsx
src/view/Manage/AssetManage/Component/AssetAction.jsx
+1
-0
AssetTable.jsx
src/view/Manage/AssetManage/Component/AssetTable.jsx
+1
-1
WorkbookDrawer.jsx
src/view/Manage/AssetManage/Component/WorkbookDrawer.jsx
+17
-12
WorksheetModal.jsx
src/view/Manage/AssetManage/Component/WorksheetModal.jsx
+5
-8
No files found.
src/model/assetmanage.js
View file @
8df595e3
...
@@ -469,3 +469,7 @@ export function* getViewUrlByWorkbookId(payload) {
...
@@ -469,3 +469,7 @@ export function* getViewUrlByWorkbookId(payload) {
export
function
*
saveWorkbookByType
(
payload
)
{
export
function
*
saveWorkbookByType
(
payload
)
{
return
yield
call
(
service
.
saveWorkbookByType
,
payload
)
return
yield
call
(
service
.
saveWorkbookByType
,
payload
)
}
}
export
function
*
deleteWorkbooks
(
payload
)
{
return
yield
call
(
service
.
deleteWorkbooks
,
payload
)
}
\ No newline at end of file
src/service/dataassetmanager.js
View file @
8df595e3
...
@@ -476,3 +476,7 @@ export function getViewUrlByWorkbookId(payload) {
...
@@ -476,3 +476,7 @@ export function getViewUrlByWorkbookId(payload) {
export
function
saveWorkbookByType
(
payload
)
{
export
function
saveWorkbookByType
(
payload
)
{
return
Post
(
"/dataassetmanagertest/reportApi/saveWorkbook"
,
payload
)
return
Post
(
"/dataassetmanagertest/reportApi/saveWorkbook"
,
payload
)
}
}
export
function
deleteWorkbooks
(
payload
)
{
return
PostJSON
(
"/dataassetmanagertest/reportApi/deleteWorkbooks"
,
payload
)
}
\ No newline at end of file
src/view/Manage/AssetManage/Component/AssetAction.jsx
View file @
8df595e3
...
@@ -604,6 +604,7 @@ const AssetAction = React.forwardRef(function (props, ref) {
...
@@ -604,6 +604,7 @@ const AssetAction = React.forwardRef(function (props, ref) {
if (reference === AssetDraftReference) {
if (reference === AssetDraftReference) {
let data = action==='add' ? { elements: newElements } : { ...assets, elements: newElements }
let data = action==='add' ? { elements: newElements } : { ...assets, elements: newElements }
data = {...data, businessRelations: relationAssetsRef.current?.assets, businessColumns: modifyMetadataColumnList}
dispatch({
dispatch({
type: 'assetmanage.updateDraft',
type: 'assetmanage.updateDraft',
...
...
src/view/Manage/AssetManage/Component/AssetTable.jsx
View file @
8df595e3
...
@@ -1047,7 +1047,7 @@ const AssetTable = (props) => {
...
@@ -1047,7 +1047,7 @@ const AssetTable = (props) => {
}
}
<Button onClick={onFilterElementClick}>可见列设置</Button>
<Button onClick={onFilterElementClick}>可见列设置</Button>
{
{
reference===AssetManageReference && (reportTypes??[]).length > 0 && <Dropdown overlay={moreMenu} placement="bottomCenter">
reference===AssetManageReference &&
template?.structured &&
(reportTypes??[]).length > 0 && <Dropdown overlay={moreMenu} placement="bottomCenter">
<Button>其他操作</Button>
<Button>其他操作</Button>
</Dropdown>
</Dropdown>
}
}
...
...
src/view/Manage/AssetManage/Component/WorkbookDrawer.jsx
View file @
8df595e3
...
@@ -2,6 +2,7 @@ import React, { useState, useEffect } from 'react';
...
@@ -2,6 +2,7 @@ import React, { useState, useEffect } from 'react';
import
{
Drawer
,
Pagination
,
List
}
from
'antd'
;
import
{
Drawer
,
Pagination
,
List
}
from
'antd'
;
import
{
dispatch
}
from
'../../../../model'
;
import
{
dispatch
}
from
'../../../../model'
;
import
{
showMessage
}
from
'../../../../util'
;
const
WorkbookDrawer
=
(
props
)
=>
{
const
WorkbookDrawer
=
(
props
)
=>
{
const
{
onCancel
,
visible
,
report
}
=
props
;
const
{
onCancel
,
visible
,
report
}
=
props
;
...
@@ -44,17 +45,18 @@ const WorkbookDrawer = (props) => {
...
@@ -44,17 +45,18 @@ const WorkbookDrawer = (props) => {
})
})
}
}
// const onDeleteClick = (id) => {
const
onDeleteClick
=
(
id
)
=>
{
// dispatch({
dispatch
({
// type: 'assetmanage.deleteWorkbooks',
type
:
'assetmanage.deleteWorkbooks'
,
// payload: {
payload
:
{
// data: [id]
data
:
[
id
]
// },
},
// callback: () => {
callback
:
()
=>
{
// getWorkbooks();
showMessage
(
'success'
,
'删除成功'
);
// }
getWorkbooks
();
// })
}
// }
})
}
const
onDevelopClick
=
(
id
)
=>
{
const
onDevelopClick
=
(
id
)
=>
{
dispatch
({
dispatch
({
...
@@ -88,7 +90,10 @@ const WorkbookDrawer = (props) => {
...
@@ -88,7 +90,10 @@ const WorkbookDrawer = (props) => {
renderItem=
{
item
=>
(
renderItem=
{
item
=>
(
<
List
.
Item
<
List
.
Item
key=
{
item
.
id
}
key=
{
item
.
id
}
actions=
{
[<
a
key=
"develop"
onClick=
{
()
=>
{
onDevelopClick
(
item
.
id
);
}
}
>
报表开发
</
a
>]
}
actions=
{
[
<
a
key=
"develop"
onClick=
{
()
=>
{
onDevelopClick
(
item
.
id
);
}
}
>
报表开发
</
a
>,
<
a
key=
"delete"
onClick=
{
()
=>
{
onDeleteClick
(
item
.
id
);
}
}
>
删除
</
a
>
]
}
>
>
<
List
.
Item
.
Meta
<
List
.
Item
.
Meta
title=
{
item
.
name
}
title=
{
item
.
name
}
...
...
src/view/Manage/AssetManage/Component/WorksheetModal.jsx
View file @
8df595e3
import
React
,
{
useEffect
,
useState
}
from
'react'
;
import
React
,
{
useEffect
,
useState
}
from
'react'
;
import
{
Modal
,
Form
,
Button
,
Space
,
Input
,
Checkbox
,
Row
,
Col
,
Typography
}
from
'antd'
;
import
{
Modal
,
Form
,
Button
,
Space
,
Input
,
Checkbox
,
Row
,
Col
,
Typography
,
Spin
}
from
'antd'
;
import
{
dispatch
}
from
'../../../../model'
;
import
{
dispatch
}
from
'../../../../model'
;
import
{
showMessage
}
from
'../../../../util'
;
import
{
showMessage
}
from
'../../../../util'
;
...
@@ -68,6 +68,7 @@ const WorksheetModal = (props) => {
...
@@ -68,6 +68,7 @@ const WorksheetModal = (props) => {
const
reset
=
()
=>
{
const
reset
=
()
=>
{
setLoading
(
false
);
setLoading
(
false
);
setAsset
();
form
?.
resetFields
();
form
?.
resetFields
();
}
}
...
@@ -102,6 +103,7 @@ const WorksheetModal = (props) => {
...
@@ -102,6 +103,7 @@ const WorksheetModal = (props) => {
</
Space
>
</
Space
>
}
}
>
>
<
Spin
spinning=
{
loading
}
>
<
Form
form=
{
form
}
style=
{
{
maxHeight
:
600
,
overflow
:
'auto'
}
}
{
...
formItemLayout
}
>
<
Form
form=
{
form
}
style=
{
{
maxHeight
:
600
,
overflow
:
'auto'
}
}
{
...
formItemLayout
}
>
<
Form
.
Item
<
Form
.
Item
label=
"名称"
label=
"名称"
...
@@ -113,17 +115,12 @@ const WorksheetModal = (props) => {
...
@@ -113,17 +115,12 @@ const WorksheetModal = (props) => {
<
Form
.
Item
<
Form
.
Item
label=
"字段"
label=
"字段"
name=
"columns"
name=
"columns"
rules=
{
[{
required
:
true
,
message
:
'请选择字段!'
}]
}
>
>
<
ColumnsItem
data=
{
asset
?.
columns
}
/>
<
ColumnsItem
data=
{
asset
?.
columns
}
/>
</
Form
.
Item
>
</
Form
.
Item
>
<
Form
.
Item
label=
"元数据"
name=
"tableName"
hidden=
{
true
}
>
<
Input
/>
</
Form
.
Item
>
</
Form
>
</
Form
>
</
Spin
>
</
Modal
>
</
Modal
>
);
);
}
}
...
...
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