| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- console.log('test1... DBG:', DBG)
- if (!URL_FETCH_TEST) {
- throw "Brak zmiennej URL_FETCH_TEST"
- }
- // Documentation: https://github.com/github/fetch
- fetch(URL_FETCH_TEST, {
- credentials: 'same-origin'
- })
- .then(function parseJSON(response) {
- return response.json()
- })
- .then(function(data) {
- //$( ".container" ).append( data.body.view );
- console.log('request succeeded with JSON response', data)
- }).catch(function(error) {
- console.log('request failed', error)
- })
- fetch(URL_FETCH_TEST_KRS, {
- credentials: 'same-origin'
- })
- .then(function parseJSON(response) {
- return response.json()
- })
- .then(function(data) {
- console.log('request succeeded with JSON response', data)
- }).catch(function(error) {
- console.log('request failed', error)
- })
- fetch(URL_FETCH_TEST_CEIDG, {
- credentials: 'same-origin'
- })
- .then(function parseJSON(response) {
- return response.json()
- })
- .then(function(data) {
- console.log('request succeeded with JSON response', data)
- }).catch(function(error) {
- console.log('request failed', error)
- })
- fetch(URL_FETCH_PRACOWNICY, {
- credentials: 'same-origin'
- })
- .then(function parseJSON(response) {
- return response.json()
- })
- .then(function(data) {
- $( ".container-bi_audit_raport" ).append( data.body.view );
- console.log('request succeeded with JSON response', data)
- }).catch(function(error) {
- console.log('request failed', error)
- })
- function checkAll() {
- $('#checkAll').change(function(){
- console.log('checkeddd');
- var checkboxes = $('form').find(':checkbox');
- if($(this).prop('checked')) {
- checkboxes.prop('checked', true);
- } else {
- checkboxes.prop('checked', false);
- }
- });
- }
- $(document).ready(function(){
- checkAll();
- });
- global.checkAll = checkAll;
|