www/includes/db_product.php

changeset 296
69fadd1aded2
parent 292
90cd3798edc2
child 299
047ead629d4a
equal deleted inserted replaced
295:cbace196bdbf 296:69fadd1aded2
430 'code' => $row['code'], 430 'code' => $row['code'],
431 'birth' => $row['birth'], 431 'birth' => $row['birth'],
432 'stage' => $row['stage'] 432 'stage' => $row['stage']
433 ); 433 );
434 } 434 }
435 header("Content-type: application/json");
435 echo json_encode($brews, JSON_UNESCAPED_UNICODE); 436 echo json_encode($brews, JSON_UNESCAPED_UNICODE);
436 return; 437 return;
437 } 438 }
438 439
439 if (isset($_GET['select']) && ($_GET['select'] == "archname")) { 440 if (isset($_GET['select']) && ($_GET['select'] == "archname")) {
449 'og' => $row['og'], 450 'og' => $row['og'],
450 'fg' => $row['fg'], 451 'fg' => $row['fg'],
451 'batch_size' => $row['batch_size'] 452 'batch_size' => $row['batch_size']
452 ); 453 );
453 } 454 }
454 syslog(LOG_NOTICE, json_encode($brews, JSON_UNESCAPED_UNICODE)); 455 header("Content-type: application/json");
455 echo json_encode($brews, JSON_UNESCAPED_UNICODE); 456 echo json_encode($brews, JSON_UNESCAPED_UNICODE);
456 return; 457 return;
457 } 458 }
458 459
459 if (isset($_GET['select']) && ($_GET['select'] == "archcode")) { 460 if (isset($_GET['select']) && ($_GET['select'] == "archcode")) {
469 'og' => $row['og'], 470 'og' => $row['og'],
470 'fg' => $row['fg'], 471 'fg' => $row['fg'],
471 'batch_size' => $row['batch_size'] 472 'batch_size' => $row['batch_size']
472 ); 473 );
473 } 474 }
475 header("Content-type: application/json");
474 echo json_encode($brews, JSON_UNESCAPED_UNICODE); 476 echo json_encode($brews, JSON_UNESCAPED_UNICODE);
475 return; 477 return;
476 } 478 }
477 479
478 if (isset($_GET['select']) && ($_GET['select'] == "archdate")) { 480 if (isset($_GET['select']) && ($_GET['select'] == "archdate")) {
489 'og' => $row['og'], 491 'og' => $row['og'],
490 'fg' => $row['fg'], 492 'fg' => $row['fg'],
491 'batch_size' => $row['batch_size'] 493 'batch_size' => $row['batch_size']
492 ); 494 );
493 } 495 }
496 header("Content-type: application/json");
494 echo json_encode($brews, JSON_UNESCAPED_UNICODE); 497 echo json_encode($brews, JSON_UNESCAPED_UNICODE);
495 return; 498 return;
496 } 499 }
497 500
498 /* 501 /*
508 'name' => $row['name'], 511 'name' => $row['name'],
509 'uuid' => $row['uuid'], 512 'uuid' => $row['uuid'],
510 'stage' => $row['stage'] 513 'stage' => $row['stage']
511 ); 514 );
512 } 515 }
516 header("Content-type: application/json");
513 echo json_encode($brews, JSON_UNESCAPED_UNICODE); 517 echo json_encode($brews, JSON_UNESCAPED_UNICODE);
514 return; 518 return;
515 } 519 }
516 520
517 /* 521 /*

mercurial