删除这条记录,真的确定不再需要了吗?
- 内容介绍
- 文章标签
- 相关推荐
本文共计181个文字,预计阅读时间需要1分钟。
javascript// api-1099208_00.js{ app: 1, record: 1, comment: 1 }
// api-1099208_01.js
// api-1099208_02.jsvar body={ app: 1, record: 1001, comment: 1 };kintone.api(kintone.api.url('/k/v1/record/comment', true), 'DELETE', body, function(resp) { });
{ "app": 1, "record": 1, "comment": 1 } api-1099208_01.js
{} api-1099208_02.js
var body = { "app": 1, "record": 1001, "comment": 1 }; kintone.api(kintone.api.url('/k/v1/record/comment', true), 'DELETE', body, function(resp) { //success console.log(resp); }, function(error) { //error console.log(error); }); api-1099208_03.js
var body = { "app": 1, "record": 1001, "comment": 1, // CSRF TOKEN: 在kintone执行API(POST, PUT, DELETE)时需要设置 "__REQUEST_TOKEN__": kintone.getRequestToken() }; var url = '{subdomain}.cybozu.com/k/v1/record/comment.json'; var xhr = new XMLHttpRequest(); xhr.open('DELETE', url); xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); xhr.setRequestHeader('Content-Type', 'application/json'); xhr.onload = function() { if (xhr.status === 200) { // success console.log(JSON.parse(xhr.responseText)); } else { // error console.log(JSON.parse(xhr.responseText)); } }; xhr.send(JSON.stringify(body));
本文共计181个文字,预计阅读时间需要1分钟。
javascript// api-1099208_00.js{ app: 1, record: 1, comment: 1 }
// api-1099208_01.js
// api-1099208_02.jsvar body={ app: 1, record: 1001, comment: 1 };kintone.api(kintone.api.url('/k/v1/record/comment', true), 'DELETE', body, function(resp) { });
{ "app": 1, "record": 1, "comment": 1 } api-1099208_01.js
{} api-1099208_02.js
var body = { "app": 1, "record": 1001, "comment": 1 }; kintone.api(kintone.api.url('/k/v1/record/comment', true), 'DELETE', body, function(resp) { //success console.log(resp); }, function(error) { //error console.log(error); }); api-1099208_03.js
var body = { "app": 1, "record": 1001, "comment": 1, // CSRF TOKEN: 在kintone执行API(POST, PUT, DELETE)时需要设置 "__REQUEST_TOKEN__": kintone.getRequestToken() }; var url = '{subdomain}.cybozu.com/k/v1/record/comment.json'; var xhr = new XMLHttpRequest(); xhr.open('DELETE', url); xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); xhr.setRequestHeader('Content-Type', 'application/json'); xhr.onload = function() { if (xhr.status === 200) { // success console.log(JSON.parse(xhr.responseText)); } else { // error console.log(JSON.parse(xhr.responseText)); } }; xhr.send(JSON.stringify(body));

