|
|
@ -20,10 +20,11 @@ func (t *TransTccProcessor) GenBranches() []TransBranch { |
|
|
steps := []M{} |
|
|
steps := []M{} |
|
|
common.MustUnmarshalString(t.Data, &steps) |
|
|
common.MustUnmarshalString(t.Data, &steps) |
|
|
for _, step := range steps { |
|
|
for _, step := range steps { |
|
|
|
|
|
branch := common.GenGid() |
|
|
for _, branchType := range []string{"cancel", "confirm", "try"} { |
|
|
for _, branchType := range []string{"cancel", "confirm", "try"} { |
|
|
branches = append(branches, TransBranch{ |
|
|
branches = append(branches, TransBranch{ |
|
|
Gid: t.Gid, |
|
|
Gid: t.Gid, |
|
|
Branch: fmt.Sprintf("%d", len(branches)+1), |
|
|
Branch: branch, |
|
|
Data: step["data"].(string), |
|
|
Data: step["data"].(string), |
|
|
Url: step[branchType].(string), |
|
|
Url: step[branchType].(string), |
|
|
BranchType: branchType, |
|
|
BranchType: branchType, |
|
|
|