Update document using REST API

Hi, I wanted to updated the document using frappe PUT call, here is the code

frappe.ui.form.on("[doc]", "on_submit", function(frm,cdt, cdn) {
var docData = {};
docData.field = "Test";    
    		url: "/api/resource/[doc]/"+docData.name,
    		type: "PUT",
    		args: {
    			data : docData
    		callback: function(r) {

In this response, following messages popup “Not allowed to change field after submission”

P.S. Document Permission is set “Is Submitable”


I had to mark that field as Allow on Submit.