本文整理汇总了PHP中getCustomer函数的典型用法代码示例。如果您正苦于以下问题:PHP getCustomer函数的具体用法?PHP getCustomer怎么用?PHP getCustomer使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getCustomer函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: getCustomerIdentifiers
/**
* Identify same "customer" as someone with the same customer id, or ip address or email address.
*
* @return array
*/
public function getCustomerIdentifiers()
{
$ip = getIp();
$quote = getCustomerQuote();
$customerid = $quote->getCustomerId();
$email = $quote->getBillingAddress()->getEmail();
if ($email == '') {
$customer = getCustomer($customerid);
$email = $customer['custconemail'];
}
$identifiers = array(
$ip,
$customerid,
$email,
);
return $identifiers;
}
开发者ID:hungnv0789,项目名称:vhtm,代码行数:24,代码来源:class.coupon.php
示例2: getCustomer
echo 'selected';
}
?>
>Pending</option><option value="paid" <?php
if ($invo[0]['status'] == 'paid') {
echo 'selected';
}
?>
>Paid</option><option value="cancelled" <?php
if ($invo[0]['status'] == 'pending') {
echo 'cancelled';
}
?>
>Cancelled</option></select>
<label>Customer Name </label><input type="text" name="name" value="<?php
$cust = getCustomer($number);
echo $cust[0]['cust_name'];
?>
" readonly >
<label>Invoice Number </label><input type="text" name="invoice" value="<?php
echo $number;
?>
" readonly >
<label>Date issued </label><input type="date" name="date_issued" value="<?php
echo $invo[0]['date_issued'];
?>
" >
<label>Amount </label><input type="number" name="amount" value="<?php
echo $invo[0]['amount'];
?>
">
开发者ID:benkip,项目名称:Reservation-system,代码行数:31,代码来源:updateinvoice.php
示例3: getBarangAvail
<?php
include 'db/pdo.php';
$jumlah_tabung = $_GET['jumlah_tabung'];
$barangs = getBarangAvail();
$customers = getCustomer();
?>
<div id='customer' class="inner-faktur-choice"><span>Customer : </span>
<input type="text" name="pilih_customer" id="customer" list="datalist2" onchange="showCustomer(this.value)">
<datalist id="datalist2">
<?php
foreach ($customers as $row) {
?>
<option onclick="showCustomer(this.value)" value="<?php
echo $row['nama_cust'];
?>
"><?php
echo $row['nama_cust'];
?>
</option>
<?php
}
?>
</datalist>
</div>
<?php
for ($i = 1; $i <= $jumlah_tabung; $i++) {
?>
<div id='tabung-$i' class="inner-faktur-choice"><span>Tabung ke <?php
echo $i;
开发者ID:blackbone23,项目名称:stoktabunghendri,代码行数:31,代码来源:buat_faktur.php
示例4: getCustomer
<div id="collapse2" class="panel-collapse collapse" role="tabpanel" aria-labelledby="heading2">
<div class="panel-body">
<?php
}
?>
<?php
if (isset($_GET['phone'])) {
?>
<?php
$phone = $_GET['phone'];
?>
<?php
$customer = getCustomer($phone);
?>
<?php
$customer = mysql_fetch_array($customer);
?>
<form role="form" action="save-order-registered-customer.php" method="post">
<div class="form-group">
<label for="first-name">First Name</label>
<input readonly type="text" id="first-name" name="first-name" class="form-control" placeholder="First Name" value="<?php
echo $customer["first_name"];
?>
" required>
</div>
开发者ID:kaanburaksener,项目名称:bicycle-rent-app,代码行数:30,代码来源:add-new-order.php
示例5: foreach
</form>
<table class="adminTable col-100" cellspacing="0">
<tr>
<th>Order No.</th>
<th>Date</th>
<th>Discount</th>
<th>Customer</th>
<th class="col-m-0">Delivery Address</th>
<th class="col-m-0">District</th>
<th>Delivery Job</th>
</tr>
<?php
foreach ($orders as $o) {
$cust = getCustomer($o[custNo]);
$dist = getDistrict($o[distNo]);
echo '<tr>
<td>' . $o[ordNo] . '</td>
<td>' . $o[ordDate] . '</td>
<td>' . $o[ordDiscount] . '</td>
<td> <a href="cust_details.php?custNo=' . $cust[custName] . '">' . $cust[custName] . '</td>
<td class="col-m-0">' . $o[deliAddr] . '</td>
<td class="col-m-0">' . $dist[distName] . '</td>
<td> <a href="job_details.php?jobNo=' . $o[jobNo] . '">' . $o[jobNo] . '</a></td>
</tr>';
}
?>
</table>
开发者ID:ahmanxdd,项目名称:WebProject,代码行数:30,代码来源:admin_order.php
示例6: foreach
$invoice->having_and = "date_between";
$filter_by_date = "yes";
$having_and_count = 1;
}
$invoice->sort = "date";
$invoice_all = $invoice->select_all();
$invoices = $invoice_all->fetchAll();
foreach ($invoices as $i => $row) {
$statement['total'] = $statement['total'] + $row['invoice_total'];
$statement['owing'] = $statement['owing'] + $row['owing'];
$statement['paid'] = $statement['paid'] + $row['INV_PAID'];
}
}
$sql = "select DISTINCT(custom_field3) from " . TB_PREFIX . "invoices where custom_field3 != ''";
$cf3 = $db->query($sql);
$biller_details = getBiller($biller_id);
$customer_details = getCustomer($customer_id);
$smarty->assign('biller_id', $biller_id);
$smarty->assign('biller_details', $biller_details);
$smarty->assign('customer_id', $customer_id);
$smarty->assign('customer_details', $customer_details);
$smarty->assign('cf3', $cf3->fetchAll());
$smarty->assign('custom_field3', $custom_field3);
$smarty->assign('filter_by_date', $filter_by_date);
$smarty->assign('invoices', $invoices);
$smarty->assign('statement', $statement);
$smarty->assign('start_date', $start_date);
$smarty->assign('end_date', $end_date);
$smarty->assign('pageActive', 'report');
$smarty->assign('active_tab', '#home');
$smarty->assign('menu', $menu);
开发者ID:alachaum,项目名称:simpleinvoices,代码行数:31,代码来源:custom_field_3.php
示例7: logger
logger($this)->addError("Mark a fulfillment as invalid", array('bidId' => $id));
return internalError($response);
}
$response->getBody()->write(json_encode(array("code" => 200, "message" => "OK")));
return $response;
} catch (PDOException $e) {
return handleError($e, $response);
}
});
$app->post('/api/bids/place', function (Request $request, Response $response) {
if (!array_key_exists('cst_session_id', $request->getCookieParams())) {
logger($this)->addWarning('No contractor session id', getPath($request));
return forbidden($response);
}
$customerSessionId = $request->getCookieParams()["cst_session_id"];
$customer = getCustomer($customerSessionId);
if (!isset($customer)) {
logger($this)->addWarning('No contractor found by session id', array('cst_session_id' => $customerSessionId, 'uri' => $request->getUri()->getPath()));
return forbidden($response);
}
$bid = json_decode($request->getBody());
list($product, $amount, $price) = parseBid($bid);
if (!isset($product)) {
logger($this)->addWarning('Wrong bid', getPath($request));
return badRequest($response);
}
$customerId = $customer['id'];
if ($price > $customer['amount']) {
logger($this)->addWarning("Customer doesn't have enough funds to place the bid with price", array('customer_id' => $customerId, 'price' => $price));
return conflict($response);
}
开发者ID:arteam,项目名称:orders-system,代码行数:31,代码来源:web.php
示例8: getCustomers
* - http://fakester.biz/
*
*/
// And we're away
require_once "../app/Mage.php";
Mage::app();
// How many orders are we creating
$num_orders = (int) $_GET["orders"];
// Get some random customer information
$customers = getCustomers($num_orders);
// Create a few orders
for ($i = 1; $i <= $num_orders; $i++) {
// Get random products
$products = getProducts();
// Get a customer
$customer = getCustomer(array_pop($customers));
// Order some mofo products for some mofo customer
$order = createOrder($products, $customer);
printf("Created order %s\n", $order->getIncrementId());
}
/*
* Get random customer information from fakester.biz
*
* @return array
*/
function getCustomers($num_customers)
{
$url = "http://fakester.biz/json?n={$num_customers}";
$json = file_get_contents($url);
$data = json_decode($json);
/*
开发者ID:ashwanibhasin,项目名称:mage-test-orders,代码行数:31,代码来源:create_test_orders.php
示例9: redirect
<?php
// initialize
include_once '../../../common/init.php';
if (!isLoggedInAdmin()) {
redirect('');
} else {
// include needed database functions
include_once $BASE_PATH . 'database/customers.php';
include_once $BASE_PATH . 'database/sales.php';
$id = $_GET['id'];
// fetch data
$customer = getCustomer($id);
// send data to smarty
$smarty->assign('customer', $customer);
$smarty->assign('graph', getCustomerSalesGraph($id));
// display smarty template
$smarty->display('manager/customers/view_customer.tpl');
}
开发者ID:vascofg,项目名称:lbaw,代码行数:19,代码来源:view_customer.php
示例10: addValueArray
} else {
$user_assigned[$uid] = $uid;
}
}
}
}
addValueArray($field['var'], ${$field}['var']);
break;
case 'customer_id':
if (!isset($_POST[$field['var']])) {
${$field}['var'] = 0;
} else {
${$field}['var'] = (int) $_POST[$field['var']];
}
if (${$field}['var'] != 0) {
$customer = getCustomer(${$field}['var']);
if (!count($customer)) {
$form_errors[] = __("Can't find the customer you tried to select") . ' (id ' . ${$field}['var'] . ')';
${$field}['var'] = '';
$customer_name_ok = True;
// Don't trigger the customer_name error
} else {
$customer_name = $customer['customer_name'];
$customer_name_ok = True;
// Don't trigger the customer_name error
}
} else {
// Maybe just the customer_name is inserted?
if (isset($_POST['customer_name']) && $_POST['customer_name'] != '') {
// Trigger error...
$customer_name_ok = False;
开发者ID:hnJaermuseet,项目名称:JM-booking,代码行数:31,代码来源:edit_entry2_datasubmit.php
示例11: user2custInfo
function user2custInfo($custNo)
{
$user = getCustomer($custNo);
$retArr = array("ID" => $user[custNo], "Name" => $user[custName], "Gender" => $user[custGender], "Date of Birth" => $user[custDOB], "Contact" => $user[custTel], "Address" => $user[custAddr], "District No" => $user[distNo]);
return $retArr;
}
开发者ID:ahmanxdd,项目名称:WebProject,代码行数:6,代码来源:User.php
示例12: getCustomer
</div><!--end of header--->
<div style="clear: both;"></div>
<div id="content" class="content">
<h1>New Payment</h1>
<div class="main-content">
<div class="data-form">
<form action="<?php
echo $_SERVER['PHP_SELF'];
?>
" method="post">
<label>Invoice Number :</label><input type="text" name="invoice_number" value="<?php
echo $invoice;
?>
" readonly >
<label>Customer Name</label> <input type="text" name="name" value="<?php
$cust = getCustomer($invoice);
echo $cust[0]['cust_name'];
?>
" readonly >
<input type="hidden" name="invoice" value="<?php
echo $invoice;
?>
" >
<label>Payment Date </label><input type="date" name="payment_date" id="from" value="<?php
echo date('m/d/Y');
?>
">
<label>Amount Paid </label><input type="number" name="amount">
<label>Payment Code</label> <input type="text" name="code" required>
<div class="controls">
开发者ID:benkip,项目名称:Reservation-system,代码行数:31,代码来源:addpayment.php
示例13: readEntryLog
//.........这里部分代码省略.........
if ($id == '0') {
$values[] = _('Nobody');
} else {
$thisone = getUser($id);
if (count($thisone)) {
$values[] = $thisone['user_name'];
}
}
}
$return[] = _('Users assigned') . ' ' . $middlestring . ' <i>' . implode(', ', $values) . '</i>';
}
break;
case 'user_assigned2':
if ($value == '') {
$return[] = _('Manual user assigned') . ' <i>' . _('not set') . '</i>';
} else {
$return[] = _('Manual user assigned') . ' ' . $middlestring . ' "' . $value . '"';
}
break;
/*
* Not in use...
case 'customer_name':
$return .= _('Customer').' '.$middlestring.' "'.$value.'"';
break;*/
/*
* Not in use...
case 'customer_name':
$return .= _('Customer').' '.$middlestring.' "'.$value.'"';
break;*/
case 'customer_id':
if ($value == 0) {
$return[] = _('Customer') . ' <i>' . _('not set') . '</i>';
} else {
$customer = getCustomer($value);
if (count($customer)) {
$return[] = _('Customer') . ' ' . $middlestring . ' <i>' . $customer['customer_name'] . '</i>';
} else {
$return[] = _('Customer ID') . ' ' . $middlestring . ' "' . $value . '"';
}
}
break;
/*
* Not in use...
case 'customer_municipal':
$return .= _('Municipal').' '.$middlestring.' "'.$value.'"';
break;*/
/*
* Not in use...
case 'customer_municipal':
$return .= _('Municipal').' '.$middlestring.' "'.$value.'"';
break;*/
case 'customer_municipal_num':
require "libs/municipals_norway.php";
if (isset($municipals[$value])) {
$return[] = _('Municipal') . ' ' . $middlestring . ' <i>' . $municipals[$value] . '</i>';
} elseif ($value == '') {
$return[] = _('Municipal') . ' <i>' . _('not set') . '</i>';
} else {
$return[] = _('Municipal') . ' ' . $middlestring . ' "' . $value . '"';
}
break;
case 'contact_person_name':
if ($value == '') {
$return[] = _('Contact person') . ' <i>' . _('not set') . '</i>';
} else {
$return[] = _('Contact person') . ' ' . $middlestring . ' "' . $value . '"';
开发者ID:HNygard,项目名称:JM-booking,代码行数:67,代码来源:functions.inc.php
示例14: chr
if ($listtype == 'servering') {
echo ' <th style="vertical-align: bottom;">Alkohol?</th>' . chr(10);
echo ' <th style="vertical-align: bottom;">' . __('Service description') . '</th>' . chr(10);
}
echo ' <th style="vertical-align: bottom;">' . __('Room') . '</th>' . chr(10);
}
echo ' </tr>' . chr(10);
while ($R = mysql_fetch_assoc($Q)) {
$entry = getEntryParseDatabaseArray($R);
if ($listtype == 'customer_list') {
if (isset($customer_list[$entry['customer_id']])) {
$customer_list[$entry['customer_id']]['c'] += $entry['num_person_child'];
$customer_list[$entry['customer_id']]['a'] += $entry['num_person_adult'];
$customer_list[$entry['customer_id']]['e']++;
} else {
$customer_list[$entry['customer_id']] = getCustomer($entry['customer_id']);
if (!count($customer_list[$entry['customer_id']])) {
$customer_list[$entry['customer_id']]['customer_id'] = $entry['customer_id'];
if ($entry['customer_id'] == 0) {
$customer_list[$entry['customer_id']]['customer_name'] = 'Ingen kunde valgt';
} else {
$customer_list[$entry['customer_id']]['customer_name'] = 'KUNDE IKKE FUNNET I DATABASE';
}
$customer_names[$entry['customer_id']] = '';
// Sort the unknowns to the top
} else {
$customer_names[$entry['customer_id']] = $customer_list[$entry['customer_id']]['customer_name'];
}
$customer_list[$entry['customer_id']]['c'] = $entry['num_person_child'];
$customer_list[$entry['customer_id']]['a'] = $entry['num_person_adult'];
$customer_list[$entry['customer_id']]['e'] = 1;
开发者ID:hnJaermuseet,项目名称:JM-booking,代码行数:31,代码来源:entry_list.php
示例15: get_language
<?php
include_once ROOT . "includes/customers.php";
$lang = get_language();
$firstname = '';
$lastname = '';
$zip = '';
$city = '';
$address1 = '';
$address2 = '';
$email = '';
if (isset($_SESSION["user"])) {
$customer = getCustomer($_SESSION["user"]->getCostumerId());
if ($customer != null) {
$firstname = $customer->getFirstname();
$lastname = $customer->getLastname();
if ($customer->getShippingAddress() != null) {
$zip = $customer->getShippingAddress()->getZip();
$city = $customer->getShippingAddress()->getCity();
$address1 = $customer->getShippingAddress()->getAddress1();
$address2 = $customer->getShippingAddress()->getAddress2();
}
$email = $customer->getEmail();
}
}
echo "<form name=\"billingForm\" action=\"index.php?site=confirm\" onsubmit=\"return validateForm();\" method=\"post\">";
echo "<table class=\"address-form-table\">";
echo "<tr>";
echo "<td class=\"address-form-table-label\">{$AddressFirstnameLabel}: </td>";
echo "<td>";
echo "<input class=\"address-form-field\" type=\"text\" name=\"firstname\" value=\"{$firstname}\" /input>";
开发者ID:nellen,项目名称:ch.bfh.bti7054.w2014.q.Web-Prophecies,代码行数:31,代码来源:billing.php
示例16: checkLogin
<?php
//stop the direct browsing to this file - let index.php handle which files get displayed
checkLogin();
$menu = false;
$payment = getPayment($_GET['id']);
/*Code to get the Invoice preference - so can link from this screen back to the invoice - START */
$invoice = getInvoice($payment['ac_inv_id']);
$biller = getBiller($payment['biller_id']);
$logo = getLogo($biller);
$logo = str_replace(" ", "%20", $logo);
$customer = getCustomer($payment['customer_id']);
$invoiceType = getInvoiceType($invoice['type_id']);
$customFieldLabels = getCustomFieldLabels();
$paymentType = getPaymentType($payment['ac_payment_type']);
$preference = getPreference($invoice['preference_id']);
$smarty->assign("payment", $payment);
$smarty->assign("invoice", $invoice);
$smarty->assign("biller", $biller);
$smarty->assign("logo", $logo);
$smarty->assign("customer", $customer);
$smarty->assign("invoiceType", $invoiceType);
$smarty->assign("paymentType", $paymentType);
$smarty->assign("preference", $preference);
$smarty->assign("customFieldLabels", $customFieldLabels);
$smarty->assign('pageActive', 'payment');
$smarty->assign('active_tab', '#money');
开发者ID:dadigo,项目名称:simpleinvoices,代码行数:27,代码来源:print.php
示例17: mysql_error
if (!$db || !@mysql_select_db(DB_NAME, $db)) {
$rsp['error'] = SL_DB_FAILURE;
$rsp['info'] = mysql_error();
respond($rsp);
}
error_log("salesApi: action " . $_REQUEST['action']);
$_silent = isset($_REQUEST['silent']) && $_REQUEST['silent'] == 'true' ? true : false;
switch ($_REQUEST['action']) {
case 'getCustomerList':
return getCustomerList();
case 'getPaymentList':
return getPaymentList();
case 'getCustomerNames':
return getCustomerNames();
case 'getCustomer':
return getCustomer();
case 'getPaymentDetails':
return getPaymentDetails();
case 'getPaymentHistory':
return getPaymentHistory();
case 'getLastPayment':
return getLastPayment();
case 'newInstance':
return newInstance($_silent);
case 'updateInstanceData':
return updateInstanceData();
default:
break;
}
// Respond positively
$rsp['status'] = SL_OK;
开发者ID:highfidelity,项目名称:love,代码行数:31,代码来源:api.php
示例18: getCustomer
if (count($address)) {
$invoice->invoice_to_line1 = $address['address_line_1'];
$invoice->invoice_to_line2 = $address['address_line_2'];
$invoice->invoice_to_line3 = $address['address_line_3'];
$invoice->invoice_to_line4 = $address['address_line_4'];
$invoice->invoice_to_line5 = $address['address_line_5'];
$invoice->invoice_to_line6 = $address['address_line_6'];
$invoice->invoice_to_line7 = $address['address_line_7'];
} else {
$invoice->invoice_to_address_id = '';
}
} else {
$invoice->invoice_to_address_id = '';
}
if ($invoice->invoice_to_customer_id > 0) {
$customer = getCustomer($invoice->invoice_to_customer_id);
if (count($customer)) {
$invoice->invoice_to_customer_name = $customer['customer_name'];
}
}
}
}
}
require "include/invoice_menu.php";
if (isset($preview) && $preview) {
echo '<h1>Forhåndsvisning</h2>';
echo '<b>(Opprettelse forsetter under)</b><br>';
echo '<div style="border: 1px solid black; overflow: auto; width: 800px; height: 400px;">';
$smarty = new Smarty();
templateAssignInvoice('smarty', $invoice);
templateAssignSystemvars('smarty');
开发者ID:HNygard,项目名称:JM-booking,代码行数:31,代码来源:invoice_create.php
示例19: SCart
include_once "Brain/User.php";
include "header1.php";
?>
<link href="css/register.css" rel="stylesheet" type="text/css" />
<script src='js/register.js'> </script>
<?php
include "Brain/District.php";
include "Brain/UserControl.php";
include "header2.php";
include_once "Brain/ShoppingCart.php";
$cart = new SCart();
if (isset($_GET["error"])) {
echo "<script> alert('Sorry, we only delivery two day after order.')</script>";
}
if (UserControl::checkState() && UserControl::getType() == 'c') {
$cust = getCustomer(getInfo(UserControl::getUserNo())[ID]);
if (isset($_POST[distNo], $_POST[custAddr], $_POST["sdate"])) {
$date = strtotime($_POST["sdate"]);
$minday = strtotime(date("Y-m-d", strtotime("+ 2 days")));
if ($date < $minday) {
header("Location: checkout.php?error=true");
} else {
if ($cart->checkout($_POST["sdate"], "100", $_POST[custAddr], $cust[custNo], $_POST[distNo])) {
header("Location: shoppingcart.php?sucess=true");
} else {
echo "<script> alert('Sorry!');</script>";
}
}
}
$district = getAllDistricts();
$box = "<select name='distNo'>";
开发者ID:ahmanxdd,项目名称:WebProject,代码行数:31,代码来源:checkout.php
示例20: run
public function run()
{
global $db;
$today = date('Y-m-d');
$cron = new cron();
$data = $cron->select_crons_to_run();
$return['cron_message'] = "Cron started";
$number_of_crons_run = "0";
$cron_log = new cronlog();
$cron_log->run_date = $today;
foreach ($data as $key => $value) {
$cron->domain_id = $value['domain_id'];
$cron_log->cron_id = $value['id'];
$cron_log->domain_id = $domain_id = $value['domain_id'];
$check_cron_log = $cron_log->check();
$i = "0";
if ($check_cron_log == 0) {
//only proceed if cron has not been run for today
$run_cron = false;
$start_date = date('Y-m-d', strtotime($value['start_date']));
$end_date = $value['end_date'];
// Seconds in a day = 60 * 60 * 24 = 86400
$diff = number_format((strtotime($today) - strtotime($start_date)) / 86400, 0);
//only check if diff is positive
if ($diff >= 0 and ($end_date == "" or $end_date >= $today)) {
if ($value['recurrence_type'] == 'day') {
$modulus = $diff % $value['recurrence'];
if ($modulus == 0) {
$run_cron = true;
} else {
#$return .= "cron does not runs TODAY-days";
}
}
if ($value['recurrence_type'] == 'week') {
$period = 7 * $value['recurrence'];
$modulus = $diff % $period;
if ($modulus == 0) {
$run_cron = true;
} else {
#$return .= "cron is not runs TODAY-week";
}
}
if ($value['recurrence_type'] == 'month') {
$start_day = date('d', strtotime($value['start_date']));
$start_month = date('m', strtotime($value['start_date']));
$start_year = date('Y', strtotime($value['start_date']));
$today_day = date('d');
$today_month = date('m');
$today_year = date('Y');
$months = $today_month - $start_month + 12 * ($today_year - $start_year);
$modulus = $months % $value['recurrence'];
if ($modulus == 0 and $start_day == $today_day) {
$run_cron = true;
} else {
#$return .= "cron is not runs TODAY-month";
}
}
if ($value['recurrence_type'] == 'year') {
$start_day = date('d', strtotime($value['start_date']));
$start_month = date('m', strtotime($value['start_date']));
$start_year = date('Y', strtotime($value['start_date']));
$today_day = date('d');
$today_month = date('m');
$today_year = date('Y');
$years = $today_year - $start_year;
$modulus = $years % $value['recurrence'];
if ($modulus == 0 and $start_day == $today_day and $start_month == $today_month) {
$run_cron = true;
} else {
#$return .= "cron is not runs TODAY-year";
}
}
//run the recurrence for this invoice
if ($run_cron) {
$number_of_crons_run++;
$return['cron_message_' . $value['cron_id']] = "Cron ID: " . $value['cron_id'] . " - Cron for " . $value['index_name'] . " with start date of " . $value['start_date'] . ", end date of " . $value['end_date'] . " where it runs each " . $value['recurrence'] . " " . $value['recurrence_type'] . " was run today :: Info diff=" . $diff;
$i++;
$ni = new invoice();
$ni->id = $value['invoice_id'];
$ni->domain_id = $domain_id;
// $domain_id gets propagated from invoice to be copied from
$new_invoice_id = $ni->recur();
//insert into cron_log date of run
//$cron_log = new cronlog();
//$cron_log->run_date = $today;
//$cron_log->domain_id = $domain_id;
//$cron_log->cron_id = $value['cron_id'];
$cron_log->insert();
## email the people
$invoiceobj = new invoice();
$invoice = $invoiceobj->select($new_invoice_id, $domain_id);
$preference = getPreference($invoice['preference_id'], $domain_id);
$biller = getBiller($invoice['biller_id'], $domain_id);
$customer = getCustomer($invoice['customer_id'], $domain_id);
#print_r($customer);
#create PDF nameVj
$spc2us_pref = str_replace(" ", "_", $invoice['index_name']);
$pdf_file_name_invoice = $spc2us_pref . ".pdf";
// email invoice
if ($value['email_biller'] == "1" or $value['email_customer'] == "1") {
//.........这里部分代码省略.........
开发者ID:dadigo,项目名称:simpleinvoices,代码行数:101,代码来源:cron.php
注:本文中的getCustomer函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论