Commit 16ea6b1b authored by hujun's avatar hujun

source

parent fda360ef
......@@ -233,9 +233,6 @@ class StoreFeeService
if ($status) {
$arr["status"] = $status;
}
if ($source) {
$arr["source"] = $source;
}
if ($payee_agent_id) {
$arr["payee_agent_id"] = $payee_agent_id;
}
......@@ -246,6 +243,10 @@ class StoreFeeService
}
$arr["update_time"] = date("Y-m-d H:i:s", time());
if ($id <= 0) {
if ($source) {
$arr["source"] = $source;
}
if ($agent_id) {
$arr["agent_id"] = $agent_id; //申请人,防止编辑前端传错误数据。
}
......
......@@ -51,9 +51,10 @@ class PositionService
*/
public function checkDistance($a_latitude, $a_longitude, $b_latitude, $b_longitude, $limit_distance = 0)
{
$first_position = $a_latitude . ',' . $a_longitude;
$end_position = $b_latitude . ',' . $b_longitude;
$distance = $this->getPositionDistance($first_position, $end_position);
// $first_position = $a_latitude . ',' . $a_longitude;
// $end_position = $b_latitude . ',' . $b_longitude;
// $distance = $this->getPositionDistance($first_position, $end_position);
$distance = $this->getDistance($a_latitude, $a_longitude, $b_latitude, $b_longitude);
if ($distance <= $limit_distance) {
$result = true;
} else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment