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


PHP Position::get方法代码示例

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


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

示例1: testUpdate

 /**
  * @covers ::save
  * @covers ::get
  */
 public function testUpdate()
 {
     $position = (object) array('positionId' => 1, 'positionName' => 'MY POSITION', 'positionDescription' => 'THIS IS A COOL JOB', 'employeeArea' => 2, 'deleted' => 0, 'guid' => null);
     $accessor = new Position();
     $accessor->save($position);
     $getter = $accessor->get(1);
     $this->assertEquals(1, $getter->positionId);
     $this->assertEquals(2, $getter->employeeArea);
     $position2 = (object) array('positionId' => 1, 'positionName' => 'MY POSITION', 'positionDescription' => 'THIS IS A COOL JOB', 'employeeArea' => 1, 'deleted' => 0);
     $accessor->save($position2);
     $getter = $accessor->get(1);
     $this->assertEquals(1, $getter->positionId);
     $this->assertEquals(1, $getter->employeeArea);
 }
开发者ID:byu-oit-ssengineering,项目名称:team-managment-tool,代码行数:18,代码来源:PositionTest.php

示例2: getNode

 public static function getNode()
 {
     $s = Position::get();
     self::$node = $s;
     return new self();
 }
开发者ID:awidarto,项目名称:jexadmin,代码行数:6,代码来源:Prefs.php

示例3: getPosition

 public static function getPosition($key = null, $val = null)
 {
     if (is_null($key)) {
         $c = Position::get();
         self::$position = $c;
         return new self();
     } else {
         $c = Position::where($key, '=', $val)->first();
         self::$position = $c;
         return $c;
     }
 }
开发者ID:awidarto,项目名称:bilnatracker,代码行数:12,代码来源:Prefs.php

示例4: function

    Route::resource('awb', 'Api\\AwbController');
    Route::resource('status', 'Api\\StatusController');
    Route::get('fl/order', 'Api\\FlapiController@index');
    Route::post('fl/status', 'Api\\FlapiController@postStatus');
    Route::post('sap/status', 'Api\\SapapiController@postStatus');
    Route::resource('sap/awb', 'Api\\SapapiController');
    Route::get('g21/order', 'Api\\G21apiController@index');
});
Route::get('lastup/{log}', function ($log) {
    $last = Threeplstatuslog::where('consignee_logistic_id', '=', $log)->orderBy('timestamp', 'desc')->first();
    print date('Y-m-d H:i:s', $last->timestamp->sec);
    print_r($last->toArray());
});
Route::get('tolower', function () {
    $pos = new Position();
    $nodes = $pos->get();
    $blist = array('_id', 'createdDate', 'lastUpdate');
    foreach ($nodes as $n) {
        $nv = $n->toArray();
        print_r($nv);
        foreach ($nv as $key => $value) {
            if (in_array($key, $blist)) {
            } else {
                $n->{strtolower($key)} = $value;
            }
        }
        $n->save();
    }
});
Route::get('btest', function () {
    $model = new Merchant();
开发者ID:awidarto,项目名称:bilnatracker,代码行数:31,代码来源:routes.php


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