收支核对修改

This commit is contained in:
wanyongkang
2020-10-26 12:14:54 +08:00
parent 96994d1219
commit 6cefe6a00e
5 changed files with 56 additions and 102 deletions

View File

@@ -5,7 +5,7 @@
* @Author: kangkang
* @Date: 2020-10-13 19:52:37
* @LastEditors: kangkang
* @LastEditTime: 2020-10-24 14:23:06
* @LastEditTime: 2020-10-26 10:36:11
*/
/*
* @Descripttion:
@@ -64,7 +64,7 @@ class IncomeCheck extends Controller
$data[0] = date('Y-m-d', strtotime($data[0]) + 86400) . ' 00:00:00';
$data[1] = date('Y-m-d', strtotime($data[1]) + 86400) . ' 23:59:59';
$check_model = new CheckModel;
$list = $check_model->getListPages(['day_time' => [['>' , $data[0]], ['<' , $data[1]]]], '*', 'id desc', "10000");
$list = $check_model->getListSearch(['day_time' => ['>' , $data[0]]], ['day_time' => ['<' , $data[1]]], '*', 'id desc', "10000");
foreach ($list as $k => &$v) {
$v['day_time'] = date('Y-m-d', strtotime($v['day_time']) - 86400);
}

View File

@@ -1,14 +1,13 @@
<?php
/*
* @Descripttion:
* @version:
* @Descripttion:
* @version:
* @Author: kangkang
* @Date: 2020-10-22 16:13:41
* @LastEditors: kangkang
* @LastEditTime: 2020-10-23 17:07:07
* @LastEditTime: 2020-10-26 10:34:48
*/
namespace app\order\model;
use fastphp\base\Model;
@@ -16,4 +15,14 @@ use fastphp\base\Model;
class IncomeCheck extends Model
{
protected $table = 'income_check';
}
/**
* @description: 单独写
* @param {*}
* @return {*}
*/
public function getListSearch($where1, $where2, $fields = '*', $order = 'id desc', $limit = '50')
{
return $this->field($fields)->where($where1)->where($where2)->order($order)->limit($limit)->fetchAll();
}
}