Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
topsun-baoshen-excel
Project
Project
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
何远江
topsun-baoshen-excel
Commits
ad21da0c
Commit
ad21da0c
authored
Jan 09, 2024
by
何远江
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG 修改
parent
14295c51
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
90 additions
and
89 deletions
+90
-89
excelConfig.ts
src/constants/excelConfig.ts
+85
-85
ExcelOperate.vue
...ws/comment-excel/components/ExcelOperate/ExcelOperate.vue
+2
-3
SetArea.vue
src/views/comment-excel/components/SetArea/SetArea.vue
+3
-1
No files found.
src/constants/excelConfig.ts
View file @
ad21da0c
export
const
authorityConfig
=
{
selectLockedCells
:
1
,
//选定锁定单元格
selectunLockedCells
:
1
,
//选定解除锁定的单元格
formatCells
:
0
,
//设置单元格格式
formatColumns
:
0
,
//设置列格式
formatRows
:
0
,
//设置行格式
insertColumns
:
0
,
//插入列
insertRows
:
0
,
//插入行
insertHyperlinks
:
0
,
//插入超链接
deleteColumns
:
0
,
//删除列
deleteRows
:
0
,
//删除行
sort
:
0
,
//排序
filter
:
0
,
//使用自动筛选
usePivotTablereports
:
0
,
//使用数据透视表和报表
editObjects
:
0
,
//编辑对象
editScenarios
:
0
,
//编辑方案
sheet
:
1
,
//如果为1或true,则该工作表受到保护;如果为0或false,则该工作表不受保护。
hintText
:
""
,
//弹窗提示的文字
algorithmName
:
"None"
,
//加密方案:MD2,MD4,MD5,RIPEMD-128,RIPEMD-160,SHA-1,SHA-256,SHA-384,SHA-512,WHIRLPOOL
saltValue
:
null
,
//密码解密的盐参数,为一个自己定的随机数值
allowRangeList
:
[],
};
export
const
showsheetbarConfig
=
{
add
:
false
,
//新增sheet
menu
:
true
,
//sheet管理菜单
sheet
:
true
,
//sheet页显示
};
export
const
sheetRightClickConfig
=
{
delete
:
false
,
// 删除
copy
:
false
,
// 复制
rename
:
false
,
//重命名
color
:
false
,
//更改颜色
hide
:
false
,
//隐藏,取消隐藏
move
:
false
,
//向左移,向右移
};
export
const
cellRightClickConfig
=
{
copy
:
false
,
// 复制
copyAs
:
false
,
// 复制为
paste
:
false
,
// 粘贴
insertRow
:
false
,
// 插入行
insertColumn
:
false
,
// 插入列
deleteRow
:
false
,
// 删除选中行
deleteColumn
:
false
,
// 删除选中列
deleteCell
:
false
,
// 删除单元格
hideRow
:
false
,
// 隐藏选中行和显示选中行
hideColumn
:
false
,
// 隐藏选中列和显示选中列
rowHeight
:
false
,
// 行高
columnWidth
:
false
,
// 列宽
clear
:
false
,
// 清除内容
matrix
:
false
,
// 矩阵操作选区
sort
:
false
,
// 排序选区
filter
:
false
,
// 筛选选区
chart
:
false
,
// 图表生成
image
:
false
,
// 插入图片
link
:
false
,
// 插入链接
data
:
false
,
// 数据验证
cellFormat
:
false
,
// 设置单元格格式
};
export
const
showstatisticBarConfig
=
{
count
:
false
,
// 计数栏
view
:
false
,
// 打印视图
zoom
:
true
,
// 缩放
}
export
const
colors
=
[
'#70a1d7'
,
'#a1de93'
,
'#f7f48b'
,
'#f47c7c'
,
'#649dad'
,
'#66c6ba'
,
'#a4e5d9'
,
'#c8f4de'
]
selectLockedCells
:
1
,
//选定锁定单元格
selectunLockedCells
:
1
,
//选定解除锁定的单元格
formatCells
:
0
,
//设置单元格格式
formatColumns
:
0
,
//设置列格式
formatRows
:
0
,
//设置行格式
insertColumns
:
0
,
//插入列
insertRows
:
0
,
//插入行
insertHyperlinks
:
0
,
//插入超链接
deleteColumns
:
0
,
//删除列
deleteRows
:
0
,
//删除行
sort
:
0
,
//排序
filter
:
0
,
//使用自动筛选
usePivotTablereports
:
0
,
//使用数据透视表和报表
editObjects
:
0
,
//编辑对象
editScenarios
:
0
,
//编辑方案
sheet
:
1
,
//如果为1或true,则该工作表受到保护;如果为0或false,则该工作表不受保护。
hintText
:
''
,
//弹窗提示的文字
algorithmName
:
'None'
,
//加密方案:MD2,MD4,MD5,RIPEMD-128,RIPEMD-160,SHA-1,SHA-256,SHA-384,SHA-512,WHIRLPOOL
saltValue
:
null
,
//密码解密的盐参数,为一个自己定的随机数值
allowRangeList
:
[]
}
export
const
areaMarksColor
=
{
'data'
:
'#65d0ea'
,
'head'
:
'#34718d'
,
'default'
:
'#ffffff'
,
'attch'
:
'#e6ccb2'
,
'attch_title'
:
'#e58e26'
,
'attch_head'
:
'#b08968'
,
}
\ No newline at end of file
export
const
showsheetbarConfig
=
{
add
:
false
,
//新增sheet
menu
:
true
,
//sheet管理菜单
sheet
:
true
//sheet页显示
}
export
const
sheetRightClickConfig
=
{
delete
:
false
,
// 删除
copy
:
false
,
// 复制
rename
:
false
,
//重命名
color
:
false
,
//更改颜色
hide
:
false
,
//隐藏,取消隐藏
move
:
false
//向左移,向右移
}
export
const
cellRightClickConfig
=
{
copy
:
false
,
// 复制
copyAs
:
false
,
// 复制为
paste
:
false
,
// 粘贴
insertRow
:
false
,
// 插入行
insertColumn
:
false
,
// 插入列
deleteRow
:
false
,
// 删除选中行
deleteColumn
:
false
,
// 删除选中列
deleteCell
:
false
,
// 删除单元格
hideRow
:
false
,
// 隐藏选中行和显示选中行
hideColumn
:
false
,
// 隐藏选中列和显示选中列
rowHeight
:
false
,
// 行高
columnWidth
:
false
,
// 列宽
clear
:
false
,
// 清除内容
matrix
:
false
,
// 矩阵操作选区
sort
:
false
,
// 排序选区
filter
:
false
,
// 筛选选区
chart
:
false
,
// 图表生成
image
:
false
,
// 插入图片
link
:
false
,
// 插入链接
data
:
false
,
// 数据验证
cellFormat
:
false
// 设置单元格格式
}
export
const
showstatisticBarConfig
=
{
count
:
false
,
// 计数栏
view
:
false
,
// 打印视图
zoom
:
true
// 缩放
}
export
const
colors
=
[
'#70a1d7'
,
'#a1de93'
,
'#f7f48b'
,
'#f47c7c'
,
'#649dad'
,
'#66c6ba'
,
'#a4e5d9'
,
'#c8f4de'
]
export
const
areaMarksColor
=
{
data
:
'#65d0ea'
,
head
:
'#34718d'
,
default
:
'#ffffff'
,
attch
:
'#e6ccb2'
,
attch_title
:
'#e58e26'
,
attch_head
:
'#b08968'
,
filter
:
'#ff0000'
}
src/views/comment-excel/components/ExcelOperate/ExcelOperate.vue
View file @
ad21da0c
...
...
@@ -203,8 +203,6 @@ import { getRangetxt } from '@/utils/excel'
import
type
{
VxeTableInstance
}
from
'vxe-table'
import
EditArea
from
'../EditArea/EditArea.vue'
const
tableData
=
ref
([])
const
connectVisible
=
ref
(
false
)
const
xTableConnect
=
ref
<
VxeTableInstance
>
()
const
beConnectTable
=
ref
<
VxeTableInstance
>
()
...
...
@@ -701,7 +699,8 @@ const filterObjKeys = (data: any) => {
}
const
expandConfig
=
reactive
({
visibleMethod
({
row
})
{
if
(
row
.
expandData
!==
undefined
&&
typeof
row
.
expandData
===
'object'
)
{
console
.
log
(
'row'
,
row
)
if
(
typeof
row
.
expendData
===
'object'
)
{
return
true
}
return
false
...
...
src/views/comment-excel/components/SetArea/SetArea.vue
View file @
ad21da0c
...
...
@@ -87,8 +87,10 @@ const saveArea = async () => {
setDataAreaRef
.
value
.
resetFormState
()
setDataAreaTitleRef
.
value
.
resetExcelAreaTitleState
()
setAttchRef
.
value
.
resetFormState
()
emits
(
'success'
,
data
)
}
else
{
return
ElMessage
.
error
(
data
.
message
||
'保存失败!'
)
}
emits
(
'success'
,
data
)
}
</
script
>
<
style
lang=
"scss"
>
...
...
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