| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- <?php
- namespace App\Models;
- use Illuminate\Support\Facades\DB;
- /**
- *
- */
- class LotteryMoneyLog extends BaseModel {
- protected $table = "lottery_money_log";
- public $timestamps = false;
- function getlist($list = 10, $where = '') {
- $data = $this->orderBy('create_time', 'desc');
- if (!empty($where) && is_array($where)) {
- $data = $data->where($where);
- }
- $data = $data->paginate($list);
- if (!$data) {
- return -4010010022; //没有数据
- }
- return $data->toArray();
- }
- /**
- * 更新彩金记录状态
- * @param $data
- * @param $id
- * @return int
- */
- function updateSta($data,$id){
- $res = $this->where('id',$id)->update($data);
- if (!$res) {
- return -4010010022; //没有数据
- }
- return 1;
- }
- }
|