Commit cc12a363 authored by suyanlong's avatar suyanlong

fix bug for execname

parent dfae34c5
......@@ -716,7 +716,7 @@ func (p *Paracross) SubmitIBTP(ibtp *pb.IBTP) (*pb.SubmitIBTPResponse, error) {
if event.Payload.EventType == types.EventType_Burn {
// 用户在联盟链一侧发起销毁。
// 第一次提交。
TokenSymbol := "" // TODO 销毁bty时,不要填写!!!
TokenSymbol := ""
if strings.ToUpper(p.chain33Config.Chain33.Symbol) == "YCC" {
TokenSymbol = "coins.ycc"
} else {
......@@ -728,8 +728,8 @@ func (p *Paracross) SubmitIBTP(ibtp *pb.IBTP) (*pb.SubmitIBTPResponse, error) {
Fee: p.MinTxFeeRate,
Note: payload.Content, // 关联数据
IsWithdraw: true,
TokenSymbol: TokenSymbol, // TODO 销毁bty时,不要填写!!!
ExecName: p.title + execer, // TODO 平行链执行器。
TokenSymbol: TokenSymbol,
ExecName: p.title + execer,
})
if err != nil {
p.logger.Error("CreateRawAssetTransferTxExt error", "error", err)
......@@ -737,6 +737,9 @@ func (p *Paracross) SubmitIBTP(ibtp *pb.IBTP) (*pb.SubmitIBTPResponse, error) {
}
tx.Nonce = int64(ibtp.Nonce)
tx.Sign(types33.SECP256K1, p.privateKey)
data := hex.EncodeToString(types33.Encode(tx))
txTmp, _ := types33.PBToJSON(tx)
p.logger.Info("SendTransaction ", "hash", common.HashHex(tx.Hash()), "error", err, "tx", util.FormatJSON(string(txTmp)), "data", data)
ret, err := p.grpcClient.SendTransaction(p.ctx, tx)
if err != nil {
data := hex.EncodeToString(types33.Encode(tx))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment