|
@@ -7,20 +7,21 @@ import (
|
|
)
|
|
)
|
|
|
|
|
|
type EtaTrial struct {
|
|
type EtaTrial struct {
|
|
- EtaTrialId int `orm:"column(eta_trial_id);pk" description:"eta试用客户id"`
|
|
|
|
- UserName string `description:"客户名称"`
|
|
|
|
- CompanyName string `description:"客户公司姓名"`
|
|
|
|
- Position string `description:"职位"`
|
|
|
|
- Password string `json:"-"`
|
|
|
|
- Account string `json:"-"`
|
|
|
|
- Mobile string `description:"手机号"`
|
|
|
|
- Enabled int `description:"1:有效,0:禁用"`
|
|
|
|
- ActiveTime int `description:"累计活跃时长"`
|
|
|
|
- LastLoginTime time.Time `description:"最后一次登陆时间"`
|
|
|
|
- SellerId int `description:"销售id"`
|
|
|
|
- Seller string `description:"销售员名称"`
|
|
|
|
- CreateTime time.Time
|
|
|
|
- ModifyTime time.Time
|
|
|
|
|
|
+ EtaTrialId int `orm:"column(eta_trial_id);pk" description:"eta试用客户id"`
|
|
|
|
+ UserName string `description:"客户名称"`
|
|
|
|
+ CompanyName string `description:"客户公司姓名"`
|
|
|
|
+ Position string `description:"职位"`
|
|
|
|
+ Password string `json:"-"`
|
|
|
|
+ Account string `json:"-"`
|
|
|
|
+ Mobile string `description:"手机号"`
|
|
|
|
+ Enabled int `description:"1:有效,0:禁用"`
|
|
|
|
+ ActiveTime int `description:"累计活跃时长"`
|
|
|
|
+ LastLoginTime time.Time `description:"最后一次登陆时间"`
|
|
|
|
+ SellerId int `description:"销售id"`
|
|
|
|
+ Seller string `description:"销售员名称"`
|
|
|
|
+ CreateTime time.Time
|
|
|
|
+ ModifyTime time.Time
|
|
|
|
+ LastLoginDuration int `description:"最后一次登录时长"`
|
|
}
|
|
}
|
|
|
|
|
|
// Update 更新用户基础信息
|
|
// Update 更新用户基础信息
|
|
@@ -56,25 +57,26 @@ func GetETATrialListCount(condition string, pars []interface{}) (count int, err
|
|
}
|
|
}
|
|
|
|
|
|
type ETATrialListRespItem struct {
|
|
type ETATrialListRespItem struct {
|
|
- EtaTrialId int `orm:"column(eta_trial_id);pk" description:"eta试用客户id"`
|
|
|
|
- UserName string `description:"客户名称"`
|
|
|
|
- CompanyName string `description:"客户公司姓名"`
|
|
|
|
- Position string `description:"职位"`
|
|
|
|
- Mobile string `description:"手机号"`
|
|
|
|
- ActiveTime string `description:"累计活跃时长"`
|
|
|
|
- LastLoginTime string `description:"最后一次登陆时间"`
|
|
|
|
- SellerId int `description:"销售id"`
|
|
|
|
- Seller string `description:"销售员名称"`
|
|
|
|
- InterestModule string `description:"感兴趣模块"`
|
|
|
|
- Expiration int `description:"账号到期时长"`
|
|
|
|
- Enabled int `description:"1:有效,0:禁用"`
|
|
|
|
- IndexNum int `description:"累计添加指标"`
|
|
|
|
- ChartNum int `description:"累计添加图表"`
|
|
|
|
- LoginNum int `description:"累计登录次数"`
|
|
|
|
- Password string
|
|
|
|
- Account string
|
|
|
|
- CreateTime string
|
|
|
|
- ModifyTime string
|
|
|
|
|
|
+ EtaTrialId int `orm:"column(eta_trial_id);pk" description:"eta试用客户id"`
|
|
|
|
+ UserName string `description:"客户名称"`
|
|
|
|
+ CompanyName string `description:"客户公司姓名"`
|
|
|
|
+ Position string `description:"职位"`
|
|
|
|
+ Mobile string `description:"手机号"`
|
|
|
|
+ ActiveTime string `description:"累计活跃时长"`
|
|
|
|
+ LastLoginTime string `description:"最后一次登陆时间"`
|
|
|
|
+ SellerId int `description:"销售id"`
|
|
|
|
+ Seller string `description:"销售员名称"`
|
|
|
|
+ InterestModule string `description:"感兴趣模块"`
|
|
|
|
+ Expiration int `description:"账号到期时长"`
|
|
|
|
+ Enabled int `description:"1:有效,0:禁用"`
|
|
|
|
+ IndexNum int `description:"累计添加指标"`
|
|
|
|
+ ChartNum int `description:"累计添加图表"`
|
|
|
|
+ LoginNum int `description:"累计登录次数"`
|
|
|
|
+ Password string
|
|
|
|
+ Account string
|
|
|
|
+ CreateTime string
|
|
|
|
+ ModifyTime string
|
|
|
|
+ LastLoginDuration string `description:"最后一次登录时长"`
|
|
}
|
|
}
|
|
|
|
|
|
type ETATrialListRespList struct {
|
|
type ETATrialListRespList struct {
|
|
@@ -102,7 +104,7 @@ func GetETATrialByMobile(mobile string) (item *EtaTrial, err error) {
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
|
|
-//新增客户
|
|
|
|
|
|
+// 新增客户
|
|
func AddETATrial(item *EtaTrial) (lastId int64, err error) {
|
|
func AddETATrial(item *EtaTrial) (lastId int64, err error) {
|
|
o := orm.NewOrm()
|
|
o := orm.NewOrm()
|
|
lastId, err = o.Insert(item)
|
|
lastId, err = o.Insert(item)
|
|
@@ -123,4 +125,4 @@ func UpdateETATrialEnable(mobile string) (err error) {
|
|
WHERE mobile=? `
|
|
WHERE mobile=? `
|
|
_, err = o.Raw(sql, mobile).Exec()
|
|
_, err = o.Raw(sql, mobile).Exec()
|
|
return
|
|
return
|
|
-}
|
|
|
|
|
|
+}
|