Announcement

Collapse
No announcement yet.

Javascript functionalities

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Javascript functionalities

    How to get number of related entities in account module and their details in js.

  • #2
    it depends, what contains your model
    what's view?

    Comment


    • #3
      I have a account, and it has two product linked with its relationship panel. I want to know the number or details of the products through codeing. What js code i have to write?

      Comment


      • #4
        in which one file? in which on method?

        possible
        Code:
        this.model.get('productsIds').length
        don't know if this relation is loaded. Print this.model in console and check attributes

        Comment


        • #5
          The file path is - client/src/views/record/detail.js

          this.model.get('productsIds').length -- This code showing error TypeError: this.model.get(...) is undefined
          Last edited by riju; 09-13-2017, 09:47 AM.

          Comment


          • tanya
            tanya commented
            Editing a comment
            do you change this file for the reason, you described above?

          • riju
            riju commented
            Editing a comment
            No. I just want the number of products linked with an account
        Working...
        X