agilecrm / javascript-api

Javascript Connector for Agile
42 stars 15 forks source link

Add Note is not working #8

Open kapilkarda opened 8 years ago

kapilkarda commented 8 years ago

Hello

Please see the code _agile.create_contact({ "email": "Test@gmail.com", "first_name": "Test", "last_name": "New", "tags":"tag1" }, { success: function add_note() {

        console.log("Done");

        _agile.add_note({
            "subject": "How to test",
            "description": "Running"
          }, { success: function(data){ 
                  console.log(data);
                  console.log("contact created");
              }, error: function(err){
                console.log("data1");
                console.log(err);
              }
          });

      }, error: function(data){

      }
  });

this is not working, Please help me in that.

Thanks

graut commented 8 years ago

Hi,

You can try below code link code.

https://gist.github.com/graut/6ec022cd8161195101ff

Note : To add note to contact you need to set email. I have set email after contact created but you can set at the top also.

chathurangadw commented 6 years ago

how can we update existing note ?