mirror of
https://github.com/mindoc-org/mindoc.git
synced 2025-10-20 19:07:25 +08:00
增加备案信息选项
This commit is contained in:
@@ -154,6 +154,15 @@ func (m *Option) Init() error {
|
||||
}
|
||||
}
|
||||
|
||||
if !o.QueryTable(m.TableNameWithPrefix()).Filter("option_name", "site_beian").Exist() {
|
||||
option := NewOption()
|
||||
option.OptionValue = ""
|
||||
option.OptionName = "site_beian"
|
||||
option.OptionTitle = "域名备案"
|
||||
if _, err := o.Insert(option); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user