Skip to content

Instantly share code, notes, and snippets.

@categulario
Created May 16, 2018 14:20
Show Gist options
  • Save categulario/0cb0c6b635e03c5a7ea5645c9ad3f17d to your computer and use it in GitHub Desktop.
Save categulario/0cb0c6b635e03c5a7ea5645c9ad3f17d to your computer and use it in GitHub Desktop.
Representación del estado de cacahuate
{
'_type': 'execution',
'id': '29uiferi',
'process_id': 'some.2018-05-16.xml',
'state': {
'_type': ':sorted_map',
'items': {
'node1_id': {
'_type': 'node',
'id': 'node1_id',
'state': 'valid',
'comment': '',
'actors': {
'_type': ':map',
'items': {
'OMNI\\og': {
'_type': 'actor',
'ref': 'node1_id',
'state': 'valid',
'user': {
'_type': 'user',
'identifier': 'OMNI\\og',
'fullname': 'Og',
},
'forms': [
{
'id': 'nifref',
'state': 'valid',
'fields': {
'_type': ':sorted_map',
'items': {
'name': {
'_type': 'field',
'name': 'name',
'label': 'Nombre',
'value_caption': 'Og',
'value': 'Og',
'state': 'valid',
},
'gender': {
'_type': 'field',
'name': 'gender',
'label': 'Género',
'value_caption': 'Femenino',
'value': 'F',
'state': 'valid',
},
},
'item_order': ['name', 'gender'],
},
}
],
},
},
},
},
'node2_id': {
'_type': 'node',
'id': 'node1_id',
'state': 'invalid',
'comment': 'el género es incorrecto',
'actors': {
'_type': ':map',
'items': {
'OMNI\\og': {
'_type': 'actor',
'ref': 'node1_id',
'state': 'invalid',
'user': {
'_type': 'user',
'identifier': 'OMNI\\og',
'fullname': 'Og',
},
'forms': [
{
'id': 'nifref',
'state': 'invalid',
'fields': {
'_type': ':sorted_map',
'items': {
'name': {
'_type': 'field',
'name': 'name',
'label': 'Nombre',
'value_caption': 'Og',
'value': 'Og',
'state': 'valid',
},
'gender': {
'_type': 'field',
'name': 'gender',
'label': 'Género',
'value_caption': 'Femenino',
'value': 'F',
'state': 'invalid',
},
},
'item_order': ['name', 'gender'],
},
}
],
},
},
},
},
'node3_id': {
'_type': 'node',
'id': 'node3_id',
'state': 'skipped',
'comment': '',
'actors': {
'_type': ':map',
'items': {},
},
},
'node4_id': {
'_type': 'node',
'id': 'node4_id',
'state': 'unfilled',
'comment': '',
'actors': {
'_type': ':map',
'items': {},
},
},
},
'item_order': [
'node1_id',
'node2_id',
'node3_id',
'node4_id',
],
},
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment