Skip to content

Commit 7c21256

Browse files
committed
fix: 1050996
--bug=1050996 --user=王孝刚 【函数库】-编辑函数后,函数的创建者显示为空,刷新后恢复 https://www.tapd.cn/57709429/s/1651111
1 parent 5453aa7 commit 7c21256

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

ui/src/views/function-lib/index.vue

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,11 @@ function getList() {
264264
function refresh(data: any) {
265265
if (data) {
266266
const index = functionLibList.value.findIndex((v) => v.id === data.id)
267+
if (user.userInfo && data.user_id === user.userInfo.id) {
268+
data.username = user.userInfo.username
269+
} else {
270+
data.username = userOptions.value.find((v) => v.value === data.user_id)?.label
271+
}
267272
functionLibList.value.splice(index, 1, data)
268273
} else {
269274
paginationConfig.total = 0

0 commit comments

Comments
 (0)