Передача полей из MIGxDB в MIGx

Добрый день.

Изучаю MIGx и столкнулся с проблемой.

Задача такая:
1. Есть справочник в виде ресурсов. Я его без проблем получаю через MIGxDB с помощью соответствующего TV
2. Далее через MIGx мне нужно выбирать нужные ресурсы справочника и отображать в таблице MIGx

Суть проблемы:
Я выбираю нужный ресурс. Нажимаю выполнить. А в MIGx добавляется пустая строка.

Вопрос:
Где и как указать эту связь, чтобы данные из MIGxDB передавались в соответствующие поля MIGx?

MIGxDB
{
  "formtabs":[
    {
      "MIGX_id":7,
      "caption":"Resource",
      "print_before_tabs":"0",
      "fields":[
        {
          "MIGX_id":18,
          "field":"pagetitle",
          "caption":"Pagetitle",
          "inputTV":"",
          "inputTVtype":"",
          "configs":"",
          "sourceFrom":"config",
          "sources":"",
          "inputOptionValues":"",
          "default":"",
          "pos":1
        }
      ],
      "pos":1
    }
  ],
  "contextmenus":"update||duplicate||recall_remove_delete||remove",
  "actionbuttons":"addItem||bulk||toggletrash||upload",
  "columnbuttons":"update||publish||unpublish",
  "filters":[
    {
      "MIGX_id":1,
      "name":"search",
      "label":"search",
      "emptytext":"search...",
      "type":"textbox",
      "getlistwhere":{
        "pagetitle:LIKE":"%[[+search]]%",
        "OR:longtitle:LIKE":"%[[+search]]%",
        "OR:content:LIKE":"%[[+search]]%"
      },
      "getcomboprocessor":"",
      "combotextfield":"",
      "comboidfield":"",
      "comboparent":""
    },
    {
      "MIGX_id":2,
      "name":"category",
      "label":"category",
      "emptytext":"- category filter -",
      "type":"combobox",
      "getlistwhere":"tvFilter::categories=inArray=[[+category]]",
      "getcomboprocessor":"getTVcombo",
      "combotextfield":"categories",
      "comboidfield":"",
      "comboparent":""
    }
  ],
  "extended":{
    "migx_add":"Add Childresource",
    "disable_add_item":"",
    "add_items_directly":"",
    "formcaption":"Child Resource",
    "update_win_title":"",
    "win_id":"childstutorial",
    "maxRecords":"",
    "addNewItemAt":"bottom",
    "media_source_id":"",
    "multiple_formtabs":"",
    "multiple_formtabs_label":"",
    "multiple_formtabs_field":"",
    "multiple_formtabs_optionstext":"",
    "multiple_formtabs_optionsvalue":"",
    "actionbuttonsperrow":1,
    "winbuttonslist":"",
    "extrahandlers":"this.handlePositionSelector||this.handleColumnSwitch",
    "filtersperrow":1,
    "packageName":"migxchildresources",
    "classname":"modResource",
    "task":"",
    "getlistsort":"menuindex",
    "getlistsortdir":"",
    "sortconfig":"",
    "gridpagesize":"",
    "use_custom_prefix":"0",
    "prefix":"",
    "grid":"",
    "gridload_mode":2,
    "check_resid":1,
    "check_resid_TV":"",
    "join_alias":"",
    "has_jointable":"yes",
    "getlistwhere":"",
    "joins":[
      {
        "alias":"CreatedBy"
      }
    ],
    "hooksnippets":"",
    "cmpmaincaption":"",
    "cmptabcaption":"",
    "cmptabdescription":"",
    "cmptabcontroller":"",
    "winbuttons":"",
    "onsubmitsuccess":"",
    "submitparams":""
  },
  "columns":[
    {
      "MIGX_id":1,
      "header":"id",
      "dataIndex":"id",
      "width":10,
      "sortable":1,
      "show_in_grid":1,
      "customrenderer":"",
      "renderer":"",
      "clickaction":"",
      "selectorconfig":"",
      "renderchunktpl":"",
      "renderoptions":"",
      "editor":""
    }
  ],
  "category":""
}
MIGx
{
  "formtabs":[
    {
      "MIGX_id":10,
      "caption":"\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u043f\u0438\u043a\u0435\u0440\u0430",
      "print_before_tabs":"0",
      "fields":[
        {
          "MIGX_id":25,
          "field":"id",
          "caption":"\u0412\u044b\u0431\u0435\u0440\u0435\u0442\u0435 \u0441\u043f\u0438\u043a\u0435\u0440\u0430",
          "description":"",
          "description_is_code":"0",
          "inputTV":"speakerList",
          "inputTVtype":"",
          "validation":"",
          "configs":"",
          "restrictive_condition":"",
          "display":"",
          "sourceFrom":"config",
          "sources":"",
          "inputOptionValues":"",
          "default":"",
          "useDefaultIfEmpty":"0",
          "pos":1
        }
      ],
      "pos":1
    }
  ],
  "contextmenus":"",
  "actionbuttons":"",
  "columnbuttons":"",
  "filters":"",
  "extended":{
    "migx_add":"",
    "disable_add_item":"",
    "add_items_directly":"",
    "formcaption":"",
    "update_win_title":"",
    "win_id":"slconfig",
    "maxRecords":"",
    "addNewItemAt":"bottom",
    "media_source_id":"",
    "multiple_formtabs":"",
    "multiple_formtabs_label":"",
    "multiple_formtabs_field":"",
    "multiple_formtabs_optionstext":"",
    "multiple_formtabs_optionsvalue":"",
    "actionbuttonsperrow":4,
    "winbuttonslist":"",
    "extrahandlers":"",
    "filtersperrow":4,
    "packageName":"",
    "classname":"",
    "task":"",
    "getlistsort":"",
    "getlistsortdir":"",
    "sortconfig":"",
    "gridpagesize":"",
    "use_custom_prefix":"0",
    "prefix":"",
    "grid":"",
    "gridload_mode":1,
    "check_resid":1,
    "check_resid_TV":"",
    "join_alias":"",
    "has_jointable":"yes",
    "getlistwhere":"",
    "joins":"",
    "hooksnippets":"",
    "cmpmaincaption":"",
    "cmptabcaption":"",
    "cmptabdescription":"",
    "cmptabcontroller":"",
    "winbuttons":"",
    "onsubmitsuccess":"",
    "submitparams":""
  },
  "columns":[
    {
      "MIGX_id":1,
      "header":"id",
      "dataIndex":"id",
      "width":50,
      "sortable":"false",
      "show_in_grid":1,
      "customrenderer":"",
      "renderer":"",
      "clickaction":"",
      "selectorconfig":"",
      "renderchunktpl":"",
      "renderoptions":"",
      "editor":""
    }
  ],
  "category":""
}
Сергей
06 января 2020, 19:42
modx.pro
1 021
0

Комментарии: 3

Сергей
07 января 2020, 01:45
0
Записал гифку, чтобы было более понятней :)
    Сергей
    08 января 2020, 00:43
    0
    Я так понимаю что MIGxdb — это объекты, а MIGx — это json. И передать данные простым способом не получится.

    Может кто подскажет альтернативный способ как получить список ресурсов (с учетом что их много) и была возможность выбирать нужные?
      Баха Волков
      08 января 2020, 14:14
      0
      Погуглите в сторону @EVAL
        Авторизуйтесь или зарегистрируйтесь, чтобы оставлять комментарии.
        3