Skip to content

Commit

Permalink
Merge pull request #335 from ChavanAnkitaMahesh/Bug154085
Browse files Browse the repository at this point in the history
Bug fix 334 :Created multiple record entries in DB while creating type items if Auto Save enabled in UCM Type.
  • Loading branch information
ankush-maherwal authored Jan 13, 2020
2 parents ad09a06 + ddb9da2 commit 768464e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/com_tjucm/media/js/core/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,15 @@ com_tjucm.Services.Base = Class.extend({

config.contentType = typeof config.contentType != "undefined" ? config.contentType : 'application/x-www-form-urlencoded; charset=UTF-8';
config.processData = typeof config.processData != "undefined" ? config.processData : true;
config.async = typeof config.async != "undefined" ? config.async : true;

return jQuery.ajax({
type: "POST",
url: url,
data: data,
contentType: config.contentType,
processData: config.processData,
async: config.async,
headers: config.headers,
beforeSend: function () {
},
Expand Down
1 change: 1 addition & 0 deletions src/components/com_tjucm/media/js/services/item.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ com_tjucm.Services.Item = new (com_tjucm.Services.Base.extend({
create: function (ucmTypeData, callback){
this.config.processData = false;
this.config.contentType = false;
this.config.async = false;
this.post(this.createNewRecordUrl, ucmTypeData, this.config, callback);
},
saveFieldData: function (ucmFormData, callback) {
Expand Down

0 comments on commit 768464e

Please sign in to comment.