1(self.webpackChunk=self.webpackChunk||[]).push([[8716],{84048:(e,t,a)=>{var i=a(74692);function n(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=i("#loader");if(e){if(t.length){var a=i(t.html());i("body").append(a),console.log(a),setTimeout(()=>{a.removeClass("hidden")},5)}}else i(".loader-overlay").addClass("hidden")}i(".personalData").each(function(){i(this).parent().hide()}),i(".isAnonymous").on("change",function(){i(this).is(":checked")?i(this).parent().parent().parent().find(".personalData").parent().show():i(this).parent().parent().parent().find(".personalData").parent().hide()}),i(".multiple-select").on("change",function(){var e=i(this).attr("id"),t=i(this).parent().children().last().attr("id"),a=[];i("#"+e+" > option:selected").each(function(){a.push(i(this).val())}),a=a.filter(Boolean),answersJSON=JSON.stringify(a),i("#"+t).val(answersJSON)}),i(".radio-input").on("change",function(){var e=i(this).attr("id"),t=i(this).parent().children().last().attr("id"),a=i("input[name="+e+"]:checked").val();i("#"+t).val(a)}),i(".checkbox-input").on("change",function(){var e=i(this).attr("id"),t=i(this).parent().children().last().attr("id"),a=[];i("input[name="+e+"]:checked").each(function(){a.push(i(this).val())}),a=a.filter(Boolean),answersJSON=JSON.stringify(a),i("#"+t).val(answersJSON)}),i(".hasParent").each(function(){i(this).parent().hide()}),i(".hasChildren").on("change",function(){var e=i(this).closest("form").attr("id");fetch("/form/"+e+"/rodzice").then(e=>e.json()).then(e=>{if(e){var t=i(this).attr("id"),a=t.slice(0,t.indexOf("-"));if("radio"==a)this.thisElementValue=i("input[name=".concat(t,"]:checked")).val();else if("checkbox"==a){var n=i("input[name=".concat(t,"]:checked")).each(function(){i(this).val()});for(var l of(this.thisElementValue=[],n))this.thisElementValue.push(l.value)}else this.thisElementValue=i(this).val();console.log("Pobrano rodziców dla formularza."),null!==e?function(e,t,a,n){if(!n[e])return!1;for(childName in n[e].children){var l=n[e].children[childName];if("select"===a||"radio"===a){var r=!1;for(childAnswer in l)t===l[childAnswer]&&(r=!0);r?i("#"+childName).parent().show():i("#"+childName).parent().hide()}else if("multipleSelect"===a||"checkbox"===a){var s=0;for(var o in l){var c=l[o];(t.includes(c)||"Brak"==c&&""!=t[0])&&s++}Object.keys(l).length===s?i("#"+childName).parent().show():i("#"+childName).parent().hide()}else"text"===a&&(""==i("#"+e).val()||null==i("#"+e).val()?i("#"+childName).parent().hide():i("#"+childName).parent().show())}}(t,this.thisElementValue,a,e):console.log("WystÄ
piÅ bÅÄ
d przy pobieraniu rodziców dla formularza.")}else console.log("WystÄ
piÅ bÅÄ
d przy pobieraniu rodziców dla formularza.")})}),i(document).on("submit",'form[name="questionnaire"]',function(e){e.preventDefault(),i("input").removeClass("is-invalid"),i("input").nextAll(".invalid-feedback").remove(),i("select").removeClass("is-invalid"),i("select").nextAll(".invalid-feedback").remove(),i("div").removeClass("is-invalid"),i("div").nextAll(".invalid-feedback").remove();var t=i(this).closest("form"),a=new FormData(i(t)[0]),l=t.attr("action"),r=window.location.protocol+"//"+window.location.host+l;n(!0),fetch(r,{method:"POST",body:a}).then(e=>e.json()).then(e=>{if(console.log("wysyÅka"),alertSuccess=i("#response-"+i(t).attr("id")+" > .alert-success"),alertDanger=i("#response-"+i(t).attr("id")+" > .alert-danger"),i(alertSuccess).hide(),i(alertDanger).hide(),"success"==e.status)i(".questionnaire").trigger("reset"),i(alertSuccess).show(),i(alertSuccess).text(e.message),-1===(a=i(location).attr("href")).lastIndexOf("#")?window.location.href=a+"#"+i(t).attr("id"):window.location.href=a;else if("error"==e.status){var a=i(location).attr("href");for(var[n,l]of(-1===a.lastIndexOf("#")?window.location.href=a+"#"+i(t).attr("id"):window.location.href=a,i(alertDanger).show(),i(alertDanger).text(e.message),Object.entries(e.errors)))n.includes("multipleSelect-")||n.includes("select-")?input=t.find("select[id*='".concat(n,"']")):n.includes("checkbox-")||n.includes("radio")?input=t.find("div[id*='".concat(n,"']")):n.includes("file")?input=t.find("input[id*='".concat(n,"']")):input=t.find("input[name*='".concat(n,"']")),i(input).addClass("is-invalid"),i(input).after('<div class="invalid-feedback d-block">'.concat(l,"</div>"))}}).finally(()=>{n(!1)})})}},e=>{e.O(0,[4692],()=>{return t=84048,e(e.s=t);var t});e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.