Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

1 line
6.2KB

  1. (self.webpackChunk=self.webpackChunk||[]).push([[945],{85201:(t,e,n)=>{"use strict";n(34569)},34569:(t,e,n)=>{n(83710),n(41539),n(39714),n(69826),n(74916),n(23123),n(82772),n(57327),n(69600),n(15306),$(document).ready((function(){!function(){var t=document.querySelectorAll('.custom-switch input[type="checkbox"]');for(i=0;i<t.length;i++)t[i].addEventListener("change",(function(){var t=this,e=this.checked,n=!e,o=this.closest(".custom-switch").dataset.url+"&newValue="+e.toString(),c=$.ajax({type:"POST",url:o,data:{},dataType:"json"});c.done((function(t){SovNotification.add("success","La propriété a bien été mise à jour.")})),c.fail((function(){t.checked=n,t.disabled=!0,t.closest(".checkbox-switch").classList.add("disabled"),SovNotification.add("error","Une erreur est survenue.")}))}))}(),function(){var t=$(".content-header-title > .title").html();$(document).on("click",".deselect-batch-button",(function(){$(this).closest(".content").find(":checkbox.form-batch-checkbox-all").prop("checked",!1).trigger("change")})),$(document).on("change",".form-batch-checkbox-all",(function(){$(this).closest(".content").find(":checkbox.form-batch-checkbox").prop("checked",$(this).prop("checked")).trigger("change")})),$(document).on("change",".form-batch-checkbox",(function(){var e=$(this).closest(".content-wrapper"),n=e.find(":hidden#batch_form_entityIds"),o=n.val()?n.val().split(","):[],c=$(this).val();$(this).prop("checked")?($(this).closest("tr").addClass("selected-row"),-1===o.indexOf(c)&&o.push(c)):($(this).closest("tr").removeClass("selected-row"),o=o.filter((function(t){return t!==c})),e.find(":checkbox.form-batch-checkbox-all").prop("checked",!1)),0===o.length?(e.find(".global-actions").show(),e.find(".batch-actions").hide(),e.find("table").removeClass("table-batch")):(e.find(".batch-actions").show(),e.find(".global-actions").hide(),e.find("table").addClass("table-batch")),n.val(o.join(",")),e.find(".content-header-title > .title").html(0===o.length?t:"")}));var e=$("#batch-action-confirmation-title"),n=e.text();$("[data-action-batch]").on("click",(function(t){t.preventDefault(),t.stopPropagation();var o=$(this),c=o.attr("data-action-name"),i=$('input[type="checkbox"].form-batch-checkbox:checked');e.text(n.replace("%action_name%",c).replace("%num_items%",i.length)),$("#modal-batch-action").modal({backdrop:!0,keyboard:!0}).off("click","#modal-batch-action-button").on("click","#modal-batch-action-button",(function(){o.unbind("click"),$form=document.createElement("form"),$form.setAttribute("action",o.attr("data-action-url")),$form.setAttribute("method","POST"),$actionNameInput=document.createElement("input"),$actionNameInput.setAttribute("type","hidden"),$actionNameInput.setAttribute("name","batchActionName"),$actionNameInput.setAttribute("value",o.attr("data-action-name")),$form.appendChild($actionNameInput),$entityFqcnInput=document.createElement("input"),$entityFqcnInput.setAttribute("type","hidden"),$entityFqcnInput.setAttribute("name","entityFqcn"),$entityFqcnInput.setAttribute("value",o.attr("data-entity-fqcn")),$form.appendChild($entityFqcnInput),$actionUrlInput=document.createElement("input"),$actionUrlInput.setAttribute("type","hidden"),$actionUrlInput.setAttribute("name","batchActionUrl"),$actionUrlInput.setAttribute("value",o.attr("data-action-url")),$form.appendChild($actionUrlInput),$csrfTokenInput=document.createElement("input"),$csrfTokenInput.setAttribute("type","hidden"),$csrfTokenInput.setAttribute("name","batchActionCsrfToken"),$csrfTokenInput.setAttribute("value",o.attr("data-action-csrf-token")),$form.appendChild($csrfTokenInput),i.each((function(t,e){$entityIdInput=document.createElement("input"),$entityIdInput.setAttribute("type","hidden"),$entityIdInput.setAttribute("name","batchActionEntityIds[".concat(t,"]")),$entityIdInput.setAttribute("value",e.value),$form.appendChild($entityIdInput)})),document.body.appendChild($form),$form.submit()}))}))}(),$("#filters_form_reset").val(""),$(".lc-reset-filters").on("click",(function(t){$(this).parents(".table-filters-line").find("select,input").val("").trigger("change"),$("#filters_form_reset").val("clearAll"),Tools.log($(this).prop("form")),$(this).prop("form").submit()}))}))},19670:(t,e,n)=>{var o=n(70111);t.exports=function(t){if(!o(t))throw TypeError(String(t)+" is not an object");return t}},19781:(t,e,n)=>{var o=n(47293);t.exports=!o((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},80317:(t,e,n)=>{var o=n(17854),c=n(70111),i=o.document,r=c(i)&&c(i.createElement);t.exports=function(t){return r?i.createElement(t):{}}},47293:t=>{t.exports=function(t){try{return!!t()}catch(t){return!0}}},17854:(t,e,n)=>{var o=function(t){return t&&t.Math==Math&&t};t.exports=o("object"==typeof globalThis&&globalThis)||o("object"==typeof window&&window)||o("object"==typeof self&&self)||o("object"==typeof n.g&&n.g)||function(){return this}()||Function("return this")()},64664:(t,e,n)=>{var o=n(19781),c=n(47293),i=n(80317);t.exports=!o&&!c((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},70111:t=>{t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},3070:(t,e,n)=>{var o=n(19781),c=n(64664),i=n(19670),r=n(57593),a=Object.defineProperty;e.f=o?a:function(t,e,n){if(i(t),e=r(e,!0),i(n),c)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},57593:(t,e,n)=>{var o=n(70111);t.exports=function(t,e){if(!o(t))return t;var n,c;if(e&&"function"==typeof(n=t.toString)&&!o(c=n.call(t)))return c;if("function"==typeof(n=t.valueOf)&&!o(c=n.call(t)))return c;if(!e&&"function"==typeof(n=t.toString)&&!o(c=n.call(t)))return c;throw TypeError("Can't convert object to primitive value")}},69826:(t,e,n)=>{"use strict";var o=n(82109),c=n(42092).find,i=n(51223),r="find",a=!0;r in[]&&Array(1).find((function(){a=!1})),o({target:"Array",proto:!0,forced:a},{find:function(t){return c(this,t,arguments.length>1?arguments[1]:void 0)}}),i(r)},83710:(t,e,n)=>{var o=n(31320),c=Date.prototype,i="Invalid Date",r="toString",a=c.toString,u=c.getTime;new Date(NaN)+""!=i&&o(c,r,(function(){var t=u.call(this);return t==t?a.call(this):i}))}},t=>{"use strict";t.O(0,[817,571],(()=>{return e=85201,t(t.s=e);var e}));t.O()}]);