We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 50070
    • 12 Posts
    Hi,

    Wonder if someone here can help me. I'm using MIGX and I've got a CMP building using the MIGX configurator and in the CMP I can add items successfully (and they save to the database), but when I right-click and edit/update the form loads in the window but the fields are empty. Also, selecting delete from the menu doesn't do anything.

    Is there something I've missed in the setup?

    Thanks!

    {
      "formtabs":[
        {
          "MIGX_id":11,
          "caption":"Information",
          "print_before_tabs":"0",
          "fields":[
            {
              "MIGX_id":40,
              "field":"job_title",
              "caption":"Job Title",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"text",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":1
            },
            {
              "MIGX_id":41,
              "field":"job_content",
              "caption":"Description",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"richtext",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":2
            },
            {
              "MIGX_id":42,
              "field":"job_salary",
              "caption":"Salary",
              "description":"Enter amount or salary band",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"text",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":3
            },
            {
              "MIGX_id":43,
              "field":"job_campus",
              "caption":"Campus",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"listbox",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"main||second||third",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":4
            }
          ],
          "pos":1
        },
        {
          "MIGX_id":12,
          "caption":"Dates",
          "print_before_tabs":"0",
          "fields":[
            {
              "MIGX_id":44,
              "field":"job_start_date",
              "caption":"Start date",
              "description":"Free text, e.g. \"September 2005, earlier if possible\"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"text",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":1
            },
            {
              "MIGX_id":45,
              "field":"job_closing_date",
              "caption":"Closing Date",
              "description":"When do applications need to be received by?",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"date",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"@EVAL return date('Y-m-d',strtotime(\"+30 days\"));",
              "useDefaultIfEmpty":1,
              "pos":2
            },
            {
              "MIGX_id":46,
              "field":"job_interview_date",
              "caption":"Interview Date",
              "description":"When will interviews begin?",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"date",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"@EVAL return date('Y-m-d H:i:s',strtotime(\"+30 days\"));",
              "useDefaultIfEmpty":1,
              "pos":3
            }
          ],
          "pos":2
        },
        {
          "MIGX_id":13,
          "caption":"Attachments",
          "print_before_tabs":"0",
          "fields":[
            {
              "MIGX_id":47,
              "field":"job_file_description",
              "caption":"Job Description",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"file",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":1
            },
            {
              "MIGX_id":48,
              "field":"job_file_person",
              "caption":"Person Specification",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"file",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":2
            },
            {
              "MIGX_id":49,
              "field":"job_file_application",
              "caption":"Application Form",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"file",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":3
            },
            {
              "MIGX_id":50,
              "field":"job_file_guidance",
              "caption":"Application Guidance",
              "description":"",
              "description_is_code":"0",
              "inputTV":"",
              "inputTVtype":"file",
              "validation":"",
              "configs":"",
              "restrictive_condition":"",
              "display":"",
              "sourceFrom":"config",
              "sources":"",
              "inputOptionValues":"",
              "default":"",
              "useDefaultIfEmpty":"0",
              "pos":4
            }
          ],
          "pos":3
        }
      ],
      "contextmenus":"update||duplicate||remove",
      "actionbuttons":"addItem",
      "columnbuttons":"update||duplicate||remove",
      "filters":"",
      "extended":{
        "migx_add":"Add Vacancy",
        "disable_add_item":"",
        "add_items_directly":"",
        "formcaption":"Vacancies",
        "update_win_title":"Edit Vacancy",
        "win_id":"jobs",
        "maxRecords":"",
        "addNewItemAt":"bottom",
        "multiple_formtabs":"",
        "multiple_formtabs_label":"",
        "multiple_formtabs_field":"",
        "multiple_formtabs_optionstext":"",
        "multiple_formtabs_optionsvalue":"",
        "actionbuttonsperrow":4,
        "winbuttonslist":"cancel||done",
        "extrahandlers":"",
        "filtersperrow":4,
        "packageName":"jobs",
        "classname":"jobs",
        "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":"Manage Vacancies",
        "cmptabcaption":"Vacancies",
        "cmptabdescription":"Manage job vacancies for different locations",
        "cmptabcontroller":"",
        "winbuttons":"",
        "onsubmitsuccess":"",
        "submitparams":""
      },
      "columns":[
        {
          "MIGX_id":1,
          "header":"Job Title",
          "dataIndex":"job_title",
          "width":50,
          "sortable":"false",
          "show_in_grid":1,
          "renderer":"",
          "clickaction":"",
          "selectorconfig":"",
          "renderchunktpl":"",
          "renderoptions":"",
          "editor":""
        },
        {
          "MIGX_id":2,
          "header":"Description",
          "dataIndex":"job_content",
          "width":50,
          "sortable":"false",
          "show_in_grid":1,
          "renderer":"",
          "clickaction":"",
          "selectorconfig":"",
          "renderchunktpl":"",
          "renderoptions":"",
          "editor":""
        },
        {
          "MIGX_id":3,
          "header":"Published?",
          "dataIndex":"published",
          "width":25,
          "sortable":"false",
          "show_in_grid":1,
          "renderer":"this.renderCrossTick",
          "clickaction":"",
          "selectorconfig":"",
          "renderchunktpl":"",
          "renderoptions":"",
          "editor":""
        }
      ]
    }
    
      • 5430
      • 247 Posts
      Just ran into this same problem. Items save just fine but can't edit/remove them. I suspect my issue is the same as yours but I'm not seeing the problem in my setup either.
        • 4172
        • 5,888 Posts
        it is the missing id-field in the columns
          -------------------------------

          you can buy me a beer, if you like MIGX

          http://webcmsolutions.de/migx.html

          Thanks!
          • 50070
          • 12 Posts
          Quote from: claytonk at Jun 02, 2015, 03:13 PM
          Just ran into this same problem. Items save just fine but can't edit/remove them. I suspect my issue is the same as yours but I'm not seeing the problem in my setup either.

          As Bruno says above - you need to add the ID column into your grid view in the MIGX configurator.
            • 5430
            • 247 Posts
            Quote from: Bruno17 at Jun 02, 2015, 03:39 PM
            it is the missing id-field in the columns

            GAH! I did another CMP two days ago and told myself "you're gonna forget the ID column next time around". Sure as ...

            phil_skipps2, in case you're not clear on what he's referring to, you're columns array needs to start like this:

            "columns":[
                {
                  "MIGX_id":5,
                  "header":"ID",
                  "dataIndex":"id",
                  "width":"",
                  "sortable":true,
                  "show_in_grid":1,
                  "renderer":"",
                  "clickaction":"",
                  "selectorconfig":"",
                  "renderchunktpl":"",
                  "renderoptions":"",
                  "editor":""
                },


            That extra column links things up.
              • 5430
              • 247 Posts
              Quote from: phil_skipps2 at Jun 02, 2015, 03:47 PM
              Quote from: claytonk at Jun 02, 2015, 03:13 PM
              Just ran into this same problem. Items save just fine but can't edit/remove them. I suspect my issue is the same as yours but I'm not seeing the problem in my setup either.

              As Bruno says above - you need to add the ID column into your grid view in the MIGX configurator.

              Sorry, looks like you beat me to the reply wink