From d09b5d831d4c6f9481db3ccb4ca9d48f12e05c5b Mon Sep 17 00:00:00 2001 From: iotcat Date: Fri, 20 Sep 2019 18:01:06 +0800 Subject: [PATCH] auto update --- yimian/.viminfo | 238 +++++++++++----------- yimian/www/settlement/api/getWeekData.php | 2 +- yimian/www/settlement/api/index.php | 2 +- yimian/www/settlement/func/functions.php | 8 +- 4 files changed, 127 insertions(+), 123 deletions(-) diff --git a/yimian/.viminfo b/yimian/.viminfo index b5f1c040..ac588042 100755 --- a/yimian/.viminfo +++ b/yimian/.viminfo @@ -14,10 +14,10 @@ $ # Command Line History (newest to oldest): -:wq :q -:q! :w +:wq +:q! :Q! :Wq @@ -130,28 +130,65 @@ $ # File marks: -'0 1 7 ~/www/settlement/imgbed/.gitignore -'1 4 0 ~/www/settlement/func/functions.php -'2 2 0 /home/ushio/www/api/functions.php -'3 5 68 ~/www/settlement/api/test.php -'4 341 0 ~/www/settlement/func/functions.php -'5 122 0 ~/www/settlement/api/index.php -'6 30 58 ~/www/settlement/imgbed/upload.php -'7 1 0 ~/www/settlement/imgbed/upload -'8 16 17 ~/www/settlement/imgbed/js/jquery.imageuploader.js -'9 52 44 ~/www/settlement/imgbed/js/main.js +'0 19 68 ~/www/settlement/api/index.php +'1 73 93 ~/www/settlement/func/functions.php +'2 4 0 ~/www/settlement/api/index.php +'3 1 7 ~/www/settlement/imgbed/.gitignore +'4 4 0 ~/www/settlement/func/functions.php +'5 2 0 /home/ushio/www/api/functions.php +'6 5 68 ~/www/settlement/api/test.php +'7 341 0 ~/www/settlement/func/functions.php +'8 122 0 ~/www/settlement/api/index.php +'9 30 58 ~/www/settlement/imgbed/upload.php # Jumplist (newest first): --' 1 7 ~/www/settlement/imgbed/.gitignore +-' 19 68 ~/www/settlement/api/index.php +-' 4 0 ~/www/settlement/api/index.php +-' 73 93 ~/www/settlement/func/functions.php +-' 70 0 ~/www/settlement/func/functions.php +-' 78 0 ~/www/settlement/func/functions.php +-' 87 0 ~/www/settlement/func/functions.php +-' 117 73 ~/www/settlement/func/functions.php +-' 118 0 ~/www/settlement/func/functions.php +-' 119 0 ~/www/settlement/func/functions.php +-' 121 0 ~/www/settlement/func/functions.php +-' 122 0 ~/www/settlement/func/functions.php +-' 151 66 ~/www/settlement/func/functions.php +-' 120 0 ~/www/settlement/func/functions.php +-' 86 0 ~/www/settlement/func/functions.php +-' 152 0 ~/www/settlement/func/functions.php +-' 157 0 ~/www/settlement/func/functions.php +-' 164 0 ~/www/settlement/func/functions.php +-' 179 0 ~/www/settlement/func/functions.php +-' 184 0 ~/www/settlement/func/functions.php +-' 189 0 ~/www/settlement/func/functions.php +-' 196 0 ~/www/settlement/func/functions.php +-' 199 0 ~/www/settlement/func/functions.php +-' 204 0 ~/www/settlement/func/functions.php +-' 207 0 ~/www/settlement/func/functions.php +-' 211 0 ~/www/settlement/func/functions.php +-' 213 0 ~/www/settlement/func/functions.php +-' 220 0 ~/www/settlement/func/functions.php +-' 222 0 ~/www/settlement/func/functions.php +-' 219 0 ~/www/settlement/func/functions.php +-' 195 0 ~/www/settlement/func/functions.php +-' 188 0 ~/www/settlement/func/functions.php +-' 178 0 ~/www/settlement/func/functions.php +-' 154 0 ~/www/settlement/func/functions.php +-' 59 0 ~/www/settlement/func/functions.php +-' 39 0 ~/www/settlement/func/functions.php +-' 67 28 ~/www/settlement/func/functions.php +-' 60 0 ~/www/settlement/func/functions.php +-' 61 42 ~/www/settlement/func/functions.php -' 4 0 ~/www/settlement/func/functions.php +-' 122 12 ~/www/settlement/api/index.php +-' 1 7 ~/www/settlement/imgbed/.gitignore -' 327 0 ~/www/settlement/func/functions.php -' 341 8 ~/www/settlement/func/functions.php -' 2 0 /home/ushio/www/api/functions.php -' 1 0 /home/ushio/www/api/functions.php -' 5 68 ~/www/settlement/api/test.php -' 1 0 ~/www/settlement/api/test.php --' 86 0 ~/www/settlement/func/functions.php --' 122 0 ~/www/settlement/api/index.php -' 78 0 ~/www/settlement/api/index.php -' 30 58 ~/www/settlement/imgbed/upload.php -' 27 16 ~/www/settlement/imgbed/upload.php @@ -165,112 +202,50 @@ $ -' 13 0 ~/www/settlement/api/getCurrent.php -' 15 0 ~/www/settlement/api/getCurrent.php -' 1 0 ~/www/settlement/api/getCurrent.php --' 14 32 ~/www/settlement/api/getDetail.php --' 1 0 ~/www/settlement/api/getDetail.php --' 1 0 ~/www/settlement/api/get --' 29 0 ~/www/settlement/api/index.php --' 10 43 ~/www/settlement/api/getAccountEvents.php --' 1 0 ~/www/settlement/api/getAccountEvents.php --' 14 13 ~/www/settlement/api/getAccountEvents.php --' 17 0 ~/www/settlement/api/getAccountEvents.php --' 38 24 ~/www/settlement/api/getWeekData.php --' 52 0 ~/www/settlement/api/getWeekData.php --' 42 4 ~/www/settlement/api/getWeekData.php --' 37 4 ~/www/settlement/api/getWeekData.php --' 31 2 ~/www/settlement/api/getWeekData.php --' 48 4 ~/www/settlement/api/getWeekData.php --' 29 10 ~/www/settlement/api/getWeekData.php --' 21 0 ~/www/settlement/api/getWeekData.php --' 19 0 ~/www/settlement/api/getWeekData.php --' 18 0 ~/www/settlement/api/getWeekData.php --' 17 0 ~/www/settlement/api/getWeekData.php --' 15 0 ~/www/settlement/api/getWeekData.php --' 50 0 ~/www/settlement/api/getWeekData.php --' 46 0 ~/www/settlement/api/getWeekData.php --' 14 4 ~/www/settlement/imgbed/index.html --' 1 0 ~/www/settlement/imgbed/index.html --' 18 12 ~/www/settlement/imgbed/js/jquery.imageuploader.js --' 9 0 ~/www/settlement/imgbed/js/jquery.imageuploader.js --' 43 0 ~/www/settlement/imgbed/upload.php --' 4 0 ~/www/settlement/imgbed/js/jquery.imageuploader.js --' 5 40 ~/www/settlement/imgbed/js/jquery.min.js --' 1 0 ~/www/settlement/imgbed/js/jquery.min.js --' 10 0 ~/www/settlement/imgbed/js/jquery.hwLayer.js --' 1 0 ~/www/settlement/imgbed/js/jquery.hwLayer.js --' 1 0 ~/www/settlement/imgbed/js/jquery.imageuploader.js --' 61 9 ~/www/settlement/imgbed/index.html --' 1 29 ~/www/settlement/imgbed/style/main.css --' 79 0 ~/www/settlement/imgbed/index.html --' 1 0 ~/www/settlement/imgbed/upload.php --' 1 0 ~/www/settlement/imgbed/uploadp --' 23 0 ~/www/settlement/api/getWeekData.php --' 53 0 ~/www/settlement/api/getWeekData.php --' 25 28 ~/www/settlement/api/getWeekData.php --' 6 0 ~/www/settlement/api/getWeekData.php --' 88 0 ~/www/settlement/func/functions.php --' 1 0 ~/www/settlement/api/index.php --' 104 0 ~/www/settlement/api/index.php --' 1 0 ~/www/settlement/api/getWeekData.php --' 3 0 ~/www/settlement/api/index.php --' 123 7 ~/www/settlement/api/index.php --' 193 29 ~/www/settlement/index.html --' 6 1 ~/www/settlement/index.html --' 1 0 ~/www/settlement/index.html --' 85 4 ~/www/settlement/api/index.php --' 8 0 ~/www/settlement/api/index.php --' 110 4 ~/www/settlement/api/index.php --' 146 8 ~/www/settlement/api/index.php --' 98 4 ~/www/settlement/api/index.php --' 1 0 ~/www/settlement/api --' 150 0 ~/www/settlement/api/index.php --' 76 8 ~/www/settlement/api/index.php --' 135 0 ~/www/settlement/api/index.php --' 9 0 ~/www/settlement/func/functions.php --' 443 6 ~/www/settlement/func/functions.php --' 300 6 ~/www/settlement/func/functions.php --' 151 38 ~/www/settlement/func/functions.php --' 117 38 ~/www/settlement/func/functions.php --' 10 1 ~/www/settlement/func/functions.php --' 1 0 ~/www/settlement/func/functions.php --' 5 0 ~/www/settlement/api/index.php --' 2 9 ~/www/settlement/index.php --' 1 0 ~/www/settlement/index.php --' 79 1 ~/www/settlement/func/functions.php --' 1 0 ~/www/settlement/.config.php --' 1 0 ~/www/settlement/.gitignore --' 149 0 /home/ushio/www/api/functions.php --' 227 0 /home/ushio/www/api/functions.php +-' 73 93 ~/www/settlement/func/functions.php +-' 70 0 ~/www/settlement/func/functions.php +-' 78 0 ~/www/settlement/func/functions.php +-' 87 0 ~/www/settlement/func/functions.php +-' 117 73 ~/www/settlement/func/functions.php +-' 118 0 ~/www/settlement/func/functions.php +-' 119 0 ~/www/settlement/func/functions.php +-' 121 0 ~/www/settlement/func/functions.php +-' 122 0 ~/www/settlement/func/functions.php +-' 151 66 ~/www/settlement/func/functions.php +-' 120 0 ~/www/settlement/func/functions.php +-' 86 0 ~/www/settlement/func/functions.php +-' 152 0 ~/www/settlement/func/functions.php +-' 157 0 ~/www/settlement/func/functions.php +-' 164 0 ~/www/settlement/func/functions.php +-' 179 0 ~/www/settlement/func/functions.php +-' 184 0 ~/www/settlement/func/functions.php +-' 189 0 ~/www/settlement/func/functions.php +-' 196 0 ~/www/settlement/func/functions.php +-' 199 0 ~/www/settlement/func/functions.php +-' 204 0 ~/www/settlement/func/functions.php +-' 207 0 ~/www/settlement/func/functions.php +-' 211 0 ~/www/settlement/func/functions.php +-' 213 0 ~/www/settlement/func/functions.php +-' 220 0 ~/www/settlement/func/functions.php +-' 222 0 ~/www/settlement/func/functions.php +-' 219 0 ~/www/settlement/func/functions.php +-' 195 0 ~/www/settlement/func/functions.php +-' 188 0 ~/www/settlement/func/functions.php +-' 178 0 ~/www/settlement/func/functions.php +-' 154 0 ~/www/settlement/func/functions.php +-' 59 0 ~/www/settlement/func/functions.php +-' 39 0 ~/www/settlement/func/functions.php +-' 67 28 ~/www/settlement/func/functions.php +-' 60 0 ~/www/settlement/func/functions.php +-' 61 42 ~/www/settlement/func/functions.php +-' 4 0 ~/www/settlement/func/functions.php # History of marks within files (newest to oldest): -> ~/www/settlement/imgbed/.gitignore - " 1 7 - ^ 1 8 - . 1 7 - + 1 7 - -> ~/www/settlement/func/functions.php - " 4 0 - ^ 88 0 - . 4 0 - + 3 37 - + 9 2 - + 4 0 - -> /home/ushio/www/api/functions.php - " 2 0 - -> ~/www/settlement/api/test.php - " 5 68 - ^ 5 69 - . 5 68 - + 3 57 - + 5 68 - > ~/www/settlement/api/index.php - " 122 0 - ^ 104 0 - . 3 37 + " 19 68 + ^ 19 69 + . 19 69 + 6 0 + 5 56 + 60 14 @@ -309,6 +284,35 @@ $ + 5 0 + 2 0 + 3 37 + + 19 69 + +> ~/www/settlement/func/functions.php + " 73 93 + ^ 73 94 + . 73 93 + + 3 37 + + 9 2 + + 4 0 + + 61 95 + + 71 56 + + 72 86 + + 73 93 + +> ~/www/settlement/imgbed/.gitignore + " 1 7 + ^ 1 8 + . 1 7 + + 1 7 + +> /home/ushio/www/api/functions.php + " 2 0 + +> ~/www/settlement/api/test.php + " 5 68 + ^ 5 69 + . 5 68 + + 3 57 + + 5 68 > ~/www/settlement/imgbed/upload.php " 30 58 diff --git a/yimian/www/settlement/api/getWeekData.php b/yimian/www/settlement/api/getWeekData.php index f645828e..878b7bcf 100644 --- a/yimian/www/settlement/api/getWeekData.php +++ b/yimian/www/settlement/api/getWeekData.php @@ -23,7 +23,7 @@ for($ii = 0; $ii < (($days < 30) ? $days: 30); $ii ++){ $sql = "select * from account where datetime>='".date('Y-m-d',strtotime('-'.($ii+1).' day'))." 00:00:00' and datetime<'".date('Y-m-d', strtotime("-$ii day"))." 00:00:00' order by id DESC limit 1"; $result = $conn->query($sql); -$tmp = 0; +static $tmp = 0; while($row = $result->fetch_assoc()) { $tmp = $row['total']; } diff --git a/yimian/www/settlement/api/index.php b/yimian/www/settlement/api/index.php index 8b6ede51..780d540a 100755 --- a/yimian/www/settlement/api/index.php +++ b/yimian/www/settlement/api/index.php @@ -16,7 +16,7 @@ if(isset($_REQUEST['id'])) $id = $_REQUEST['id']; /* cnt to db */ $conn = db__connect(); -$lastItem = end(db__getData($conn, "account")); +$lastItem = end(db__getData($conn, "account","","","","","order by id")); $datetime = date('Y-m-d H:i:s'); $tmpItem = $lastItem; $tmpItem['datetime'] = $datetime; diff --git a/yimian/www/settlement/func/functions.php b/yimian/www/settlement/func/functions.php index a8e0b161..196dcaf9 100755 --- a/yimian/www/settlement/func/functions.php +++ b/yimian/www/settlement/func/functions.php @@ -58,7 +58,7 @@ function db__rowNum($conn,$table,$clmnName="",$value="",$clmnName2="",$value2="" } //get row data from database::(data_cnnct var, table name,column name, column value)::(row info) -function db__getData($conn,$table,$clmnName="",$value="",$clmnName2="",$value2="") +function db__getData($conn,$table,$clmnName="",$value="",$clmnName2="",$value2="",$sql_plus = "") { $table=db__antisql($table); @@ -68,9 +68,9 @@ function db__getData($conn,$table,$clmnName="",$value="",$clmnName2="",$value2=" $value2=db__antisql($value2); - if($clmnName=="") $sql = "SELECT * FROM $table"; - elseif($clmnName2=="") $sql = "SELECT * FROM $table where $clmnName='$value'"; - else $sql = "SELECT * FROM $table where $clmnName='$value' AND $clmnName2='$value2'"; + if($clmnName=="") $sql = "SELECT * FROM $table $sql_plus"; + elseif($clmnName2=="") $sql = "SELECT * FROM $table where $clmnName='$value' $sql_plus"; + else $sql = "SELECT * FROM $table where $clmnName='$value' AND $clmnName2='$value2' $sql_plus"; $result = $conn->query($sql); //no data