You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1124 lines
30 KiB
Go
1124 lines
30 KiB
Go
1 year ago
|
// Code generated by ent, DO NOT EDIT.
|
||
|
|
||
|
package ent
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdate) SetNotEmptyVersion(value int64) *DepartmentUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetVersion(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdateOne) SetNotEmptyVersion(value int64) *DepartmentUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetVersion(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdate) SetNotEmptyName(value string) *DepartmentUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdateOne) SetNotEmptyName(value string) *DepartmentUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdate) SetNotEmptyLeaderID(value int64) *DepartmentUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetLeaderID(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdateOne) SetNotEmptyLeaderID(value int64) *DepartmentUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetLeaderID(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdate) SetNotEmptyRemark(value string) *DepartmentUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetRemark(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdateOne) SetNotEmptyRemark(value string) *DepartmentUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetRemark(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdate) SetNotEmptyParentID(value int64) *DepartmentUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetParentID(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DepartmentUpdateOne) SetNotEmptyParentID(value int64) *DepartmentUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetParentID(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdate) SetNotEmptyVersion(value int64) *DictionaryUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetVersion(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdateOne) SetNotEmptyVersion(value int64) *DictionaryUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetVersion(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdate) SetNotEmptyTitle(value string) *DictionaryUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetTitle(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdateOne) SetNotEmptyTitle(value string) *DictionaryUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetTitle(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdate) SetNotEmptyName(value string) *DictionaryUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdateOne) SetNotEmptyName(value string) *DictionaryUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdate) SetNotEmptyDescription(value string) *DictionaryUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetDescription(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DictionaryUpdateOne) SetNotEmptyDescription(value string) *DictionaryUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetDescription(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptySort(value uint32) *DictionaryDetailUpdate {
|
||
|
if value != 0 {
|
||
|
return dd.SetSort(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptySort(value uint32) *DictionaryDetailUpdateOne {
|
||
|
if value != 0 {
|
||
|
return dd.SetSort(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptyVersion(value int64) *DictionaryDetailUpdate {
|
||
|
if value != 0 {
|
||
|
return dd.SetVersion(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptyVersion(value int64) *DictionaryDetailUpdateOne {
|
||
|
if value != 0 {
|
||
|
return dd.SetVersion(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptyTitle(value string) *DictionaryDetailUpdate {
|
||
|
if value != "" {
|
||
|
return dd.SetTitle(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptyTitle(value string) *DictionaryDetailUpdateOne {
|
||
|
if value != "" {
|
||
|
return dd.SetTitle(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptyKey(value string) *DictionaryDetailUpdate {
|
||
|
if value != "" {
|
||
|
return dd.SetKey(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptyKey(value string) *DictionaryDetailUpdateOne {
|
||
|
if value != "" {
|
||
|
return dd.SetKey(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptyValue(value string) *DictionaryDetailUpdate {
|
||
|
if value != "" {
|
||
|
return dd.SetValue(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptyValue(value string) *DictionaryDetailUpdateOne {
|
||
|
if value != "" {
|
||
|
return dd.SetValue(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdate) SetNotEmptyDictionaryID(value int64) *DictionaryDetailUpdate {
|
||
|
if value != 0 {
|
||
|
return dd.SetDictionaryID(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (dd *DictionaryDetailUpdateOne) SetNotEmptyDictionaryID(value int64) *DictionaryDetailUpdateOne {
|
||
|
if value != 0 {
|
||
|
return dd.SetDictionaryID(value)
|
||
|
}
|
||
|
return dd
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyName(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyName(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyShortName(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetShortName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyShortName(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetShortName(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyCode(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetCode(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyCode(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetCode(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyProvince(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetProvince(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyProvince(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetProvince(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyCity(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetCity(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyCity(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetCity(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyArea(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetArea(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyArea(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetArea(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyStreet(value string) *DistrictUpdate {
|
||
|
if value != "" {
|
||
|
return d.SetStreet(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyStreet(value string) *DistrictUpdateOne {
|
||
|
if value != "" {
|
||
|
return d.SetStreet(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyLevel(value uint32) *DistrictUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetLevel(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyLevel(value uint32) *DistrictUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetLevel(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyLatitude(value float64) *DistrictUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetLatitude(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyLatitude(value float64) *DistrictUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetLatitude(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdate) SetNotEmptyLongitude(value float64) *DistrictUpdate {
|
||
|
if value != 0 {
|
||
|
return d.SetLongitude(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (d *DistrictUpdateOne) SetNotEmptyLongitude(value float64) *DistrictUpdateOne {
|
||
|
if value != 0 {
|
||
|
return d.SetLongitude(value)
|
||
|
}
|
||
|
return d
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyVersion(value int64) *LoginRecordUpdate {
|
||
|
if value != 0 {
|
||
|
return lr.SetVersion(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyVersion(value int64) *LoginRecordUpdateOne {
|
||
|
if value != 0 {
|
||
|
return lr.SetVersion(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyUserID(value int64) *LoginRecordUpdate {
|
||
|
if value != 0 {
|
||
|
return lr.SetUserID(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyUserID(value int64) *LoginRecordUpdateOne {
|
||
|
if value != 0 {
|
||
|
return lr.SetUserID(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyLastLoginIpv4(value string) *LoginRecordUpdate {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginIpv4(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyLastLoginIpv4(value string) *LoginRecordUpdateOne {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginIpv4(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyLastLoginDevice(value string) *LoginRecordUpdate {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginDevice(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyLastLoginDevice(value string) *LoginRecordUpdateOne {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginDevice(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyLastLoginUA(value string) *LoginRecordUpdate {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginUA(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyLastLoginUA(value string) *LoginRecordUpdateOne {
|
||
|
if value != "" {
|
||
|
return lr.SetLastLoginUA(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdate) SetNotEmptyLoginCount(value uint64) *LoginRecordUpdate {
|
||
|
if value != 0 {
|
||
|
return lr.SetLoginCount(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (lr *LoginRecordUpdateOne) SetNotEmptyLoginCount(value uint64) *LoginRecordUpdateOne {
|
||
|
if value != 0 {
|
||
|
return lr.SetLoginCount(value)
|
||
|
}
|
||
|
return lr
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyName(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetName(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyName(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetName(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyClientID(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetClientID(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyClientID(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetClientID(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyClientSecret(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetClientSecret(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyClientSecret(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetClientSecret(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyRedirectURL(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetRedirectURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyRedirectURL(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetRedirectURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyScopes(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetScopes(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyScopes(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetScopes(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyAuthURL(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetAuthURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyAuthURL(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetAuthURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyTokenURL(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetTokenURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyTokenURL(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetTokenURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyInfoURL(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetInfoURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyInfoURL(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetInfoURL(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdate) SetNotEmptyDescription(value string) *OauthProviderUpdate {
|
||
|
if value != "" {
|
||
|
return op.SetDescription(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (op *OauthProviderUpdateOne) SetNotEmptyDescription(value string) *OauthProviderUpdateOne {
|
||
|
if value != "" {
|
||
|
return op.SetDescription(value)
|
||
|
}
|
||
|
return op
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdate) SetNotEmptyVersion(value int64) *RoleUpdate {
|
||
|
if value != 0 {
|
||
|
return r.SetVersion(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdateOne) SetNotEmptyVersion(value int64) *RoleUpdateOne {
|
||
|
if value != 0 {
|
||
|
return r.SetVersion(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdate) SetNotEmptyCode(value string) *RoleUpdate {
|
||
|
if value != "" {
|
||
|
return r.SetCode(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdateOne) SetNotEmptyCode(value string) *RoleUpdateOne {
|
||
|
if value != "" {
|
||
|
return r.SetCode(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdate) SetNotEmptyName(value string) *RoleUpdate {
|
||
|
if value != "" {
|
||
|
return r.SetName(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdateOne) SetNotEmptyName(value string) *RoleUpdateOne {
|
||
|
if value != "" {
|
||
|
return r.SetName(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdate) SetNotEmptyDescription(value string) *RoleUpdate {
|
||
|
if value != "" {
|
||
|
return r.SetDescription(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (r *RoleUpdateOne) SetNotEmptyDescription(value string) *RoleUpdateOne {
|
||
|
if value != "" {
|
||
|
return r.SetDescription(value)
|
||
|
}
|
||
|
return r
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptyVersion(value int64) *TokenUpdate {
|
||
|
if value != 0 {
|
||
|
return t.SetVersion(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptyVersion(value int64) *TokenUpdateOne {
|
||
|
if value != 0 {
|
||
|
return t.SetVersion(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptyUserID(value int64) *TokenUpdate {
|
||
|
if value != 0 {
|
||
|
return t.SetUserID(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptyUserID(value int64) *TokenUpdateOne {
|
||
|
if value != 0 {
|
||
|
return t.SetUserID(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptyTokenType(value string) *TokenUpdate {
|
||
|
if value != "" {
|
||
|
return t.SetTokenType(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptyTokenType(value string) *TokenUpdateOne {
|
||
|
if value != "" {
|
||
|
return t.SetTokenType(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptyAccessToken(value string) *TokenUpdate {
|
||
|
if value != "" {
|
||
|
return t.SetAccessToken(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptyAccessToken(value string) *TokenUpdateOne {
|
||
|
if value != "" {
|
||
|
return t.SetAccessToken(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptyRefreshToken(value string) *TokenUpdate {
|
||
|
if value != "" {
|
||
|
return t.SetRefreshToken(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptyRefreshToken(value string) *TokenUpdateOne {
|
||
|
if value != "" {
|
||
|
return t.SetRefreshToken(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdate) SetNotEmptySource(value string) *TokenUpdate {
|
||
|
if value != "" {
|
||
|
return t.SetSource(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (t *TokenUpdateOne) SetNotEmptySource(value string) *TokenUpdateOne {
|
||
|
if value != "" {
|
||
|
return t.SetSource(value)
|
||
|
}
|
||
|
return t
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyVersion(value int64) *UserUpdate {
|
||
|
if value != 0 {
|
||
|
return u.SetVersion(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyVersion(value int64) *UserUpdateOne {
|
||
|
if value != 0 {
|
||
|
return u.SetVersion(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyUsername(value string) *UserUpdate {
|
||
|
if value != "" {
|
||
|
return u.SetUsername(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyUsername(value string) *UserUpdateOne {
|
||
|
if value != "" {
|
||
|
return u.SetUsername(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyPhoneNumber(value string) *UserUpdate {
|
||
|
if value != "" {
|
||
|
return u.SetPhoneNumber(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyPhoneNumber(value string) *UserUpdateOne {
|
||
|
if value != "" {
|
||
|
return u.SetPhoneNumber(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyEmail(value string) *UserUpdate {
|
||
|
if value != "" {
|
||
|
return u.SetEmail(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyEmail(value string) *UserUpdateOne {
|
||
|
if value != "" {
|
||
|
return u.SetEmail(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyPassword(value string) *UserUpdate {
|
||
|
if value != "" {
|
||
|
return u.SetPassword(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyPassword(value string) *UserUpdateOne {
|
||
|
if value != "" {
|
||
|
return u.SetPassword(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdate) SetNotEmptyNickname(value string) *UserUpdate {
|
||
|
if value != "" {
|
||
|
return u.SetNickname(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (u *UserUpdateOne) SetNotEmptyNickname(value string) *UserUpdateOne {
|
||
|
if value != "" {
|
||
|
return u.SetNickname(value)
|
||
|
}
|
||
|
return u
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdate) SetNotEmptyVersion(value int64) *UserMetaUpdate {
|
||
|
if value != 0 {
|
||
|
return um.SetVersion(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdateOne) SetNotEmptyVersion(value int64) *UserMetaUpdateOne {
|
||
|
if value != 0 {
|
||
|
return um.SetVersion(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdate) SetNotEmptyUserID(value int64) *UserMetaUpdate {
|
||
|
if value != 0 {
|
||
|
return um.SetUserID(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdateOne) SetNotEmptyUserID(value int64) *UserMetaUpdateOne {
|
||
|
if value != 0 {
|
||
|
return um.SetUserID(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdate) SetNotEmptyKey(value string) *UserMetaUpdate {
|
||
|
if value != "" {
|
||
|
return um.SetKey(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdateOne) SetNotEmptyKey(value string) *UserMetaUpdateOne {
|
||
|
if value != "" {
|
||
|
return um.SetKey(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdate) SetNotEmptyValue(value string) *UserMetaUpdate {
|
||
|
if value != "" {
|
||
|
return um.SetValue(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (um *UserMetaUpdateOne) SetNotEmptyValue(value string) *UserMetaUpdateOne {
|
||
|
if value != "" {
|
||
|
return um.SetValue(value)
|
||
|
}
|
||
|
return um
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyUserID(value int64) *UserSocialUpdate {
|
||
|
if value != 0 {
|
||
|
return us.SetUserID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyUserID(value int64) *UserSocialUpdateOne {
|
||
|
if value != 0 {
|
||
|
return us.SetUserID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyProvider(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetProvider(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyProvider(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetProvider(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyAccessToken(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetAccessToken(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyAccessToken(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetAccessToken(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyRefreshToken(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetRefreshToken(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyRefreshToken(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetRefreshToken(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyUID(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetUID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyUID(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetUID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyOpenID(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetOpenID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyOpenID(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetOpenID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyUnionID(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetUnionID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyUnionID(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetUnionID(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyKey(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetKey(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyKey(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetKey(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyExpiresIn(value uint64) *UserSocialUpdate {
|
||
|
if value != 0 {
|
||
|
return us.SetExpiresIn(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyExpiresIn(value uint64) *UserSocialUpdateOne {
|
||
|
if value != 0 {
|
||
|
return us.SetExpiresIn(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdate) SetNotEmptyUserProfile(value string) *UserSocialUpdate {
|
||
|
if value != "" {
|
||
|
return us.SetUserProfile(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|
||
|
|
||
|
// set field if value is not empty. e.g. string does not equal to ""
|
||
|
func (us *UserSocialUpdateOne) SetNotEmptyUserProfile(value string) *UserSocialUpdateOne {
|
||
|
if value != "" {
|
||
|
return us.SetUserProfile(value)
|
||
|
}
|
||
|
return us
|
||
|
}
|