Inheritance: extends CI_Controller
コード例 #1
0
 /**
  * Delete a customer record
  */
 public function deleteAction()
 {
     $customersTable = new Customers();
     $customer = $customersTable->find($this->_getParam('id'))->current();
     !is_null($customer) && $customer->delete();
     $this->_redirect('/customers');
 }
コード例 #2
0
function contacts_holidays_list_BeforeShow(&$sender)
{
    $contacts_holidays_list_BeforeShow = true;
    $Component =& $sender;
    $Container =& CCGetParentContainer($sender);
    global $contacts_holidays_list;
    //Compatibility
    //End contacts_holidays_list_BeforeShow
    //Custom Code @22-2A29BDB7
    // -------------------------
    // Write your own code here.
    $del_guid = CCGetFromGet("del_guid", "");
    $o = CCGetFromGet("o", "");
    if ($o == "delrecord" && strlen($del_guid) > 0) {
        global $FileName;
        $params["guid"] = $del_guid;
        $customers = new Customers();
        $customers->deleteHolidaysByGuid($params);
        $querystring = CCGetQueryString("QueryString", array("o", "del_guid"));
        //Forcing redirect
        header("Location: {$FileName}?{$querystring}");
    }
    // -------------------------
    //End Custom Code
    //Close contacts_holidays_list_BeforeShow @1-2AE37F02
    return $contacts_holidays_list_BeforeShow;
}
コード例 #3
0
function getCompanyName($id)
{
    $localvars = localvars::getInstance();
    $validate = new validate();
    $customers = new Customers();
    $returnValue = "";
    if (isnull($id) && !$validate->integer($id)) {
        throw new Exception('not valid integer');
        return false;
    } else {
        $data = $customers->getRecords($id);
        $returnValue = $data[0]['companyName'];
        return $returnValue;
    }
}
コード例 #4
0
 public static function fromArray($data)
 {
     $settings = new RoleSettings();
     foreach ($data as $key => $value) {
         if (property_exists(get_class($settings), $key)) {
             if (is_array($value)) {
                 if ($key == "transactions") {
                     $settings->{$key} = Transactions::fromArray($value);
                 }
                 if ($key == "reports") {
                     $settings->{$key} = Reports::fromArray($value);
                 }
                 if ($key == "help") {
                     $settings->{$key} = Help::fromArray($value);
                 }
                 if ($key == "mobileVTAccess") {
                     $settings->{$key} = MobileVTAcces::fromArray($value);
                 }
                 if ($key == "admin") {
                     $settings->{$key} = Admin::fromArray($value);
                 }
                 if ($key == "customer") {
                     $settings->{$key} = Customers::fromArray($value);
                 }
                 if ($key == "webPosAccess") {
                     $settings->{$key} = WebPosAccess::fromArray($value);
                 }
             } else {
                 $settings->{$key} = $value;
             }
         }
     }
     return $settings;
 }
コード例 #5
0
ファイル: Customers.php プロジェクト: kokkez/shineisp
 public function customers()
 {
     $registry = Shineisp_Registry::getInstance();
     $translator = $registry->Zend_Translate;
     $this->view->customers = Customers::getList($translator->translate('Select the customer ...'), array(array('where' => 'u.status_id = ?', 'params' => Statuses::id('active', 'customers'))));
     return $this->view->render('partials/customers.phtml');
 }
コード例 #6
0
ファイル: Email.php プロジェクト: kokkez/shineisp
 public function isValid($value)
 {
     $customer = Customers::getCustomerbyEmail($value);
     if (isset($customer[0])) {
         $this->_error(self::ALREADYUSED);
         return false;
     } else {
         return true;
     }
 }
コード例 #7
0
ファイル: AjaxController.php プロジェクト: hoaitn/base-zend
 public function customerloginAction()
 {
     $response['code'] = 'Invalid ID or password.';
     $email = $this->getRequest()->getParam('email');
     $password = $this->getRequest()->getParam('password');
     $Customer = Customers::setCustomerLogin($email, $password);
     if ($Customer) {
         $Customer->setLastLogin();
         $_SESSION['Customer'] = $Customer;
         $response['code'] = 'SUCCESS';
     }
     echo json_encode($response);
 }
コード例 #8
0
ファイル: Ordersitems.php プロジェクト: kokkez/shineisp
 public function getAll($uuid)
 {
     $customers = Customers::findWithUuid($uuid);
     if (empty($customers)) {
         throw new Shineisp_Api_Exceptions(400006, ":: 'uuid' not valid");
         exit;
     }
     $id = $customers['customer_id'];
     $services = Products::getAllServicesByCustomerID($id, 'o.order_id, oi.detail_id as detail_id, pd.name as productname, 
     DATE_FORMAT(oi.date_start, "%d/%m/%Y") AS date_start, DATE_FORMAT(oi.date_end, "%d/%m/%Y") AS date_end, 
     DATEDIFF(oi.date_end, CURRENT_DATE) AS daysleft, oi.price as price, oi.autorenew as autorenew, oi.uuid as uuid, s.status as status');
     return $services;
 }
コード例 #9
0
 public function actionIndex()
 {
     if (Helper::checkRoute('index')) {
         $searchModel = new ProvinceSearch();
         $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
         if (Yii::$app->request->post('hasEditable')) {
             $ID = \Yii::$app->request->post('editableKey');
             $model = Customers::findOne($ID);
             $out = Json::encode(['output' => '', 'message' => '']);
             // fetch the first entry in posted data (there should
             // only be one entry anyway in this array for an
             // editable submission)
             // - $posted is the posted data for Book without any indexes
             // - $post is the converted array for single model validation
             $post = [];
             $posted = current($_POST['Customers']);
             $post['Customers'] = $posted;
             // load model like any single model validation
             if ($model->load($post)) {
                 // can save model or do something before saving model
                 $model->save();
                 // custom output to return to be displayed as the editable grid cell
                 // data. Normally this is empty - whereby whatever value is edited by
                 // in the input by user is updated automatically.
                 $output = '';
                 // specific use case where you need to validate a specific
                 // editable column posted when you have more than one
                 // EditableColumn in the grid view. We evaluate here a
                 // check to see if buy_amount was posted for the Book model
                 if (isset($posted['CUST_KD_ALIAS'])) {
                     // $output =  Yii::$app->formatter->asDecimal($model->EMP_NM, 2);
                     $output = $model->CUST_KD_ALIAS;
                 }
                 // similarly you can check if the name attribute was posted as well
                 // if (isset($posted['name'])) {
                 //   $output =  ''; // process as you need
                 // }
                 $out = Json::encode(['output' => $output, 'message' => '']);
                 // return ajax json encoded response and exit
                 echo $out;
                 return;
             }
         }
         return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
     } else {
         Yii::$app->user->logout();
         $this->redirect(array('/site/login'));
         //
     }
 }
コード例 #10
0
ファイル: Orders.php プロジェクト: eix/catalog
 /**
  * Get an order, first checking if the current user can view it.
  */
 protected function getEntity($id)
 {
     // Fetch the order from the ID.
     $order = Orders::getInstance()->findEntity($id);
     // Find the customer whom the order belongs to.
     $orderCustomerId = $order->getCustomer()->getId();
     if ($orderCustomerId != Customers::getCurrent()->getId()) {
         // A 'not found' exception is thrown instead of the expected 'not
         // authorised' to prevent order enumeration from malicious users.
         throw new NotFoundException('The current customer cannot use this order.');
     }
     // Everything looks fine, return the order.
     return $order;
 }
コード例 #11
0
 public static function filter($input, $limit = 24)
 {
     return Customers::where(function ($query) use($input) {
         if (array_key_exists('name', $input) && strlen($input['name'])) {
             $query->where('name', 'LIKE', "%" . $input['name'] . "%");
         }
         if (array_key_exists('address', $input) && strlen($input['address'])) {
             $query->where('address', 'LIKE', "%" . $input['address'] . "%");
         }
         if (array_key_exists('contact', $input) && strlen($input['contact'])) {
             $query->where('contact', 'LIKE', "%" . $input['contact'] . "%");
         }
     })->orderBy('name', 'asc')->paginate($limit);
 }
コード例 #12
0
ファイル: InvoicesForm.php プロジェクト: kokkez/shineisp
 public function init()
 {
     // Set the custom decorator
     $this->addElementPrefixPath('Shineisp_Decorator', 'Shineisp/Decorator/', 'decorator');
     $translate = Shineisp_Registry::get('Zend_Translate');
     $this->addElement('text', 'invoice_date', array('filters' => array('StringTrim'), 'required' => true, 'label' => $translate->_('Date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control date', 'dateformat' => Settings::getJsDateFormat()));
     $this->addElement('select', 'order_id', array('label' => $translate->_('Order No.'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('order_id')->setAllowEmpty(false)->setMultiOptions(Orders::getList(true));
     $this->addElement('select', 'customer_parent_id', array('label' => $translate->_('Invoice destination'), 'decorators' => array('Bootstrap'), 'class' => 'form-control', 'disable' => 'true'));
     $this->getElement('customer_parent_id')->setAllowEmpty(true)->setMultiOptions(Customers::getList(true));
     $this->addElement('text', 'number', array('filters' => array('StringTrim'), 'required' => true, 'label' => $translate->_('Sequential number'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'formatted_number', array('filters' => array('StringTrim'), 'required' => false, 'label' => $translate->_('Invoice number'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('textarea', 'note', array('filters' => array('StringTrim'), 'label' => $translate->_('Private Notes'), 'decorators' => array('Bootstrap'), 'class' => 'col-lg-12 form-control wysiwyg'));
     $this->addElement('hidden', 'invoice_id');
 }
コード例 #13
0
ファイル: TicketsForm.php プロジェクト: kokkez/shineisp
 public function init()
 {
     // Set the custom decorator
     $this->addElementPrefixPath('Shineisp_Decorator', 'Shineisp/Decorator/', 'decorator');
     $translate = Shineisp_Registry::get('Zend_Translate');
     $this->addElement('text', 'subject', array('filters' => array('StringTrim'), 'required' => false, 'decorators' => array('Bootstrap'), 'label' => $translate->_('Subject'), 'class' => 'form-control'));
     $this->addElement('text', 'datetime', array('filters' => array('StringTrim'), 'label' => $translate->_('Date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('textarea', 'note', array('filters' => array('StringTrim'), 'class' => 'col-lg-12 form-control wysiwyg'));
     $this->addElement('select', 'sendemail', array('label' => $translate->_('Send Email'), 'description' => $translate->_('Send an email to the customer.'), 'decorators' => array('Bootstrap'), 'class' => 'form-control', 'multioptions' => array('1' => $translate->_('Yes'), '0' => $translate->_('No'))));
     $this->addElement('select', 'category_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Category'), 'class' => 'form-control'));
     $this->getElement('category_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(TicketsCategories::getList());
     $this->addElement('select', 'customer_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Customer'), 'class' => 'form-control'));
     $this->getElement('customer_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Customers::getList());
     $this->addElement('select', 'category', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Category'), 'class' => 'form-control'));
     $this->getElement('category')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(TicketsCategories::getList());
     $this->addElement('select', 'order_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Order reference'), 'class' => 'form-control'));
     $this->getElement('order_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Orders::getList(true));
     $this->addElement('select', 'sibling_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Relationships'), 'class' => 'form-control'));
     $this->getElement('sibling_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false);
     $this->addElement('select', 'user_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Operator'), 'class' => 'form-control'));
     $this->getElement('user_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(AdminUser::getList());
     #->setMultiOptions(AdminUser::getUserbyRoleID(AdminRoles::getIdRoleByName('operator')));
     $this->addElement('select', 'status_id', array('decorators' => array('Bootstrap'), 'label' => $translate->_('Status'), 'class' => 'form-control'));
     $this->getElement('status_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Statuses::getList('tickets'));
     // If the browser client is an Apple client hide the file upload html object
     if (false == Shineisp_Commons_Utilities::isAppleClient()) {
         $MBlimit = Settings::findbyParam('adminuploadlimit');
         $Types = Settings::findbyParam('adminuploadfiletypes', 'Admin');
         if (empty($MBlimit)) {
             $MBlimit = 1;
         }
         if (empty($Types)) {
             $Types = "zip,jpg";
         }
         $Byteslimit = Shineisp_Commons_Utilities::MB2Bytes($MBlimit);
         $file = $this->createElement('file', 'attachments', array('label' => $translate->_('Attachment'), 'decorators' => array('File', array('ViewScript', array('viewScript' => 'partials/file.phtml', 'placement' => false))), 'description' => $translate->_('Select the document to upload. Files allowed are (%s) - Max %s', $Types, Shineisp_Commons_Utilities::formatSizeUnits($Byteslimit)), 'data-classButton' => 'btn btn-primary', 'data-input' => 'false', 'class' => 'filestyle'));
         $file->addValidator('Extension', false, $Types)->addValidator('Size', false, $Byteslimit)->addValidator('Count', false, 1);
         $this->addElement($file);
     } else {
         $this->addElement('hidden', 'attachments');
     }
     $this->addElement('hidden', 'ticket_id');
 }
コード例 #14
0
ファイル: IntroVisit.php プロジェクト: Headrun-php/TLG
 static function addSchedule($inputs)
 {
     $introVisit = new IntroVisit();
     $introVisit['customer_id'] = $inputs['customerId'];
     $introVisit->student_id = $inputs['studentIdIntroVisit'];
     $introVisit->class_id = $inputs['eligibleClassesCbx'];
     $introVisit->batch_id = $inputs['introbatchCbx'];
     //$introVisit->status             = 'ACTIVE/SCHEDULED';
     $introVisit->franchisee_id = Session::get('franchiseId');
     $introVisit->iv_date = date('Y-m-d', strtotime($inputs['introVisitTxtBox']));
     $introVisit->created_by = Session::get('userId');
     $introVisit->created_at = date("Y-m-d H:i:s");
     $introVisit->save();
     $customerObj = Customers::find($inputs['customerId']);
     if ($customerObj) {
         $customerObj->stage = "IV SCHEDULED";
         $customerObj->save();
     }
     return $introVisit;
 }
コード例 #15
0
ファイル: PaymentsForm.php プロジェクト: kokkez/shineisp
 public function init()
 {
     // Set the custom decorator
     $this->addElementPrefixPath('Shineisp_Decorator', 'Shineisp/Decorator/', 'decorator');
     $translate = Shineisp_Registry::get('Zend_Translate');
     $this->addElement('text', 'paymentdate', array('filters' => array('StringTrim'), 'required' => true, 'label' => $translate->_('Payment date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control date', 'dateformat' => Settings::getJsDateFormat()));
     $this->addElement('text', 'reference', array('filters' => array('StringTrim'), 'label' => $translate->_('Transaction Reference'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'income', array('filters' => array('StringTrim'), 'label' => $translate->_('Income'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'outcome', array('filters' => array('StringTrim'), 'label' => $translate->_('Expense'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('select', 'confirmed', array('filters' => array('StringTrim'), 'label' => $translate->_('Does the Transaction has been confirmed?'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('confirmed')->setAllowEmpty(false)->setMultiOptions(array('0' => "No, it has been not", '1' => "Yes, it has been"));
     $this->addElement('select', 'bank_id', array('decorators' => array('Bootstrap'), 'label' => 'Method of Payments', 'class' => 'form-control'));
     $this->getElement('bank_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Banks::getList());
     $this->addElement('select', 'order_id', array('decorators' => array('Bootstrap'), 'label' => 'Order', 'class' => 'form-control'));
     $this->getElement('order_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Orders::getList());
     $this->addElement('select', 'customer_id', array('decorators' => array('Bootstrap'), 'label' => 'Customer', 'class' => 'form-control'));
     $this->getElement('customer_id')->setAllowEmpty(false)->setRegisterInArrayValidator(false)->setMultiOptions(Customers::getList());
     $this->addElement('textarea', 'description', array('filters' => array('StringTrim'), 'label' => $translate->_('Description'), 'id' => 'description', 'rows' => '3', 'decorators' => array('Bootstrap'), 'class' => 'col-lg-12 form-control'));
     $this->addElement('hidden', 'payment_id');
 }
コード例 #16
0
 /**
  * Resets all references to other model objects or collections of model objects.
  *
  * This method is a user-space workaround for PHP's inability to garbage collect
  * objects with circular references (even in PHP 5.3). This is currently necessary
  * when using Propel in certain daemon or large-volume/high-memory operations.
  *
  * @param boolean $deep Whether to also clear the references on all referrer objects.
  */
 public function clearAllReferences($deep = false)
 {
     if ($deep && !$this->alreadyInClearAllReferencesDeep) {
         $this->alreadyInClearAllReferencesDeep = true;
         if ($this->collDetailTransaksis) {
             foreach ($this->collDetailTransaksis as $o) {
                 $o->clearAllReferences($deep);
             }
         }
         if ($this->aCustomers instanceof Persistent) {
             $this->aCustomers->clearAllReferences($deep);
         }
         $this->alreadyInClearAllReferencesDeep = false;
     }
     // if ($deep)
     if ($this->collDetailTransaksis instanceof PropelCollection) {
         $this->collDetailTransaksis->clearIterator();
     }
     $this->collDetailTransaksis = null;
     $this->aCustomers = null;
 }
コード例 #17
0
ファイル: DomainsForm.php プロジェクト: kokkez/shineisp
 public function init()
 {
     // Set the custom decorator
     $this->addElementPrefixPath('Shineisp_Decorator', 'Shineisp/Decorator/', 'decorator');
     $translate = Shineisp_Registry::get('Zend_Translate');
     $this->addElement('text', 'domain', array('filters' => array('StringTrim'), 'required' => true, 'decorators' => array('Bootstrap'), 'label' => $translate->_('Domain'), 'description' => $translate->_('Write down the name of the domain without any extension, white spaces, or symbols.'), 'class' => 'form-control updatechkdomain'));
     $this->addElement('select', 'tld_id', array('label' => $translate->_('TLD'), 'description' => $translate->_('Select the TLD from the list'), 'decorators' => array('Bootstrap'), 'class' => 'form-control updatechkdomain'));
     $this->getElement('tld_id')->setAllowEmpty(false)->setMultiOptions(DomainsTlds::getList())->setRequired(true);
     $this->addElement('select', 'registrars_id', array('label' => $translate->_('Registrar'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('registrars_id')->setAllowEmpty(true)->setMultiOptions(Registrars::getList());
     // Domain Ownership
     $this->addElement('select', 'owner', array('label' => $translate->_('Owner'), 'description' => $translate->_("If the domain owner's profile is not set, the domain customer information will be used."), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('owner')->setAllowEmpty(true)->setMultiOptions(DomainsProfiles::getList(true));
     $this->addElement('select', 'admin', array('label' => $translate->_('Admin-C'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('admin')->setAllowEmpty(true)->setMultiOptions(DomainsProfiles::getList(true));
     $this->addElement('select', 'tech', array('label' => $translate->_('Tech'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('tech')->setAllowEmpty(true)->setMultiOptions(DomainsProfiles::getList(true));
     $this->addElement('select', 'billing', array('label' => $translate->_('Billing'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('billing')->setAllowEmpty(true)->setMultiOptions(DomainsProfiles::getList(true));
     $this->addElement('text', 'creation_date', array('filters' => array('StringTrim'), 'label' => $translate->_('Creation date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control date', 'dateformat' => Settings::getJsDateFormat()));
     $this->addElement('text', 'expiring_date', array('filters' => array('StringTrim'), 'label' => $translate->_('Expiry Date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control date', 'dateformat' => Settings::getJsDateFormat()));
     $this->addElement('text', 'authinfocode', array('filters' => array('StringTrim'), 'label' => $translate->_('AUTHINFO CODE'), 'description' => $translate->_('Write down the Authinfo code in order to transfer the domain to this ISP'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('checkbox', 'autorenew', array('filters' => array('StringTrim'), 'decorators' => array('Bootstrap'), 'label' => $translate->_('Auto renewal'), 'class' => 'form-control'));
     $this->addElement('select', 'customer_id', array('label' => $translate->_('Customer'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('customer_id')->setAllowEmpty(false)->setMultiOptions(Customers::getList())->setRequired(true);
     //
     $note = $this->addElement('textarea', 'note', array('filters' => array('StringTrim'), 'decorators' => array('Bootstrap'), 'label' => $translate->_('Private Notes'), 'class' => 'col-lg-12 form-control'));
     $note = $this->addElement('textarea', 'message', array('filters' => array('StringTrim'), 'required' => false, 'decorators' => array('Bootstrap'), 'label' => $translate->_('Message'), 'class' => 'col-lg-12 form-control wysiwyg'));
     $status = $this->addElement('select', 'status_id', array('label' => 'Status', 'required' => true, 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     // DNS SECTION
     // ==============
     $this->addElement('text', 'subdomain', array('filters' => array('StringTrim'), 'decorators' => array('Bootstrap'), 'label' => $translate->_('Subdomain'), 'class' => 'form-control'));
     $this->addElement('text', 'target', array('filters' => array('StringTrim'), 'decorators' => array('Bootstrap'), 'label' => $translate->_('Target'), 'class' => 'form-control'));
     $this->addElement('select', 'zone', array('label' => $translate->_('Zone'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('zone')->setAllowEmpty(false)->setMultiOptions(Dns_Zones_Types::getZones());
     $status = $this->getElement('status_id')->setAllowEmpty(false)->setMultiOptions(Statuses::getList('domains'));
     $save = $this->addElement('submit', 'save', array('required' => false, 'label' => $translate->_('Save'), 'decorators' => array('Bootstrap'), 'class' => 'btn'));
     $id = $this->addElement('hidden', 'domain_id');
 }
コード例 #18
0
 public function indexAction()
 {
     $auth = Zend_Auth::getInstance();
     $registry = Shineisp_Registry::getInstance();
     $translation = Shineisp_Registry::get('Zend_Translate');
     $retval = array();
     if ($auth->hasIdentity()) {
         $request = Zend_Controller_Front::getInstance()->getRequest();
         try {
             $form = new Admin_Form_BulkmailForm(array('action' => '/admin/bulkmail/#bulkmail', 'method' => 'post'));
             if ($request->isPost()) {
                 $isp = Isp::getActiveISP();
                 if ($form->isValid($request->getPost())) {
                     $data = $request->getPost();
                     $mail = new Bulkmails();
                     $mail->subject = $data['subject'];
                     $mail->body = $data['body'];
                     $mail->senddate = date('Y-m-d H:i:s');
                     $mail->save();
                     $customers = Customers::getEmails();
                     foreach ($customers as $customer) {
                         $body = str_replace('{fullname}', $customer['fullname'], $data['body']);
                         $result = Shineisp_Commons_Utilities::SendEmail($isp['email'], $customer['email'], null, $data['subject'], $body, true);
                         if ($result !== true) {
                             $retval[] = $result;
                         }
                     }
                 }
             }
             $retval = count($retval) > 0 ? $retval : null;
             $this->view->form = $form;
             $this->view->title = $translation->translate("Mass eMail");
             $this->view->description = $translation->translate("Write here a message to send to all your own customers.");
             $this->view->errors = $retval;
         } catch (Exception $e) {
             die($e->getMessage());
         }
     }
 }
コード例 #19
0
ファイル: Customers.php プロジェクト: kokkez/shineisp
 public function insert($params)
 {
     $this->authenticate();
     $form = new Api_Form_CustomerForm(array('action' => '#', 'method' => 'post'));
     if (array_key_exists('countrycode', $params)) {
         $country_id = Countries::getIDbyCode($params['countrycode']);
         if ($country_id == null) {
             throw new Shineisp_Api_Exceptions(400005, ":: 'countrycode' not valid");
             exit;
         }
         unset($params['coutrycode']);
         $params['country_id'] = $country_id;
     }
     if (array_key_exists('provincecode', $params) && $params['provincecode'] != "") {
         $params['area'] = $params['provincecode'];
         unset($params['provincecode']);
     }
     if ($form->isValid($params)) {
         if ($params['status'] == false) {
             $params['status'] = 'disabled';
         }
         $idcustomers = Customers::Create($params);
         $customer = Customers::find($idcustomers);
         return $customer['uuid'];
     } else {
         $errors = $form->getMessages();
         $message = "";
         foreach ($errors as $field => $errorsField) {
             $message .= "Field '{$field}'<br/>";
             foreach ($errorsField as $error => $describe) {
                 $message .= " => {$error} ({$describe})";
             }
         }
         throw new Shineisp_Api_Exceptions(400004, ":\n{$message}");
         exit;
     }
 }
コード例 #20
0
 public function init()
 {
     // Set the custom decorator
     $this->addElementPrefixPath('Shineisp_Decorator', 'Shineisp/Decorator/', 'decorator');
     $translate = Shineisp_Registry::get('Zend_Translate');
     $this->addElement('select', 'customer_id', array('label' => $translate->_('Owner of the domain profile'), 'description' => $translate->_('This is the customer who has created the domain profiles.'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('customer_id')->setAllowEmpty(false)->setMultiOptions(Customers::getList())->setRequired(true);
     $this->addElement('text', 'firstname', array('filters' => array('StringTrim'), 'required' => true, 'label' => $translate->_('Firstname'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'lastname', array('filters' => array('StringTrim'), 'required' => true, 'label' => $translate->_('Lastname'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('select', 'gender', array('label' => $translate->_('Gender'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('gender')->setAllowEmpty(true)->setMultiOptions(array('M' => $translate->translate('Man'), 'F' => $translate->translate('Female')));
     $this->addElement('text', 'birthdate', array('filters' => array('StringTrim'), 'label' => $translate->_('Birth date'), 'decorators' => array('Bootstrap'), 'class' => 'form-control date'));
     $this->addElement('text', 'birthplace', array('filters' => array('StringTrim'), 'label' => $translate->_('Birth place'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'birthdistrict', array('filters' => array('StringTrim'), 'label' => $translate->_('Birth district'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'birthcountry', array('filters' => array('StringTrim'), 'label' => $translate->_('Birth country'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'birthnationality', array('filters' => array('StringTrim'), 'label' => $translate->_('Birth nationality'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('select', 'type_id', array('label' => $translate->_('Company Type'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('type_id')->setAllowEmpty(true)->setMultiOptions(CompanyTypes::getList(true));
     $this->addElement('select', 'legalform_id', array('label' => 'Legal form', 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('legalform_id')->setAllowEmpty(true)->setMultiOptions(Legalforms::getList());
     $this->addElement('text', 'company', array('filters' => array('StringTrim'), 'label' => $translate->_('Company Name'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'vat', array('filters' => array('StringTrim'), 'label' => $translate->_('VAT Number'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'taxpayernumber', array('filters' => array('StringTrim'), 'label' => $translate->_('Taxpayer Number'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'address', array('filters' => array('StringTrim'), 'label' => $translate->_('Address'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'zip', array('filters' => array('StringTrim'), 'label' => $translate->_('Zip code'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'area', array('filters' => array('StringTrim'), 'label' => $translate->_('Area'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'city', array('filters' => array('StringTrim'), 'label' => $translate->_('City'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('select', 'country_id', array('label' => $translate->_('Country'), 'decorators' => array('Bootstrap'), 'class' => 'form-control', 'onchange' => 'onChangeCountry( this );'));
     $this->getElement('country_id')->setAllowEmpty(false)->setMultiOptions(Countries::getList(true))->setRequired(true);
     $this->addElement('text', 'phone', array('filters' => array('StringTrim'), 'label' => $translate->_('Phone'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'fax', array('filters' => array('StringTrim'), 'label' => $translate->_('Fax'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->addElement('text', 'email', array('filters' => array('StringTrim', 'StringToLower'), 'decorators' => array('Bootstrap'), 'validators' => array('EmailAddress'), 'required' => true, 'label' => $translate->_('Email'), 'class' => 'form-control'));
     $this->addElement('select', 'status_id', array('label' => $translate->_('Status'), 'decorators' => array('Bootstrap'), 'class' => 'form-control'));
     $this->getElement('status_id')->setAllowEmpty(false)->setMultiOptions(Statuses::getList('customers'));
     $this->addElement('hidden', 'profile_id');
 }
コード例 #21
0
                        $message .= 'Payment Processing Gross Price: ' . $total . "<br />\n";
                        write_log($message);
                        break;
                    }
                    $sql = 'UPDATE ' . TABLE_ORDERS . ' SET
								status = 2,
								transaction_number = \'' . $transaction_number . '\',
								payment_date = \'' . date('Y-m-d H:i:s') . '\',
								status_changed = \'' . date('Y-m-d H:i:s') . '\',
								payment_type = 1,
								payment_method = ' . $payment_method . '
							WHERE order_number = \'' . $order_number . '\'';
                    if (database_void_query($sql)) {
                        // update customer orders/listings amount
                        Customers::SetOrdersForCustomer($result[0]['customer_id'], '+');
                        Customers::SetListingsForCustomer($result[0]['customer_id'], $result[0]['advertise_plan_id'], $result[0]['listings_amount'], '+');
                        // send email to customer
                        if (Orders::SendOrderEmail($order_number, 'completed', $result[0]['customer_id'])) {
                            write_log($sql, _ORDER_PLACED_MSG);
                        } else {
                            write_log($sql, _ORDER_ERROR);
                        }
                    } else {
                        write_log($sql, mysql_error());
                    }
                } else {
                    write_log($sql, 'Error: no records found. ' . mysql_error());
                }
                break;
            case 'Updated':
                // 3 updated already
コード例 #22
0
function licensing_customerscontent_BeforeShow(&$sender)
{
    $licensing_customerscontent_BeforeShow = true;
    $Component =& $sender;
    $Container =& CCGetParentContainer($sender);
    global $licensing_customerscontent;
    //Compatibility
    //End licensing_customerscontent_BeforeShow
    //Custom Code @152-2A29BDB7
    // -------------------------
    // Write your own code here.
    global $Tpl;
    $tab = CCGetFromGet("tab", "tab1_active");
    switch ($tab) {
        default:
        case "details":
            $Tpl->setvar("tab1_active", "active");
            break;
        case "licensing":
            $Tpl->setvar("tab2_active", "active");
            break;
        case "licenselist":
            $Tpl->setvar("tab3_active", "active");
            break;
        case "licensearchive":
            $Tpl->setvar("tab4_active", "active");
            break;
        case "competitor_renewals":
            $Tpl->setvar("tab5_active", "active");
            break;
        case "product_displacement":
            $Tpl->setvar("tab6_active", "active");
            break;
    }
    //Setting the active tab for licensing when the cssForm is present and has licensing as the form submitted
    $cssForm = trim(CCGetFromGet("ccsForm", ""));
    if ($cssForm == "licensing") {
        //Whichever tab set will be reset to avoid more than 1 tab active
        $Tpl->setvar("tab1_active", "");
        $Tpl->setvar("tab2_active", "active");
        $Tpl->setvar("tab3_active", "");
        $Tpl->setvar("tab4_active", "");
        $Tpl->setvar("tab5_active", "");
        $Tpl->setvar("tab6_active", "");
    }
    //Settingup saved message popup
    global $MainPage;
    $showalert = CCGetSession("showalert", "hide");
    $MainPage->Attributes->SetValue("showalert", $showalert);
    if ($showalert == "show") {
        CCSetSession("showalert", "hide");
    }
    //Setting up alerts to let user know the customer has not contacts yet
    $customers = new Customers();
    $customer_guid = CCGetFromGet("guid", "");
    $params = array();
    $params["customer_guid"] = $customer_guid;
    $hasContacts = $customers->customerHasContacts($params);
    if ($hasContacts["hasContacts"] == "1") {
        $MainPage->Attributes->SetValue("showalert_contacterror", "hide");
    } else {
        $MainPage->Attributes->SetValue("showalert_contacterror", "show");
    }
    //Setting up alerts to let user know the license may need support
    $license_guid = trim(CCGetFromGet("license_guid", ""));
    if (strlen($license_guid) > 0) {
        $products = new Alm\Products();
        $params = array();
        $params["license_guid"] = $license_guid;
        $hasSupport = $products->licenseHasSupport($params);
        if ($hasSupport["hasSupport"] == "1") {
            $MainPage->Attributes->SetValue("showalert_addsupport", "hide");
        } else {
            $MainPage->Attributes->SetValue("showalert_addsupport", "show");
        }
    } else {
        $MainPage->Attributes->SetValue("showalert_addsupport", "hide");
    }
    //Check if session variable showalert_addsupport has a show value
    $showalert_addsupport = CCGetSession("showalert_addsupport", "");
    if ($showalert_addsupport == "show") {
        CCSetSession("showalert_addsupport", "hide");
        $MainPage->Attributes->SetValue("showalert_addsupport", $showalert);
    }
    //Procesing file uploading
    $hidlicense_guid = trim(CCGetFromPost("hidlicense_guid", ""));
    if (!empty($_FILES) && strlen($hidlicense_guid) > 0) {
        $params = array();
        $params["license_guid"] = $hidlicense_guid;
        $products = new \Alm\Products();
        $products->uploadLicenseFile($_FILES, $params);
        //Finishing script execution for file uploads because its asyncronous
        exit;
    }
    $license_guid = trim(CCGetFromGet("license_guid", ""));
    $licensefile_guid = trim(CCGetFromGet("licensefile_guid", ""));
    $o = trim(CCGetFromGet("o", ""));
    //Delete licensing operation
    if (strlen($licensefile_guid) > 0 && $o == "dellicense") {
        $params = array();
        $params["licensefile_guid"] = $licensefile_guid;
        $products = new \Alm\Products();
        $products->deleteLicenseFileByGuid($params);
        $querystring = CCGetQueryString("QueryString", array("licensefile_guid", "o"));
        global $FileName;
        $urlRedirect = $FileName . "?{$querystring}";
        header("Location: {$urlRedirect}");
    }
    //Delete full licensing operation
    if (strlen($license_guid) > 0 && $o == "delfulllicense") {
        $params = array();
        $params["license_guid"] = $license_guid;
        $products = new \Alm\Products();
        $products->deleteFullLicenseByGuid($params);
        $querystring = CCGetQueryString("QueryString", array("license_guid", "o"));
        global $FileName;
        $urlRedirect = $FileName . "?{$querystring}";
        header("Location: {$urlRedirect}");
    }
    if (strlen($license_guid) > 0) {
        //License files grid
        $params = array();
        $params["license_guid"] = $license_guid;
        $products = new \Alm\Products();
        $licenseFiles = $products->getLicenseFiles($params);
        $licenseFiles = $licenseFiles["licensefiles"];
        $querystring = CCGetQueryString("QueryString", array("o", "licensefile_guid", "tab"));
        foreach ($licenseFiles as $licenseFile) {
            $licensefile_guid = $licenseFile["guid"];
            $linkdelete = "";
            if (CCGetGroupID() == "4") {
                //Moved linkdelete to code because issues displaying panels inside custom template blocks
                $linkdelete = "<a href='licensing_customers.php?o=dellicense&licensefile_guid={$licensefile_guid}&tab=licenselist&{$querystring}' class='dellicense' ><li class='icon-trash bigger-150 red'></li></a>";
            }
            $Tpl->setvar("linkdelete", $linkdelete);
            $Tpl->setvar("licensefile_guid", $licensefile_guid);
            $Tpl->setvar("getparams", "&" . $querystring);
            $Tpl->Parse("licensefile_list", true);
        }
    }
    // -------------------------
    //End Custom Code
    //Close licensing_customerscontent_BeforeShow @1-0B488567
    return $licensing_customerscontent_BeforeShow;
}
コード例 #23
0
<?php

$title = "Кабинет терминального клиента";
$tpl->Assign('h1', $title);
$GLOBALS['IERA_LINKS'] = array();
$GLOBALS['IERA_LINKS'][1]['title'] = $title;
$GLOBALS['IERA_LINKS'][1]['url'] = _base_url . '/cabinet/';
$no_tpl = '';
$Customer = new Customers();
$Customer->SetFieldsById($User->fields['id_user']);
$fields = array('date', 'id_order', 'status');
$f_assoc = array('date' => 'o.creation_date', 'id_order' => 'o.id_order', 'status' => 'o.id_order_status');
$orderby = "o.id_order desc";
// Список заказов
$orders = $Customer->GetOrdersTerminal($orderby);
if (!$no_tpl) {
    $tpl->Assign('orders', $orders);
}
$Order = new Orders();
$order_statuses = $Order->GetStatuses();
if (!$no_tpl) {
    $tpl->Assign('order_statuses', $order_statuses);
}
if (!$no_tpl) {
    $parsed_res = array('issuccess' => TRUE, 'html' => $tpl->Parse($GLOBALS['PATH_tpl'] . 'cp_terminal_cab.tpl'));
}
コード例 #24
0
ファイル: Login.class.php プロジェクト: mozdial/Directory
 /**
  * 	Load listing
  */
 public function LoadListings()
 {
     // prepare allowed plans
     $customer_plans = Customers::GetListingsForCustomer(Session::Get('session_account_id'));
     Session::Set('session_customer_plans', $customer_plans);
 }
コード例 #25
0
ファイル: cp_cab_anonim.php プロジェクト: Arikito/webking.xt
<?php

$GLOBALS['IERA_LINKS'][] = array('title' => $header, 'url' => _base_url . '/cabinet/');
$tpl->Assign('header', $header);
$no_tpl = '';
$Customer = new Customers();
$Customer->SetFieldsById($User->fields['id_user']);
// Список заказов
$orders = $Customer->GetOrders_demo();
if (!$no_tpl) {
    $tpl->Assign('orders', $orders);
}
$Order = new Orders();
$order_statuses = $Order->GetStatuses();
if (!$no_tpl) {
    $tpl->Assign('order_statuses', $order_statuses);
}
if (!$no_tpl) {
    $parsed_res = array('issuccess' => true, 'html' => $tpl->Parse($GLOBALS['PATH_tpl'] . 'cp_anonim_cab.tpl'));
}
コード例 #26
0
<?php

// ---- center ----
unset($parsed_res);
$Customer = new Customers();
$header[id_stroka] = "№ строки";
$header[id_zakaz] = "№ заказа";
$header[art_tovar] = "Артикул товара";
$header[n_opt] = "Количество по опту";
$header[n_mopt] = "Количество";
$header[zena_opt] = "ID поставщика";
$header[zena_mopt] = "Цена по сайту";
$header[zena__zak_opt] = "Цена закупки по опту";
$header[zena__zak_mopt] = "Цена закупки";
$header[n_opt_fakt] = "Количество факт по опту";
$header[n_mopt_fakt] = "Количество факт";
$header[zena_mopt5000] = "Цена 5000 грн";
$header[filial] = "Код филиала";
$tpl->Assign('header', $header);
// Список заказов+
$order2 = "";
//print_r($date3);
$tovar = $Customer->GetTovar_export($order2);
//print_r($tovar);
$tpl->Assign('tovar', $tovar);
echo $tpl->Parse($GLOBALS['PATH_tpl'] . 'cp_manager_tovar_export.tpl');
exit(0);
// ---- right ----
?>

コード例 #27
0
ファイル: Main.php プロジェクト: kokkez/shineisp
 /**
  * Create a Nic-Handle for the client 
  * 
  * Executes the 'login' command on Ascio's servers, to retrive the session variable
  * for execute the commands.
  * 
  *   Parameters
  *   ===========
  *   string session : the session id
  *   string name : the contact name
  *   string firstname : the contact firstname
  *   string sex : the contact sex (M/F)
  *   string password : the contact password
  *   string email : the contact email
  *   string phone : the contact phone number (international format, ex: +33.899701761)
  *   string fax : the contact fax number
  *   string address : the contact address
  *   string city : the contact city
  *   string area : the contact area
  *   string zip : the contact zip code
  *   string country : the contact country (be|fr|pl|es|lu|ch|de|...)
  *   string language : the contact language (fr|en|pl|es|de)
  *   boolean isOwner : is it an owner nic ? default false
  *   string legalform : the contact legalform (corporation|individual|association|other)
  *   string organisation : organisation name
  *   string legalName : the contact legalname
  *   string legalNumber : the contact legalnumber (SIRET/SIREN/...)
  *   string vat : the contact vat
  *   string birthDay : the contact birthDay
  *   string birthCity : the contact birth city
  *   string nationalIdentificationNumber : the contact fiscal code or company vat
  *   string companyNationalIdentificationNumber : the contact vat
  *   string corporationType : the contact vat (s.a.s.|s.n.c.|s.r.l.|s.p.a.|s.a.p.a.|s.c.a.r.l.|individuale)
  * 
  * 
  * @param      integer      $customerID		Code identifier
  * @return     string       $nicHandle		the new contact handle id
  * @access     private
  */
 private function createNicHandle($customerID)
 {
     $soap = $this->Connect();
     if (!empty($this->session)) {
         $fields = "c.customer_id as customer_id, c.company as company, c.firstname as firstname, c.lastname as lastname, c.gender as gender, c.email as email, c.password as password, c.birthdate as birthdate, c.birthplace as birthplace, c.taxpayernumber as taxpayernumber, c.vat as vat, c.note as note,  a.address as address, a.code as code, a.city as city, a.area as area, ct.name as country, ct.code as countrycode, cts.type_id as type_id, cts.name as companytype, l.legalform_id as legalform_id, l.name as legalform, s.status_id as status_id, s.status as status, cn.contact as contact";
         $customer = Customers::getAllInfo($customerID, $fields);
         return $soap->nicCreateIT($this->session['id'], $customer['lastname'], $customer['firstname'], $customer['gender'], Shineisp_Commons_Utilities::GenerateRandomString(), $customer['email'], $customer['contact'], null, $customer['address'], $customer['city'], $customer['area'], $customer['code'], strtolower($customer['countrycode']), "en", true, $customer['legalform'], $customer['company'], $customer['firstname'] . " " . $customer['lastname'], null, $customer['vat'], Shineisp_Commons_Utilities::formatDateOut($customer['birthdate']), $customer['birthplace'], $customer['taxpayernumber'], $customer['vat'], $customer['companytype']);
         // Corporation Type
     }
     return false;
 }
コード例 #28
0
* @license http://www.gnu.org/licenses/
*/
// *** Make sure the file isn't accessed directly
defined('APPHP_EXEC') or die('Restricted Access');
//--------------------------------------------------------------------------
$act = isset($_POST['act']) ? prepare_input($_POST['act']) : '';
$password_sent = (bool) Session::Get('activation_email_resent');
$email = isset($_POST['email']) ? prepare_input($_POST['email']) : '';
$msg = '';
if ($act == 'resend') {
    if (!$password_sent) {
        if (Customers::Reactivate($email)) {
            $msg = draw_success_message(str_replace('_EMAIL_', $email, _ACTIVATION_EMAIL_WAS_SENT), false);
            Session::Set('activation_email_resent', true);
        } else {
            $msg = draw_important_message(Customers::GetStaticError(), false);
        }
    } else {
        $msg = draw_message(_ACTIVATION_EMAIL_ALREADY_SENT, false);
    }
}
// Draw title bar
draw_title_bar(_RESEND_ACTIVATION_EMAIL);
// Check if customer is logged in
if (!$objLogin->IsLoggedIn() && ModulesSettings::Get('customers', 'allow_registration') == 'yes') {
    echo $msg;
    ?>
	<div class="pages_contents">
	<form action="index.php?customer=resend_activation" method="post">
		<?php 
    draw_hidden_field('act', 'resend');
コード例 #29
0
if (isset($_POST['id_order']) && !empty($_POST['id_order'])) {
    $id_order = intval($_POST['id_order']);
}
$Order = new Orders();
if (isset($_POST['change_client'])) {
    $Order->SetNote_diler($_POST['order'], $_POST['client']);
}
if (isset($_POST['change_status'])) {
    $Order->UpdateStatus($_POST['order'], $_POST['status'], isset($_POST['target_date']) ? $_POST['target_date'] : null);
}
if (isset($_POST['target'])) {
    $target = $_POST['target'];
} else {
    $target = 100;
}
$Customer = new Customers();
$Customer->SetFieldsById($Users->fields['id_user']);
$tpl->Assign('current_customer', $Customer->fields);
$klients = $Customer->SetList($Users->fields['email']);
$tpl->Assign('klient', $klients);
$Contragent->SetFieldsById($Users->fields['id_user']);
$tpl->Assign("contragent", $Contragent->fields);
$contrdates = $Contragent->SetCurrentWeek();
$DaysOfWeek = array("Вс", "Пн", "Вт", "Ср", "Чт", "Пт", "Сб");
$ts = time();
for ($ii = 0; $ii <= $GLOBALS['CONFIG']['order_day_end'] + 7; $ii++) {
    $ts_tmp = $ts + 86400 * $ii;
    $arr = getdate($ts_tmp);
    $dates[date("d.m.Y", $ts_tmp)] = array('d_word' => $DaysOfWeek[$arr['wday']], 'd' => date("Y_m_d", $ts_tmp));
    if ($arr['wday'] == 0 || $arr['wday'] == 6) {
        $dates[date("d.m.Y", $ts_tmp)]['red'] = true;
コード例 #30
0
<?php

// ---- center ----
unset($parsed_res);
//$Page = new Page();
//$Page->PagesList();
//$tpl->Assign('list_menu', $Page->list);
//$GLOBALS['IERA_LINKS'] = array();
//$GLOBALS['IERA_LINKS'][0]['title'] = "Каталог";
//$GLOBALS['IERA_LINKS'][0]['url'] = $GLOBALS['URL_base'].'demo_order/';
// $no_tpl='';
$Customer = new Customers();
$header[date] = "Дата заказа";
$header[nomer] = "№ заказа";
$header[id_clienta] = "ID клиен";
$header[id_marsr] = "ID на маршрут";
$header[nakladna_cust] = "Накладная покупателя";
$header[nakladna_cont] = "Накладная контрагента";
$header[nakladna_fakt] = "Накладная факт";
$header[primec] = "Прим";
$header[klient] = "Контактное лицо";
$header[telef] = "Телефон клиентов";
$header[adres] = "Адрес доставки";
$header[mail] = "E-mail";
$header[sposob] = "Способ доставки";
$header[slusba] = "Служба доставки";
$header[otpusk] = "Сумма заказа";
$header[zakupka] = "Сумма закупки";
$header[kontragent] = "Контрагент";
$header[filial] = "Код филиала";
$tpl->Assign('header', $header);