Announcement

Collapse
No announcement yet.

create custom entity not working!

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

  • create custom entity not working!

    Hi,
    i have follow the "how-to-create-custom-entity" guide from http://blog.espocrm.com/development/...custom-entity/
    but it seems not working! i have recheck myself to see i didn't miss something but all have done as the guide.

    i have espocrm 2.5 version.


  • #2
    Hi

    At least a few people created their custom entities following the guide.
    Check what's in log (data/logs) and what's in browser console.

    Comment


    • #3
      [2014-09-06 05:14:50] Espo.ERROR: Json::decode():Syntax error, malformed JSON [] []
      [2014-09-06 06:08:50] Espo.ERROR: Json::decode():Syntax error, malformed JSON [] []
      [2014-09-06 06:09:18] Espo.ERROR: Json::decode():Syntax error, malformed JSON [] []
      [2014-09-06 06:09:33] Espo.ERROR: Json::decode():Syntax error, malformed JSON [] []

      here is the error but where is the Syntax error? why the log not give you the file that the error is there?

      Thanks

      Comment


      • #4
        Your json is invalid. Maybe ending comma.

        It's not a commercial application to ask "why not this does something". Correct to say: "It would be better if it will do something".
        Last edited by yuri; 09-06-2014, 07:03 AM.

        Comment


        • #5
          Hi yuri,
          i found my problem! now all works great.
          i just don't understand why we need to create task project?
          ​i want to use the core task, how can i make relationship between projects and core task? i want to be able to select the project in the "create task" Parent field.

          Thanks

          Comment


          • #6
            See how it's defined for Account - Task relationship and then replicate.

            metadata >> entityDefs >> Task
            fields >> parent >> options
            Add Project to the array

            metadata >> entityDefs >> Project
            links >> tasks
            {
            'type': 'hasChildren',
            'foreign': 'parent',
            'entity': 'Task'
            }



            Comment

            Working...
            X