forked from XinFinOrg/XDCScan
-
Notifications
You must be signed in to change notification settings - Fork 0
/
db-internal.js
39 lines (37 loc) · 1.04 KB
/
db-internal.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/******
DEPRECATED -- DO NOT USE
*******/
var mongoose = require( 'mongoose' );
var Schema = mongoose.Schema;
var InternalTransaction = new Schema(
{
"type": String,
"action": {
"from": String, // for call
"to": String,
"value": String,
"gas": Number,
"input":String,
"callType":String,
"init": String, // for create
"address": String, // for suicide
"refundAddress": String,
"balance": String
},
"result": {
"gasUsed":Number,
"output":String,
"code": String,
"address": String
},
"error": String,
"traceAddress":[String],
"subtraces":Number,
"transactionPosition":Number,
"transactionHash": {type: String, index: {unique: false}}, // parent transaction
"blockNumber":{type: Number, index: {unique: false}},
"timestamp": Number,
"blockHash":String
});
mongoose.model('InternalTransaction', InternalTransaction);
module.exports.InternalTransaction = mongoose.model('InternalTransaction');