1. Fabrik 3.9 has been released. If you have updated Joomla to 3.9, this is a required update.
    Dismiss Notice

How to find "join id"?

Discussion in 'Community' started by bluetoothbj, Jan 14, 2020 at 3:47 PM.

  1. bluetoothbj

    bluetoothbj Member

    Level: Community
    Dear Sir:
    About "Calculating Cost in a repeat group ", there is a code on end of this page :
    "var i = this.id.match(/_(\d+)$/)[1];
    document.id('join___12___order___total_'+i).value = parseFloat(document.id('join___12___order___qty_'+i).value) * parseFloat(document.id('join___12___order___unit_price_'+i).value);"

    Note "Replace '12' with your join id (execute your form and look at the code to find this ID)"
    How to "execute your form and look at the code to find this ID".
    I don't understand.Could give me a detail instruction to find the join ID?

    Many thanks!
     
  2. troester

    troester Well-Known Member Staff Member

    Level: Community
    Can you post a link to this page? I have the feeling this is outdated.
     
  3. bluetoothbj

    bluetoothbj Member

    Level: Community
  4. troester

    troester Well-Known Member Staff Member

    Level: Community
    I have updated the WIKI with what I think is working now.
     
  5. bluetoothbj

    bluetoothbj Member

    Level: Community
    Thanks troester,
    I added JS on both quantiy and price elements ,But the Total element didn't display calculate data,If the Total element need some additional setting?

    cal1.png

    cal0.JPG
     
    Last edited: Jan 18, 2020 at 8:17 AM
  6. troester

    troester Well-Known Member Staff Member

    Level: Community
    In your JS there's a _ missing at the end of all your element names.

    Gesendet von meinem SM-G930F mit Tapatalk
     

Share This Page