diff --git a/public_html/assets/css/leftside-modal.css b/public_html/assets/css/leftside-modal.css index cd1be94..6a42d3c 100644 --- a/public_html/assets/css/leftside-modal.css +++ b/public_html/assets/css/leftside-modal.css @@ -102,28 +102,25 @@ /*------------------------------*/ - - - - - .close { - float: right; - font-size: 22.5px; - font-weight: bold; + z-index: 1; + position: absolute; + right: 10px; line-height: 1; + font-size: 75px; + font-weight: bold; color: #ffffff; text-shadow: 0 1px 0 #ffffff; - opacity: 0.2; - filter: alpha(opacity=20) + /* opacity: 0.2; */ + /* filter: alpha(opacity=20) */ } .close:hover,.close:focus { color: #ffffff; text-decoration: none; cursor: pointer; - opacity: 0.5; - filter: alpha(opacity=50) + /* opacity: 0.5; */ + /* filter: alpha(opacity=50) */ } button.close { @@ -214,8 +211,12 @@ button.close { } .modal-header { + display: flex; + align-items: center; + justify-content: space-between; + position: relative; padding: 15px; - border-bottom: 1px solid #e5e5e5 + border-bottom: 1px solid #e5e5e5; } #sidebar-left .modal-header { @@ -228,10 +229,18 @@ button.close { } .modal-title { + flex: none; + width: 300px !important; + text-align: left; + white-space: normal; + word-wrap: break-word; + overflow: visible; margin: 0; - line-height: 1.42857143 + line-height: 1.42857143; + padding-right: 60px; } + .modal-body { position: relative; padding: 20px diff --git a/public_html/assets/css/main.css b/public_html/assets/css/main.css index 64297ca..d8d5f36 100644 --- a/public_html/assets/css/main.css +++ b/public_html/assets/css/main.css @@ -1680,7 +1680,7 @@ table.table-search-report .tb-list th { pointer-events: auto; cursor: pointer; color:var(--color-sub); - font-size: 16px; + font-size: 30px; font-weight: 700; } @@ -1689,14 +1689,52 @@ table.table-search-report .tb-list th { } .point-overlay { - background-color:white; - width:350px; - z-index: 1000; - cursor:default; - pointer-events: auto; - padding:5px; - border-radius: 5px; position: relative; + background-color:white; + padding: 5px; + border-radius: 5px; + width: 350px; + user-select: none; + transform: none !important; + cursor:default; + position: relative; +} + +.address-row { + display: flex; + justify-content: space-between; + align-items: stretch; + padding: 0; + margin: 0; +} + +.address-title { + width: 40%; + padding: 5px 10px; + font-size: 14px; + font-weight: 500; + background-color: var(--color-sub); + color: #fff; + border-right: .5px solid #c9e0d3; + border-left: .5px solid #c9e0d3; + border-bottom: .5px solid #c9e0d3; + display: flex; + align-items: center; +} + +.address-content { + width: 60%; + padding: 5px 10px; + font-size: 14px; + color: #fff; + border-right: .5px solid #c9e0d3; + border-bottom: .5px solid #c9e0d3; + display: flex; + align-items: center; +} + +.address-link { + text-decoration: underline; } #popupMessage { diff --git a/public_html/assets/css/mapMAPCSS.css b/public_html/assets/css/mapMAPCSS.css index a2f9153..beedb74 100644 --- a/public_html/assets/css/mapMAPCSS.css +++ b/public_html/assets/css/mapMAPCSS.css @@ -469,8 +469,9 @@ .mapBtn{ border:none; color: #fff; - padding: 5px ; + padding: 15px ; border-radius: 5px; + font-size: 12px; } .btn-primary-modal{ background-color: #558B2F; diff --git a/public_html/assets/internal_api.php b/public_html/assets/internal_api.php index 9e95bed..379ce5b 100644 --- a/public_html/assets/internal_api.php +++ b/public_html/assets/internal_api.php @@ -84,7 +84,9 @@ class API extends CONF { IFNULL(DATE_FORMAT(tc.c_lastpickupdate,'%Y-%m-%d'),'') as c_lastpickupdate, IFNULL(DATE_FORMAT(tc.c_lastpaiddate,'%Y-%m-%d'),'') as c_lastpaiddate, IFNULL(tc.c_geolat,'') as lat, - IFNULL(tc.c_geolon,'') as lon + IFNULL(tc.c_geolon,'') as lon, + td.d_ruid, + td.r_note FROM (SELECT c_uid, @@ -110,17 +112,21 @@ class API extends CONF { FROM tbl_customer) tc, (SELECT - d_uid, - d_customeruid, - d_orderdate, - d_quantity, - d_estquantity, - d_ordertype, - d_driveruid, - d_createruid, - d_status + td.d_uid, + td.d_ruid, + tr.r_note, + td.d_customeruid, + td.d_orderdate, + td.d_quantity, + td.d_estquantity, + td.d_ordertype, + td.d_driveruid, + td.d_createruid, + td.d_status FROM - tbl_daily) td + tbl_daily td + LEFT OUTER JOIN tbl_request tr + ON td.d_ruid = tr.r_uid) td WHERE tc.c_uid = td.d_customeruid AND td.d_driveruid = ".(int)$_POST['driver']." @@ -190,6 +196,8 @@ class API extends CONF { "last_pickup_date" => $rstOptionPoint['c_lastpickupdate'], "last_paid_date" => $rstOptionPoint['c_lastpaiddate'], "duid" => $rstOptionPoint['d_uid'], + "druid" => $rstOptionPoint['d_ruid'], + "rnote" => $rstOptionPoint['r_note'], "orderFlag" => $orderFlag ); if(strlen($uidList) > 0){ @@ -943,6 +951,7 @@ class API extends CONF { try { $sqShortInfo = qry("SELECT + c_name, c_paymenttype, c_comment_ri, c_location @@ -984,6 +993,7 @@ class API extends CONF { $result = array( "id" => $_POST['id'], + "name" => $rstShortInfo['c_name'], "payment_type" => $rstShortInfo['c_paymenttype'], "paymentstring" => $d_paystatusSTR, "comment" => $rstShortInfo['c_comment_ri'], diff --git a/public_html/doc/export_process.php b/public_html/doc/export_process.php index 80f5bd9..58d7a63 100644 --- a/public_html/doc/export_process.php +++ b/public_html/doc/export_process.php @@ -13,7 +13,7 @@ echo""; //include getenv("DOCUMENT_ROOT")."/include/session_include.php"; -// Level 6 ϸ +// Level 6 ÀÌÇϸ¸ »ç¿ë °¡´É $func->checkLevelModal(7); @@ -94,7 +94,7 @@ if ($actionStr == "CUSTOMER") { $strData .= "".$rt_city['a_text']."\n"; } - else if /* 2025.06.11 ¥ ÷ YYYY-MM-DD */ + else if /* 2025.06.11 ³¯Â¥ °ü·Ã Ä÷³ YYYY-MM-DD ·Î º¯°æ */ (($export_customer[$ii] == 'c_form_eu') || ($export_customer[$ii] == 'c_form_corsia') || ($export_customer[$ii] == 'c_contractdate') || @@ -120,7 +120,7 @@ if ($actionStr == "CUSTOMER") { $strData .= "".$toDateStr."\n"; } - // 2025.06.11 Note ߰ + // 2025.06.11 Note Ãß°¡ else if ($export_customer[$ii] == 'n_customeruid') { $query_note = "SELECT * FROM tbl_note @@ -162,7 +162,7 @@ if ($actionStr == "CUSTOMER") { } } else if ($actionStr == "OILHISTORY") { - // Inactive Accounts ٿ޵ û (2024.04.19) + // Inactive Accounts µµ ´Ù¿î¹Þµµ·Ï ¿äû¹ÞÀ½ (2024.04.19) //$query = "SELECT * FROM tbl_customer // WHERE c_status = 'A' // ORDER BY c_accountno DESC "; @@ -241,7 +241,7 @@ if ($actionStr == "CUSTOMER") { $strData .= "".$rt_city['a_text']."\n"; } - else if /* 2025.06.11 ¥ ÷ YYYY-MM-DD */ + else if /* 2025.06.11 ³¯Â¥ °ü·Ã Ä÷³ YYYY-MM-DD ·Î º¯°æ */ (($export_oil[$ii] == 'c_form_eu') || ($export_oil[$ii] == 'c_form_corsia') || ($export_oil[$ii] == 'c_contractdate') || @@ -649,6 +649,187 @@ if ($actionStr == "CUSTOMER") { $list_number++; //if ($list_number == 100) break; } + + + +} else if ($actionStr == "FORECAST") { + $list_number = 1; + // For Excel Variable + $strData .= ""; + foreach ($forecastArray AS $key=>$value) + { + $strData .= "$value\n"; + } + $strData .= "\n"; + + if ($c_type_r == 'R') { + $orderdate = str_replace("-", "", $orderdate); + $qry_r = "SELECT * FROM tbl_request + WHERE r_driveruid ='$org_driveruid' AND r_status = 'A' AND r_requestdate = '$orderdate' + ORDER BY r_uid DESC"; + + $rt_r=$jdb->nQuery($qry_r, "list error"); + + while($list=mysqli_fetch_array($rt_r, MYSQLI_ASSOC)) { + for($i=0; $i $value ) + $$key = $value; + } + + $qry_rc = "SELECT * FROM tbl_customer WHERE c_uid = '$r_customeruid'"; + $rt_rc = $jdb->fQuery($qry_rc, "query error"); + + //echo "[$qry_rc]"; + for($i=0; $i $value ) + $$key = $value; + } + + $list_numberSTR = "R"; + $c_nameSTR = str_replace("\\", "", $c_name); + $c_addressSTR = str_replace("\\", "", $c_address); + $c_containerSTR = str_replace("\\", "", $c_container); + $c_lastpickupdateSTR = $func -> convertFormat ($c_lastpickupdate, 3); + $c_fullquantitydateSTR = $func -> convertFormat ($c_fullquantitydate, 3); + $c_fullquantityActual = round(floatval($c_fullquantity + ($dDiff * $c_fullquantitydaily))); + $c_fullquantitySTR = number_format($c_fullquantityActual); + $c_fullcycleSTR = $c_fullcycle; + $getThisYear = date("Y"); + $getLastYear = date("Y", strtotime('last year')); + + $qry_sum = "SELECT + SUM(CASE WHEN d_visitdate like '".$getThisYear."%' THEN d_quantity ELSE 0 END) AS THISYEAR, + SUM(CASE WHEN d_visitdate like '".$getLastYear."%' THEN d_quantity ELSE 0 END) AS LASTYEAR + FROM tbl_daily + WHERE d_customeruid = '".$r_customeruid."' AND d_status = 'F' "; + $rt_sum = $jdb->fQuery($qry_sum, "fetch query error"); + + $getThisYearQ = number_format(floatval($rt_sum['THISYEAR'])); + $getLastYearQ = number_format(floatval($rt_sum['LASTYEAR'])); + + // For Excel Data + $strData .= ""; + + foreach ($forecastArray AS $key=>$value) { + $strData .= "".$$key."\n"; + } + + $strData .= "\n"; + } + } + if ($c_type_p == 'P') { + $getWeekDay = strtoupper(date('D', strtotime($orderdate))); + $orderdate = str_replace("-", "", $orderdate); + + $qry_s = "SELECT * FROM tbl_customer + WHERE c_driveruid ='$org_driveruid' AND c_status = 'A' + AND (c_schedulebasic = '$orderdate' OR (c_schedule = '1W' AND c_scheduleday LIKE '%".$getWeekDay."%')) + ORDER BY c_uid DESC"; + + $rt_s=$jdb->nQuery($qry_s, "list error"); + + while($list=mysqli_fetch_array($rt_s, MYSQLI_ASSOC)) { + for($i=0; $i $value ) + $$key = $value; + } + + $list_numberSTR = "S"; + $c_nameSTR = str_replace("\\", "", $c_name); + $c_addressSTR = str_replace("\\", "", $c_address); + $c_containerSTR = str_replace("\\", "", $c_container); + $c_lastpickupdateSTR = $func -> convertFormat ($c_lastpickupdate, 3); + $c_fullquantitydateSTR = $func -> convertFormat ($c_fullquantitydate, 3); + $c_fullquantityActual = round(floatval($c_fullquantity + ($dDiff * $c_fullquantitydaily))); + $c_fullquantitySTR = number_format($c_fullquantityActual); + $c_fullcycleSTR = $c_fullcycle; + $getThisYear = date("Y"); + $getLastYear = date("Y", strtotime('last year')); + + $qry_sum = "SELECT + SUM(CASE WHEN d_visitdate like '".$getThisYear."%' THEN d_quantity ELSE 0 END) AS THISYEAR, + SUM(CASE WHEN d_visitdate like '".$getLastYear."%' THEN d_quantity ELSE 0 END) AS LASTYEAR + FROM tbl_daily + WHERE d_customeruid = '".$c_uid."' AND d_status = 'F' "; + $rt_sum = $jdb->fQuery($qry_sum, "fetch query error"); + + $getThisYearQ = number_format(floatval($rt_sum['THISYEAR'])); + $getLastYearQ = number_format(floatval($rt_sum['LASTYEAR'])); + + // For Excel Data + $strData .= ""; + + foreach ($forecastArray AS $key=>$value) { + $strData .= "".$$key."\n"; + } + + $strData .= "\n"; + } + } + + // query + $query = "SELECT * FROM tbl_customer + WHERE c_uid <> '' AND c_status = 'A' " . $orderflagQRY. $driveruidQRY . $typeQRY . $add_srchquery . $newaccountQRY . $dormantaccountQRY . $fullcycleQRY . $fullquantityQRY . $containerQRY . $areaQRY . + $add_query_order . $add_query; + + $result=$jdb->nQuery($query, "list error"); + + while($list=mysqli_fetch_array($result, MYSQLI_ASSOC)) { + for($i=0; $i $value ) + $$key = $value; + } + + if ($c_schedule == 'Will Call') { + $list_numberSTR = "W"; + } + else if ($c_schedule != 'Will Call' && $c_schedule != 'None' ) { + $list_numberSTR = "S"; + } + else { + $list_numberSTR = $list_number; + } + $c_nameSTR = str_replace("\\", "", $c_name); + $c_addressSTR = str_replace("\\", "", $c_address); + $c_containerSTR = str_replace("\\", "", $c_container); + $c_lastpickupdateSTR = $func -> convertFormat ($c_lastpickupdate, 3); + $c_fullquantitydateSTR = $func -> convertFormat ($c_fullquantitydate, 3); + $c_fullquantityActual = round(floatval($c_fullquantity + ($dDiff * $c_fullquantitydaily))); + $c_fullquantitySTR = number_format($c_fullquantityActual); + if ($c_fullcycleflag == 1) { + $c_fullcycleSTR = $c_fullcycleforced; + } + else { + $c_fullcycleSTR = $c_fullcycle; + } + + // year sum + $qry_sum = "SELECT + SUM(CASE WHEN d_visitdate like '".$getThisYear."%' THEN d_quantity ELSE 0 END) AS THISYEAR, + SUM(CASE WHEN d_visitdate like '".$getLastYear."%' THEN d_quantity ELSE 0 END) AS LASTYEAR + FROM tbl_daily + WHERE d_customeruid = '".$c_uid."' AND d_status = 'F' "; + $rt_sum = $jdb->fQuery($qry_sum, "fetch query error"); + + $getThisYearQ = number_format(floatval($rt_sum['THISYEAR'])); + $getLastYearQ = number_format(floatval($rt_sum['LASTYEAR'])); + + // For Excel Data + $strData .= ""; + + foreach ($forecastArray AS $key=>$value) { + $strData .= "".$$key."\n"; + } + + $strData .= "\n"; + $list_number++; + } + + + } addLog ("add", "EXPORT", $actionStr, $_SESSION['ss_ID'], $query, ""); diff --git a/public_html/doc/forecast_list.php b/public_html/doc/forecast_list.php index f43c6a1..38cce93 100644 --- a/public_html/doc/forecast_list.php +++ b/public_html/doc/forecast_list.php @@ -921,10 +921,45 @@ $(document).ready(function(){
-
- Will Call - Scheduled - Request +
+
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ Will Call + Scheduled + Request +
diff --git a/public_html/doc/map.php b/public_html/doc/map.php index ca71b97..3e7a136 100644 --- a/public_html/doc/map.php +++ b/public_html/doc/map.php @@ -404,9 +404,15 @@ function popup(){ - Sludge + Sludge (%) - + +
+ + + +
+ @@ -598,6 +604,10 @@ function popup(){ + + + + @@ -1639,6 +1649,8 @@ function popup(){ lastPickupDate: json.result[i]['last_pickup_date'], lastPaidDate: json.result[i]['last_paid_date'], duid: json.result[i]['duid'], + druid: json.result[i]['druid'], + rnote: json.result[i]['rnote'], orderFlag: json.result[i]['orderFlag'] @@ -1970,7 +1982,7 @@ function popup(){ } function showShortInfo(id){ - + let loadingTxt = 'Loading...'; jQuery("#customerShortInfo .shortinfo-payment-type").text(loadingTxt); jQuery("#customerShortInfo #c_comment_ri,#customerShortInfo #c_location").val(loadingTxt).attr("disabled","disabled"); @@ -1986,6 +1998,7 @@ function popup(){ var rstInqShortInfo = function(json) { jQuery("#customerShortInfo .c_uid").val(json.result['id']); + jQuery("#customerShortInfo .shortinfo-store-name").text(json.result['name']); jQuery("#customerShortInfo .shortinfo-payment-type").text(json.result['payment_type']); jQuery("#customerShortInfo .shortinfo-payment-string").text(json.result['paymentstring']); jQuery("#customerShortInfo #c_comment_ri").val(json.result['comment']).attr("disabled",false); @@ -2126,7 +2139,7 @@ function popup(){ - + @@ -2134,14 +2147,6 @@ function popup(){ ${property.phone} - - - - -
Restaurant NameName
Payment Type Cheque ${property.rate}
Phone
Address - ${property.address} - -
Forecast @@ -2161,21 +2166,33 @@ function popup(){
+ +
+
Address
+ +

- - `; + + `; if(`${property.date}` === 'null') { - innerHtml += ``; - innerHtml += ``; + innerHtml += ``; + innerHtml += ``; }else{ - innerHtml += ``; - innerHtml += ``; + innerHtml += ``; + innerHtml += ``; } - innerHtml += ` - - + innerHtml += ` + +
@@ -2199,4 +2216,27 @@ function popup(){ jQuery(".loading-overlay").css("display","none"); } + + + \ No newline at end of file diff --git a/public_html/include/arrayinfo.php b/public_html/include/arrayinfo.php index c7d100b..4102412 100644 --- a/public_html/include/arrayinfo.php +++ b/public_html/include/arrayinfo.php @@ -1,5 +1,6 @@ 'Inactive', 'A' => 'Active', 'H' => 'Hold', 'D' => 'Delete', 'F' => 'Finish' ); $arrPaymenttype = array ('CA' => 'Cash', 'CHQ' => 'Cheque', 'DIRECT' => 'Direct Deposit', 'DONATION' => 'Donation', 'EFT' => 'EFT', @@ -78,4 +79,22 @@ $receiptArray = array( "d_visitdateSTR"=>"Date", "d_nameSTR"=>"Restaurant Name", "d_accountnoSTR"=>"Account No", "d_addressSTR"=>"Address", "d_driverSTR"=>"Driver", "d_quantity"=>"Oil Quantity", "d_payamount"=>"Paid" ); + +$forecastArray = array( + "list_numberSTR"=>"No" + , "c_nameSTR"=>"Restaurant Name" + , "c_accountno"=>"Account" + , "c_maincontainer"=>"Container" + , "c_containerSTR"=>"Detail" + , "c_paymenttype"=>"Payment" + , "c_rate"=>"Rate" + , "c_addressSTR"=>"Address" + , "c_city"=>"City" + , "getLastYearQ"=>$yearLast + , "getThisYearQ"=>$yearNow + , "c_fullcycleSTR"=>"Cycle" + , "c_mainvolume"=>"Main Vol." + , "c_lastpickupdateSTR"=>"Last PU" + , "c_fullquantitySTR"=>"Liter" + ); ?> \ No newline at end of file