Merge pull request #153 from CircleMonogatari/master

中文全角空格问题!
This commit is contained in:
xxj
2021-07-20 17:50:55 +08:00
committed by GitHub

View File

@@ -113,43 +113,44 @@ func getUninStr(left, middle, right string) string {
return re return re
} }
func getGormModelElement() []EmInfo { func getGormModelElement() []EmInfo {
    var result []EmInfo var result []EmInfo
    result = append(result, EmInfo{ result = append(result, EmInfo{
        IsMulti:       false, IsMulti: false,
        Notes:         "Primary key", Notes: "Primary key",
        Type:          "int64", // Type.类型标记 Type: "int64", // Type.类型标记
        ColName:       "id", ColName: "id",
        ColNameEx:     "id", ColNameEx: "id",
        ColStructName: "ID", ColStructName: "ID",
    }) })
    result = append(result, EmInfo{
        IsMulti:       false,
        Notes:         "created time",
        Type:          "time.Time", // Type.类型标记
        ColName:       "created_at",
        ColNameEx:     "created_at",
        ColStructName: "CreatedAt",
    })
    result = append(result, EmInfo{ result = append(result, EmInfo{
        IsMulti:       false, IsMulti: false,
        Notes:         "updated at", Notes: "created time",
        Type:          "time.Time", // Type.类型标记 Type: "time.Time", // Type.类型标记
        ColName:       "updated_at", ColName: "created_at",
        ColNameEx:     "updated_at", ColNameEx: "created_at",
        ColStructName: "UpdatedAt", ColStructName: "CreatedAt",
    }) })
    result = append(result, EmInfo{ result = append(result, EmInfo{
        IsMulti:       false, IsMulti: false,
        Notes:         "deleted time", Notes: "updated at",
        Type:          "time.Time", // Type.类型标记 Type: "time.Time", // Type.类型标记
        ColName:       "deleted_at", ColName: "updated_at",
        ColNameEx:     "deleted_at", ColNameEx: "updated_at",
        ColStructName: "DeletedAt", ColStructName: "UpdatedAt",
    }) })
    return result
result = append(result, EmInfo{
IsMulti: false,
Notes: "deleted time",
Type: "time.Time", // Type.类型标记
ColName: "deleted_at",
ColNameEx: "deleted_at",
ColStructName: "DeletedAt",
})
return result
} }
func buildFList(list *[]FList, key ColumnsKey, keyName, tp, colName string) { func buildFList(list *[]FList, key ColumnsKey, keyName, tp, colName string) {