crm_config.go 423 B

12345678910111213141516
  1. package models
  2. import "github.com/beego/beego/v2/client/orm"
  3. const ConfAreaCodeListKey = "area_code_list" // 手机号区号列表
  4. type CrmConfig struct {
  5. ConfigValue string `description:"详情"`
  6. }
  7. func GetConfigDetailByCode(configCode string) (item CrmConfig, err error) {
  8. o := orm.NewOrm()
  9. sql := ` SELECT config_value FROM crm_config WHERE config_code=? `
  10. err = o.Raw(sql, configCode).QueryRow(&item)
  11. return
  12. }