| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- <?php
- /**
- * Created by PhpStorm.
- * User: blues
- * Date: 2018/10/30
- * Time: 15:09
- */
- namespace App\Models;
- class SystemAppupdate extends BaseModel
- {
- protected $table = 'system_appupdate';
- public $timestamps = false;
- function getlist($where,$limit ){
- return $this->where($where)
- ->limit($limit)->orderby('create_date','desc')
- ->get(['id','version_no','settype','download_url','update_num','status','other','create_date'])
- ->toArray();
- }
- function addRecord($data){
- $res=$this->insert($data);
- if(!$res){
- return -6030001222;
- }
- }
- function getIdData($id){
- return $this->where("id",$id)->first();
- }
- public function updateIdData(int $id,$data){
- return $this->where("id",$id)->update($data);
- }
- }
|