dao

package
v0.0.0-...-83adff0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicResp

type BasicResp struct {
	Code    int          `json:"code"`
	Message string       `json:"messge"`
	Data    *interface{} `json:"data"`
}

BasicResp pay response.

type Dao

type Dao struct {
	// contains filtered or unexported fields
}

Dao struct info of Dao.

func New

func New(c *conf.Config) (d *Dao)

New new a Dao and return.

func (*Dao) ActivityOrder

func (d *Dao) ActivityOrder(c context.Context, orderNO string) (res *model.VipOrderActivityRecord, err error)

ActivityOrder get activity order by order_no.

func (*Dao) AddAssociateGrantCount

func (d *Dao) AddAssociateGrantCount(c context.Context, arg *model.VipAssociateGrantCount) (err error)

AddAssociateGrantCount add associate grant count.

func (*Dao) AddCacheBindInfoByMid

func (d *Dao) AddCacheBindInfoByMid(c context.Context, mid int64, v *model.OpenBindInfo, appID int64) (err error)

AddCacheBindInfoByMid add bind info cache.

func (*Dao) AddCacheOpenInfoByOpenID

func (d *Dao) AddCacheOpenInfoByOpenID(c context.Context, openID string, v *model.OpenInfo, appID int64) (err error)

AddCacheOpenInfoByOpenID add open info cache.

func (*Dao) AddOldPayOrder

func (d *Dao) AddOldPayOrder(c context.Context, r *model.VipOldPayOrder) (err error)

AddOldPayOrder add old payorder.

func (*Dao) AddOldRechargeOrder

func (d *Dao) AddOldRechargeOrder(c context.Context, r *model.VipOldRechargeOrder) (err error)

AddOldRechargeOrder add recharge order.

func (*Dao) AddOpenInfo

func (d *Dao) AddOpenInfo(c context.Context, a *model.OpenInfo) (err error)

AddOpenInfo add open info.

func (*Dao) AddPayOrder

func (d *Dao) AddPayOrder(c context.Context, ip string, o *model.PayOrder, data *model.AddPayOrderResp) (err error)

AddPayOrder add pay order.

func (*Dao) AddReceiveRedirectWelfare

func (d *Dao) AddReceiveRedirectWelfare(c context.Context, wid, mid int64) (err error)

AddReceiveRedirectWelfare add redirect url

func (*Dao) AddTransferLock

func (d *Dao) AddTransferLock(c context.Context, key string) (succeed bool)

AddTransferLock add lock.

func (*Dao) AllMonthByOrder

func (d *Dao) AllMonthByOrder(c context.Context, orderStr string) (res []*model.Month, err error)

AllMonthByOrder order by month.

func (*Dao) AllPointExchangePrice

func (d *Dao) AllPointExchangePrice(c context.Context) (pe []*model.PointExchangePrice, err error)

AllPointExchangePrice .

func (*Dao) AllTips

func (d *Dao) AllTips(c context.Context, now int64) (rs []*model.Tips, err error)

AllTips all tips.

func (*Dao) AssociateGrantCountInfo

func (d *Dao) AssociateGrantCountInfo(c context.Context, mid int64, appID int64, months int32) (res *model.VipAssociateGrantCount, err error)

AssociateGrantCountInfo associate grant count info.

func (*Dao) BcoinSalaryList

func (d *Dao) BcoinSalaryList(c context.Context, mid int64, start, end time.Time) (res []*model.VipBcoinSalary, err error)

BcoinSalaryList vip user bcoin salary list.

func (*Dao) BeginTran

func (d *Dao) BeginTran(c context.Context) (tx *sql.Tx, err error)

BeginTran begin tran.

func (*Dao) BindInfoByMid

func (d *Dao) BindInfoByMid(c context.Context, id int64, appID int64) (res *model.OpenBindInfo, err error)

BindInfoByMid get data from cache if miss will call source method, then add to cache.

func (*Dao) BindInfoByOutOpenIDAndMid

func (d *Dao) BindInfoByOutOpenIDAndMid(c context.Context, mid int64, outOpenID string, appID int64) (res *model.OpenBindInfo, err error)

BindInfoByOutOpenIDAndMid get bind info by out_open_id AND mid.

func (*Dao) ByOutOpenID

func (d *Dao) ByOutOpenID(c context.Context, outOpenID string, appID int64) (res *model.OpenBindInfo, err error)

ByOutOpenID get open bind info by out_open_id.

func (*Dao) CacheBindInfoByMid

func (d *Dao) CacheBindInfoByMid(c context.Context, mid int64, appID int64) (v *model.OpenBindInfo, err error)

CacheBindInfoByMid get vip bind by mid cache.

func (*Dao) CacheOpenInfoByOpenID

func (d *Dao) CacheOpenInfoByOpenID(c context.Context, openID string, appID int64) (v *model.OpenInfo, err error)

CacheOpenInfoByOpenID get vip open info by open id cache.

func (*Dao) CleanCache

func (d *Dao) CleanCache(c context.Context, mid int64) (err error)

CleanCache clean job cache.

func (*Dao) Close

func (d *Dao) Close()

Close close connections of mc, redis, db.

func (*Dao) CountAssociateByMidAndMonths

func (d *Dao) CountAssociateByMidAndMonths(c context.Context, mid int64, appID int64, months int32) (count int64, err error)

CountAssociateByMidAndMonths count grant order by mid and months .

func (*Dao) CountAssociateGrants

func (d *Dao) CountAssociateGrants(c context.Context, mid int64, appID int64) (count int64, err error)

CountAssociateGrants associate grant count.

func (*Dao) CountAssociateOrder

func (d *Dao) CountAssociateOrder(c context.Context, mid int64, appID int64) (count int64, err error)

CountAssociateOrder associate order count.

func (*Dao) CountGrantOrderByOutTradeNo

func (d *Dao) CountGrantOrderByOutTradeNo(c context.Context, outTradeNo string, appID int64) (count int64, err error)

CountGrantOrderByOutTradeNo grant order by out_trade_no count.

func (*Dao) CountProductBuy

func (d *Dao) CountProductBuy(c context.Context, mid int64, months int32, panelType string) (count int64, err error)

CountProductBuy get user by product count.

func (*Dao) CountReceiveRedirectWelfare

func (d *Dao) CountReceiveRedirectWelfare(c context.Context, wid, mid int64) (count int64, err error)

CountReceiveRedirectWelfare count it

func (*Dao) CountRecommendWelfare

func (d *Dao) CountRecommendWelfare(c context.Context, req *model.ArgWelfareList) (count int64, err error)

CountRecommendWelfare count recommend welfare

func (*Dao) CountWelfare

func (d *Dao) CountWelfare(c context.Context, req *model.ArgWelfareList) (count int64, err error)

CountWelfare count welfare list

func (*Dao) DelBindInfoCache

func (d *Dao) DelBindInfoCache(c context.Context, mid int64, appID int64) (err error)

DelBindInfoCache del bind info cache.

func (*Dao) DelCache

func (d *Dao) DelCache(c context.Context, key string) (err error)

DelCache del cache.

func (*Dao) DelOpenInfoCache

func (d *Dao) DelOpenInfoCache(c context.Context, openID string, appID int64) (err error)

DelOpenInfoCache del open info cache.

func (*Dao) DelRedisCache

func (d *Dao) DelRedisCache(c context.Context, mid int64) (err error)

DelRedisCache del redis cache.

func (*Dao) DelVipFrozen

func (d *Dao) DelVipFrozen(c context.Context, mid int64) (err error)

DelVipFrozen del vip frozen.

func (*Dao) DelVipInfoCache

func (d *Dao) DelVipInfoCache(c context.Context, mid int64) (err error)

DelVipInfoCache delete vipinfo cache.

func (*Dao) DialogAll

func (d *Dao) DialogAll(c context.Context) (res []*model.ConfDialog, err error)

DialogAll .

func (*Dao) DiscountSQL

func (d *Dao) DiscountSQL(c context.Context, mid int64, discountID int64) (dh *model.VipUserDiscountHistory, err error)

DiscountSQL discount sql.

func (*Dao) DoQuickPay

func (d *Dao) DoQuickPay(c context.Context, ip string, token string, thirdTradeNo string, data *model.PayRetResp) (err error)

DoQuickPay do quick pay.

func (*Dao) EffectiveAssociateVips

func (d *Dao) EffectiveAssociateVips(c context.Context) (res []*model.AssociateVipResp, err error)

EffectiveAssociateVips effective associate vips.

func (*Dao) EleBindUnion

func (d *Dao) EleBindUnion(c context.Context, a *model.ArgEleBindUnion) (data *model.EleBindUnionResp, err error)

EleBindUnion ele bind union salary vip.

func (*Dao) EleCanPurchase

func (d *Dao) EleCanPurchase(c context.Context, a *model.ArgEleCanPurchase) (data *model.EleCanPurchaseResp, err error)

EleCanPurchase ele can purchase.

func (*Dao) EleOauthGenerateAccessToken

func (d *Dao) EleOauthGenerateAccessToken(c context.Context, a *model.ArgEleAccessToken) (data *model.EleAccessTokenResp, err error)

EleOauthGenerateAccessToken get access_token by auth_code.

func (*Dao) EleRedPackages

func (d *Dao) EleRedPackages(c context.Context) (data []*model.EleRedPackagesResp, err error)

EleRedPackages get ele red packages.

func (*Dao) EleSpecailFoods

func (d *Dao) EleSpecailFoods(c context.Context) (data []*model.EleSpecailFoodsResp, err error)

EleSpecailFoods get ele specail foods.

func (*Dao) EleUnionMobile

func (d *Dao) EleUnionMobile(c context.Context, a *model.ArgEleUnionMobile) (data *model.EleUnionMobileResp, err error)

EleUnionMobile get ele union mobile.

func (*Dao) EleUnionReceivePrizes

func (d *Dao) EleUnionReceivePrizes(c context.Context, a *model.ArgEleReceivePrizes) (data []*model.EleReceivePrizesResp, err error)

EleUnionReceivePrizes union receive prizes.

func (*Dao) EleUnionUpdateOpenID

func (d *Dao) EleUnionUpdateOpenID(c context.Context, a *model.ArgEleUnionUpdateOpenID) (data *model.EleUnionUpdateOpenIDResp, err error)

EleUnionUpdateOpenID update_open_id req.

func (*Dao) FrozenTime

func (d *Dao) FrozenTime(c context.Context, mid int64) (frozenTime int64, err error)

FrozenTime get user frozen time

func (*Dao) GetMyWelfare

func (d *Dao) GetMyWelfare(c context.Context, mid int64) (res []*model.MyWelfareResp, err error)

GetMyWelfare get my welfare infos

func (*Dao) GetOpenCodeCount

func (d *Dao) GetOpenCodeCount(c context.Context, mid int64) (val int, err error)

GetOpenCodeCount get open code count.

func (*Dao) GetOpenInfo

func (d *Dao) GetOpenInfo(c context.Context, code string) (data *model.OpenCodeResp, err error)

GetOpenInfo get open info.

func (*Dao) GetPassportDetail

func (d *Dao) GetPassportDetail(c context.Context, mid int64) (res *model.PassportDetail, err error)

GetPassportDetail get passport detail

func (*Dao) GetPointTip

func (d *Dao) GetPointTip(c context.Context, mid, id int64) (val int, err error)

GetPointTip get pointTip.

func (*Dao) GetReceivedCode

func (d *Dao) GetReceivedCode(c context.Context, wid, mid int64) (res []*model.ReceivedCodeResp, err error)

GetReceivedCode get received code

func (*Dao) GetRecommendWelfare

func (d *Dao) GetRecommendWelfare(c context.Context, req *model.ArgWelfareList) (res []*model.WelfareListResp, err error)

GetRecommendWelfare get recommend welfare

func (*Dao) GetSignVip

func (d *Dao) GetSignVip(c context.Context, mid int64) (val int, err error)

GetSignVip .

func (*Dao) GetToken

func (d *Dao) GetToken(c context.Context, bid string, ip string) (data *model.TokenResq, err error)

GetToken get open token.

func (*Dao) GetVipFrozen

func (d *Dao) GetVipFrozen(c context.Context, mid int64) (val int, err error)

GetVipFrozen set vip frozen.

func (*Dao) GetWelfareBatch

func (d *Dao) GetWelfareBatch(c context.Context, wid int64) (res []*model.WelfareBatchResp, err error)

GetWelfareBatch get welfare batch infos

func (*Dao) GetWelfareCodeUnReceived

func (d *Dao) GetWelfareCodeUnReceived(c context.Context, wid int64, bids []string) (res []*model.UnReceivedCodeResp, err error)

GetWelfareCodeUnReceived get unReceived welfare code

func (*Dao) GetWelfareInfo

func (d *Dao) GetWelfareInfo(c context.Context, id int64) (res *model.WelfareInfoResp, err error)

GetWelfareInfo get welfare info

func (*Dao) GetWelfareList

func (d *Dao) GetWelfareList(c context.Context, req *model.ArgWelfareList) (res []*model.WelfareListResp, err error)

GetWelfareList get welfare list

func (*Dao) GetWelfareTypeList

func (d *Dao) GetWelfareTypeList(c context.Context) (res []*model.WelfareTypeListResp, err error)

GetWelfareTypeList get welfare type list

func (*Dao) InsertReceiveRecord

func (d *Dao) InsertReceiveRecord(c context.Context, tx *sql.Tx, mid, wid, monthYear int64) (err error)

InsertReceiveRecord to prevent repeated receive

func (*Dao) InsertVipBcoinSalary

func (d *Dao) InsertVipBcoinSalary(c context.Context, r *model.VipBcoinSalary) (err error)

InsertVipBcoinSalary insert vip bcoin salary

func (*Dao) InsertVipChangeHistory

func (d *Dao) InsertVipChangeHistory(tx *sql.Tx, r *model.VipChangeHistory) (id int64, err error)

InsertVipChangeHistory insert vipChangeHistory

func (*Dao) InsertVipUserInfo

func (d *Dao) InsertVipUserInfo(tx *sql.Tx, r *model.VipInfoDB) (err error)

InsertVipUserInfo insert vipUserInfo

func (*Dao) Jointlys

func (d *Dao) Jointlys(c context.Context, now int64) (res []*model.Jointly, err error)

Jointlys jointly list.

func (*Dao) LoginCount

func (d *Dao) LoginCount(c context.Context, mid int64) (count int64, err error)

LoginCount get user recent loggin count

func (*Dao) Loginout

func (d *Dao) Loginout(c context.Context, mid int64) (err error)

Loginout login out

func (*Dao) MailCouponCodeCreate

func (d *Dao) MailCouponCodeCreate(c context.Context, a *model.ArgMailCouponCodeCreate) (err error)

MailCouponCodeCreate mail coupon code create.

func (*Dao) OldFrozenChange

func (d *Dao) OldFrozenChange(c context.Context, mid int64) (err error)

OldFrozenChange .

func (*Dao) OldInsertVipBcoinSalary

func (d *Dao) OldInsertVipBcoinSalary(c context.Context, r *model.VipBcoinSalary) (err error)

OldInsertVipBcoinSalary insert vip bcoin salary

func (*Dao) OldInsertVipChangeHistory

func (d *Dao) OldInsertVipChangeHistory(c context.Context, tx *sql.Tx, r *model.VipChangeHistory) (id int64, err error)

OldInsertVipChangeHistory insert vipChangeHistory

func (*Dao) OldInsertVipUserInfo

func (d *Dao) OldInsertVipUserInfo(c context.Context, tx *sql.Tx, r *model.VipUserInfo) (err error)

OldInsertVipUserInfo insert vipUserInfo.

func (*Dao) OldSelLastBcoin

func (d *Dao) OldSelLastBcoin(c context.Context, mid int64) (r *model.VipBcoinSalary, err error)

OldSelLastBcoin sel last bcoin by mid

func (*Dao) OldSelVipUserInfo

func (d *Dao) OldSelVipUserInfo(c context.Context, mid int64) (r *model.VipUserInfo, err error)

OldSelVipUserInfo select user info by mid

func (*Dao) OldStartTx

func (d *Dao) OldStartTx(c context.Context) (tx *sql.Tx, err error)

OldStartTx old start tx

func (*Dao) OldTxAddChangeHistory

func (d *Dao) OldTxAddChangeHistory(tx *sql.Tx, r *model.VipChangeHistory) (err error)

OldTxAddChangeHistory .

func (*Dao) OldTxDelBcoinSalary

func (d *Dao) OldTxDelBcoinSalary(tx *sql.Tx, mid int64, month time.Time) (err error)

OldTxDelBcoinSalary del bcoin salary

func (*Dao) OldTxSelVipUserInfo

func (d *Dao) OldTxSelVipUserInfo(tx *sql.Tx, mid int64) (r *model.VipInfoDB, err error)

OldTxSelVipUserInfo .

func (*Dao) OldTxUpdateVipUserInfo

func (d *Dao) OldTxUpdateVipUserInfo(tx *sql.Tx, r *model.VipInfoDB, ver int64) (eff int64, err error)

OldTxUpdateVipUserInfo .

func (*Dao) OldUpdateOrderCancel

func (d *Dao) OldUpdateOrderCancel(c context.Context, r *model.VipPayOrderOld) (a int64, err error)

OldUpdateOrderCancel order update order cancel.

func (*Dao) OldUpdateVipUserInfo

func (d *Dao) OldUpdateVipUserInfo(c context.Context, tx *sql.Tx, r *model.VipUserInfo) (a int64, err error)

OldUpdateVipUserInfo update vip user info by id

func (*Dao) OldVipchangeHistory

func (d *Dao) OldVipchangeHistory(c context.Context, relationID string, batchID int64) (r *model.VipChangeHistory, err error)

OldVipchangeHistory old vip change history.

func (*Dao) OpenCode

func (d *Dao) OpenCode(c context.Context, mid, batchCodeID int64, unit int32, remark, code string) (data *model.CommonResq, err error)

OpenCode open code.

func (*Dao) OpenInfoByMid

func (d *Dao) OpenInfoByMid(c context.Context, mid int64, appID int64) (res *model.OpenInfo, err error)

OpenInfoByMid get open info by mid.

func (*Dao) OpenInfoByOpenID

func (d *Dao) OpenInfoByOpenID(c context.Context, id string, appID int64) (res *model.OpenInfo, err error)

OpenInfoByOpenID get data from cache if miss will call source method, then add to cache.

func (*Dao) OrderCount

func (d *Dao) OrderCount(c context.Context, mid int64, status int8) (count int64, err error)

OrderCount order count.

func (*Dao) OrderInfo

func (d *Dao) OrderInfo(c context.Context, orderNo string) (r *model.OrderInfo, err error)

OrderInfo select order by order no.

func (*Dao) OrderList

func (d *Dao) OrderList(c context.Context, mid int64, status int8, pn, ps int) (res []*model.PayOrder, err error)

OrderList order list.

func (*Dao) PayBanks

func (d *Dao) PayBanks(c context.Context, ip string, data []*model.PayBankResp) (err error)

PayBanks .

func (*Dao) PayCashier

func (d *Dao) PayCashier(c context.Context, ip string, o *model.PayOrder, data *model.APIPayOrderResp, payCode string, bankCode string) (err error)

PayCashier pay cashier.

func (*Dao) PayClose

func (d *Dao) PayClose(c context.Context, orderNO string, ip string) (data *model.APIPayCancelResp, err error)

PayClose pay close.

func (*Dao) PayIapAccess

func (d *Dao) PayIapAccess(c context.Context, ip string, o *model.PayOrder, data *model.APIPayOrderResp, productID string) (err error)

PayIapAccess pay iap access.

func (*Dao) PayOrderLast

func (d *Dao) PayOrderLast(c context.Context, mid int64, status int8, orderTypes ...int64) (r *model.PayOrder, err error)

PayOrderLast .

func (*Dao) PayQrCode

func (d *Dao) PayQrCode(c context.Context, mid int64, orderID string, req map[string]interface{}) (data *model.PayQrCode, err error)

PayQrCode pay qr code.

func (*Dao) PayQrcode

func (d *Dao) PayQrcode(c context.Context, ip string, o *model.PayOrder, data *model.APIPayOrderResp, payCode string) (err error)

PayQrcode pay qrcode.

func (*Dao) PayRecission

func (d *Dao) PayRecission(c context.Context, params map[string]interface{}, clietIP string) (err error)

PayRecission call pay refund api.

func (*Dao) PaySDK

func (d *Dao) PaySDK(c context.Context, ip string, o *model.PayOrder, data *model.APIPayOrderResp, payCode string) (err error)

PaySDK moblie pay sdk.

func (*Dao) PaySign

func (d *Dao) PaySign(params map[string]string, token string) (sign string)

PaySign pay sign.

func (*Dao) PaySignNotDel

func (d *Dao) PaySignNotDel(params map[string]string, token string) (sign string)

PaySignNotDel pay sign not del.

func (*Dao) PayWallet

func (d *Dao) PayWallet(c context.Context, mid int64, ip string, data *model.PayAccountResp) (err error)

PayWallet .

func (*Dao) Ping

func (d *Dao) Ping(c context.Context) (err error)

Ping ping health of db.

func (*Dao) PlatformAll

func (d *Dao) PlatformAll(c context.Context) (res []*model.ConfPlatform, err error)

PlatformAll .

func (*Dao) PlatformByID

func (d *Dao) PlatformByID(c context.Context, id int64) (r *model.ConfPlatform, err error)

PlatformByID get info by open id.

func (*Dao) PointExchangePrice

func (d *Dao) PointExchangePrice(c context.Context, month int16) (pe *model.PointExchangePrice, err error)

PointExchangePrice def.

func (*Dao) PriceMapping

func (d *Dao) PriceMapping(c context.Context, monthID int64, platform int8) (r *model.PriceMapping, err error)

PriceMapping all price mapping.

func (*Dao) PrivilegeList

func (d *Dao) PrivilegeList(c context.Context) (res []*model.Privilege, err error)

PrivilegeList query .

func (*Dao) PrivilegeResourcesList

func (d *Dao) PrivilegeResourcesList(c context.Context) (res []*model.PrivilegeResources, err error)

PrivilegeResourcesList query privilege resources .

func (*Dao) QuickPayToken

func (d *Dao) QuickPayToken(c context.Context, ip string, accessKey string, cookie []*http.Cookie, data *model.QucikPayResp) (err error)

QuickPayToken quick pay token.

func (*Dao) RawBindInfoByMid

func (d *Dao) RawBindInfoByMid(c context.Context, mid int64, appID int64) (res *model.OpenBindInfo, err error)

RawBindInfoByMid get open bind info by mid.

func (*Dao) RawOpenInfoByOpenID

func (d *Dao) RawOpenInfoByOpenID(c context.Context, openID string, appID int64) (res *model.OpenInfo, err error)

RawOpenInfoByOpenID get info by open id.

func (*Dao) RemQueue

func (d *Dao) RemQueue(c context.Context, mid int64) (err error)

RemQueue del a frozen user from redis sortset queue

func (*Dao) SelActives

func (d *Dao) SelActives(c context.Context, relations []string) (rep []*model.VipActiveShow, err error)

SelActives sel active data.

func (*Dao) SelAllConfig

func (d *Dao) SelAllConfig(c context.Context) (res []*model.VipConfig, err error)

SelAllConfig sel all config

func (*Dao) SelBatchCode

func (d *Dao) SelBatchCode(c context.Context, id int64) (bc *model.VipResourceBatchCode, err error)

SelBatchCode set batch code.

func (*Dao) SelBatchCodes

func (d *Dao) SelBatchCodes(c context.Context, ids []int64) (bcs []*model.VipResourceBatchCode, err error)

SelBatchCodes sel batchcodes

func (*Dao) SelBatchCodesByBisID

func (d *Dao) SelBatchCodesByBisID(c context.Context, bisID int64) (bcs []*model.VipResourceBatchCode, err error)

SelBatchCodesByBisID set batch codes by business id.

func (*Dao) SelBatchCount

func (d *Dao) SelBatchCount(c context.Context, batchCodeID, mid int64) (count int64, err error)

SelBatchCount sel batch count

func (*Dao) SelBusiness

func (d *Dao) SelBusiness(c context.Context, id int64) (r *model.VipBusinessInfo, err error)

SelBusiness select businessInfo by id

func (*Dao) SelChangeHistory

func (d *Dao) SelChangeHistory(c context.Context, arg *model.ArgChangeHistory) (vcs []*model.VipChangeHistory, err error)

SelChangeHistory .

func (*Dao) SelChangeHistoryCount

func (d *Dao) SelChangeHistoryCount(c context.Context, arg *model.ArgChangeHistory) (count int64, err error)

SelChangeHistoryCount .

func (*Dao) SelCode

func (d *Dao) SelCode(c context.Context, codeStr string) (code *model.VipResourceCode, err error)

SelCode sel code.

func (*Dao) SelCodeOpened

func (d *Dao) SelCodeOpened(c context.Context, bisIDs []int64, arg *model.ArgCodeOpened) (cs []*model.CodeInfoResp, err error)

SelCodeOpened set code open.

func (*Dao) SelCodes

func (d *Dao) SelCodes(c context.Context, codes []string) (cs []*model.VipResourceCode, err error)

SelCodes sel codes

func (*Dao) SelCodesByBMid

func (d *Dao) SelCodesByBMid(c context.Context, mid int64) (cs []string, err error)

SelCodesByBMid sel codes by bmid

func (*Dao) SelLastBcoin

func (d *Dao) SelLastBcoin(c context.Context, mid int64) (r *model.VipBcoinSalary, err error)

SelLastBcoin sel last bcoin by mid.

func (*Dao) SelNewBusiness

func (d *Dao) SelNewBusiness(c context.Context, id int64) (r *model.VipBusinessInfo, err error)

SelNewBusiness select newdb businessInfo by id.

func (*Dao) SelNewBusinessByAppkey

func (d *Dao) SelNewBusinessByAppkey(c context.Context, appkey string) (r *model.VipBusinessInfo, err error)

SelNewBusinessByAppkey select newdb businessInfo by id.

func (*Dao) SelNewResourcePool

func (d *Dao) SelNewResourcePool(c context.Context, id int64) (r *model.VipResourcePool, err error)

SelNewResourcePool select new resource pool by id

func (*Dao) SelOldPayOrder

func (d *Dao) SelOldPayOrder(c context.Context, orderNo string) (r *model.VipPayOrderOld, err error)

SelOldPayOrder sel old payorder

func (*Dao) SelPayOrderLog

func (d *Dao) SelPayOrderLog(c context.Context, orderNo, refundID string, status int8) (res *model.VipPayOrderLog, err error)

SelPayOrderLog sel pay order log.

func (*Dao) SelResourcePool

func (d *Dao) SelResourcePool(c context.Context, id int64) (r *model.VipResourcePool, err error)

SelResourcePool select resource pool by id

func (*Dao) SelVipAppInfo

func (d *Dao) SelVipAppInfo(c context.Context, t int) (res []*model.VipAppInfo, err error)

SelVipAppInfo selVipAppInfo

func (*Dao) SelVipChangeHistory

func (d *Dao) SelVipChangeHistory(c context.Context, relationID string) (r *model.VipChangeHistory, err error)

SelVipChangeHistory select vip_change_history by relationId

func (*Dao) SelVipResourceBatch

func (d *Dao) SelVipResourceBatch(c context.Context, id int64) (r *model.VipResourceBatch, err error)

SelVipResourceBatch select vip resource Batch by id

func (*Dao) SendBcoinCoupon

func (d *Dao) SendBcoinCoupon(c context.Context, mids, activityID string, money int64, dueTime time.Time) (err error)

SendBcoinCoupon send bcoin coupon

func (*Dao) SendCleanCache

func (d *Dao) SendCleanCache(c context.Context, mid int64, months int16, days int64, t int, ip string) (err error)

SendCleanCache clean cache

func (*Dao) SendMultipMsg

func (d *Dao) SendMultipMsg(c context.Context, mids, content, title, mc, ip string, dataType int) (err error)

SendMultipMsg send multip msg

func (*Dao) SetOpenCode

func (d *Dao) SetOpenCode(c context.Context, mid int64, count int) (err error)

SetOpenCode set open code.

func (*Dao) SetPointTip

func (d *Dao) SetPointTip(c context.Context, mid, id int64, val int, expired int32) (err error)

SetPointTip set point tip.

func (*Dao) SetSignVip

func (d *Dao) SetSignVip(c context.Context, mid int64, t int) (err error)

SetSignVip .

func (*Dao) SetVipInfoCache

func (d *Dao) SetVipInfoCache(c context.Context, mid int64, v *model.VipInfo) (err error)

SetVipInfoCache set vip info cache.

func (*Dao) StartTx

func (d *Dao) StartTx(c context.Context) (tx *sql.Tx, err error)

StartTx start tx

func (*Dao) SyncAddUser

func (d *Dao) SyncAddUser(tx *sql.Tx, r *model.VipInfoDB) (err error)

SyncAddUser insert vipUserInfo

func (*Dao) SyncUpdateUser

func (d *Dao) SyncUpdateUser(tx *sql.Tx, r *model.VipInfoDB, ver int64) (eff int64, err error)

SyncUpdateUser insert vipUserInfo

func (*Dao) TxAddBind

func (d *Dao) TxAddBind(tx *sql.Tx, arg *model.OpenBindInfo) (err error)

TxAddBind add bind.

func (*Dao) TxAddIosVipUserInfo

func (d *Dao) TxAddIosVipUserInfo(tx *sql.Tx, r *model.VipInfoDB) (eff int64, err error)

TxAddIosVipUserInfo tx add ios vip user info.

func (*Dao) TxAddOrder

func (d *Dao) TxAddOrder(tx *sql.Tx, p *model.PayOrder) (id int64, err error)

TxAddOrder tx add order.

func (*Dao) TxAddOrderLog

func (d *Dao) TxAddOrderLog(tx *sql.Tx, arg *model.VipPayOrderLog) (err error)

TxAddOrderLog .

func (*Dao) TxAddUserDiscount

func (d *Dao) TxAddUserDiscount(tx *sql.Tx, r *model.VipUserDiscountHistory) (eff int64, err error)

TxAddUserDiscount add user discount history.

func (*Dao) TxDeleteBindInfo

func (d *Dao) TxDeleteBindInfo(tx *sql.Tx, id int64) (err error)

TxDeleteBindInfo bind info.

func (*Dao) TxDupUserDiscount

func (d *Dao) TxDupUserDiscount(tx *sql.Tx, mid, discountID int64, orderNo string, status int8) (err error)

TxDupUserDiscount .

func (*Dao) TxInsertAssociateGrantOrder

func (d *Dao) TxInsertAssociateGrantOrder(tx *sql.Tx, oa *model.VipOrderAssociateGrant) (aff int64, err error)

TxInsertAssociateGrantOrder insert associate grant order.

func (*Dao) TxSelVipUserInfo

func (d *Dao) TxSelVipUserInfo(tx *sql.Tx, mid int64) (r *model.VipInfoDB, err error)

TxSelVipUserInfo .

func (*Dao) TxUpdateAssociateGrantState

func (d *Dao) TxUpdateAssociateGrantState(tx *sql.Tx, oa *model.VipOrderAssociateGrant) (aff int64, err error)

TxUpdateAssociateGrantState update associate grant state.

func (*Dao) TxUpdateBatchCode

func (d *Dao) TxUpdateBatchCode(tx *sql.Tx, id int64, sc int32) (eff int64, err error)

TxUpdateBatchCode tx update batch code.

func (*Dao) TxUpdateBindByOutOpenID

func (d *Dao) TxUpdateBindByOutOpenID(tx *sql.Tx, arg *model.OpenBindInfo) (err error)

TxUpdateBindByOutOpenID update bind by out_open_id.

func (*Dao) TxUpdateChannelID

func (d *Dao) TxUpdateChannelID(tx *sql.Tx, mid int64, payChannelID int32, ver int64, oldVer int64) (err error)

TxUpdateChannelID .

func (*Dao) TxUpdateCode

func (d *Dao) TxUpdateCode(tx *sql.Tx, id int64, mid int64, useTime time.Time) (eff int64, err error)

TxUpdateCode tx update code.

func (*Dao) TxUpdateCodeStatus

func (d *Dao) TxUpdateCodeStatus(tx *sql.Tx, id int64, status int8) (eff int64, err error)

TxUpdateCodeStatus tx update code status.

func (*Dao) TxUpdateIosPayOrder

func (d *Dao) TxUpdateIosPayOrder(tx *sql.Tx, o *model.OrderInfo, ver int64) (err error)

TxUpdateIosPayOrder .

func (*Dao) TxUpdateIosRenewUserInfo

func (d *Dao) TxUpdateIosRenewUserInfo(tx *sql.Tx, paychannelID, ver, oldVer, mid int64, payType int8) (err error)

TxUpdateIosRenewUserInfo .

func (*Dao) TxUpdateIosUserInfo

func (d *Dao) TxUpdateIosUserInfo(tx *sql.Tx, iosTime time.Time, mid int64) (eff int64, err error)

TxUpdateIosUserInfo update ios time

func (*Dao) TxUpdateOrderStatus

func (d *Dao) TxUpdateOrderStatus(c context.Context, tx *sql.Tx, status int8, payType string, thirdTradeNO string, orderNO string) (err error)

TxUpdateOrderStatus update order status.

func (*Dao) TxUpdatePayOrder

func (d *Dao) TxUpdatePayOrder(tx *sql.Tx, o *model.OrderInfo, ver int64) (err error)

TxUpdatePayOrder .

func (*Dao) TxUpdatePayOrderRefundAmount

func (d *Dao) TxUpdatePayOrderRefundAmount(tx *sql.Tx, id int64, refundAmount float64, ver, oldVer int64) (err error)

TxUpdatePayOrderRefundAmount update payorder refund amount

func (*Dao) TxUpdatePayOrderStatus

func (d *Dao) TxUpdatePayOrderStatus(tx *sql.Tx, status int8, id int64, ver int64) (a int64, err error)

TxUpdatePayOrderStatus .

func (*Dao) UpdateActivityState

func (d *Dao) UpdateActivityState(c context.Context, state int8, orderNO string) (aff int64, err error)

UpdateActivityState update act vip grant state.

func (*Dao) UpdateAssociateGrantCount

func (d *Dao) UpdateAssociateGrantCount(c context.Context, arg *model.VipAssociateGrantCount) (err error)

UpdateAssociateGrantCount update associate grant count.

func (*Dao) UpdateBatchCount

func (d *Dao) UpdateBatchCount(c context.Context, tx *sql.Tx, r *model.VipResourceBatch, ver int64) (a int64, err error)

UpdateBatchCount updateBatch by Id

func (*Dao) UpdateBindState

func (d *Dao) UpdateBindState(c context.Context, arg *model.OpenBindInfo) (err error)

UpdateBindState update bind state.

func (*Dao) UpdatePayType

func (d *Dao) UpdatePayType(tx *sql.Tx, mid int64, payType int8, ver, oldVer int64) (a int64, err error)

UpdatePayType .

func (*Dao) UpdateVipTypeAndStatus

func (d *Dao) UpdateVipTypeAndStatus(c context.Context, mid int64, vipStatus int32, vipType int32) (ret int64, err error)

UpdateVipTypeAndStatus update vip type and status.

func (*Dao) UpdateVipUserInfo

func (d *Dao) UpdateVipUserInfo(tx *sql.Tx, r *model.VipInfoDB, ver int64) (a int64, err error)

UpdateVipUserInfo update vip user info by id

func (*Dao) UpdateWelfareBatch

func (d *Dao) UpdateWelfareBatch(c context.Context, tx *sql.Tx, bid int) (err error)

UpdateWelfareBatch reduce count

func (*Dao) UpdateWelfareCodeUser

func (d *Dao) UpdateWelfareCodeUser(c context.Context, tx *sql.Tx, id int, mid int64) (affectedRows int64, err error)

UpdateWelfareCodeUser user receive welfare

func (*Dao) Verify

func (d *Dao) Verify(c context.Context, code, token, ip string) (data *model.TokenResq, err error)

Verify verify code.

func (*Dao) VipInfo

func (d *Dao) VipInfo(c context.Context, mid int64) (r *model.VipInfoDB, err error)

VipInfo select user info by mid.

func (*Dao) VipInfoCache

func (d *Dao) VipInfoCache(c context.Context, mid int64) (v *model.VipInfo, err error)

VipInfoCache get vip info.

func (*Dao) VipPayOrderSuccs

func (d *Dao) VipPayOrderSuccs(c context.Context, mid int64) (mpo map[string]struct{}, err error)

VipPayOrderSuccs get succ of vip pay orders.

func (*Dao) VipPriceByID

func (d *Dao) VipPriceByID(c context.Context, id int64) (vpc *model.VipPriceConfig, err error)

VipPriceByID vip price by id.

func (*Dao) VipPriceByProductID

func (d *Dao) VipPriceByProductID(c context.Context, productID string) (vpc *model.VipPriceConfig, err error)

VipPriceByProductID select vip price by product id.

func (*Dao) VipPriceConfigs

func (d *Dao) VipPriceConfigs(c context.Context) (vpcs []*model.VipPriceConfig, err error)

VipPriceConfigs get vip price configs.

func (*Dao) VipPriceDiscountByProductID

func (d *Dao) VipPriceDiscountByProductID(c context.Context, productID string) (vpc []*model.VipDPriceConfig, err error)

VipPriceDiscountByProductID select vip price discount by product id.

func (*Dao) VipPriceDiscountConfigs

func (d *Dao) VipPriceDiscountConfigs(c context.Context) (mvp map[int64]*model.VipDPriceConfig, err error)

VipPriceDiscountConfigs get vip price discount configs.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL