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


PHP Job::getJob方法代码示例

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


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

示例1: testGetSetJob

 /**
  * Test getter/setter job
  */
 public function testGetSetJob()
 {
     $this->assertEmpty($this->jobInstance->getJob());
     $expectedConfiguration = array('key1' => 'value1', 'key2' => 'value2', 'key3' => 'value3');
     $mockJob = $this->getMockBuilder('Akeneo\\Bundle\\BatchBundle\\Job\\Job')->disableOriginalConstructor()->getMock();
     $mockJob->expects($this->any())->method('getConfiguration')->will($this->returnValue($expectedConfiguration));
     $this->assertEntity($this->jobInstance->setJob($mockJob));
     $this->assertEquals($expectedConfiguration, $this->jobInstance->getRawConfiguration());
     $this->assertEquals($mockJob, $this->jobInstance->getJob());
 }
开发者ID:xleliberty,项目名称:BatchBundle,代码行数:13,代码来源:JobInstanceTest.php

示例2: outputJob

 private static function outputJob($jobId)
 {
     $job = Job::getJob($jobId);
     $output = "";
     $output .= "Job with ID: " . Job::getJobId($job) . "<br>\n";
     /* Display a short table with information */
     $output .= "<table border=\"1\">\n";
     /* header */
     $output .= "<tr>\n";
     $output .= "<th>Region</th>\n";
     $output .= "<th>District</th>\n";
     $output .= "<th>WorkType</th>\n";
     $output .= "<th>Category</th>\n";
     $output .= "<th>SubCategory</th>\n";
     $output .= "<th>Job Title</th>\n";
     $output .= "<th>Job Description</th>\n";
     $output .= "<th>Salary Range</th>\n";
     $output .= "<th>Start Date</th>\n";
     $output .= "<th>End Date</th>\n";
     $output .= "</tr>\n";
     $output .= "<tr>\n";
     $output .= "<td>" . Job::getRegion($job) . "</td>\n";
     $output .= "<td>" . Job::getDistrict($job) . "</td>\n";
     $output .= "<td>" . Job::getWorkType($job) . "</td>\n";
     $output .= "<td>" . Job::getJobCategory($job) . "</td>\n";
     $output .= "<td>" . Job::getJobSubCategory($job) . "</td>\n";
     $output .= "<td>" . Job::getJobTitle($job) . "</td>\n";
     $output .= "<td>" . Job::getJobDescription($job) . "</td>\n";
     /* These last fields need formatting */
     $formattedSalaryLow = sprintf("%-6d", Job::getSalaryLow($job));
     $formattedSalaryHigh = sprintf("%-6d", Job::getSalaryHigh($job));
     $startDate = new DateTime(Job::getDateOfAdvertisement($job));
     $formattedStartDate = $startDate->format("j M Y");
     $endDate = new DateTime(Job::getEndDateOfAdvertisement($job));
     $formattedEndDate = $endDate->format("D, j M Y");
     $output .= "<td>\${$formattedSalaryLow} - \${$formattedSalaryHigh}</td>\n";
     $output .= "<td>{$formattedStartDate}</td>\n";
     $output .= "<td>{$formattedEndDate}</td>\n";
     $output .= "</tr>";
     $output .= "</table>\n";
     return $output;
 }
开发者ID:preeti07,项目名称:GetTheJob,代码行数:42,代码来源:jobDisplay.php

示例3: array

/* This program is free software. You can redistribute it and/or	   */
/* modify it under the terms of the GNU General Public License		   */
/* as published by the Free Software Foundation.					   */
/***********************************************************************/
// $Id$
$_user_location = 'public';
define(AT_INCLUDE_PATH, '../../include/');
include AT_INCLUDE_PATH . 'vitals.inc.php';
include AT_JB_INCLUDE . 'classes/Job.class.php';
$_custom_css = $_base_path . AT_JB_BASENAME . 'module.css';
// use a custom stylesheet
/* 
 * Add the submenu on this page so that user can go back to the listing.
 * Reason why this is not included in module.php is because we don't want the 
 * 'view_post' submenu to show on job_board/index.php
 */
$_pages[AT_JB_BASENAME . 'index.php']['children'] = array(AT_JB_BASENAME . 'view_post.php');
$jid = intval($_REQUEST['jid']);
$job = new Job();
$job_post = $job->getJob($jid);
//handle add to cart event
if ($_GET['action'] == 'add_to_cart') {
    $job->addToJobCart($_SESSION['member_id'], $jid);
} elseif ($_GET['action'] == 'remove_from_cart') {
    $job->removeFromJobCart($_SESSION['member_id'], $jid);
}
include AT_INCLUDE_PATH . 'header.inc.php';
$savant->assign('job_obj', $job);
$savant->assign('job_post', $job_post);
$savant->display('jb_view_post.tmpl.php');
include AT_INCLUDE_PATH . 'footer.inc.php';
开发者ID:jorge683,项目名称:job_board,代码行数:31,代码来源:view_post.php

示例4: setJobAtRandom

 public function setJobAtRandom()
 {
     $this->schema['job_name'] = Job::getJob('1234');
     return $this->schema['job_name'];
 }
开发者ID:ryo01u,项目名称:fb_driland_modoki,代码行数:5,代码来源:Follower.php

示例5: dirname

<?php

require dirname(__FILE__) . '/../../model/Job.php';
$Model = new Job();
echo Job::getJob();
开发者ID:ryo01u,项目名称:fb_driland_modoki,代码行数:5,代码来源:JobTest.php

示例6: Facebook

$config['appId'] = $appId;
$config['secret'] = $secret;
$facebook = new Facebook($config);
$loginParams = array('scope' => 'user_birthday');
$statusParam = array('ok_session' => 'Now Login', 'no_user' => 'No User', 'no_session' => 'No Session');
if ($facebook->getUser()) {
    $fql = 'SELECT uid,name,pic,sex FROM user WHERE uid IN(SELECT uid2 FROM friend where uid1 = me())';
    $followers = $facebook->api(array('method' => 'fql.query', 'query' => $fql));
    foreach ($followers as $follower) {
        $data = array();
        $data['facebook_id'] = $follower['uid'];
        $data['name'] = $follower['name'];
        $data['pic'] = $follower['pic'];
        $data['power'] = rand(1, 100);
        $data['money'] = rand(1, 100);
        $data['job_name'] = Job::getJob();
        $uid = $follower['uid'];
        $result = $Follower->findBy(array('facebook_id' => $uid));
        if ($result->num_rows == 0) {
            $Follower->insert($data);
            var_dump($data);
        }
        echo "<hr />";
    }
} else {
    ?>
<a href="<?php 
    echo $facebook->getLoginUrl($loginParams);
    ?>
">ログイン</a><br />
<?php 
开发者ID:ryo01u,项目名称:fb_driland_modoki,代码行数:31,代码来源:FollowerTest_INSERT.php

示例7: dirname

require_once dirname(__FILE__) . '/../facebook.php';
require_once dirname(__FILE__) . '/../model/Follower.php';
require_once dirname(__FILE__) . '/../model/Party.php';
require_once dirname(__FILE__) . '/../calc_used_money.php';
// Follower,Party Model用意
$Follower = new Follower();
$Party = new Party();
// 全Follower情報取得を試みる
$fql = 'SELECT uid,name,pic,sex FROM user WHERE uid IN (SELECT uid2 FROM friend WHERE uid1 = me())';
$followers = $facebook->api(array('method' => 'fql.query', 'query' => $fql));
$followers_data = array();
// 全Followerの情報がMySQLにあるか確認 なければINSERT
foreach ($followers as $follower) {
    $uid = $follower['uid'];
    $result = $Follower->findBy(array('facebook_id' => $uid));
    if ($result->num_rows == 0) {
        // INSERTするデータを用意
        $data = array('facebook_id' => $uid, 'name' => $follower['name'], 'power' => Job::getPower($uid), 'money' => Job::getMoney($uid), 'pic' => $follower['pic'], 'sex' => $follower['sex'] == 'male' ? 0 : 1, 'job_name' => Job::getMood($uid) . Job::getPosition($uid) . Job::getJob($uid));
        $Follower->insert($data);
        array_push($followers_data, $data);
    } else {
        $follower_info = $result->fetch_assoc();
        array_push($followers_data, $follower_info);
    }
}
$party = array('', '', '');
$result = $Party->findBy(array('president_id' => $facebook->getUser()));
$index = 0;
while ($p = $result->fetch_assoc()) {
    $party[$index++] = $p;
}
开发者ID:ryo01u,项目名称:fb_driland_modoki,代码行数:31,代码来源:index_controller.php


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