Your IP : 216.73.216.40


Current Path : /var/www/html/mmishra/erp/views/
Upload File :
Current File : /var/www/html/mmishra/erp/views/test_view.php

<?php
//if (!class_exists($erpView)) {
// face detector class
	require_once __DIR__."/erp_view.php";
//}

class testView extends erpView {
    var $controller;
    var $model;
    
    //define(SEPARATOR, ":|:");

    public function __construct($controller, $model) {
               
		$this->controller 				= $controller;	// instantiate controller
        $this->model 					= $model;		// instantiate model
    }

    public function __destruct() {
		// throw last executed sql statement
		if ($this->model->sqlStmt) print("<hr>" .$this->model->sqlStmt);
		
        if (!in_array($this->controller->menu, ['booking', 'photoshop']) && !in_array($this->controller->action, ['print', 'show', 'docUpload'])) {
			print(":|:" .$this->erpMenus(). ":|:" .$this->erpXupdate(). ":|:" .$this->erpError(). ":|:" .$this->erpClock(). ":|:" .$this->erpLogin());
		}
	}
	
   
    public function testHello($action, $rowID) {
		$app					= $this->controller->app;
		$menu					= $this->controller->menu;
		
		$rowID	 				= $this->controller->manageHello($action, $rowID);// initiate controller action 
		$ro 					= $this->controller->editLock;							// ensure default edit lock

        $hellos 				= $this->model->listHellos();
        //$hostel 				= $this->model->getHostel($hostelID);					// get record
       	$toolbar				= $this->erpToolbar('');
		
		$str = $this->pageHeader($findbar, $toolbar);

		$str .= "<h1>Hello World</h1>
			Name: <input type='text' name='myname' value='' size='50' $ro>

		";
		$str .= $this->pageFooter('', $toolbar);
		
		$str .= "<table class='report'>";
		foreach ($hellos as $hello) {
			$i++;
			$str .= "<tr><td>$i</td><td>" .$hello['myName']. "</td></tr>";
		}
        $str .= "</table>";
		
		return $str;
    }

 
}
?>