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
d8665a27
Commit
d8665a27
authored
Dec 21, 2023
by
何远江
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改数据区,解析完成之后表格样式修改
parent
a462c48f
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
8 deletions
+18
-8
ExcelOperate.vue
...ws/comment-excel/components/ExcelOperate/ExcelOperate.vue
+18
-8
No files found.
src/views/comment-excel/components/ExcelOperate/ExcelOperate.vue
View file @
d8665a27
...
@@ -145,7 +145,7 @@
...
@@ -145,7 +145,7 @@
>
>
<vxe-column
title=
"title"
field=
"title"
:edit-render=
"{}"
>
<vxe-column
title=
"title"
field=
"title"
:edit-render=
"{}"
>
<
template
#
edit=
"{ row }"
>
<
template
#
edit=
"{ row }"
>
<el-input
v-model=
"row.title"
size=
"small"
></el-input>
<el-input
:disabled=
"isEditCurrentArea"
v-model=
"row.title"
size=
"small"
></el-input>
</
template
>
</
template
>
</vxe-column>
</vxe-column>
<vxe-column
title=
"单元格"
field=
"cell"
width=
"90"
>
<vxe-column
title=
"单元格"
field=
"cell"
width=
"90"
>
...
@@ -162,10 +162,10 @@
...
@@ -162,10 +162,10 @@
@
click=
"resetCurrentAreaState(true)"
@
click=
"resetCurrentAreaState(true)"
>
取消修改
</el-button
>
取消修改
</el-button
>
>
<el-button
type=
"default"
size=
"small"
@
click=
"resetCurrentArea()"
>
重置选区
</el-button>
<
!-- <
el-button type="default" size="small" @click="resetCurrentArea()">重置选区</el-button>
<el-button type="default" size="small" @click="resetCurrentHeadArea"
<el-button type="default" size="small" @click="resetCurrentHeadArea"
>重置标题区</el-button
>重置标题区</el-button
>
>
-->
</div>
</div>
<div
class=
"mt-6 pl-2 pr-2 pb-2 text-sm border-b-2"
>
<div
class=
"mt-6 pl-2 pr-2 pb-2 text-sm border-b-2"
>
...
@@ -283,10 +283,18 @@
...
@@ -283,10 +283,18 @@
<vxe-modal
width=
"80%"
title=
"解析结果"
v-model=
"runResultVisible"
>
<vxe-modal
width=
"80%"
title=
"解析结果"
v-model=
"runResultVisible"
>
<el-button
@
click=
"exportRunData"
>
导出数据
</el-button>
<el-button
@
click=
"exportRunData"
>
导出数据
</el-button>
<vxe-table
ref=
"runDataTable"
size=
"mini"
:data=
"runResultData"
border
height=
"500"
>
<vxe-table
ref=
"runDataTable"
size=
"mini"
show-overflow=
"tooltip"
:data=
"runResultData"
border
height=
"500"
>
<vxe-column
title=
"行号"
field=
"sortNum"
width=
"120"
></vxe-column>
<vxe-column
title=
"行号"
field=
"sortNum"
width=
"120"
></vxe-column>
<vxe-column
title=
"数据区"
field=
"数据区"
width=
"120"
></vxe-column>
<
template
v-for=
"item in runResultTitle"
:key=
"item"
>
<
template
v-for=
"item in runResultTitle"
:key=
"item"
>
<vxe-column
:title=
"item"
:field=
"item"
width=
"12
0"
></vxe-column>
<vxe-column
:title=
"item"
:field=
"item"
max-width=
"20
0"
></vxe-column>
</
template
>
</
template
>
</vxe-table>
</vxe-table>
</vxe-modal>
</vxe-modal>
...
@@ -1097,9 +1105,11 @@ const toRun = async () => {
...
@@ -1097,9 +1105,11 @@ const toRun = async () => {
if
(
!
data
.
result
.
length
)
return
if
(
!
data
.
result
.
length
)
return
runResultData
.
value
=
data
.
result
runResultData
.
value
=
data
.
result
runResultTitle
.
value
=
Object
.
keys
(
data
.
result
[
0
])
runResultTitle
.
value
=
Object
.
keys
(
data
.
result
[
0
]).
filter
((
field
)
=>
{
const
idx
=
runResultTitle
.
value
.
findIndex
((
v
)
=>
v
==
'sortNum'
)
return
field
!=
'sortNum'
&&
field
!=
'数据区'
runResultTitle
.
value
.
splice
(
idx
,
1
)
})
// const idx = runResultTitle.value.findIndex((v) => v == 'sortNum')
// runResultTitle.value.splice(idx, 1)
runResultVisible
.
value
=
true
runResultVisible
.
value
=
true
}
catch
{
}
catch
{
nextTick
(()
=>
{
nextTick
(()
=>
{
...
...
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