当前位置: 首页>>代码示例>>PHP>>正文


PHP Checkout::where方法代码示例

本文整理汇总了PHP中Checkout::where方法的典型用法代码示例。如果您正苦于以下问题:PHP Checkout::where方法的具体用法?PHP Checkout::where怎么用?PHP Checkout::where使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Checkout的用法示例。


在下文中一共展示了Checkout::where方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: post_deleteops

 public function post_deleteops()
 {
     Log::write('info', Request::ip() . ' User : ' . Auth::user()->fullname . ' Event: Mengapus histori setoran', true);
     $data = Input::json();
     $checkin = Checkin::find($data->checkin_id);
     Checkout::where('operasi_time', '=', $checkin->operasi_time)->where('fleet_id', '=', $checkin->fleet_id)->first()->delete();
     $checkin->delete();
     return json_encode(array('status' => 1));
 }
开发者ID:acmadi,项目名称:diantaksi,代码行数:9,代码来源:financials.php

示例2: post_saveCheck

 public function post_saveCheck()
 {
     Log::write('info', Request::ip() . ' User : ' . Auth::user()->fullname . ' Event: Save Checkin', true);
     $data = Input::json();
     $id = $data->id;
     $docs_ket = $data->std_docs;
     $neats = $data->std_neats;
     $equips = $data->std_equips;
     $sp_kets = $data->ket_sp;
     $checkin = Checkin::find($id);
     $checkin->km_fleet = $data->km_fleet;
     $checkin->rit = $data->rit;
     $checkin->incomekm = $data->incomekm;
     //$checkin->checkin_step_id = 2;
     $checkin->save();
     //update yang nyangkut
     $checkout = Checkout::where('fleet_id', '=', $checkin->fleet_id)->where('operasi_time', '=', $checkin->operasi_time)->first();
     if ($checkout) {
         $checkout->checkout_step_id = 7;
         $checkout->save();
     }
     $docs = array();
     foreach (Stddoc::all() as $doc) {
         array_push($docs, $doc->id);
     }
     $sps = array();
     foreach (Stdfleet::all() as $sp) {
         array_push($sps, $sp->id);
     }
     $cin = Checkindocument::where_checkin_id($id)->first();
     if ($cin->operasi_time > date('Y-m-d', Myfungsi::sysdate())) {
         $datax['message'] = 'invalide time';
     } else {
         $cin->std_neats_id = implode(",", $neats);
         $cin->std_document_id = implode(",", $docs);
         $cin->ket = implode(",", $docs_ket);
         $cin->std_equip_id = implode(",", $equips);
         $cin->save();
         $datax['message'] = 'Data Saved';
     }
     return json_encode($datax);
 }
开发者ID:acmadi,项目名称:diantaksi,代码行数:42,代码来源:checkins.php


注:本文中的Checkout::where方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。