diff --git a/client/dist/js/bundle.js b/client/dist/js/bundle.js index 62990d4..7c53762 100644 --- a/client/dist/js/bundle.js +++ b/client/dist/js/bundle.js @@ -1 +1 @@ -!function(e){function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}var t={};n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s="./client/src/bundles/bundle.js")}({"./client/src/boot/index.js":function(e,n,t){"use strict";window.document.addEventListener("DOMContentLoaded",function(){})},"./client/src/bundles/bundle.js":function(e,n,t){"use strict";t("./client/src/legacy/hasonefield.js"),t("./client/src/boot/index.js")},"./client/src/legacy/hasonefield.js":function(e,n,t){"use strict";var i=t(0);(function(e){return e&&e.__esModule?e:{default:e}})(i).default.entwine("ss",function(e){e.entwine("ss",function(e){e(".grid-field.hasonebutton .add-existing-autocompleter .action_gridfield_relationadd").entwine({onclick:function(e){this._super(e),grid_field=this.getGridField(),grid_field.reload()}})})})},0:function(e,n){e.exports=jQuery}}); \ No newline at end of file +!function(e){function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}var t={};n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s="./client/src/bundles/bundle.js")}({"./client/src/boot/index.js":function(e,n,t){"use strict";window.document.addEventListener("DOMContentLoaded",function(){})},"./client/src/bundles/bundle.js":function(e,n,t){"use strict";t("./client/src/legacy/hasonefield.js"),t("./client/src/boot/index.js")},"./client/src/legacy/hasonefield.js":function(e,n,t){"use strict";var i=t(0);(function(e){return e&&e.__esModule?e:{default:e}})(i).default.entwine("ss",function(e){e(".grid-field.hasonebutton .add-existing-autocompleter .action_gridfield_relationadd").entwine({onclick:function(e){this._super(e),this.getGridField().reload()}})})},0:function(e,n){e.exports=jQuery}}); \ No newline at end of file diff --git a/client/src/legacy/hasonefield.js b/client/src/legacy/hasonefield.js index 1fc21fe..3affbc9 100644 --- a/client/src/legacy/hasonefield.js +++ b/client/src/legacy/hasonefield.js @@ -2,15 +2,13 @@ import jQuery from 'jquery'; jQuery.entwine('ss', ($) => { - $.entwine('ss', function($) { - // Covers both tabular delete button, and the button on the detail form - $('.grid-field.hasonebutton .add-existing-autocompleter .action_gridfield_relationadd').entwine({ - onclick: function(e) { - this._super(e); + // Covers both tabular delete button, and the button on the detail form + $('.grid-field.hasonebutton .add-existing-autocompleter .action_gridfield_relationadd').entwine({ + onclick: function(e) { + this._super(e); - grid_field = this.getGridField(); - grid_field.reload(); - } - }); + let grid_field = this.getGridField(); + grid_field.reload(); + } }); });