Tryag File Manager
Home
||
Turbo Force
||
B-F Config_Cpanel
Current Path :
/
home
/
ltman.eemo.co.kr
/
public_html
/
www
/
Or
Select Your Path :
Upload File :
New :
File
Dir
/home/ltman.eemo.co.kr/public_html/www/farm_feed_banpum_do.php
<? session_cache_limiter('no-cache, must-revalidate'); session_start(); header("Pragma: no-cache"); header("Cache-Control: no-cache,must-revalidate"); header("Content-Type: text/html; charset=utf-8"); include_once("dbconn.php"); include_once("lib.php"); foreach($_GET as $key => $value) { ${$key}=mysql_real_escape_string(trim($value)); } foreach($_POST as $key => $value) { ${$key}=mysql_real_escape_string(trim($value)); } $arr_rst=array(); $vv2=str_replace("-","",$farm_code); $is_rs=RS("select * from farm_feed_banpum_log where parts_no='$parts_no' and req_date='$jdate' "); if($is_rs[is_chk]==1) { $arr_rst['rst']='is_chk'; echo json_encode($arr_rst); exit; } $rs_parts=RS("select * from farm_contract_parts where no='$parts_no' "); $rs_contract=RS("select * from farm_contract where no='{$rs_parts[contract_no]}' "); $rs_feed_com=RS("select * from feed_company where no='{$rs_contract[feed_company_no]}' "); if(!$is_rs[no]) { $query="insert into farm_feed_banpum_log set farm_no='{$rs_parts[farm_no]}', parts_no='$parts_no', contract_no='{$rs_parts[contract_no]}', company_no='{$rs_contract[contractor_company_no]}', req_date='$jdate', feed_company_no='{$rs_contract[feed_company_no]}', feed_gubun='$feed_gubun', banpum_ton='$banpum_ton', banpum_gubun='$banpum_gubun', is_result='1', feed_product_no='$feed_gubun', regdate=now() "; mysql_query($query) or die(mysql_error()); } else { /* $query="update farm_feed_banpum_log set feed_gubun='$feed_gubun', banpum_ton='$banpum_ton', banpum_gubun='$banpum_gubun' where parts_no='$parts_no' and req_date='$jdate' "; mysql_query($query) or die(mysql_error()); */ $arr_rst['rst']='is_chk'; echo json_encode($arr_rst); exit; } $arr_rst['rst']='1'; echo json_encode($arr_rst); ?>