1
This commit is contained in:
parent
bcbbfb3584
commit
18a93ea11d
@ -1,41 +0,0 @@
|
|||||||
package service
|
|
||||||
|
|
||||||
import (
|
|
||||||
"q5"
|
|
||||||
"f5"
|
|
||||||
"main/constant"
|
|
||||||
)
|
|
||||||
|
|
||||||
func SendSysMail(uniKey string, to string, subject string, content string, sendTime int32, expireTime int32,
|
|
||||||
tag1 int32, tag2 int32) bool {
|
|
||||||
var dbErr error
|
|
||||||
nowTime := f5.GetApp().GetRealSeconds()
|
|
||||||
f5.GetGoStyleDb().Upsert(
|
|
||||||
constant.MAIL_DB,
|
|
||||||
"t_sys_mail",
|
|
||||||
[][]string{
|
|
||||||
{"unikey", uniKey},
|
|
||||||
},
|
|
||||||
[][]string{
|
|
||||||
},
|
|
||||||
[][]string{
|
|
||||||
{"unikey", uniKey},
|
|
||||||
{"subject", subject},
|
|
||||||
{"content", content},
|
|
||||||
{"recipients", q5.EncodeJson([]string{
|
|
||||||
to,
|
|
||||||
})},
|
|
||||||
{"tag1", q5.ToString(tag1)},
|
|
||||||
{"tag2", q5.ToString(tag2)},
|
|
||||||
{"sendtime", q5.ToString(sendTime)},
|
|
||||||
{"expiretime", q5.ToString(expireTime)},
|
|
||||||
{"user_reg_start_time", q5.ToString(0)},
|
|
||||||
{"user_reg_end_time", q5.ToString(nowTime + 3600 * 24 * 365 * 10)},
|
|
||||||
{"createtime", q5.ToString(nowTime)},
|
|
||||||
{"modifytime", q5.ToString(nowTime)},
|
|
||||||
},
|
|
||||||
func (err error, lastInsertId int64, rowsAffected int64) {
|
|
||||||
dbErr = err
|
|
||||||
})
|
|
||||||
return dbErr == nil
|
|
||||||
}
|
|
@ -113,14 +113,14 @@ func (this* repairNft) repairNft(ds *f5.DataSet) bool {
|
|||||||
var itemId int32
|
var itemId int32
|
||||||
var quality int32
|
var quality int32
|
||||||
if service.GetHeroByTokenId(tokenId, &itemId, &quality) {
|
if service.GetHeroByTokenId(tokenId, &itemId, &quality) {
|
||||||
this.updateNftItemId(netId, contractAddress, tokenId, itemId)
|
this.updateNftItemId(netId, contractAddress, tokenId, itemId, quality)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case jccommon.NFT_TYPE_GOLD_BULLION:
|
case jccommon.NFT_TYPE_GOLD_BULLION:
|
||||||
{
|
{
|
||||||
var itemId int32
|
var itemId int32
|
||||||
if service.GetGoldBullionByNetIdTokenId(netId, tokenId, &itemId) {
|
if service.GetGoldBullionByNetIdTokenId(netId, tokenId, &itemId) {
|
||||||
this.updateNftItemId(netId, contractAddress, tokenId, itemId)
|
this.updateNftItemId(netId, contractAddress, tokenId, itemId, 0)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -128,7 +128,7 @@ func (this* repairNft) repairNft(ds *f5.DataSet) bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (this* repairNft) updateNftItemId(netId int32, contractAddress string, tokenId string,
|
func (this* repairNft) updateNftItemId(netId int32, contractAddress string, tokenId string,
|
||||||
itemId int32) {
|
itemId int32, quality int32) {
|
||||||
f5.GetGoStyleDb().Update(
|
f5.GetGoStyleDb().Update(
|
||||||
constant.BCNFT_DB,
|
constant.BCNFT_DB,
|
||||||
"t_nft",
|
"t_nft",
|
||||||
@ -140,6 +140,7 @@ func (this* repairNft) updateNftItemId(netId int32, contractAddress string, toke
|
|||||||
},
|
},
|
||||||
[][]string {
|
[][]string {
|
||||||
{"item_id", q5.ToString(itemId)},
|
{"item_id", q5.ToString(itemId)},
|
||||||
|
{"quality", q5.ToString(quality)},
|
||||||
},
|
},
|
||||||
func (err error, lastInsertId int64, rowsAffected int64) {
|
func (err error, lastInsertId int64, rowsAffected int64) {
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user