orchidsoftware / platform

Orchid is a @laravel package that allows for rapid application development of back-office applications, admin/user panels, and dashboards.
https://orchid.software
MIT License
4.26k stars 631 forks source link

Uncaught TypeError: Cannot read properties of null (reading 'value') #2806

Open Abdullajon8111 opened 4 months ago

Abdullajon8111 commented 4 months ago

Uncaught TypeError: Cannot read properties of null (reading 'value')

at orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:16:74061 at O (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:2:50262) at F.allowRequestToBeIntercepted (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:2:53795) at F.perform (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:2:52589) at D.start (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:2:57366) at ht.submitForm (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:16:17718) at Object.formSubmitted (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:16:32358) at U.submitBubbled (orchid.js?id=4b1e0fdeaa7520a732477f55e0e6a61e:2:61843)

image

Amineembarki commented 3 weeks ago

This error is coming from base.blade.php ==> @includeWhen(isset($state), 'platform::partials.state') and app.js ==> window.addEventListener("turbo:before-fetch-request", (event) => { let state = document.getElementById("screen-state").value;

if (state.length > 0) {
    event.detail?.fetchOptions?.body?.append("_state", state);
}

}); The $state is not yet set.