From d6e940803d852d31a222a00ef68e5b070b72008b Mon Sep 17 00:00:00 2001 From: hoteas Date: Fri, 4 Nov 2022 02:25:33 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=80=A7=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- code.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/code.go b/code.go index 8b677e1..8d4fd81 100644 --- a/code.go +++ b/code.go @@ -546,11 +546,11 @@ var TptProject = Proj{ column := that.MakeCodeRouter[hotimeName].TableColumns[tableName][k] - if column == nil { + if column == nil || column["link"] == nil && !(column["list"] == nil || column["list"] == true) { continue } - if (column["list"] == nil || column["list"] == true) && column["name"] == "parent_id" && column.GetString("link") != "" { + if column["name"] == "parent_id" { parentC := that.Db.Get(column.GetString("link"), column.GetString("value"), Map{"id": v.GetCeilInt(k)}) v[column.GetString("link")+"_"+column.GetString("name")+"_"+column.GetString("value")] = "" @@ -559,8 +559,7 @@ var TptProject = Proj{ } } - if column.GetString("link") != "" && - column.GetString("name") != "parent_id" { + if column.GetString("name") != "parent_id" { reStr := "" if column.GetString("value") == "name" && that.MakeCodeRouter[hotimeName].TableColumns[column.GetString("link")]["nickname"] != nil {