gandalf.api
gandalf.api copied to clipboard
Gandalf Web does not display Variants with Conditions like the Data Shows.
Gandalf Web does not display the conditions for variants in the same order as from the Object or data in MongoDB. Please see the data from MongoDB and compare with screen shot from Gandalf Web. All fields for Rupee should be $is_set, but its taking properties from other fields. Thank you.
"variants" : [
{
"title" : "name",
"description" : "description",
"default_title" : "You may pass",
"default_description" : "You may pass",
"probability" : 0,
"default_decision" : "You may pass",
"rules" : [
{
"than" : "You are a NEWB",
"title" : "You are a NEWB",
"description" : "You are a NEWB",
"conditions" : [
{
"field_key" : "profession",
"condition" : "$eq",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fdc")
},
{
"field_key" : "level",
"condition" : "$eq",
"value" : false,
"_id" : ObjectId("58d3a8de917f1a6d63150fdd")
},
{
"field_key" : "key",
"condition" : "$eq",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fde")
},
{
"field_key" : "rupee",
"condition" : "$is_set",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fdf")
}
],
"_id" : ObjectId("58d3a8de917f1a6d63150fe0")
},
{
"than" : "You are not a WIZARD",
"title" : "You are not a WIZARD",
"description" : "You are not a WIZARD",
"conditions" : [
{
"field_key" : "profession",
"condition" : "$eq",
"value" : false,
"_id" : ObjectId("58d3a8de917f1a6d63150fe1")
},
{
"field_key" : "level",
"condition" : "$is_set",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe2")
},
{
"field_key" : "key",
"condition" : "$is_set",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe3")
},
{
"field_key" : "rupee",
"condition" : "$is_set",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe4")
}
],
"_id" : ObjectId("58d3a8de917f1a6d63150fe5")
},
{
"than" : "You do not have the KEY",
"title" : "You do not have the KEY",
"description" : "You do not have the KEY",
"conditions" : [
{
"field_key" : "profession",
"condition" : "$eq",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe6")
},
{
"field_key" : "level",
"condition" : "$eq",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe7")
},
{
"field_key" : "key",
"condition" : "$eq",
"value" : false,
"_id" : ObjectId("58d3a8de917f1a6d63150fe8")
},
{
"field_key" : "rupee",
"condition" : "$is_set",
"value" : true,
"_id" : ObjectId("58d3a8de917f1a6d63150fe9")
}
],
"_id" : ObjectId("58d3a8de917f1a6d63150fea")
}
],
"_id" : ObjectId("58d3a8de917f1a6d63150feb")
}
],
Hello, thanks for finding this bug.
I'll add this issues to our backlog, we will investigate and fix it whenever we will have some spare time.
Thanks Andrew.