本文整理汇总了PHP中Client::getPhone方法的典型用法代码示例。如果您正苦于以下问题:PHP Client::getPhone方法的具体用法?PHP Client::getPhone怎么用?PHP Client::getPhone使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Client
的用法示例。
在下文中一共展示了Client::getPhone方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: InsertNewClient
public function InsertNewClient(Client $c = null)
{
if ($c == null || !$c instanceof Client) {
return false;
}
$props = array("Name," => $c->getName(), "Alias," => $c->getAlias(), "ContactName," => $c->getContactName(), "Phone," => $c->getPhone(), "Country," => $c->getCountry(), "StateProv," => $c->getStateProv(), "City," => $c->getCity(), "ZipPostal," => $c->getZipPostal(), "DateAdded," => $c->getDateAdded(), "AddedByUserID," => $c->getAddedByUserID(), "OnSiteEmployee" => $c->getOnSiteEmployee());
foreach ($props as $k => $v) {
if ($v != null) {
if ($k == "OnSiteEmployee") {
$_props[$k] = "{$v}";
} else {
if (gettype($v) == "string") {
$_props[$k] = "'" . $v . "', ";
} else {
$_props[$k] = "{$v}, ";
}
}
}
}
$this->_dbAdapt->IStatement($this->dbTbl, $_props);
$tmp = $this->_dbAdapt->getLnk();
$tmp->query($this->_dbAdapt->getQry());
unset($tmp);
return true;
}
示例2: testGetPhone
function testGetPhone()
{
$name = "Stuart";
$phone = "555-555-5555";
$stylist_id = 1;
$test_client = new Client($name, $phone, $stylist_id);
$result = $test_client->getPhone();
$this->assertEquals($phone, $result);
}
示例3: Stylist
function test_getPhone()
{
//Arrange
$client_name = "Bill Withers";
$client_phone = "5415134876";
$stylist = new Stylist("Diane", "5035528959", "MPB", false);
$stylist->save();
$client = new Client($client_name, $client_phone, $stylist->getId());
//Act
$result = $client->getPhone();
//Assert
$this->assertEquals($client_phone, $result);
}
示例4: Client
function test_getPhone()
{
//Arrange
$name = "Sandra Jane";
$phone = "542-334-0984";
$style_choice = "The Rachel";
$stylist_id = 1;
$id = null;
$test_client = new Client($name, $phone, $style_choice, $stylist_id, $id);
//Act
$result = $test_client->getPhone();
//Assert
$this->assertEquals($phone, $result);
}
示例5: editClient
/**
* Modify a client saved in the database.
*
* @param Client $client
* @return integer
*/
public function editClient(Client $client)
{
$mcrypt = new MCrypt();
$sql = "UPDATE client \n\t\t\tSET id_client = '" . $client->getIdClient() . "', client_name = '" . replaceCharacters($client->getClientName()) . "', agent = '" . replaceCharacters($client->getAgent()) . "', address = '" . replaceCharacters($client->getAddress()) . "', phone = '" . $client->getPhone() . "', email = '" . $client->getEmail() . "', website = '" . $client->getWebsite() . "', user = '" . $client->getUser() . "', password = '" . $mcrypt->encrypt($client->getPassword()) . "' WHERE id_client = '" . $client->getIdClient() . "'";
return DB::query($sql);
}
示例6: Client
<div id="container">
<div id="sidebar" style="float:left;width:15%;">
<?php
include 'sidebar.php';
?>
</div>
<div id="content" style="float:right;width:85%;">
<table>
<tr><td style="width:200px;">Name</td>
<td style="width:200px;">Phone</td>
<td style="width:200px;">Email</td>
<td style="width:200px;">Website</td>
<td style="width:200px;">Action</td>
</tr>
<?php
for ($i = 0; $i < sizeof($mClientList); $i++) {
$mClient = new Client($mClientList[$i]);
echo "<tr>";
echo "<td>" . $mClient->getName() . "</td>";
echo "<td>" . $mClient->getPhone() . "</td>";
echo "<td>" . $mClient->getEmail() . "</td>";
echo "<td>" . $mClient->getWebsite() . "</td>";
echo "<td><input type='submit' value='Assign'><input type='submit' value='Track'></td>";
echo "</tr>";
}
?>
</table>
<div>
</div>
</body>
示例7: Stylist
function test_update()
{
$name = "Sally";
$phone = "555-555-5555";
$id = null;
$test_stylist = new Stylist($name, $phone, $id);
$test_stylist->save();
$name = "Maggie";
$phone = "123-321-1234";
$stylist_id = $test_stylist->getId();
$test_client = new Client($name, $phone, $id, $stylist_id);
$test_client->save();
$new_name = "George";
$new_phone = "123-456-7890";
$test_client->update($new_name, $new_phone);
$this->assertEquals("George", $test_client->getName());
$this->assertEquals("123-456-7890", $test_client->getPhone());
}
示例8: Stylist
function test_setPhone()
{
//Arrange
$name = "Sasha";
$id = null;
$test_stylist = new Stylist($name, $id);
$test_stylist->save();
$c_name = "Garry Gergich";
$phone = "503-472-8959";
$stylist_id = $test_stylist->getId();
$test_client = new Client($c_name, $phone, $id, $stylist_id);
$new_phone = "503-434-5549";
$test_client->save();
//Act
$test_client->setPhone($new_phone);
//Assert
$this->assertEquals($test_client->getPhone(), $new_phone);
}
示例9: render
//.........这里部分代码省略.........
Nombre <small>(*)</small>
</label>
<input name="client_name" type="text" required value="<?php
echo $client->getClientName();
?>
" />
</div>
<div>
<label for="agent">
Representante <small>(*)</small>
</label>
<input name="agent" type="text" required value="<?php
echo $client->getAgent();
?>
" />
</div>
<div>
<label for="address">
Dirección <small>(*)</small>
</label>
<input name="address" type="text" required value="<?php
echo $client->getAddress();
?>
" />
</div>
<div>
<label for="phone">
Teléfono <small>(*)</small>
</label>
<input name="phone" type="tel" required value="<?php
echo $client->getPhone();
?>
" />
</div>
</div>
<div class="col-md-6">
<div>
<label for="email">
Correo electrónico <small>(*)</small>
</label>
<input name="email" type="email" required value="<?php
echo $client->getEmail();
?>
" />
</div>
<div>
<label for="website">
Sitio web
</label>
<input name="website" type="url" value="<?php
echo $client->getWebsite();
?>
" />
</div>
<div>
<label for="user">
Usuario <small>(*)</small>
</label>
示例10: render
/**
* Renderize the view.
*
* @return null
*/
public function render(Client $client)
{
?>
<p>
<?php
echo REQUIRED_FIELDS_TEXT;
?>
</p>
<form action="<?php
echo $this->generateURL('client', 'edit', $client->getIdClient());
?>
" method="post">
<fieldset>
<div class="row">
<div class="col-md-6">
<div>
<label for="client_name">
Nombre <small>(*)</small>
</label>
<input name="client_name" type="text" required value="<?php
echo $client->getClientName();
?>
" />
</div>
<div>
<label for="agent">
Representante <small>(*)</small>
</label>
<input name="agent" type="text" required value="<?php
echo $client->getAgent();
?>
" />
</div>
<div>
<label for="address">
Dirección <small>(*)</small>
</label>
<input name="address" type="text" required value="<?php
echo $client->getAddress();
?>
" />
</div>
<div>
<label for="phone">
Teléfono <small>(*)</small>
</label>
<input name="phone" type="tel" required value="<?php
echo $client->getPhone();
?>
" />
</div>
</div>
<div class="col-md-6">
<div>
<label for="email">
Correo electrónico <small>(*)</small>
</label>
<input name="email" type="email" required value="<?php
echo $client->getEmail();
?>
" />
</div>
<div>
<label for="website">
Sitio web
</label>
<input name="website" type="url" value="<?php
echo $client->getWebsite();
?>
" />
</div>
<div>
<label for="user">
Usuario <small>(*)</small>
</label>
<input name="user" type="text" required value="<?php
echo $client->getUser();
?>
" />
</div>
//.........这里部分代码省略.........