Tagged: 

Viewing 4 reply threads
  • Author
    Posts
    • #5653
      Jan
      Participant

      Hello,

      i have repeater group of fields, and i`m manually creating inputs using php imports (cron).

      Everything was fine until client edited using wp-admin some data, probably he didn`t even edited data in given repeater group, but he saved post. And what happends, was that we got suddenly different structure of output array.

      Example:
      Before wp-admin CPT save:

      Array
      (
      [0] => Array
      (
      [extras_id] => 809572740000100325
      [extras_name] => Hostess
      [extras_price] => 125.0
      [extras_currency] => EUR
      [extras_timeunit] => 86400000
      [extras_customquantity] => 0
      [extras_validdatefrom] => 1970-01-01
      [extras_validdateto] => 2121-05-26
      [extras_sailingdatefrom] => 1970-01-01
      [extras_sailingdateto] => 2121-05-26
      [extras_obligatory] => 0
      [extras_perperson] => 0
      [extras_includedinbaseprice] => 0
      [extras_payableoninvoice] => 0
      [extras_availableinbase] => -1
      [extras_incluldesdepositwaiver] => 0
      )

      [1] => Array
      (
      [extras_id] => 809571150000100325
      [extras_name] => Transit log (from 38 to 41 ft)
      [extras_price] => 130.0
      [extras_currency] => EUR
      [extras_timeunit] => 0
      [extras_customquantity] => 0
      [extras_validdatefrom] => 1970-01-01
      [extras_validdateto] => 2121-05-26
      [extras_sailingdatefrom] => 1970-01-01
      [extras_sailingdateto] => 2121-05-26
      [extras_obligatory] => 1
      [extras_perperson] => 0
      [extras_includedinbaseprice] => 0
      [extras_payableoninvoice] => 0
      [extras_availableinbase] => -1
      [extras_incluldesdepositwaiver] => 0
      )

      After save:
      Array
      (
      [0] => Array
      (
      [extras_id] => Array
      (
      [0] => 6797510316300809
      [1] => 1327880281100809
      [2] => 5279300316300809
      [3] => 5279000316300809
      [4] => 220188710000100809
      [5] => 5222990316300809
      [6] => 220188970000100809
      [7] => 220188870000100809
      )

      [extras_name] => Array
      (
      [0] => Wi-Fi
      [1] => Tourist tax (1 EUR /person /day)
      [2] => Skipper
      [3] => Transit log Hanse 505
      [4] => Outboard engine
      [5] => One Way fee
      [6] => Hostess
      [7] => Safety net
      )
      etc..

      Do you have idea, whats wrong?

    • #5661
      Steve
      Keymaster

      @horecny– What version of Piklist are you using? And did you switch anywhere. The first looks like the array in Piklist v0.9.9x, which is the newer version…nice and clean. The second looks like the older array format, for Piklist 0.9.4.29.

      • #5674
        Jan
        Participant

        Hi Steve

        its always public version of Piklist 0.9.4.29. Thats a problem.

        Anyway: if we updated this project into latest 0.9.9x the problem was even bigger:

        1. after update we have not seen any data in editing post (we have large repeater groups)
        2. we were not able to save data – no changes in backend and front end
        3. our imports were not working – we are using basic structure of arrays in php to save post meta

      • #5680
        Steve
        Keymaster

        Based on your last reply: Did you install 0.9.4.29, then install 0.9.9.x, run the importer, and then switch back to 0.9.4.29?

    • #5684
      Jan
      Participant

      no we did this steps:

      1. installed 0.9.4.29
      2. identified problems
      3. installed 0.9.9.x
      4. saw bigger problems
      5. made database backup restore

    • #5707
      Stefan
      Participant

      Similar issue here after upgrade to 9.9.7, the array structure changed.

    • #5717
      Steve
      Keymaster

      @stefanrinaldi– I believe your issue is different. The array structure is supposed to change. That’s the point of the update script. You can learn more about it here >

Viewing 4 reply threads
  • You must be logged in to reply to this topic.