Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
B
basic-vue-admin
概览
概览
详情
活动
周期分析
版本库
存储库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Basic
basic-vue-admin
Commits
33a335a3
提交
33a335a3
authored
8月 09, 2021
作者:
无木
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix(table): `0` is not shown in editable cell
修复可编辑单元格中未能正确显示零值的问题 fixed: #1039
上级
9d2231b1
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
10 行增加
和
10 行删除
+10
-10
CHANGELOG.zh_CN.md
CHANGELOG.zh_CN.md
+3
-1
EditableCell.vue
...components/Table/src/components/editable/EditableCell.vue
+7
-9
没有找到文件。
CHANGELOG.zh_CN.md
浏览文件 @
33a335a3
### 🐛 Bug Fixes
### 🐛 Bug Fixes
-
**Cropper**
修复未能及时销毁的问题
-
**Cropper**
修复未能及时销毁的问题
-
**BasicTable**
修复
`CellFormat`
无法使用
`Map`
类型数据的问题
-
**BasicTable**
-
修复
`CellFormat`
无法使用
`Map`
类型数据的问题
-
修复可编辑单元格未能正确显示
`0`
值的问题
-
**Qrcode**
修复二维码组件在创建时未能及时绘制的问题
-
**Qrcode**
修复二维码组件在创建时未能及时绘制的问题
## 2.7.0(2021-08-03)
## 2.7.0(2021-08-03)
...
...
src/components/Table/src/components/editable/EditableCell.vue
浏览文件 @
33a335a3
...
@@ -5,8 +5,8 @@
...
@@ -5,8 +5,8 @@
:class=
"
{ [`${prefixCls}__normal`]: true, 'ellipsis-cell': column.ellipsis }"
:class=
"
{ [`${prefixCls}__normal`]: true, 'ellipsis-cell': column.ellipsis }"
@click="handleEdit"
@click="handleEdit"
>
>
<div
class=
"cell-content"
:title=
"column.ellipsis ? getValues
||
'' : ''"
>
{{
<div
class=
"cell-content"
:title=
"column.ellipsis ? getValues
??
'' : ''"
>
{{
getValues
||
' '
getValues
??
' '
}}
</div>
}}
</div>
<FormOutlined
:class=
"`$
{prefixCls}__normal-icon`" v-if="!column.editRow" />
<FormOutlined
:class=
"`$
{prefixCls}__normal-icon`" v-if="!column.editRow" />
</div>
</div>
...
@@ -35,11 +35,10 @@
...
@@ -35,11 +35,10 @@
</
template
>
</
template
>
<
script
lang=
"ts"
>
<
script
lang=
"ts"
>
import
type
{
CSSProperties
,
PropType
}
from
'vue'
;
import
type
{
CSSProperties
,
PropType
}
from
'vue'
;
import
{
computed
,
defineComponent
,
nextTick
,
ref
,
toRaw
,
unref
,
watchEffect
}
from
'vue'
;
import
type
{
BasicColumn
}
from
'../../types/table'
;
import
type
{
BasicColumn
}
from
'../../types/table'
;
import
type
{
EditRecordRow
}
from
'./index'
;
import
type
{
EditRecordRow
}
from
'./index'
;
import
{
CheckOutlined
,
CloseOutlined
,
FormOutlined
}
from
'@ant-design/icons-vue'
;
import
{
defineComponent
,
ref
,
unref
,
nextTick
,
computed
,
watchEffect
,
toRaw
}
from
'vue'
;
import
{
FormOutlined
,
CloseOutlined
,
CheckOutlined
}
from
'@ant-design/icons-vue'
;
import
{
CellComponent
}
from
'./CellComponent'
;
import
{
CellComponent
}
from
'./CellComponent'
;
import
{
useDesign
}
from
'/@/hooks/web/useDesign'
;
import
{
useDesign
}
from
'/@/hooks/web/useDesign'
;
...
@@ -48,9 +47,9 @@
...
@@ -48,9 +47,9 @@
import
clickOutside
from
'/@/directives/clickOutside'
;
import
clickOutside
from
'/@/directives/clickOutside'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
is
String
,
isBoolean
,
isFunction
,
isNumber
,
isArray
}
from
'/@/utils/is'
;
import
{
is
Array
,
isBoolean
,
isFunction
,
isNumber
,
isString
}
from
'/@/utils/is'
;
import
{
createPlaceholderMessage
}
from
'./helper'
;
import
{
createPlaceholderMessage
}
from
'./helper'
;
import
{
set
,
omi
t
}
from
'lodash-es'
;
import
{
omit
,
se
t
}
from
'lodash-es'
;
import
{
treeToList
}
from
'/@/utils/helper/treeHelper'
;
import
{
treeToList
}
from
'/@/utils/helper/treeHelper'
;
export
default
defineComponent
({
export
default
defineComponent
({
...
@@ -214,8 +213,7 @@
...
@@ -214,8 +213,7 @@
if
(
isBoolean
(
editRule
)
&&
!
currentValue
&&
!
isNumber
(
currentValue
))
{
if
(
isBoolean
(
editRule
)
&&
!
currentValue
&&
!
isNumber
(
currentValue
))
{
ruleVisible
.
value
=
true
;
ruleVisible
.
value
=
true
;
const
component
=
unref
(
getComponent
);
const
component
=
unref
(
getComponent
);
const
message
=
createPlaceholderMessage
(
component
);
ruleMessage
.
value
=
createPlaceholderMessage
(
component
);
ruleMessage
.
value
=
message
;
return
false
;
return
false
;
}
}
if
(
isFunction
(
editRule
))
{
if
(
isFunction
(
editRule
))
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论