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


PHP Properties::find方法代码示例

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


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

示例1: propertiesJsonQuery

 public function propertiesJsonQuery($string)
 {
     $propertiesClient = new Properties();
     if (!$this->validateProperties($string)) {
         return "";
     }
     $response = $propertiesClient->find($string);
     return $response;
 }
开发者ID:linniux,项目名称:atsd-api-php,代码行数:9,代码来源:BasicApiProxy.php

示例2: postAddRepairHistory

 public function postAddRepairHistory()
 {
     $property = Properties::find(Input::get('properties_id'));
     if (!$property) {
         App::abort(404);
     }
     $validator = Validator::make(Input::all(), ['transaction' => 'required|in:REPLACEMENT,ADDITION', 'details' => 'required|max:50', 'effectdate' => 'required|date_format:Y-m-d', 'cost' => 'required|numeric']);
     if ($validator->fails()) {
         return Redirect::route('add-repair-history', $property->id)->withErrors($validator)->withInput();
     }
     $repair = new Repair();
     $repair->transaction = Input::get('transaction');
     $repair->details = Input::get('details');
     $repair->effectdate = Input::get('effectdate');
     $repair->cost = Input::get('cost');
     $repair->property()->associate($property);
     $repair->save();
     return Redirect::route('repair-history', $property->id)->with('alert', 'success|Repair history entry created successfully.');
 }
开发者ID:codeblues1516,项目名称:godaddy,代码行数:19,代码来源:PropertyController.php

示例3: Properties

<?php

/*
* Copyright 2015 Axibase Corporation or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* https://www.axibase.com/atsd/axibase-apache-2.0.pdf
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
namespace axibase\atsdPHP;

require_once '../atsdPHP/models/Properties.php';
require_once '../atsdPHP/HttpClient.php';
require_once '../atsdPHP/Utils.php';
$type = "System";
$entity = "awsswgvml001";
$queryClient = new Properties();
$json = '{"queries":[{"type":"' . $type . '","entity":"' . $entity . '"}]}';
$response = $queryClient->find($json);
$viewConfig = new ViewConfiguration("Properties for entity: " . $entity . "; type: " . $type, "properties");
$propertiesTable = Utils::propertyAsHtmlTable($response, $viewConfig);
Utils::render(array($propertiesTable));
开发者ID:linniux,项目名称:atsd-api-php,代码行数:29,代码来源:PropertiesExample.php

示例4: getViewUserProperty

 public function getViewUserProperty($id)
 {
     $prop = Properties::find($id);
     $histories = PropertiesHistory::where('properties_id', $id)->orderBy('created_at', 'desc')->get();
     if (!$prop) {
         App::abort(404);
     }
     return View::make('view-property')->with('histories', $histories)->with('prop', $prop);
 }
开发者ID:codeblues1516,项目名称:godaddy,代码行数:9,代码来源:UsersController.php


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