Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
wangxiaolu-sfa-ui
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
sfa
wangxiaolu-sfa-ui
Commits
a2298768
提交
a2298768
authored
3月 20, 2025
作者:
lidongxu
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'ldx' into dev
上级
7fbcab2c
03c87990
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
337 行增加
和
48 行删除
+337
-48
supply.js
src/api/bi/supply.js
+32
-0
index.js
src/api/index.js
+1
-0
index.js
src/api/jimu/index.js
+11
-6
report.vue
src/views/bi/finance/report.vue
+211
-0
index.vue
src/views/bi/supply/index.vue
+36
-18
index.vue
src/views/jimureport/ext/index.vue
+45
-24
index.vue
src/views/promotion/plan/index.vue
+1
-0
没有找到文件。
src/api/bi/supply.js
0 → 100644
浏览文件 @
a2298768
import
request
from
'@/utils/request'
// 获取积木报表列表
export
function
getReportListAPI
(
params
)
{
return
request
({
url
:
'/report/customer/share/list'
,
params
})
}
// 获取自定义报表列表
export
function
getReportListBySelfAPI
()
{
return
request
({
url
:
'/report/customer/query/list'
})
}
// 自定义分组报表列表查询
export
function
getReportListByGroupAPI
(
params
)
{
return
request
({
url
:
'/report/customer/query/group/list'
,
params
})
}
// 自定义分组新增
export
function
addReportGroupAPI
(
data
)
{
return
request
({
url
:
'/report/customer/core/group/save'
,
method
:
'post'
,
data
})
}
\ No newline at end of file
src/api/index.js
浏览文件 @
a2298768
...
...
@@ -9,6 +9,7 @@ export * from './bi/livecate'
export
*
from
'./bi/product'
export
*
from
'./bi/sale'
export
*
from
'./bi/store'
export
*
from
'./bi/supply'
export
*
from
'./jimu/index'
export
*
from
'./monitor/cache'
export
*
from
'./monitor/job'
...
...
src/api/jimu/index.js
浏览文件 @
a2298768
import
request
from
'@/utils/request'
// 获取报表列表
export
function
getReportListAPI
()
{
return
request
({
url
:
'/report/share/list'
})
}
// 提交其他报表超链接
export
function
submitOtherReportAPI
(
data
)
{
...
...
@@ -13,4 +8,13 @@ export function submitOtherReportAPI(data) {
method
:
'post'
,
data
})
}
// 录入其他平台报表链接
export
function
enterOtherReportAPI
(
data
)
{
return
request
({
url
:
'/report/customer/core/save'
,
method
:
'POST'
,
data
})
}
\ No newline at end of file
src/views/bi/finance/report.vue
0 → 100644
浏览文件 @
a2298768
<
template
>
<div
class=
"app-container"
>
<el-card
class=
"container"
>
<template
#
header
>
<div
class=
"card-header"
>
<span>
常用报表
</span>
<el-button
class=
"custom"
type=
"primary"
link
@
click=
"visible = true"
>
自定义
</el-button>
</div>
</
template
>
<div
v-for=
"item in groups"
class=
"group_item"
>
<div>
<p
class=
"group_name"
>
<el-icon
color=
"blue"
size=
"18"
>
<Folder
/>
</el-icon>
<span>
{{ item.groupName }}
</span>
</p>
<div
class=
"link_wrap"
>
<div
class=
"link_item"
v-for=
"obj in item.items"
>
<el-icon
color=
"green"
size=
"16"
>
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + obj.previewUrl"
target=
"_blank"
>
{{ obj.reportName }}
</el-link>
</div>
</div>
</div>
</div>
</el-card>
<el-dialog
title=
"编辑常用报表"
v-model=
"visible"
>
<div
class=
"wrap"
>
<div
class=
"left"
>
<draggable
v-model=
"reportList"
group=
"reports"
ghost-class=
"dragging-item-left"
item-key=
"id"
>
<
template
#
item=
"{ element }"
>
<div
class=
"link_item"
>
<el-icon
color=
"green"
size=
"16"
>
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + element.previewUrl"
target=
"_blank"
>
{{
element
.
reportName
}}
</el-link>
</div>
</
template
>
</draggable>
</div>
<div
class=
"right"
>
<div
class=
"group-container"
>
<el-card
v-for=
"group in groups"
:key=
"group.id"
class=
"group_card"
:style=
"{ width: '100%' }"
>
<
template
#
header
>
<div
class=
"card-header"
>
<span>
{{
group
.
groupName
}}
</span>
</div>
</
template
>
<draggable
v-model=
"group.items"
group=
"reports"
ghost-class=
"dragging-item"
item-key=
"id"
@
change=
"groupChange"
>
<
template
#
item=
"{ element }"
>
<div
class=
"link_item"
>
<el-icon
color=
"green"
size=
"16"
>
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + element.previewUrl"
target=
"_blank"
>
{{
element
.
reportName
}}
</el-link>
</div>
</
template
>
</draggable>
</el-card>
</div>
</div>
</div>
</el-dialog>
</div>
</template>
<
script
setup
>
import
{
getReportListAPI
,
getReportListBySelfAPI
,
getReportListByGroupAPI
,
addReportGroupAPI
}
from
'@/api'
import
draggable
from
'vuedraggable'
const
visible
=
ref
(
false
)
const
groups
=
ref
([])
const
baseURL
=
ref
(
import
.
meta
.
env
.
VITE_APP_REPORT_URL
+
'/report'
)
const
reportList
=
ref
([])
const
getReportList
=
async
()
=>
{
// 积木报表
const
{
data
}
=
await
getReportListAPI
({
categoryName
:
'财务报表'
})
// 其他报表
const
{
data
:
otherData
}
=
await
getReportListBySelfAPI
()
reportList
.
value
=
data
.
concat
(
otherData
)
// 右侧分组列表
const
res
=
await
getReportListByGroupAPI
({
categoryName
:
'财务报表'
})
groups
.
value
=
res
.
data
// 左侧报表里要删除右侧里面有的了,用 reportId 来判断
reportList
.
value
=
reportList
.
value
.
filter
(
item
=>
{
return
!
groups
.
value
.
some
(
group
=>
group
.
items
.
some
(
groupItem
=>
groupItem
.
reportId
===
item
.
reportId
))
})
}
// 拖入拖出+顺序改变
const
groupChange
=
async
(
e
)
=>
{
groups
.
value
.
forEach
(
o
=>
{
o
.
id
=
o
.
groupId
})
await
addReportGroupAPI
(
groups
.
value
)
}
getReportList
()
</
script
>
<
style
scoped
lang=
"scss"
>
.el-card__header
{
.custom
{
float
:
right
;
padding
:
3px
0
;
}
}
.group_item
{
.group_name
{
display
:
flex
;
align-items
:
center
;
gap
:
10px
;
font-size
:
16px
;
font-weight
:
800
;
}
.link_wrap
{
display
:
flex
;
flex-wrap
:
wrap
;
padding
:
0
0
0
20px
;
.link_item
{
padding
:
10px
0
;
width
:
25%
;
/* 超出宽度文字省略号 */
overflow
:
hidden
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
}
}
}
.link_item
{
padding
:
5px
0
;
display
:
flex
;
align-items
:
center
;
gap
:
10px
;
}
.group_card
{
margin-top
:
20px
;
}
.wrap
{
display
:
flex
;
gap
:
20px
;
width
:
100%
;
height
:
100%
;
.left
{
width
:
100%
;
height
:
100%
;
overflow-y
:
scroll
;
overflow-x
:
hidden
;
}
.right
{
width
:
100%
;
height
:
100%
;
overflow-y
:
scroll
;
overflow-x
:
hidden
;
}
}
/* 添加拖拽时的样式 */
.dragging-item-left
{
background-color
:
transparent
;
}
.dragging-item
{
background-color
:
#a1ccf2
;
}
</
style
>
\ No newline at end of file
src/views/bi/supply/index.vue
浏览文件 @
a2298768
...
...
@@ -21,7 +21,7 @@
<Folder
/>
</el-icon>
<span>
{{ item.
n
ame }}
{{ item.
groupN
ame }}
</span>
</p>
<div
class=
"link_wrap"
>
...
...
@@ -32,7 +32,7 @@
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + obj.previewUrl"
target=
"_blank"
>
{{ obj.
n
ame }}
</el-link>
target=
"_blank"
>
{{ obj.
reportN
ame }}
</el-link>
</div>
</div>
</div>
...
...
@@ -53,7 +53,7 @@
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + element.previewUrl"
target=
"_blank"
>
{{
element
.
n
ame
}}
</el-link>
target=
"_blank"
>
{{
element
.
reportN
ame
}}
</el-link>
</div>
</
template
>
</draggable>
...
...
@@ -66,13 +66,14 @@
:style=
"{ width: '100%' }"
>
<
template
#
header
>
<div
class=
"card-header"
>
<span>
{{
group
.
n
ame
}}
</span>
<span>
{{
group
.
groupN
ame
}}
</span>
</div>
</
template
>
<draggable
v-model=
"group.items"
group=
"reports"
ghost-class=
"dragging-item"
item-key=
"id"
>
item-key=
"id"
@
change=
"groupChange"
>
<
template
#
item=
"{ element }"
>
<div
class=
"link_item"
>
<el-icon
color=
"green"
...
...
@@ -80,7 +81,7 @@
<Document></Document>
</el-icon>
<el-link
:href=
"baseURL + element.previewUrl"
target=
"_blank"
>
{{
element
.
n
ame
}}
</el-link>
target=
"_blank"
>
{{
element
.
reportN
ame
}}
</el-link>
</div>
</
template
>
</draggable>
...
...
@@ -93,23 +94,39 @@
</template>
<
script
setup
>
import
{
getReportListAPI
}
from
'@/api'
import
{
getReportListAPI
,
getReportListBySelfAPI
,
getReportListByGroupAPI
,
addReportGroupAPI
}
from
'@/api'
import
draggable
from
'vuedraggable'
const
visible
=
ref
(
false
)
const
groups
=
ref
([
{
id
:
1
,
name
:
'品控部'
,
items
:
[]
},
{
id
:
2
,
name
:
'物流部'
,
items
:
[]
},
{
id
:
3
,
name
:
'计划部'
,
items
:
[]
},
{
id
:
4
,
name
:
'采购部'
,
items
:
[]
},
{
id
:
5
,
name
:
'滁州工厂'
,
items
:
[]
},
])
const
groups
=
ref
([])
const
baseURL
=
ref
(
import
.
meta
.
env
.
VITE_APP_REPORT_URL
+
'/report'
)
const
reportList
=
ref
([])
const
getReportList
=
async
()
=>
{
const
{
data
}
=
await
getReportListAPI
()
reportList
.
value
=
data
.
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
).
concat
(
data
)
// 积木报表
const
{
data
}
=
await
getReportListAPI
({
categoryName
:
'供应链报表'
})
// 其他报表
const
{
data
:
otherData
}
=
await
getReportListBySelfAPI
()
reportList
.
value
=
data
.
concat
(
otherData
)
// 右侧分组列表
const
res
=
await
getReportListByGroupAPI
({
categoryName
:
'供应链报表'
})
groups
.
value
=
res
.
data
// 左侧报表里要删除右侧里面有的了,用 reportId 来判断
reportList
.
value
=
reportList
.
value
.
filter
(
item
=>
{
return
!
groups
.
value
.
some
(
group
=>
group
.
items
.
some
(
groupItem
=>
groupItem
.
reportId
===
item
.
reportId
))
})
}
// 拖入拖出+顺序改变
const
groupChange
=
async
(
e
)
=>
{
groups
.
value
.
forEach
(
o
=>
{
o
.
id
=
o
.
groupId
})
await
addReportGroupAPI
(
groups
.
value
)
}
getReportList
()
</
script
>
...
...
@@ -187,7 +204,7 @@ getReportList()
background-color
:
transparent
;
}
.dragging-item
{
background-color
:
transparent
;
background-color
:
#a1ccf2
;
}
</
style
>
\ No newline at end of file
src/views/jimureport/ext/index.vue
浏览文件 @
a2298768
...
...
@@ -7,16 +7,18 @@
</div>
</
template
>
<el-form
:model=
"form"
:rules=
"rules"
ref=
"reportRef"
label-width=
"100px"
>
<el-form-item
label=
"报表名字"
prop=
"
reportN
ame"
>
<el-input
v-model=
"form.
reportN
ame"
prop=
"
n
ame"
>
<el-input
v-model=
"form.
n
ame"
placeholder=
"请输入报表名字"
/>
</el-form-item>
<!-- 超链接输入 -->
<el-form-item
label=
"超链接"
prop=
"
link
"
>
<el-input
v-model=
"form.
link
"
prop=
"
previewUrl
"
>
<el-input
v-model=
"form.
previewUrl
"
placeholder=
"请输入超链接地址"
/>
</el-form-item>
<!-- 提交按钮 -->
...
...
@@ -25,7 +27,6 @@
@
click=
"handleSubmit"
>
提交
</el-button>
</el-form-item>
</el-form>
</el-card>
</div>
</template>
...
...
@@ -33,32 +34,52 @@
<
script
setup
>
import
{
ref
}
from
'vue'
import
{
ElMessage
}
from
'element-plus'
import
{
submit
OtherReportAPI
}
from
'@/api'
// 假设你的API接口
import
{
enter
OtherReportAPI
}
from
'@/api'
// 假设你的API接口
const
{
proxy
}
=
getCurrentInstance
();
// 表单数据
const
form
=
ref
({
link
:
''
,
remark
:
''
id
:
''
,
name
:
''
,
previewUrl
:
''
,
})
// 提交处理
const
handleSubmit
=
async
()
=>
{
try
{
if
(
!
form
.
value
.
group
||
!
form
.
value
.
link
)
{
ElMessage
.
warning
(
'请填写完整信息'
)
return
// 表单验证规则
const
rules
=
ref
({
name
:
[
{
required
:
true
,
message
:
'请输入报表名字'
,
trigger
:
'blur'
}
],
previewUrl
:
[
{
required
:
true
,
message
:
'请输入超链接地址'
,
trigger
:
'blur'
},
// 判断必须是个完成的链接
{
validator
:
(
rule
,
value
,
callback
)
=>
{
if
(
!
/^https
?
:
\/\/
/
.
test
(
value
))
{
callback
(
new
Error
(
'请输入正确的超链接地址'
))
}
else
{
callback
()
}
}
}
]
})
await
submitOtherReportAPI
(
form
.
value
)
ElMessage
.
success
(
'提交成功'
)
// 清空表单
form
.
value
=
{
link
:
''
,
remark
:
''
// 提交处理
const
handleSubmit
=
async
()
=>
{
// 调用表单验证方法
proxy
.
$refs
[
"reportRef"
].
validate
(
async
valid
=>
{
if
(
valid
)
{
// 表单验证通过,进行提交操作
await
enterOtherReportAPI
(
form
.
value
)
ElMessage
.
success
(
'提交成功'
)
// 清空表单
form
.
value
=
{
id
:
''
,
name
:
''
,
previewUrl
:
''
,
}
proxy
.
$refs
[
"reportRef"
].
resetFields
()
}
}
catch
(
error
)
{
ElMessage
.
error
(
'提交失败'
)
}
})
}
</
script
>
...
...
src/views/promotion/plan/index.vue
浏览文件 @
a2298768
...
...
@@ -762,6 +762,7 @@ const handleEditEmp = () => {
}
// 确定批量修改计划人
const
handleEditPlanEmp
=
async
()
=>
{
const
res
=
await
batchUpdatePlanAPI
({
employeeId
:
editPlanEmpForm
.
value
.
employeeId
,
operName
:
store
.
state
.
value
.
user
.
userInfo
.
nickName
,
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论